]> git.ipfire.org Git - thirdparty/krb5.git/commitdiff
Work around uninitialized warning in logger.c 395/head
authorGreg Hudson <ghudson@mit.edu>
Thu, 14 Jan 2016 17:24:31 +0000 (12:24 -0500)
committerGreg Hudson <ghudson@mit.edu>
Thu, 14 Jan 2016 17:24:31 +0000 (12:24 -0500)
gcc 4.6.3 erroneously detects uninitialized use of the variable f
after commit 9914b93516bbce9b1123ed5f9f796b7028944892.  Initialize it
to work around this warning.

ticket: 8344

src/lib/kadm5/logger.c

index f4a93877619b11b4f1e2b8e569c3576ce8cb39ed..3c314ffc7369bf7bfe2368e58aaaba09156593c7 100644 (file)
@@ -359,7 +359,7 @@ krb5_klog_init(krb5_context kcontext, char *ename, char *whoami, krb5_boolean do
     char        savec = '\0';
     int         error;
     int         do_openlog, log_facility;
-    FILE        *f;
+    FILE        *f = NULL;
 
     /* Initialize */
     do_openlog = 0;