Sophie

Sophie

distrib > Mandriva > current > i586 > media > contrib-release-src > by-pkgid > b8a83605ea8c288760ff961eac1fe0b4 > files > 14

gcl-2.6.8.20090701cvs-3mdv2010.1.src.rpm

diff -dur gcl-2.6.8.ORIG/o/unixfsys.c gcl-2.6.8/o/unixfsys.c
--- gcl-2.6.8.ORIG/o/unixfsys.c	2008-12-29 17:42:18.000000000 -0700
+++ gcl-2.6.8/o/unixfsys.c	2008-12-29 17:51:35.000000000 -0700
@@ -214,7 +214,7 @@
     
 #ifndef NO_PWD_H  
   if(namestring->st.st_self[0]=='~')
-    {char name[20];
+    {char name[LOGIN_NAME_MAX];
      int n;
      char *q = namestring->st.st_self;
 #ifndef __STDC__
@@ -224,8 +224,7 @@
 
      struct passwd *pwent;
      int m=0;
-     q=namestring->st.st_self;
-     for (n=0; n< namestring->st.st_fillp; n++)
+     for (n=1; n< namestring->st.st_fillp; n++)
        if (q[n]=='/') break;
      bcopy(q+1,name,n-1);
      name[n-1]= 0;