r3461: another place where "open" was used as a structure element
authorAndrew Tridgell <tridge@samba.org>
Tue, 2 Nov 2004 04:51:57 +0000 (04:51 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:05:16 +0000 (13:05 -0500)
(This used to be commit 1087ea830e7aead86d54a1836512e88554afc919)

12 files changed:
source4/lib/tdb/tools/tdbtorture.c
source4/ntvfs/cifs/vfs_cifs.c
source4/ntvfs/ipc/vfs_ipc.c
source4/ntvfs/nbench/vfs_nbench.c
source4/ntvfs/ntvfs.h
source4/ntvfs/ntvfs_generic.c
source4/ntvfs/ntvfs_interface.c
source4/ntvfs/posix/vfs_posix.c
source4/ntvfs/simple/vfs_simple.c
source4/ntvfs/unixuid/vfs_unixuid.c
source4/smb_server/reply.c
source4/torture/torture.c

index 6471aec3ad399651e03ef3ecd58a3bf0c95fe928..e90a967138b84a27e525a938a55e232b1bb17c57 100644 (file)
@@ -22,6 +22,7 @@
 
 #include "includes.h"
 #include "system/time.h"
+#include "system/wait.h"
 
 #endif
 
index 39befebae586725afd1dc63d258959fbd8051696..535b529a6309fa594ff7c2317496a03b34a5075a 100644 (file)
@@ -829,7 +829,7 @@ NTSTATUS ntvfs_cifs_init(void)
        ops.chkpath = cvfs_chkpath;
        ops.qpathinfo = cvfs_qpathinfo;
        ops.setpathinfo = cvfs_setpathinfo;
-       ops.open = cvfs_open;
+       ops.openfile = cvfs_open;
        ops.mkdir = cvfs_mkdir;
        ops.rmdir = cvfs_rmdir;
        ops.rename = cvfs_rename;
index 6b6dc9700348a2b3aa0a193819c3424a7a84acfb..a0604a9d083872d25f8bce86419b13c79484c320 100644 (file)
@@ -719,7 +719,7 @@ NTSTATUS ntvfs_ipc_init(void)
        ops.chkpath = ipc_chkpath;
        ops.qpathinfo = ipc_qpathinfo;
        ops.setpathinfo = ipc_setpathinfo;
-       ops.open = ipc_open;
+       ops.openfile = ipc_open;
        ops.mkdir = ipc_mkdir;
        ops.rmdir = ipc_rmdir;
        ops.rename = ipc_rename;
index 8820279584a36bdaf380cb75233c7b4859da1c72..eef407638b701a967ae48fabbdf532fea29810da 100644 (file)
@@ -280,7 +280,7 @@ static NTSTATUS nbench_setpathinfo(struct ntvfs_module_context *ntvfs,
 /*
   open a file
 */
-static void nbench_open_send(struct smbsrv_request *req)
+static void nbench_openfile_send(struct smbsrv_request *req)
 {
        union smb_open *io = req->async_states->private_data;
 
@@ -306,12 +306,12 @@ static void nbench_open_send(struct smbsrv_request *req)
        PASS_THRU_REP_POST(req);
 }
 
-static NTSTATUS nbench_open(struct ntvfs_module_context *ntvfs,
-                           struct smbsrv_request *req, union smb_open *io)
+static NTSTATUS nbench_openfile(struct ntvfs_module_context *ntvfs,
+                               struct smbsrv_request *req, union smb_open *io)
 {
        NTSTATUS status;
 
-       PASS_THRU_REQ(ntvfs, req, open, io, (ntvfs, req, io));
+       PASS_THRU_REQ(ntvfs, req, openfile, io, (ntvfs, req, io));
 
        return status;
 }
@@ -874,7 +874,7 @@ NTSTATUS ntvfs_nbench_init(void)
        ops.chkpath = nbench_chkpath;
        ops.qpathinfo = nbench_qpathinfo;
        ops.setpathinfo = nbench_setpathinfo;
-       ops.open = nbench_open;
+       ops.openfile = nbench_openfile;
        ops.mkdir = nbench_mkdir;
        ops.rmdir = nbench_rmdir;
        ops.rename = nbench_rename;
index 04e9b871c72233308e5cfb124135c3f5f4f144b1..5e7088018bd26b048557d1f558bd9656793bb3d3 100644 (file)
@@ -51,7 +51,7 @@ struct ntvfs_ops {
                                struct smbsrv_request *req, union smb_fileinfo *st);
        NTSTATUS (*setpathinfo)(struct ntvfs_module_context *ntvfs, 
                                struct smbsrv_request *req, union smb_setfileinfo *st);
-       NTSTATUS (*open)(struct ntvfs_module_context *ntvfs, 
+       NTSTATUS (*openfile)(struct ntvfs_module_context *ntvfs, 
                                struct smbsrv_request *req, union smb_open *oi);
        NTSTATUS (*mkdir)(struct ntvfs_module_context *ntvfs, 
                                struct smbsrv_request *req, union smb_mkdir *md);
index 835011437f15899e90c2ced4a46786edb41ec763..8eaa3cf1b266668507fde5a78b08beac4ed64bd7 100644 (file)
@@ -156,7 +156,7 @@ NTSTATUS ntvfs_map_open_openx(struct smbsrv_request *req,
        io2->generic.in.file_attr = io->openx.in.file_attrs;
        io2->generic.in.fname = io->openx.in.fname;
        
-       status = ntvfs->ops->open(ntvfs, req, io2);
+       status = ntvfs->ops->openfile(ntvfs, req, io2);
        if (!NT_STATUS_IS_OK(status)) {
                return status;
        }
@@ -285,7 +285,7 @@ NTSTATUS ntvfs_map_open(struct smbsrv_request *req, union smb_open *io,
                DEBUG(9,("ntvfs_map_open(OPEN): mapped flags=0x%x to access_mask=0x%x and share_access=0x%x\n",
                        io->openold.in.flags, io2->generic.in.access_mask, io2->generic.in.share_access));
 
-               status = ntvfs->ops->open(ntvfs, req, io2);
+               status = ntvfs->ops->openfile(ntvfs, req, io2);
                if (!NT_STATUS_IS_OK(status)) {
                        return status;
                }
index 7ba1c0d6bee3fde6f871b35dc1115de11bc2422d..95c01a0b503aebb5b0f624e546957accb91474a9 100644 (file)
@@ -77,13 +77,13 @@ NTSTATUS ntvfs_setpathinfo(struct smbsrv_request *req, union smb_setfileinfo *st
        return ntvfs->ops->setpathinfo(ntvfs, req, st);
 }
 
-NTSTATUS ntvfs_open(struct smbsrv_request *req, union smb_open *oi)
+NTSTATUS ntvfs_openfile(struct smbsrv_request *req, union smb_open *oi)
 {
        struct ntvfs_module_context *ntvfs = req->tcon->ntvfs_ctx->modules;
-       if (!ntvfs->ops->open) {
+       if (!ntvfs->ops->openfile) {
                return NT_STATUS_NOT_IMPLEMENTED;
        }
-       return ntvfs->ops->open(ntvfs, req, oi);
+       return ntvfs->ops->openfile(ntvfs, req, oi);
 }
 
 NTSTATUS ntvfs_mkdir(struct smbsrv_request *req, union smb_mkdir *md)
@@ -360,13 +360,13 @@ NTSTATUS ntvfs_next_setpathinfo(struct ntvfs_module_context *ntvfs,
        return ntvfs->next->ops->setpathinfo(ntvfs->next, req, st);
 }
 
-NTSTATUS ntvfs_next_open(struct ntvfs_module_context *ntvfs, 
+NTSTATUS ntvfs_next_openfile(struct ntvfs_module_context *ntvfs, 
                         struct smbsrv_request *req, union smb_open *oi)
 {
-       if (!ntvfs->next || !ntvfs->next->ops->open) {
+       if (!ntvfs->next || !ntvfs->next->ops->openfile) {
                return NT_STATUS_NOT_IMPLEMENTED;
        }
-       return ntvfs->next->ops->open(ntvfs->next, req, oi);
+       return ntvfs->next->ops->openfile(ntvfs->next, req, oi);
 }
 
 NTSTATUS ntvfs_next_mkdir(struct ntvfs_module_context *ntvfs, 
index 8dc87b160d4424b2ab2b7ab11e102262e64d430d..7ebea2ea9a72d365d94114d18300b2daa6902013 100644 (file)
@@ -213,7 +213,7 @@ NTSTATUS ntvfs_posix_init(void)
        ops.chkpath = pvfs_chkpath;
        ops.qpathinfo = pvfs_qpathinfo;
        ops.setpathinfo = pvfs_setpathinfo;
-       ops.open = pvfs_open;
+       ops.openfile = pvfs_open;
        ops.mkdir = pvfs_mkdir;
        ops.rmdir = pvfs_rmdir;
        ops.rename = pvfs_rename;
index c84483ea23f3e4d58af4078aae99823da303cedc..4df0bc9782396017196227c6ca4cd4bcded3de34 100644 (file)
@@ -961,7 +961,7 @@ NTSTATUS ntvfs_simple_init(void)
        ops.chkpath = svfs_chkpath;
        ops.qpathinfo = svfs_qpathinfo;
        ops.setpathinfo = svfs_setpathinfo;
-       ops.open = svfs_open;
+       ops.openfile = svfs_open;
        ops.mkdir = svfs_mkdir;
        ops.rmdir = svfs_rmdir;
        ops.rename = svfs_rename;
index 296dadcfe4372de12e44e139d82490b104ca8307..9c74c12f918eb0539bd6cb4315da8c2e7722ae56 100644 (file)
@@ -469,12 +469,12 @@ static NTSTATUS unixuid_setpathinfo(struct ntvfs_module_context *ntvfs,
 /*
   open a file
 */
-static NTSTATUS unixuid_open(struct ntvfs_module_context *ntvfs,
-                           struct smbsrv_request *req, union smb_open *io)
+static NTSTATUS unixuid_openfile(struct ntvfs_module_context *ntvfs,
+                                struct smbsrv_request *req, union smb_open *io)
 {
        NTSTATUS status;
 
-       PASS_THRU_REQ(ntvfs, req, open, (ntvfs, req, io));
+       PASS_THRU_REQ(ntvfs, req, openfile, (ntvfs, req, io));
 
        return status;
 }
@@ -760,7 +760,7 @@ NTSTATUS ntvfs_unixuid_init(void)
        ops.chkpath = unixuid_chkpath;
        ops.qpathinfo = unixuid_qpathinfo;
        ops.setpathinfo = unixuid_setpathinfo;
-       ops.open = unixuid_open;
+       ops.openfile = unixuid_openfile;
        ops.mkdir = unixuid_mkdir;
        ops.rmdir = unixuid_rmdir;
        ops.rename = unixuid_rename;
index 1ffd55bf3f66ad0ea82a67c8d098c6e8e80e5223..8c20b2bb72088d0e3e58c629e846a30af48642e9 100644 (file)
@@ -443,7 +443,7 @@ void reply_open(struct smbsrv_request *req)
        req->async_states->private_data = oi;
        
        /* call backend */
-       req->async_states->status = ntvfs_open(req, oi);
+       req->async_states->status = ntvfs_openfile(req, oi);
 
        REQ_ASYNC_TAIL;
 }
@@ -519,7 +519,7 @@ void reply_open_and_X(struct smbsrv_request *req)
        req->async_states->private_data = oi;
 
        /* call the backend */
-       req->async_states->status = ntvfs_open(req, oi);
+       req->async_states->status = ntvfs_openfile(req, oi);
 
        REQ_ASYNC_TAIL;
 }
@@ -570,7 +570,7 @@ void reply_mknew(struct smbsrv_request *req)
        req->async_states->private_data = oi;
 
        /* call the backend */
-       req->async_states->status = ntvfs_open(req, oi);
+       req->async_states->status = ntvfs_openfile(req, oi);
 
        REQ_ASYNC_TAIL;
 }
@@ -624,7 +624,7 @@ void reply_ctemp(struct smbsrv_request *req)
        req->async_states->private_data = oi;
 
        /* call the backend */
-       req->async_states->status = ntvfs_open(req, oi);
+       req->async_states->status = ntvfs_openfile(req, oi);
 
        REQ_ASYNC_TAIL;
 }
@@ -1423,7 +1423,7 @@ void reply_printopen(struct smbsrv_request *req)
        req->async_states->private_data = oi;
 
        /* call backend */
-       req->async_states->status = ntvfs_open(req, oi);
+       req->async_states->status = ntvfs_openfile(req, oi);
 
        REQ_ASYNC_TAIL;
 }
@@ -2300,7 +2300,7 @@ void reply_ntcreate_and_X(struct smbsrv_request *req)
        req->async_states->private_data = io;
 
        /* call the backend */
-       req->async_states->status = ntvfs_open(req, io);
+       req->async_states->status = ntvfs_openfile(req, io);
 
        REQ_ASYNC_TAIL;
 }
index 62b69ea8fb01f2a768c98e2d1d606e44b8f1137e..4ff2fd9287168e090c35a9f9a8917988cdb1c030 100644 (file)
@@ -22,6 +22,7 @@
 #include "lib/cmdline/popt_common.h"
 #include "libcli/raw/libcliraw.h"
 #include "system/time.h"
+#include "system/wait.h"
 
 int torture_nprocs=4;
 int torture_numops=100;