summaryrefslogtreecommitdiff
path: root/source3/utils
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>1998-04-17 22:44:01 +0000
committerJeremy Allison <jra@samba.org>1998-04-17 22:44:01 +0000
commitf9a96f060bdc8d045748b5f7e31d177e43e8810a (patch)
treea8d75fc796573d7b841896116073a43d0e8ab958 /source3/utils
parent373d7c62577c13e1a85043844953a8d779858432 (diff)
downloadsamba-f9a96f060bdc8d045748b5f7e31d177e43e8810a.tar.gz
samba-f9a96f060bdc8d045748b5f7e31d177e43e8810a.tar.bz2
samba-f9a96f060bdc8d045748b5f7e31d177e43e8810a.zip
clientgen.c: Changes 'cli_xxx_' calls to use the following
regularized parameter syntax: setup, setup_count, max_setup_count, params, params_count, max_params_count, data, data_count, max_data_count, (and if a reply is needed) *reply_params, *reply_data_len *reply_data, *reply_data_len This allows the pointers and the lengths that relate to these pointers to be next to each other in the parameter list. This makes seeing what you are passing to these functions much easier to see. Getting ready for adding the lib/rpc/client functions needed to do security=domain. torture.c: Fixed it so it uses / rather than \\ internally for the //machine/share syntax. Jeremy. (This used to be commit 38350ea8b949d0908497490898ff04df7591ccac)
Diffstat (limited to 'source3/utils')
-rw-r--r--source3/utils/torture.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/source3/utils/torture.c b/source3/utils/torture.c
index c7fded6b3f..ede801afe9 100644
--- a/source3/utils/torture.c
+++ b/source3/utils/torture.c
@@ -32,12 +32,12 @@ static char *sockops="";
static struct timeval tp1,tp2;
-static void start_timer()
+static void start_timer(void)
{
gettimeofday(&tp1,NULL);
}
-static double end_timer()
+static double end_timer(void)
{
gettimeofday(&tp2,NULL);
return((tp2.tv_sec - tp1.tv_sec) +
@@ -191,7 +191,7 @@ static BOOL rw_torture(struct cli_state *c, int numops)
static void usage(void)
{
- printf("Usage: smbtorture \\\\server\\share <options>\n");
+ printf("Usage: smbtorture //server/share <options>\n");
printf("\t-U user%%pass\n");
printf("\t-N numprocs\n");
@@ -841,12 +841,16 @@ static void create_procs(int nprocs, int numops)
usage();
}
- if (strncmp(argv[1], "\\\\", 2)) {
+ for(p = argv[1]; *p; p++)
+ if(*p == '\\')
+ *p = '/';
+
+ if (strncmp(argv[1], "//", 2)) {
usage();
}
fstrcpy(host, &argv[1][2]);
- p = strchr(&host[2],'\\');
+ p = strchr(&host[2],'/');
if (!p) {
usage();
}