r3993: use distinctive fnums in the ipc backend, to make monitoring sniffs easier
authorAndrew Tridgell <tridge@samba.org>
Mon, 29 Nov 2004 06:18:58 +0000 (06:18 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:06:12 +0000 (13:06 -0500)
source/ntvfs/ipc/vfs_ipc.c

index a53accd53379ac841b9cdafc2c5b892eda2759fd..b4c41d58d35982de28d9c3ade790177851840f8e 100644 (file)
@@ -30,6 +30,8 @@
 #include "dlinklist.h"
 #include "smb_server/smb_server.h"
 
+#define IPC_BASE_FNUM 0x400
+
 /* this is the private structure used to keep the state of an open
    ipc$ connection. It needs to keep information about all open
    pipes */
@@ -196,7 +198,7 @@ static NTSTATUS ipc_open_generic(struct ntvfs_module_context *ntvfs,
                return NT_STATUS_NO_MEMORY;
        }
 
-       fnum = idr_get_new(private->idtree_fnum, p, UINT16_MAX);
+       fnum = idr_get_new_above(private->idtree_fnum, p, IPC_BASE_FNUM, UINT16_MAX);
        if (fnum == -1) {
                return NT_STATUS_TOO_MANY_OPENED_FILES;
        }