Skip to content
Snippets Groups Projects
Commit 5db4eb95 authored by rswindell's avatar rswindell
Browse files

Bugfix: bounced messages created a new header record pointing to the

original messages's data, but it didn't increment the data allocation counter
for the data blocks. Now uses the new smb_incmsg() function to increment
the allocation counters, so if the original message is free'd, the data blocks
will not be prematurely reused.
parent 70211388
No related branches found
No related tags found
No related merge requests found
......@@ -2440,6 +2440,11 @@ BOOL bounce(smb_t* smb, smbmsg_t* msg, char* err, BOOL immediate)
if((i=smb_addmsghdr(smb,&newmsg,SMB_SELFPACK))!=0)
lprintf("0000 !BOUNCE ERROR %d (%s) adding message header"
,i,smb->last_error);
else {
if((i=smb_incmsg(smb,&newmsg))!=0)
lprintf("0000 !BOUNCE ERROR %d (%s) incrementing data allocation units"
,i,smb->last_error);
}
newmsg.dfield=NULL; /* Don't double-free the data fields */
newmsg.hdr.total_dfields=0;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment