diff options
Diffstat (limited to 'radix.c')
-rw-r--r-- | radix.c | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -69,7 +69,7 @@ typedef unsigned short my_u_short; | |||
69 | 69 | ||
70 | 70 | ||
71 | int | 71 | int |
72 | creds_to_radix(CREDENTIALS *creds, unsigned char *buf) | 72 | creds_to_radix(CREDENTIALS *creds, unsigned char *buf, size_t buflen) |
73 | { | 73 | { |
74 | char *p, *s; | 74 | char *p, *s; |
75 | int len; | 75 | int len; |
@@ -119,7 +119,7 @@ creds_to_radix(CREDENTIALS *creds, unsigned char *buf) | |||
119 | p += creds->ticket_st.length; | 119 | p += creds->ticket_st.length; |
120 | len = p - temp; | 120 | len = p - temp; |
121 | 121 | ||
122 | return (uuencode((unsigned char *)temp, len, (char *)buf)); | 122 | return (uuencode((unsigned char *)temp, len, (char *)buf, buflen)); |
123 | } | 123 | } |
124 | 124 | ||
125 | int | 125 | int |
@@ -131,7 +131,8 @@ radix_to_creds(const char *buf, CREDENTIALS *creds) | |||
131 | char version; | 131 | char version; |
132 | char temp[2048]; | 132 | char temp[2048]; |
133 | 133 | ||
134 | if (!(len = uudecode(buf, (unsigned char *)temp, sizeof(temp)))) | 134 | len = uudecode(buf, (unsigned char *)temp, sizeof(temp)); |
135 | if (len < 0) | ||
135 | return 0; | 136 | return 0; |
136 | 137 | ||
137 | p = temp; | 138 | p = temp; |