diff options
-rw-r--r-- | source3/smbd/lanman.c | 2 | ||||
-rw-r--r-- | source3/smbd/uid.c | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/source3/smbd/lanman.c b/source3/smbd/lanman.c index 0db1af6032..d8c1cc6f60 100644 --- a/source3/smbd/lanman.c +++ b/source3/smbd/lanman.c @@ -72,7 +72,7 @@ static int CopyExpanded(connection_struct *conn, StrnCpy(buf,src,sizeof(buf)/2); pstring_sub(buf,"%S",lp_servicename(snum)); standard_sub_conn(conn,buf,sizeof(buf)); - l = push_ascii(*dst,buf,*n-1, STR_TERMINATE); + l = push_ascii(*dst,buf,*n, STR_TERMINATE); (*dst) += l; (*n) -= l; return l; diff --git a/source3/smbd/uid.c b/source3/smbd/uid.c index 9a38d6e9e2..48b9768358 100644 --- a/source3/smbd/uid.c +++ b/source3/smbd/uid.c @@ -49,6 +49,8 @@ BOOL change_to_guest(void) current_user.conn = NULL; current_user.vuid = UID_FIELD_INVALID; + passwd_free(&pass); + return True; } |