diff options
author | Volker Lendecke <vlendec@samba.org> | 2004-03-30 08:11:59 +0000 |
---|---|---|
committer | Volker Lendecke <vlendec@samba.org> | 2004-03-30 08:11:59 +0000 |
commit | 6bc88d91e569541e4d4a2147e28439db96d02bd6 (patch) | |
tree | a308c95eb74c1c68b0cffa15ca44cd2475a71e1a /source/nsswitch | |
parent | 8037750df568e6b51b2b0cba9192468110470388 (diff) | |
download | samba-6bc88d91e569541e4d4a2147e28439db96d02bd6.tar.gz samba-6bc88d91e569541e4d4a2147e28439db96d02bd6.tar.xz samba-6bc88d91e569541e4d4a2147e28439db96d02bd6.zip |
Merge a fix from HEAD to 3_0
Volker
Diffstat (limited to 'source/nsswitch')
-rw-r--r-- | source/nsswitch/winbindd_wins.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source/nsswitch/winbindd_wins.c b/source/nsswitch/winbindd_wins.c index bc982d00443..a1eef159c0a 100644 --- a/source/nsswitch/winbindd_wins.c +++ b/source/nsswitch/winbindd_wins.c @@ -201,7 +201,10 @@ enum winbindd_result winbindd_wins_byname(struct winbindd_cli_state *state) } if (i != 0) { /* Clear out the newline character */ - response[strlen(response)-1] = ' '; + /* But only if there is something in there, + otherwise we clobber something in the stack */ + if (strlen(response)) + response[strlen(response)-1] = ' '; } fstrcat(response,addr); fstrcat(response,"\t"); |