diff options
author | Jim McDonough <jmcd@samba.org> | 2002-07-08 20:46:54 +0000 |
---|---|---|
committer | Jim McDonough <jmcd@samba.org> | 2002-07-08 20:46:54 +0000 |
commit | 83060558c98051fd96ed831e22e218497ba5dfd7 (patch) | |
tree | 98c21e332fe2b94569349321295a1fad1ec1591f /source3/libads | |
parent | 18742edd2acc4848bacf2af6008bf9fea5f82f6b (diff) | |
download | samba-83060558c98051fd96ed831e22e218497ba5dfd7.tar.gz samba-83060558c98051fd96ed831e22e218497ba5dfd7.tar.bz2 samba-83060558c98051fd96ed831e22e218497ba5dfd7.zip |
Fix length in snprintf invocation to account for "dn:" in sasl gssapi bind.
Also remove unused line which incremented pointer by the wrong length anyway.
Provided by Anthony Liguori (aliguori@us.ibm.com).
(This used to be commit 47b7a3e0f3d101a3bcffd33db6ef4c0672b57ae0)
Diffstat (limited to 'source3/libads')
-rw-r--r-- | source3/libads/sasl.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/source3/libads/sasl.c b/source3/libads/sasl.c index eb29c71fce..1b55453cac 100644 --- a/source3/libads/sasl.c +++ b/source3/libads/sasl.c @@ -171,8 +171,7 @@ ADS_STATUS ads_sasl_gssapi_bind(ADS_STRUCT *ads) *p++ = max_msg_size>>16; *p++ = max_msg_size>>8; *p++ = max_msg_size; - snprintf(p, strlen(ads->bind_path)+1, "dn:%s", ads->bind_path); - p += strlen(ads->bind_path); + snprintf(p, strlen(ads->bind_path)+4, "dn:%s", ads->bind_path); output_token.length = strlen(ads->bind_path) + 8; |