summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2009-11-20 17:47:21 +0100
committerMichael Adam <obnox@samba.org>2009-11-23 23:51:07 +0100
commit63a801e5c931e401351b02445704800d1103417c (patch)
tree4c546ff29372f6bc856285589c8b4b52899c3796
parent632e4afc3611511f78a1d5c45e0a91cd00334d28 (diff)
downloadsamba-63a801e5c931e401351b02445704800d1103417c.tar.gz
samba-63a801e5c931e401351b02445704800d1103417c.tar.bz2
samba-63a801e5c931e401351b02445704800d1103417c.zip
s3:torture: move the torture-specific headers to new torture/torture.h
Michael
-rw-r--r--source3/include/proto.h55
-rw-r--r--source3/torture/denytest.c1
-rw-r--r--source3/torture/mangle_test.c1
-rw-r--r--source3/torture/nbio.c1
-rw-r--r--source3/torture/scanner.c1
-rw-r--r--source3/torture/torture.c1
-rw-r--r--source3/torture/torture.h81
-rw-r--r--source3/torture/utable.c1
8 files changed, 87 insertions, 55 deletions
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 88f6dd54ae..5b1ce7462c 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -7163,61 +7163,6 @@ int vfs_lstat_smb_fname(struct connection_struct *conn, const char *fname,
SMB_STRUCT_STAT *psbuf);
NTSTATUS vfs_stat_fsp(files_struct *fsp);
-/* The following definitions come from torture/denytest.c */
-
-bool torture_denytest1(int dummy);
-bool torture_denytest2(int dummy);
-
-/* The following definitions come from torture/mangle_test.c */
-
-bool torture_mangle(int dummy);
-
-/* The following definitions come from torture/nbio.c */
-
-double nbio_total(void);
-void nb_alarm(int ignore);
-void nbio_shmem(int n);
-void nb_setup(struct cli_state *cli);
-void nb_unlink(const char *fname);
-void nb_createx(const char *fname,
- unsigned create_options, unsigned create_disposition, int handle);
-void nb_writex(int handle, int offset, int size, int ret_size);
-void nb_readx(int handle, int offset, int size, int ret_size);
-void nb_close(int handle);
-void nb_rmdir(const char *fname);
-void nb_rename(const char *oldname, const char *newname);
-void nb_qpathinfo(const char *fname);
-void nb_qfileinfo(int fnum);
-void nb_qfsinfo(int level);
-void nb_findfirst(const char *mask);
-void nb_flush(int fnum);
-void nb_deltree(const char *dname);
-void nb_cleanup(void);
-
-/* The following definitions come from torture/scanner.c */
-
-bool torture_trans2_scan(int dummy);
-bool torture_nttrans_scan(int dummy);
-
-/* The following definitions come from torture/torture.c */
-
-void start_timer(void);
-double end_timer(void);
-void *shm_setup(int size);
-bool smbcli_parse_unc(const char *unc_name, TALLOC_CTX *mem_ctx,
- char **hostname, char **sharename);
-void torture_open_connection_free_unclist(char **unc_list);
-bool torture_open_connection(struct cli_state **c, int conn_index);
-bool torture_cli_session_setup2(struct cli_state *cli, uint16 *new_vuid);
-bool torture_close_connection(struct cli_state *c);
-bool torture_ioctl_test(int dummy);
-bool torture_chkpath_test(int dummy);
-
-/* The following definitions come from torture/utable.c */
-
-bool torture_utable(int dummy);
-bool torture_casetable(int dummy);
-
/* The following definitions come from utils/passwd_util.c */
char *stdin_new_passwd( void);
diff --git a/source3/torture/denytest.c b/source3/torture/denytest.c
index 66a1c9f935..bf491bc22e 100644
--- a/source3/torture/denytest.c
+++ b/source3/torture/denytest.c
@@ -18,6 +18,7 @@
*/
#include "includes.h"
+#include "torture.h"
extern bool torture_showall;
diff --git a/source3/torture/mangle_test.c b/source3/torture/mangle_test.c
index 34c908e642..e5f69479a5 100644
--- a/source3/torture/mangle_test.c
+++ b/source3/torture/mangle_test.c
@@ -18,6 +18,7 @@
*/
#include "includes.h"
+#include "torture.h"
extern int torture_numops;
diff --git a/source3/torture/nbio.c b/source3/torture/nbio.c
index bef54f75fe..5e7a458025 100644
--- a/source3/torture/nbio.c
+++ b/source3/torture/nbio.c
@@ -20,6 +20,7 @@
*/
#include "includes.h"
+#include "torture.h"
#define MAX_FILES 1000
diff --git a/source3/torture/scanner.c b/source3/torture/scanner.c
index e42e80abca..4d9ee286e8 100644
--- a/source3/torture/scanner.c
+++ b/source3/torture/scanner.c
@@ -18,6 +18,7 @@
*/
#include "includes.h"
+#include "torture.h"
#define VERBOSE 0
#define OP_MIN 0
diff --git a/source3/torture/torture.c b/source3/torture/torture.c
index bf89ca35b1..19103dfbef 100644
--- a/source3/torture/torture.c
+++ b/source3/torture/torture.c
@@ -20,6 +20,7 @@
#include "includes.h"
#include "nsswitch/libwbclient/wbc_async.h"
+#include "torture.h"
extern char *optarg;
extern int optind;
diff --git a/source3/torture/torture.h b/source3/torture/torture.h
new file mode 100644
index 0000000000..353b98cff3
--- /dev/null
+++ b/source3/torture/torture.h
@@ -0,0 +1,81 @@
+/*
+ Unix SMB/CIFS implementation.
+
+ SMB torture tester - header file
+
+ Copyright (C) Andrew Tridgell 1997-1998
+ Copyright (C) Jeremy Allison 2009
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#ifndef __TORTURE_H__
+#define __TORTURE_H__
+
+/* The following definitions come from torture/denytest.c */
+
+bool torture_denytest1(int dummy);
+bool torture_denytest2(int dummy);
+
+/* The following definitions come from torture/mangle_test.c */
+
+bool torture_mangle(int dummy);
+
+/* The following definitions come from torture/nbio.c */
+
+double nbio_total(void);
+void nb_alarm(int ignore);
+void nbio_shmem(int n);
+void nb_setup(struct cli_state *cli);
+void nb_unlink(const char *fname);
+void nb_createx(const char *fname,
+ unsigned create_options, unsigned create_disposition, int handle);
+void nb_writex(int handle, int offset, int size, int ret_size);
+void nb_readx(int handle, int offset, int size, int ret_size);
+void nb_close(int handle);
+void nb_rmdir(const char *fname);
+void nb_rename(const char *oldname, const char *newname);
+void nb_qpathinfo(const char *fname);
+void nb_qfileinfo(int fnum);
+void nb_qfsinfo(int level);
+void nb_findfirst(const char *mask);
+void nb_flush(int fnum);
+void nb_deltree(const char *dname);
+void nb_cleanup(void);
+
+/* The following definitions come from torture/scanner.c */
+
+bool torture_trans2_scan(int dummy);
+bool torture_nttrans_scan(int dummy);
+
+/* The following definitions come from torture/torture.c */
+
+void start_timer(void);
+double end_timer(void);
+void *shm_setup(int size);
+bool smbcli_parse_unc(const char *unc_name, TALLOC_CTX *mem_ctx,
+ char **hostname, char **sharename);
+void torture_open_connection_free_unclist(char **unc_list);
+bool torture_open_connection(struct cli_state **c, int conn_index);
+bool torture_cli_session_setup2(struct cli_state *cli, uint16 *new_vuid);
+bool torture_close_connection(struct cli_state *c);
+bool torture_ioctl_test(int dummy);
+bool torture_chkpath_test(int dummy);
+
+/* The following definitions come from torture/utable.c */
+
+bool torture_utable(int dummy);
+bool torture_casetable(int dummy);
+
+#endif /* __TORTURE_H__ */
diff --git a/source3/torture/utable.c b/source3/torture/utable.c
index 1f75164848..247642b044 100644
--- a/source3/torture/utable.c
+++ b/source3/torture/utable.c
@@ -18,6 +18,7 @@
*/
#include "includes.h"
+#include "torture.h"
bool torture_utable(int dummy)
{