Remove "conn" parameter from np_open, smb_request contains it
authorVolker Lendecke <vl@samba.org>
Sun, 9 Nov 2008 16:25:40 +0000 (17:25 +0100)
committerVolker Lendecke <vl@samba.org>
Fri, 28 Nov 2008 09:06:32 +0000 (10:06 +0100)
source3/include/proto.h
source3/rpc_server/srv_pipe_hnd.c
source3/smbd/nttrans.c
source3/smbd/pipes.c

index 71f12a684478c4bfd2c1426adc1a2132d925c6df..59df098d0da579aacf15c77d99c7e6cb3533b53a 100644 (file)
@@ -6996,8 +6996,8 @@ pipes_struct *get_next_internal_pipe(pipes_struct *p);
 void init_rpc_pipe_hnd(void);
 
 bool fsp_is_np(struct files_struct *fsp);
-NTSTATUS np_open(struct smb_request *smb_req, struct connection_struct *conn,
-                const char *name, struct files_struct **pfsp);
+NTSTATUS np_open(struct smb_request *smb_req, const char *name,
+                struct files_struct **pfsp);
 NTSTATUS np_write(struct files_struct *fsp, const uint8_t *data, size_t len,
                  ssize_t *nwritten);
 NTSTATUS np_read(struct files_struct *fsp, uint8_t *data, size_t len,
index 03a0f72b332e66a12481311d3c74f4873b1a8cf1..1cff95dcaba0d713f5caa89cd433f0aa2854c60f 100644 (file)
@@ -1078,9 +1078,10 @@ static struct np_proxy_state *make_external_rpc_pipe_p(TALLOC_CTX *mem_ctx,
        return NULL;
 }
 
-NTSTATUS np_open(struct smb_request *smb_req, struct connection_struct *conn,
-                const char *name, struct files_struct **pfsp)
+NTSTATUS np_open(struct smb_request *smb_req, const char *name,
+                struct files_struct **pfsp)
 {
+       struct connection_struct *conn = smb_req->conn;
        NTSTATUS status;
        struct files_struct *fsp;
        const char **proxy_list;
index fe2029eeed9e08c3a1cdf09ab9112a494c485531..18dd7d5c26e78bd0a52cac145bcf1f0bed48e8de 100644 (file)
@@ -284,7 +284,7 @@ static void nt_open_pipe(char *fname, connection_struct *conn,
        /* Strip \\ off the name. */
        fname++;
 
-       status = np_open(req, conn, fname, &fsp);
+       status = np_open(req, fname, &fsp);
        if (!NT_STATUS_IS_OK(status)) {
                if (NT_STATUS_EQUAL(status, NT_STATUS_OBJECT_NAME_NOT_FOUND)) {
                        reply_botherror(req, NT_STATUS_OBJECT_NAME_NOT_FOUND,
index b52b1b02d07d7aca1e1962b9418ccd871eb44fbe..261f12cb08195e2f33160769c8e39f194f4db8d6 100644 (file)
@@ -78,7 +78,7 @@ void reply_open_pipe_and_X(connection_struct *conn, struct smb_request *req)
        }
 #endif
 
-       status = np_open(req, conn, fname, &fsp);
+       status = np_open(req, fname, &fsp);
        if (!NT_STATUS_IS_OK(status)) {
                if (NT_STATUS_EQUAL(status, NT_STATUS_OBJECT_NAME_NOT_FOUND)) {
                        reply_botherror(req, NT_STATUS_OBJECT_NAME_NOT_FOUND,