poke-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[COMMITTED] ios-dev-file.c: avoid using uninitialized variable


From: Jose E. Marchesi
Subject: [COMMITTED] ios-dev-file.c: avoid using uninitialized variable
Date: Sat, 27 Feb 2021 09:25:07 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

commit d96978ffb6cf36075ee91283be8eb1d1a46f8bd8 (HEAD -> master, origin/master, 
origin/HEAD)
Author: Jose E. Marchesi <jose.marchesi@oracle.com>
Date:   Sat Feb 27 09:22:18 2021 +0100

    ios-dev-file.c: avoid using uninitialized variable
    
    2021-02-27  Jose E. Marchesi  <jemarch@gnu.org>
    
            * libpoke/ios-dev-file.c (ios_dev_file_open): Avoid accessing to
            an uninitialized variable.

diff --git a/ChangeLog b/ChangeLog
index 6b2069c6..15ddeb6a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2021-02-27  Jose E. Marchesi  <jemarch@gnu.org>
+
+       * libpoke/ios-dev-file.c (ios_dev_file_open): Avoid accessing to
+       an uninitialized variable.
+
 2021-02-27  Thomas WeiƟschuh <thomas@t-8ch.de>
 
        * configure.ac: Call AX_CREATE_PKGCONFIG_INFO.
diff --git a/libpoke/ios-dev-file.c b/libpoke/ios-dev-file.c
index 5584ed37..5d39d19c 100644
--- a/libpoke/ios-dev-file.c
+++ b/libpoke/ios-dev-file.c
@@ -67,7 +67,7 @@ static void *
 ios_dev_file_open (const char *handler, uint64_t flags, int *error)
 {
   struct ios_dev_file *fio = NULL;
-  FILE *f;
+  FILE *f = NULL;
   int internal_error = IOD_ERROR;
   const char *mode;
   uint8_t flags_mode = flags & IOS_FLAGS_MODE;



reply via email to

[Prev in Thread] Current Thread [Next in Thread]