summaryrefslogtreecommitdiff
path: root/source3/smbd/ipc.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/smbd/ipc.c')
-rw-r--r--source3/smbd/ipc.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/source3/smbd/ipc.c b/source3/smbd/ipc.c
index 3cc9aca99e..1418d3444f 100644
--- a/source3/smbd/ipc.c
+++ b/source3/smbd/ipc.c
@@ -36,6 +36,7 @@ extern fstring local_machine;
#define NERR_notsupported 50
extern int smb_read_error;
+extern uint32 global_client_caps;
/*******************************************************************
copies parameters and data, as needed, into the smb buffer
@@ -102,8 +103,14 @@ void send_trans_reply(char *outbuf,
if (buffer_too_large)
{
/* issue a buffer size warning. on a DCE/RPC pipe, expect an SMBreadX... */
- SIVAL(outbuf, smb_flg2, SVAL(outbuf, smb_flg2) | FLAGS2_32_BIT_ERROR_CODES);
- SIVAL(outbuf, smb_rcls, 0x80000000 | STATUS_BUFFER_OVERFLOW);
+ if (!(global_client_caps & (CAP_NT_SMBS | CAP_STATUS32 ))) {
+ /* Win9x version. */
+ SSVAL(outbuf, smb_err, ERRmoredata);
+ SCVAL(outbuf, smb_rcls, ERRDOS);
+ } else {
+ SIVAL(outbuf, smb_flg2, SVAL(outbuf, smb_flg2) | FLAGS2_32_BIT_ERROR_CODES);
+ SIVAL(outbuf, smb_rcls, 0x80000000 | STATUS_BUFFER_OVERFLOW);
+ }
}
copy_trans_params_and_data(outbuf, align,