git.samba.org
/
mat
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
bf35606
)
s3:smbd: pass down smbd_server_connection via smbd_echo_state
author
Stefan Metzmacher
<metze@samba.org>
Mon, 12 Dec 2011 10:20:06 +0000
(11:20 +0100)
committer
Stefan Metzmacher
<metze@samba.org>
Mon, 12 Dec 2011 13:35:42 +0000
(14:35 +0100)
metze
source3/smbd/process.c
patch
|
blob
|
history
diff --git
a/source3/smbd/process.c
b/source3/smbd/process.c
index 3f710c090c63fc53a804c4faa96f5fb20557b3d9..0e15e32d35958adb805d05db874f7f02b9a88988 100644
(file)
--- a/
source3/smbd/process.c
+++ b/
source3/smbd/process.c
@@
-2664,7
+2664,8
@@
static void smbd_echo_writer_done(struct tevent_req *req)
smbd_echo_activate_writer(state);
}
smbd_echo_activate_writer(state);
}
-static bool smbd_echo_reply(uint8_t *inbuf, size_t inbuf_len,
+static bool smbd_echo_reply(struct smbd_echo_state *state,
+ uint8_t *inbuf, size_t inbuf_len,
uint32_t seqnum)
{
struct smb_request req;
uint32_t seqnum)
{
struct smb_request req;
@@
-2685,12
+2686,12
@@
static bool smbd_echo_reply(uint8_t *inbuf, size_t inbuf_len,
DEBUG(10, ("Got short packet: %d bytes\n", (int)inbuf_len));
return false;
}
DEBUG(10, ("Got short packet: %d bytes\n", (int)inbuf_len));
return false;
}
- if (!valid_smb_header(s
mbd_server_
conn, inbuf)) {
+ if (!valid_smb_header(s
tate->s
conn, inbuf)) {
DEBUG(10, ("Got invalid SMB header\n"));
return false;
}
DEBUG(10, ("Got invalid SMB header\n"));
return false;
}
- if (!init_smb_request(&req, s
mbd_server_
conn, inbuf, 0, false,
+ if (!init_smb_request(&req, s
tate->s
conn, inbuf, 0, false,
seqnum)) {
return false;
}
seqnum)) {
return false;
}
@@
-2814,7
+2815,7
@@
static void smbd_echo_got_packet(struct tevent_req *req)
exit(1);
}
exit(1);
}
- reply = smbd_echo_reply((uint8_t *)buf, buflen, seqnum);
+ reply = smbd_echo_reply(
state,
(uint8_t *)buf, buflen, seqnum);
if (!reply) {
size_t num_pending;
struct iovec *tmp;
if (!reply) {
size_t num_pending;
struct iovec *tmp;