diff options
author | Jeremy Allison <jra@samba.org> | 2006-08-14 16:53:14 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 11:38:38 -0500 |
commit | 6fd4813ece5e03c92334acfa7e168cd7d0248919 (patch) | |
tree | 8abb94bdb18825437feb20e67098cd6afe538415 /source3/smbd/error.c | |
parent | b757699e8b14fb0d5780e2513ffe64c087f5871d (diff) | |
download | samba-6fd4813ece5e03c92334acfa7e168cd7d0248919.tar.gz samba-6fd4813ece5e03c92334acfa7e168cd7d0248919.tar.bz2 samba-6fd4813ece5e03c92334acfa7e168cd7d0248919.zip |
r17541: When returning a trans2 request, if the "max data
bytes returned" is less than the amount we want
to send, return what we can and set STATUS_BUFFER_OVERFLOW
(doserror ERRDOS,ERRbufferoverflow). Required by
OS/2 to handle EA's that are too large. It's hard
to test this in Samba4 smbtorture as the max data
bytes returned is hard coded at 0xffff (as it is
in the Samba3 client libraries also). I used a
custom version of Samba4 smbtorture to test this
out. Might add a "max data bytes" param to make
this testable in the build farm. Confirmed by
"Guenter Kukkukk (sambaos2)" <sambaos2@kukkukk.com>
and Andreas Taegener <atsamba11@eideltown.de>
that this fixes the issue.
Jeremy.
(This used to be commit ff2f1202b76991a404dae8df17c36f8135c8dc51)
Diffstat (limited to 'source3/smbd/error.c')
-rw-r--r-- | source3/smbd/error.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/source3/smbd/error.c b/source3/smbd/error.c index 409781eaa9..0860b7d1d9 100644 --- a/source3/smbd/error.c +++ b/source3/smbd/error.c @@ -81,9 +81,8 @@ BOOL use_nt_status(void) If the override errors are set they take precedence over any passed in values. ****************************************************************************/ -int error_packet(char *outbuf, uint8 eclass, uint32 ecode, NTSTATUS ntstatus, int line, const char *file) +void error_packet_set(char *outbuf, uint8 eclass, uint32 ecode, NTSTATUS ntstatus, int line, const char *file) { - int outsize = set_message(outbuf,0,0,True); BOOL force_nt_status = False; BOOL force_dos_status = False; @@ -125,6 +124,11 @@ int error_packet(char *outbuf, uint8 eclass, uint32 ecode, NTSTATUS ntstatus, in eclass, ecode)); } +} +int error_packet(char *outbuf, uint8 eclass, uint32 ecode, NTSTATUS ntstatus, int line, const char *file) +{ + int outsize = set_message(outbuf,0,0,True); + error_packet_set(outbuf, eclass, ecode, ntstatus, line, file); return outsize; } |