diff options
Diffstat (limited to 'sys-apps/shadow/files')
-rw-r--r-- | sys-apps/shadow/files/shadow-4.0.15-uclibc-missing-l64a.patch | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/sys-apps/shadow/files/shadow-4.0.15-uclibc-missing-l64a.patch b/sys-apps/shadow/files/shadow-4.0.15-uclibc-missing-l64a.patch new file mode 100644 index 000000000000..3adf1b8f90e8 --- /dev/null +++ b/sys-apps/shadow/files/shadow-4.0.15-uclibc-missing-l64a.patch @@ -0,0 +1,37 @@ +uClibc svn has l64a() support in it, but not uClibc 0.9.28 release + +--- shadow-4.0.15/libmisc/salt.c ++++ shadow-4.0.15/libmisc/salt.c +@@ -14,6 +14,32 @@ + #include "prototypes.h" + #include "defines.h" + #include "getdef.h" ++ ++#ifndef HAVE_A64L ++ ++/* ++ * l64a - convert a long to a string of radix 64 characters ++ */ ++ ++char * ++l64a(long l) ++{ ++ static char buf[8]; ++ int i = 0; ++ ++ if (l < 0L) ++ return ((char *) 0); ++ ++ do { ++ buf[i++] = i64c ((int) (l % 64)); ++ buf[i] = '\0'; ++ } while (l /= 64L, l > 0 && i < 6); ++ ++ return (buf); ++} ++ ++#endif /* !HAVE_A64L */ ++ + /* + * Generate 8 base64 ASCII characters of random salt. If MD5_CRYPT_ENAB + * in /etc/login.defs is "yes", the salt string will be prefixed by "$1$" |