From f87219d6e6e049a6d233696d126ea231cbbc1672 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Sat, 25 Oct 2008 15:23:36 +0200 Subject: Move the is_known_pipename check into np_open --- source3/smbd/nttrans.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) (limited to 'source3/smbd/nttrans.c') diff --git a/source3/smbd/nttrans.c b/source3/smbd/nttrans.c index b78c946388..30841686fb 100644 --- a/source3/smbd/nttrans.c +++ b/source3/smbd/nttrans.c @@ -276,21 +276,16 @@ static void nt_open_pipe(char *fname, connection_struct *conn, DEBUG(4,("nt_open_pipe: Opening pipe %s.\n", fname)); - /* See if it is one we want to handle. */ - - if (!is_known_pipename(fname)) { - reply_botherror(req, NT_STATUS_OBJECT_NAME_NOT_FOUND, - ERRDOS, ERRbadpipe); - return; - } - /* Strip \\ off the name. */ fname++; - DEBUG(3,("nt_open_pipe: Known pipe %s opening.\n", fname)); - status = np_open(req, conn, 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, + ERRDOS, ERRbadpipe); + return; + } reply_nterror(req, status); return; } -- cgit