summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShirish Kalele <kalele@samba.org>2000-03-17 20:38:23 +0000
committerShirish Kalele <kalele@samba.org>2000-03-17 20:38:23 +0000
commitd617c864b74021735842ebe38ab1f09d04d85cad (patch)
treebed769f020f454683dd250d091d61eb7b4df1057
parent4499109ad2da9f94e2a4d9cf0f102520e085ddfa (diff)
downloadsamba-d617c864b74021735842ebe38ab1f09d04d85cad.tar.gz
samba-d617c864b74021735842ebe38ab1f09d04d85cad.tar.xz
samba-d617c864b74021735842ebe38ab1f09d04d85cad.zip
Cleaned up compiler warnings.
-rw-r--r--source/rpc_client/cli_dfs.c2
-rw-r--r--source/rpc_parse/parse_dfs.c4
-rw-r--r--source/rpcclient/cmd_dfs.c40
3 files changed, 24 insertions, 22 deletions
diff --git a/source/rpc_client/cli_dfs.c b/source/rpc_client/cli_dfs.c
index c6ef69190af..415aabe3ca8 100644
--- a/source/rpc_client/cli_dfs.c
+++ b/source/rpc_client/cli_dfs.c
@@ -13,9 +13,7 @@ static BOOL _dfs_exist(struct cli_connection *con)
{
prs_struct buf;
prs_struct rbuf;
- prs_struct *ps = &rbuf;
DFS_R_DFS_EXIST q_d;
- uint32 dfs_exist_flag = 0;
prs_init(&buf, 0, 4, False);
prs_init(&rbuf, 0 ,4, True);
diff --git a/source/rpc_parse/parse_dfs.c b/source/rpc_parse/parse_dfs.c
index 4587fd46e49..136dadcfa40 100644
--- a/source/rpc_parse/parse_dfs.c
+++ b/source/rpc_parse/parse_dfs.c
@@ -32,6 +32,7 @@ BOOL make_dfs_q_dfs_remove(DFS_Q_DFS_REMOVE *q_d, char *entrypath,
make_unistr2(&(q_d->ServerName), servername, strlen(servername)+1);
make_unistr2(&(q_d->ShareName), sharename, strlen(sharename)+1);
q_d->ptr_ServerName = q_d->ptr_ShareName = 1;
+ return True;
}
/*******************************************************************
@@ -99,6 +100,7 @@ BOOL make_dfs_q_dfs_add(DFS_Q_DFS_ADD *q_d, char *entrypath, char *servername,
}
q_d->Flags = flags;
+ return True;
}
/************************************************************
@@ -163,6 +165,7 @@ BOOL make_dfs_q_dfs_enum(DFS_Q_DFS_ENUM *q_d, uint32 level, DFS_INFO_CTR *ctr)
q_d->num_entries2 = 0;
q_d->reshnd.ptr_hnd = 1;
q_d->reshnd.handle = 0;
+ return True;
}
/************************************************************
@@ -307,6 +310,7 @@ BOOL dfs_io_r_dfs_enum(char *desc, DFS_R_DFS_ENUM *q_d, prs_struct *ps, int dept
smb_io_enum_hnd("resume_hnd", &(q_d->reshnd), ps, depth);
prs_uint32("status", ps, depth, &(q_d->status));
+ return True;
}
BOOL smb_io_dfs_storage_info(char *desc, DFS_INFO_3* info3,
diff --git a/source/rpcclient/cmd_dfs.c b/source/rpcclient/cmd_dfs.c
index cd3be42f2a9..d73613149c9 100644
--- a/source/rpcclient/cmd_dfs.c
+++ b/source/rpcclient/cmd_dfs.c
@@ -85,7 +85,7 @@ void cmd_dfs_remove(struct client_info *info, int argc, char *argv[])
}
}
-void display_dfs_enum_1(FILE *out_hnd, DFS_INFO_CTR *ctr)
+void display_dfs_enum_1(FILE *hnd, DFS_INFO_CTR *ctr)
{
int i=0;
for(i=0;i<ctr->num_entries;i++)
@@ -93,12 +93,12 @@ void display_dfs_enum_1(FILE *out_hnd, DFS_INFO_CTR *ctr)
fstring path;
UNISTR2 *unipath = &(ctr->dfs.info1[i].entrypath);
unistr2_to_ascii(path, unipath, sizeof(path)-1);
- report(out_hnd, "Path: %s\n",path);
+ report(hnd, "Path: %s\n",path);
}
free(ctr->dfs.info1);
}
-void display_dfs_enum_2(FILE *out_hnd, DFS_INFO_CTR *ctr)
+void display_dfs_enum_2(FILE *hnd, DFS_INFO_CTR *ctr)
{
int i=0;
for(i=0;i<ctr->num_entries;i++)
@@ -110,9 +110,9 @@ void display_dfs_enum_2(FILE *out_hnd, DFS_INFO_CTR *ctr)
unistr2_to_ascii(path, unipath, sizeof(path)-1);
unistr2_to_ascii(comment, unicomment, sizeof(comment)-1);
- report(out_hnd, "Path: %s\n",path);
+ report(hnd, "Path: %s\n",path);
if(*comment)
- report(out_hnd, "Comment: [%s]\n",comment);
+ report(hnd, "Comment: [%s]\n",comment);
switch(ctr->dfs.info2[i].state)
{
@@ -122,13 +122,13 @@ void display_dfs_enum_2(FILE *out_hnd, DFS_INFO_CTR *ctr)
case 4: fstrcpy(state, "ONLINE"); break;
default: fstrcpy(state, "UNKNOWN"); break;
}
- report(out_hnd, "State: %s Number of storages: %u\n\n",state,
+ report(hnd, "State: %s Number of storages: %u\n\n",state,
ctr->dfs.info2[i].num_storages);
}
free(ctr->dfs.info2);
}
-void display_dfs_enum_3_storages(FILE *out_hnd, DFS_INFO_3 *info3)
+void display_dfs_enum_3_storages(FILE *hnd, DFS_INFO_3 *info3)
{
int i=0;
if((info3 == NULL) || (info3->storages==NULL))
@@ -145,11 +145,11 @@ void display_dfs_enum_3_storages(FILE *out_hnd, DFS_INFO_3 *info3)
fstrcat(storagepath,"\\");
fstrcat(storagepath,sharename);
- report(out_hnd, " Storage %1u: %-33s[%s] \n",i+1, storagepath,
+ report(hnd, " Storage %1u: %-33s[%s] \n",i+1, storagepath,
(stor->state==2?"ONLINE":"OFFLINE"));
}
}
-void display_dfs_enum_3(FILE *out_hnd, DFS_INFO_CTR *ctr)
+void display_dfs_enum_3(FILE *hnd, DFS_INFO_CTR *ctr)
{
int i=0;
@@ -171,35 +171,35 @@ void display_dfs_enum_3(FILE *out_hnd, DFS_INFO_CTR *ctr)
default: fstrcpy(state, "UNKNOWN"); break;
}
- report(out_hnd, "Dfs path:%-40sState: %s\n",path,state);
+ report(hnd, "Dfs path:%-40sState: %s\n",path,state);
if(*comment)
- report(out_hnd, "Comment: [%s]\n",comment);
+ report(hnd, "Comment: [%s]\n",comment);
- display_dfs_enum_3_storages(out_hnd, &(ctr->dfs.info3[i]));
- report(out_hnd,"\n");
+ display_dfs_enum_3_storages(hnd, &(ctr->dfs.info3[i]));
+ report(hnd,"\n");
}
free(ctr->dfs.info3);
}
-void display_dfs_enum(FILE *out_hnd, char *srv_name, DFS_INFO_CTR *ctr)
+void display_dfs_enum(FILE *hnd, char *srv_name, DFS_INFO_CTR *ctr)
{
/* print header */
- report(out_hnd, "\tDfs Namespace at %s [Info level %u]\n\n",srv_name,
+ report(hnd, "\tDfs Namespace at %s [Info level %u]\n\n",srv_name,
ctr->switch_value);
switch(ctr->switch_value)
{
case 1:
- display_dfs_enum_1(out_hnd, ctr);
+ display_dfs_enum_1(hnd, ctr);
break;
case 2:
- display_dfs_enum_2(out_hnd, ctr);
+ display_dfs_enum_2(hnd, ctr);
break;
case 3:
- display_dfs_enum_3(out_hnd, ctr);
+ display_dfs_enum_3(hnd, ctr);
break;
default:
- report(out_hnd, "\tUnknown info level [%u]\n",ctr->switch_value);
+ report(hnd, "\tUnknown info level [%u]\n",ctr->switch_value);
}
- report(out_hnd, "\n");
+ report(hnd, "\n");
}
/****************************************************************************