summaryrefslogtreecommitdiff
path: root/source4/auth
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-12-02 04:51:56 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:06:16 -0500
commit4183b2ac3832cdc2055d7eb3ed7121a9ea91085c (patch)
tree880492048be3a307eb82ebc663b4a7d3805dd337 /source4/auth
parent3b863542dca8e638cdba6daad043f224d81fcd6a (diff)
downloadsamba-4183b2ac3832cdc2055d7eb3ed7121a9ea91085c.tar.gz
samba-4183b2ac3832cdc2055d7eb3ed7121a9ea91085c.tar.bz2
samba-4183b2ac3832cdc2055d7eb3ed7121a9ea91085c.zip
r4037: fixed a bunch of "might be uninitialised" warnings after enabling -O1 in my compile
(This used to be commit 0928b1f5b68c858922c3ea6c27ed03b5091c6221)
Diffstat (limited to 'source4/auth')
-rw-r--r--source4/auth/auth_util.c34
1 files changed, 18 insertions, 16 deletions
diff --git a/source4/auth/auth_util.c b/source4/auth/auth_util.c
index e929e59cc7..1ea7da4672 100644
--- a/source4/auth/auth_util.c
+++ b/source4/auth/auth_util.c
@@ -500,26 +500,28 @@ NTSTATUS make_server_info_netlogon_validation(TALLOC_CTX *mem_ctx,
union netr_Validation *validation)
{
NTSTATUS nt_status;
- struct netr_SamBaseInfo *base;
+ struct netr_SamBaseInfo *base = NULL;
switch (validation_level) {
- case 2:
- if (!validation || !validation->sam2) {
- return NT_STATUS_INVALID_PARAMETER;
- }
- base = &validation->sam2->base;
+ case 2:
+ if (!validation || !validation->sam2) {
+ return NT_STATUS_INVALID_PARAMETER;
+ }
+ base = &validation->sam2->base;
break;
- case 3:
- if (!validation || !validation->sam3) {
- return NT_STATUS_INVALID_PARAMETER;
- }
- base = &validation->sam3->base;
+ case 3:
+ if (!validation || !validation->sam3) {
+ return NT_STATUS_INVALID_PARAMETER;
+ }
+ base = &validation->sam3->base;
break;
- case 6:
- if (!validation || !validation->sam6) {
- return NT_STATUS_INVALID_PARAMETER;
- }
- base = &validation->sam6->base;
+ case 6:
+ if (!validation || !validation->sam6) {
+ return NT_STATUS_INVALID_PARAMETER;
+ }
+ base = &validation->sam6->base;
break;
+ default:
+ return NT_STATUS_INVALID_LEVEL;
}
nt_status = make_server_info(mem_ctx, server_info, internal_username);