error: .. may be used uninitialized in this function
Eray Aslan
eray.aslan at caf.com.tr
Thu Mar 22 06:47:38 EDT 2012
The patch below quietens -Werror=uninitialized compile errors for
krb5-1.10.1 with gcc-4.6.2.
--- a/src/kdc/do_as_req.c
+++ b/src/kdc/do_as_req.c
@@ -191,6 +191,7 @@ finish_process_as_req(struct as_req_state *state, krb5_error_code errcode)
* by request keytype list.
*/
client_key = NULL;
+ useenctype = 0;
for (i = 0; i < state->request->nktypes; i++) {
useenctype = state->request->ktype[i];
if (!krb5_c_valid_enctype(useenctype))
--- a/src/lib/kadm5/srv/svr_iters.c
+++ b/src/lib/kadm5/srv/svr_iters.c
@@ -187,7 +187,7 @@ static kadm5_ret_t kadm5_get_either(int princ,
#ifdef BSD_REGEXPS
char *msg;
#endif
- char *regexp;
+ char *regexp = NULL;
int i, ret;
kadm5_server_handle_t handle = server_handle;
--- a/src/slave/kprop.c
+++ b/src/slave/kprop.c
@@ -91,7 +91,7 @@ main(argc, argv)
int argc;
char **argv;
{
- int fd, database_fd, database_size;
+ int fd = 0, database_fd, database_size;
krb5_error_code retval;
krb5_context context;
krb5_creds *my_creds;
--
Eray Aslan
More information about the krbdev
mailing list