s3: Fix print_spool_end
authorVolker Lendecke <vl@samba.org>
Sat, 2 Apr 2011 16:46:58 +0000 (18:46 +0200)
committerVolker Lendecke <vl@samba.org>
Tue, 5 Apr 2011 10:26:29 +0000 (12:26 +0200)
We have to use the spoolss pipe instance opened in print_spool_open, otherwise
the spoolss server won't be able to find the right printer and job.

source3/printing/printspoolss.c

index 01137df7efc8a335a7a9909d184be3c743587cc2..352fcb8b6bc338766131e1c2dc241f9cacd721e3 100644 (file)
@@ -277,18 +277,6 @@ void print_spool_end(files_struct *fsp, enum file_close_type close_type)
        WERROR werr;
        struct dcerpc_binding_handle *b = NULL;
 
-       status = rpc_pipe_open_interface(fsp->conn,
-                                        &ndr_table_spoolss.syntax_id,
-                                        fsp->conn->session_info,
-                                        &fsp->conn->sconn->client_id,
-                                        fsp->conn->sconn->msg_ctx,
-                                        &fsp->conn->spoolss_pipe);
-       if (!NT_STATUS_IS_OK(status)) {
-               DEBUG(0, ("print_spool_end: "
-                         "Failed to get spoolss pipe [%s]\n",
-                         nt_errstr(status)));
-               return;
-       }
        b = fsp->conn->spoolss_pipe->binding_handle;
 
        switch (close_type) {