ref: d52e35055d189e18104fdf1b5891acc10df6a3df
parent: 3bb0b9f4ea46431189b2cae2a6c2887f786d822a
author: cinap_lenrek <[email protected]>
date: Fri Aug 28 04:41:16 EDT 2015
libauthsrv: fix _asgetresp() for passwd
--- a/sys/src/libauthsrv/_asgetresp.c
+++ b/sys/src/libauthsrv/_asgetresp.c
@@ -8,11 +8,14 @@
char tbuf[TICKETLEN+AUTHENTLEN];
int n, m;
+ m = TICKETLEN;
memset(t, 0, sizeof(Ticket));
- if(a != nil)
+ if(a != nil){
+ m += AUTHENTLEN;
memset(a, 0, sizeof(Authenticator));
+ }
- n = _asrdresp(fd, tbuf, sizeof(tbuf));
+ n = _asrdresp(fd, tbuf, m);
if(n <= 0)
return -1;