summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLukas Slebodnik <lslebodn@redhat.com>2013-07-18 11:44:24 +0200
committerJakub Hrozek <jhrozek@redhat.com>2013-07-22 11:44:09 +0200
commit08e3f641a8b8d6b5d7eb0b523599702eda960da2 (patch)
tree1df65df3a326aca81d3bb003502668184268a421 /src
parentd6c2ee96f5f181f21b0003aa8f3506e82522291d (diff)
downloadsssd-08e3f641a8b8d6b5d7eb0b523599702eda960da2.tar.gz
sssd-08e3f641a8b8d6b5d7eb0b523599702eda960da2.tar.bz2
sssd-08e3f641a8b8d6b5d7eb0b523599702eda960da2.zip
Fix warnings: uninitialized variable
Diffstat (limited to 'src')
-rw-r--r--src/providers/krb5/krb5_child.c3
-rw-r--r--src/providers/krb5/krb5_child_handler.c4
-rw-r--r--src/sss_client/ssh/sss_ssh_client.c2
-rw-r--r--src/util/usertools.c2
4 files changed, 5 insertions, 6 deletions
diff --git a/src/providers/krb5/krb5_child.c b/src/providers/krb5/krb5_child.c
index 051079fd..47c8fb29 100644
--- a/src/providers/krb5/krb5_child.c
+++ b/src/providers/krb5/krb5_child.c
@@ -1820,8 +1820,7 @@ static krb5_error_code check_fast_ccache(TALLOC_CTX *mem_ctx,
tmp_ctx = talloc_new(NULL);
if (tmp_ctx == NULL) {
DEBUG(1, ("talloc_new failed.\n"));
- kerr = ENOMEM;
- goto done;
+ return ENOMEM;
}
ccname = talloc_asprintf(tmp_ctx, "FILE:%s/fast_ccache_%s", DB_PATH, realm);
diff --git a/src/providers/krb5/krb5_child_handler.c b/src/providers/krb5/krb5_child_handler.c
index dda53ab1..044c2719 100644
--- a/src/providers/krb5/krb5_child_handler.c
+++ b/src/providers/krb5/krb5_child_handler.c
@@ -486,7 +486,7 @@ parse_krb5_child_response(TALLOC_CTX *mem_ctx, uint8_t *buf, ssize_t len,
errno_t ret;
bool skip;
char *ccname = NULL;
- size_t ccname_len;
+ size_t ccname_len = 0;
int32_t msg_status;
int32_t msg_type;
int32_t msg_len;
@@ -496,7 +496,7 @@ parse_krb5_child_response(TALLOC_CTX *mem_ctx, uint8_t *buf, ssize_t len,
uint32_t *msg_subtype;
struct krb5_child_response *res;
const char *upn = NULL;
- size_t upn_len;
+ size_t upn_len = 0;
bool otp = false;
if ((size_t) len < sizeof(int32_t)) {
diff --git a/src/sss_client/ssh/sss_ssh_client.c b/src/sss_client/ssh/sss_ssh_client.c
index 5312dba2..245a0205 100644
--- a/src/sss_client/ssh/sss_ssh_client.c
+++ b/src/sss_client/ssh/sss_ssh_client.c
@@ -106,7 +106,7 @@ sss_ssh_get_ent(TALLOC_CTX *mem_ctx,
errno_t ret;
uint32_t flags;
uint32_t name_len;
- uint32_t alias_len;
+ uint32_t alias_len = 0;
uint32_t domain_len;
size_t req_len;
uint8_t *req = NULL;
diff --git a/src/util/usertools.c b/src/util/usertools.c
index 7ec14b35..9edae41e 100644
--- a/src/util/usertools.c
+++ b/src/util/usertools.c
@@ -394,7 +394,7 @@ int sss_parse_name_for_domains(TALLOC_CTX *memctx,
const char *default_domain,
const char *orig, char **domain, char **name)
{
- struct sss_domain_info *dom, *match;
+ struct sss_domain_info *dom, *match = NULL;
char *rdomain, *rname;
char *dmatch, *nmatch;
char *candidate_name = NULL;