From aae4d09a121ab50107a8b70969df8dce9c7b6603 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?IOhannes=20m=20zm=C3=B6lnig?= Date: Thu, 26 Sep 2024 17:04:57 +0200 Subject: [PATCH] use 'else' clauses for discussing various OSs --- comport.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/comport.c b/comport.c index a3a5bf2..89ee3c8 100644 --- a/comport.c +++ b/comport.c @@ -1374,17 +1374,14 @@ specify a COM port number greater than 9, use the following syntax: "\\\\.\\COM10". This syntax works for all port numbers and hardware that allows COM port numbers to be specified. */ serial_device_prefix = "\\\\.\\COM"; -#endif /* _WIN32 */ /* for UNIX, this is a glob pattern for matching devices */ -#ifdef __APPLE__ +#elif defined __APPLE__ serial_device_prefix = "/dev/tty.*"; -#endif /* __APPLE__ */ -#ifdef IRIX - serial_device_prefix = "/dev/ttyd*"; -#endif /* IRIX */ -#ifdef __linux__ +#elif defined __linux__ /* serial: ttyS? USB-serial: ttyUSB? USB-CDC: ttyACM? */ serial_device_prefix = "/dev/tty[ASU]*"; +#elif defined IRIX + serial_device_prefix = "/dev/ttyd*"; #endif /* __linux__ */ if(argc > 0) {