summaryrefslogtreecommitdiff
path: root/source3/rpc_server
diff options
context:
space:
mode:
Diffstat (limited to 'source3/rpc_server')
-rw-r--r--source3/rpc_server/srv_lsa.c2
-rw-r--r--source3/rpc_server/srv_samr.c4
-rw-r--r--source3/rpc_server/srv_spoolss_nt.c45
3 files changed, 3 insertions, 48 deletions
diff --git a/source3/rpc_server/srv_lsa.c b/source3/rpc_server/srv_lsa.c
index a7abc614e3..9c3d785627 100644
--- a/source3/rpc_server/srv_lsa.c
+++ b/source3/rpc_server/srv_lsa.c
@@ -298,7 +298,7 @@ static void init_lsa_trans_names(DOM_R_REF *ref, LSA_TRANS_NAME_ENUM *trn,
uint32 rid = 0xffffffff;
int dom_idx = -1;
fstring name, dom_name;
- enum SID_NAME_USE sid_name_use = 0;
+ enum SID_NAME_USE sid_name_use = (enum SID_NAME_USE)0;
/* Lookup sid from winbindd */
diff --git a/source3/rpc_server/srv_samr.c b/source3/rpc_server/srv_samr.c
index e3425f3247..7891fc16dc 100644
--- a/source3/rpc_server/srv_samr.c
+++ b/source3/rpc_server/srv_samr.c
@@ -966,7 +966,7 @@ static BOOL samr_reply_query_aliasinfo(SAMR_Q_QUERY_ALIASINFO *q_u,
SAMR_R_QUERY_ALIASINFO r_e;
fstring alias_desc = "Local Unix group";
fstring alias="";
- uint8 type;
+ enum SID_NAME_USE type;
uint32 alias_rid;
ZERO_STRUCT(r_e);
@@ -1112,7 +1112,7 @@ static BOOL samr_reply_lookup_names(SAMR_Q_LOOKUP_NAMES *q_u,
prs_struct *rdata)
{
uint32 rid[MAX_SAM_ENTRIES];
- uint8 type[MAX_SAM_ENTRIES];
+ enum SID_NAME_USE type[MAX_SAM_ENTRIES];
uint32 status = 0;
int i;
int num_rids = q_u->num_names1;
diff --git a/source3/rpc_server/srv_spoolss_nt.c b/source3/rpc_server/srv_spoolss_nt.c
index 717ee1bed1..c32ca8d871 100644
--- a/source3/rpc_server/srv_spoolss_nt.c
+++ b/source3/rpc_server/srv_spoolss_nt.c
@@ -318,10 +318,8 @@ static BOOL get_printer_snum(POLICY_HND *hnd, int *number)
return (*number != -1);
case PRINTER_HANDLE_IS_PRINTSERVER:
return False;
- break;
default:
return False;
- break;
}
}
@@ -1459,7 +1457,6 @@ static uint32 size_of_notify_info_data(uint16 type, uint16 field)
(notify_info_data_table[i].field == field ) )
{
return (notify_info_data_table[i].size);
- continue;
}
i++;
}
@@ -1486,7 +1483,6 @@ static BOOL type_of_notify_info_data(uint16 type, uint16 field)
{
return (True);
}
- continue;
}
i++;
}
@@ -1796,10 +1792,8 @@ uint32 _spoolss_rfnpcnex( POLICY_HND *handle, uint32 change,
switch (Printer->printer_type) {
case PRINTER_HANDLE_IS_PRINTSERVER:
return printserver_notify_info(handle, info);
- break;
case PRINTER_HANDLE_IS_PRINTER:
return printer_notify_info(handle, info);
- break;
}
return ERROR_INVALID_HANDLE;
@@ -2503,18 +2497,14 @@ uint32 _spoolss_enumprinters( uint32 flags, const UNISTR2 *servername, uint32 le
switch (level) {
case 1:
return enumprinters_level1(flags, name, buffer, offered, needed, returned);
- break;
case 2:
return enumprinters_level2(flags, name, buffer, offered, needed, returned);
- break;
case 5:
return enumprinters_level5(flags, name, buffer, offered, needed, returned);
- break;
case 3:
case 4:
default:
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -2679,7 +2669,6 @@ uint32 _spoolss_getprinter(POLICY_HND *handle, uint32 level,
return getprinter_level_3(servername,snum, buffer, offered, needed);
default:
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -3137,19 +3126,14 @@ uint32 _spoolss_getprinterdriver2(POLICY_HND *handle, const UNISTR2 *uni_arch, u
switch (level) {
case 1:
return getprinterdriver2_level1(servername, architecture, clientmajorversion, snum, buffer, offered, needed);
- break;
case 2:
return getprinterdriver2_level2(servername, architecture, clientmajorversion, snum, buffer, offered, needed);
- break;
case 3:
return getprinterdriver2_level3(servername, architecture, clientmajorversion, snum, buffer, offered, needed);
- break;
case 6:
return getprinterdriver2_level6(servername, architecture, clientmajorversion, snum, buffer, offered, needed);
- break;
default:
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -3629,17 +3613,13 @@ uint32 _spoolss_setprinter(POLICY_HND *handle, uint32 level,
switch (level) {
case 0:
return control_printer(handle, command, p);
- break;
case 2:
return update_printer(handle, level, info, devmode_ctr.devmode);
- break;
case 3:
return update_printer_sec(handle, level, info, p,
secdesc_ctr);
- break;
default:
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -3893,15 +3873,12 @@ uint32 _spoolss_enumjobs( POLICY_HND *handle, uint32 firstjob, uint32 numofjobs,
switch (level) {
case 1:
return enumjobs_level1(queue, snum, buffer, offered, needed, returned);
- break;
case 2:
return enumjobs_level2(queue, snum, buffer, offered, needed, returned);
- break;
default:
safe_free(queue);
*returned=0;
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -4217,18 +4194,14 @@ uint32 _spoolss_enumprinterdrivers( UNISTR2 *name, UNISTR2 *environment, uint32
switch (level) {
case 1:
return enumprinterdrivers_level1(servername, architecture, buffer, offered, needed, returned);
- break;
case 2:
return enumprinterdrivers_level2(servername, architecture, buffer, offered, needed, returned);
- break;
case 3:
return enumprinterdrivers_level3(servername, architecture, buffer, offered, needed, returned);
- break;
default:
*returned=0;
safe_free(list);
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -4609,13 +4582,10 @@ uint32 _spoolss_enumports( UNISTR2 *name, uint32 level,
switch (level) {
case 1:
return enumports_level_1(buffer, offered, needed, returned);
- break;
case 2:
return enumports_level_2(buffer, offered, needed, returned);
- break;
default:
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -4703,15 +4673,12 @@ uint32 _spoolss_addprinterex( const UNISTR2 *uni_srv_name, uint32 level,
/* we don't handle yet */
/* but I know what to do ... */
return ERROR_INVALID_LEVEL;
- break;
case 2:
return spoolss_addprinterex_level_2(uni_srv_name, info,
unk0, unk1, unk2, unk3,
user_switch, user, handle);
- break;
default:
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -4810,10 +4777,8 @@ uint32 _spoolss_getprinterdriverdirectory(UNISTR2 *name, UNISTR2 *uni_environmen
switch(level) {
case 1:
return getprinterdriverdir_level_1(name, uni_environment, buffer, offered, needed);
- break;
default:
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -5198,10 +5163,8 @@ uint32 _spoolss_enumprintprocessors(UNISTR2 *name, UNISTR2 *environment, uint32
switch (level) {
case 1:
return enumprintprocessors_level_1(buffer, offered, needed, returned);
- break;
default:
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -5250,10 +5213,8 @@ uint32 _spoolss_enumprintprocdatatypes(UNISTR2 *name, UNISTR2 *processor, uint32
switch (level) {
case 1:
return enumprintprocdatatypes_level_1(buffer, offered, needed, returned);
- break;
default:
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -5342,13 +5303,10 @@ uint32 _spoolss_enumprintmonitors(UNISTR2 *name,uint32 level,
switch (level) {
case 1:
return enumprintmonitors_level_1(buffer, offered, needed, returned);
- break;
case 2:
return enumprintmonitors_level_2(buffer, offered, needed, returned);
- break;
default:
return ERROR_INVALID_LEVEL;
- break;
}
}
@@ -5479,14 +5437,11 @@ uint32 _spoolss_getjob( POLICY_HND *handle, uint32 jobid, uint32 level,
switch (level) {
case 1:
return getjob_level_1(queue, count, snum, jobid, buffer, offered, needed);
- break;
case 2:
return getjob_level_2(queue, count, snum, jobid, buffer, offered, needed);
- break;
default:
safe_free(queue);
return ERROR_INVALID_LEVEL;
- break;
}
}
#undef OLD_NTDOMAIN