summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/reply.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c
index 8b6a164a66..2421e2ffd9 100644
--- a/source3/smbd/reply.c
+++ b/source3/smbd/reply.c
@@ -529,7 +529,7 @@ int reply_tcon_and_X(connection_struct *conn, char *inbuf,char *outbuf,int lengt
}
p += srvstr_pull_talloc(ctx, inbuf, SVAL(inbuf, smb_flg2), &client_devicetype, p,
- 6, STR_ASCII);
+ MIN(6,smb_bufrem(inbuf, p)), STR_ASCII);
if (client_devicetype == NULL) {
TALLOC_FREE(ctx);