This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

mkpasswd: problem with (UNC-)paths including dollar sign


hi

mkpasswd has a problem with special paths like \\server\user$
it seems that windows quotes the $ with $ (so it gives $$)

below is a patch which changes the behaviour of mkpasswd, but it probably has to be fixed elsewhere
(it does of course only work with mkpasswd -m)

$ diff -up mkpasswd.c.orig mkpasswd.c
--- mkpasswd.c.orig     Mon Jul  2 11:35:07 2001
+++ mkpasswd.c  Mon Jul  2 12:19:07 2001
@@ -83,6 +83,11 @@ psx_dir (char *in, char *out)
     {
       if (*in == '\\')
        *out = '/';
+      else if (*in == '$')
+        if (*(in+1) == '$')
+          *out = '$';
+        else
+          out--;
       else
        *out = *in;
       in++;



-- 
thanks
ronny


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]