]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Support new USB serial filenames on Linux (STR #2061)
authormike <mike@7a7537e8-13f0-0310-91df-b6672ffda945>
Fri, 27 Oct 2006 16:44:19 +0000 (16:44 +0000)
committermike <mike@7a7537e8-13f0-0310-91df-b6672ffda945>
Fri, 27 Oct 2006 16:44:19 +0000 (16:44 +0000)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@6066 7a7537e8-13f0-0310-91df-b6672ffda945

CHANGES-1.2.txt
backend/serial.c

index 630532c9f5beec0708741484c37bbd43c4b68794..278a5fe1125946f6079e8ba30a77edd5a08f0f83 100644 (file)
@@ -3,6 +3,8 @@ CHANGES-1.2.txt
 
 CHANGES IN CUPS V1.2.6
 
+       - The serial backend did not support the new USB serial
+         filenames on Linux (STR #2061)
        - The parallel backend did not support bidirectional I/O
          properly (STR #2056)
        - The network backends now log the numeric address that
index 0e613b49057fb652e5474077bbf7001ccb3b11db..650fda8d200f3583be918b129c42dddf588ee064 100644 (file)
@@ -778,6 +778,14 @@ list_devices(void)
       printf("serial serial:%s?baud=230400 \"Unknown\" \"USB Serial Port #%d\"\n",
              device, i + 1);
     }
+
+    sprintf(device, "/dev/ttyUSB%d", i);
+    if ((fd = open(device, O_WRONLY | O_NOCTTY | O_NDELAY)) >= 0)
+    {
+      close(fd);
+      printf("serial serial:%s?baud=230400 \"Unknown\" \"USB Serial Port #%d\"\n",
+             device, i + 1);
+    }
   }
 
   for (i = 0; i < 64; i ++)