1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-22 06:02:11 +02:00

Bug 509118. Extend regexp to detect devices in /dev for Linux.

Change-Id: I1dfcca8f34019a210702473afb946b2a76cb37d7
Signed-off-by: Zoltan Adasz <adanrg@gmail.com>
This commit is contained in:
Zoltan Adasz 2017-03-23 20:10:52 +01:00 committed by Gerrit Code Review @ Eclipse.org
parent a66ccee4f0
commit 4572eb75f0

View file

@ -228,7 +228,7 @@ public class SerialPort {
if (osName.equals("Mac OS X")) { //$NON-NLS-1$
return listDevs(Pattern.compile("cu\\..*")); //$NON-NLS-1$
} else if (osName.equals("Linux")) { //$NON-NLS-1$
return listDevs(Pattern.compile("ttyUSB.*")); //$NON-NLS-1$
return listDevs(Pattern.compile("(ttyUSB|ttyACM).*")); //$NON-NLS-1$
} else if (osName.startsWith("Windows")) { //$NON-NLS-1$
List<String> ports = new ArrayList<>();
int i = 0;