# HG changeset patch # User Eric Blake # Date 1293663195 25200 # Node ID 602afdb74dc3ead4024cd0874b6e04c8486b2e9c # Parent b968dd130aedb6af8a5e29cea25a6b43bef82b0f mountlist: tweak previous commit * lib/mountlist.c (me_remote): Guarantee trailing backslash. Reported by Paul Eggert. Signed-off-by: Eric Blake diff --git a/ChangeLog b/ChangeLog --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2010-12-29 Eric Blake + mountlist: tweak previous commit + * lib/mountlist.c (me_remote): Guarantee trailing backslash. + Reported by Paul Eggert. + mountlist: fix local drive detection on cygwin * lib/mountlist.c (ME_REMOTE) [__CYGWIN__]: Provide implementation that works for cygwin. diff --git a/lib/mountlist.c b/lib/mountlist.c --- a/lib/mountlist.c +++ b/lib/mountlist.c @@ -166,7 +166,8 @@ { if (fs_name[0] && fs_name[1] == ':') { - char const drive[3] = { fs_name[0], ':', '\0' }; + char drive[4]; + sprintf (drive, "%c:\\", fs_name[0]); switch (GetDriveType (drive)) { case DRIVE_REMOVABLE: