summaryrefslogtreecommitdiff
path: root/source4/rpc_server/echo
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2005-06-16 11:52:15 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:18:15 -0500
commit804b8d2792246abf24096dea99160b454353670b (patch)
tree335c8679084be9093d9fa94cee123a9970ad50b7 /source4/rpc_server/echo
parentaf237084ecd4f9928c6c282b9c5c73598d5c73d6 (diff)
downloadsamba-804b8d2792246abf24096dea99160b454353670b.tar.gz
samba-804b8d2792246abf24096dea99160b454353670b.tar.bz2
samba-804b8d2792246abf24096dea99160b454353670b.zip
r7634: move TestSleep functions so that all of them are together
metze (This used to be commit 520d5c67329e957121e3b71c1ffc0be3893c2033)
Diffstat (limited to 'source4/rpc_server/echo')
-rw-r--r--source4/rpc_server/echo/rpc_echo.c44
1 files changed, 22 insertions, 22 deletions
diff --git a/source4/rpc_server/echo/rpc_echo.c b/source4/rpc_server/echo/rpc_echo.c
index b67c172579..5e50a69641 100644
--- a/source4/rpc_server/echo/rpc_echo.c
+++ b/source4/rpc_server/echo/rpc_echo.c
@@ -118,28 +118,6 @@ static NTSTATUS echo_TestEnum(struct dcesrv_call_state *dce_call, TALLOC_CTX *me
return NT_STATUS_OK;
}
-struct echo_TestSleep_private {
- struct dcesrv_call_state *dce_call;
- struct echo_TestSleep *r;
-};
-
-static void echo_TestSleep_handler(struct event_context *ev, struct timed_event *te,
- struct timeval t, void *private)
-{
- struct echo_TestSleep_private *p = talloc_get_type(private,
- struct echo_TestSleep_private);
- struct echo_TestSleep *r = p->r;
- NTSTATUS status;
-
- r->out.result = r->in.seconds;
-
- status = dcesrv_reply(p->dce_call);
- if (!NT_STATUS_IS_OK(status)) {
- DEBUG(0,("echo_TestSleep_handler: dcesrv_reply() failed - %s\n",
- nt_errstr(status)));
- }
-}
-
static NTSTATUS echo_TestSurrounding(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, struct echo_TestSurrounding *r)
{
if (!r->in.data) {
@@ -163,6 +141,28 @@ static uint16_t echo_TestDoublePointer(struct dcesrv_call_state *dce_call, TALLO
return ***r->in.data;
}
+struct echo_TestSleep_private {
+ struct dcesrv_call_state *dce_call;
+ struct echo_TestSleep *r;
+};
+
+static void echo_TestSleep_handler(struct event_context *ev, struct timed_event *te,
+ struct timeval t, void *private)
+{
+ struct echo_TestSleep_private *p = talloc_get_type(private,
+ struct echo_TestSleep_private);
+ struct echo_TestSleep *r = p->r;
+ NTSTATUS status;
+
+ r->out.result = r->in.seconds;
+
+ status = dcesrv_reply(p->dce_call);
+ if (!NT_STATUS_IS_OK(status)) {
+ DEBUG(0,("echo_TestSleep_handler: dcesrv_reply() failed - %s\n",
+ nt_errstr(status)));
+ }
+}
+
static long echo_TestSleep(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, struct echo_TestSleep *r)
{
struct echo_TestSleep_private *p;