Hi,

On Mon Jan 07, 2013 at 19:23:14 +0000, Sascha Silbe wrote:
> Package: minicom
> Version: 2.6.1-1
> Severity: normal
> 
> Dear Maintainer,
> 
> 123456789012345678901234567890123456789012345678901234567890123456789012
> minicom cuts off the name of the serial device file at the first colon,
> so by-path persistent serial device names can't be used; at least not
> for USB serial adapters.
> 
> I'm using several el-cheapo USB serial adapters that have no serial
> number on the same host, so the only way to distinguish them reliably is
> to identify them by the physical port of the USB hub they're plugged
> into, which is exactly what the /dev/serial/by-path/*usb* symlinks do.
> 
> To reproduce:
> 
> 1. Plug in a USB serial adapter
> 2. Check /dev/serial/by-path for the device name, e.g.
>    /dev/serial/by-path/platform-orion-ehci.0-usb-0:1.1:1.0-port0
> 3. Create a new minicom configuration file:
>    minicom -s P1
> 4. In "Serial port setup", enter the device name from 2. in
>    A - Serial Device.
> 5. Choose "Exit" (not "Exit from Minicom")
> 6. The following error message will appear:
>    minicom: cannot open /dev/serial/by-path/platform-orion-ehci.0-usb-0: No 
> such file or directory
> 
> 
> As you can see, minicom cuts off the device name after the first
> colon. Shortening the path (for testing purposes) or adding a backslash
> for to escape the colon shows the same result.
> 
> minicom(1) mentions space, comma and semicolon as special characters in
> the device name, but not colon.

Thanks for the report. I have fixed this in upstream with the following
patch. This changes old behaviour but I favor support for this kind of
paths more than the old feature of path delimiters.

--- a/src/util.c        Fri Dec 21 22:16:13 2012 +0100
+++ b/src/util.c        Wed Jan 09 23:14:03 2013 +0100
@@ -175,7 +175,7 @@
 }
 
 /*
- * Get next port from a space-, comma-, colon-, or semi-colon-separated
+ * Get next port from a space-, comma-, or semi-colon-separated
  * list (we're easy :-)) in a PARS_VAL_LEN length string.
  *
  * Returns NULL pointer on end-of-list.
@@ -197,10 +197,10 @@
     strncpy(loc_port_list, port_list, PARS_VAL_LEN);
     loc_port_list[PARS_VAL_LEN - 1] = 0;
     ep = &loc_port_list[strlen(loc_port_list)];
-    sp = strtok(loc_port_list, ":;, ");
+    sp = strtok(loc_port_list, ";, ");
   }
   else if (*sp != 0)
-    sp = strtok(sp, ":;, ");
+    sp = strtok(sp, ";, ");
   else
     sp = NULL;



Adam
-- 
Adam                 a...@os.inf.tu-dresden.de
  Lackorzynski         http://os.inf.tu-dresden.de/~adam/


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to