updated the 3.0 branch from the head branch - ready for alpha18
[samba.git] / source3 / libads / sasl.c
index eb29c71fce2ebcb5cd2f38bc31e90df0f3d5fbee..1b55453cac9f2d780715a177c26eca74c37983b2 100644 (file)
@@ -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;