! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Fix undeclared
Status:
RESOLVED: FIXED
Product:
Xfce4-sensors-plugin
Component:
General

Comments

Description poma 2017-02-14 14:28:09 CET
[PATCH] Fix error: ‘gdir’ undeclared
...
hddtemp.c: In function ‘read_disks_fallback’:
hddtemp.c:252:18: error: ‘gdir’ undeclared (first use in this function)
     g_dir_close (gdir);
                  ^~~~
hddtemp.c:252:18: note: each undeclared identifier is reported only once for each function it appears in
...

---
 lib/hddtemp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/hddtemp.c b/lib/hddtemp.c
index 1c34f77..345e540 100644
--- a/lib/hddtemp.c
+++ b/lib/hddtemp.c
@@ -249,7 +249,7 @@ read_disks_fallback (t_chip *chip)
         }
     }
 
-    g_dir_close (gdir);
+    g_dir_close (ptr_dir);
 
     /* FIXME: read SCSI info from where? SATA?  */
 
--
Comment 1 Fabian Nowak editbugs 2017-02-15 17:29:46 CET
Whoops, yes, missed checking the different possibilities for compiling the sensors plugin. Will checkin fix soon.
Comment 2 poma 2017-02-16 02:39:10 CET
[PATCH] Fix error: ‘chip’ undeclared

hddtemp.c: In function ‘initialize_hddtemp’:
hddtemp.c:404:29: error: ‘chip’ undeclared (first use in this function)
         read_disks_linux26 (chip);
                             ^~~~
hddtemp.c:404:29: note: each undeclared identifier is reported only once for each function it appears in
...

hddtemp.c: In function ‘initialize_hddtemp’:
hddtemp.c:406:30: error: ‘chip’ undeclared (first use in this function)
         read_disks_fallback (chip); /* hopefully, that's a safe variant */
                              ^~~~
hddtemp.c:406:30: note: each undeclared identifier is reported only once for each function it appears in

---
 lib/hddtemp.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/hddtemp.c b/lib/hddtemp.c
index 478ad78..68a14e2 100644
--- a/lib/hddtemp.c
+++ b/lib/hddtemp.c
@@ -401,9 +401,9 @@ initialize_hddtemp (GPtrArray *arr_ptr_chips, gboolean *suppressmessage)
      and major/minor number stuff from compile time*/
 
     if (strcmp(p_uname->sysname, "Linux")==0 && (generation>=3 || (generation==2 && major>=5)))
-        read_disks_linux26 (chip);
+        read_disks_linux26 (ptr_chip);
     else
-        read_disks_fallback (chip); /* hopefully, that's a safe variant */
+        read_disks_fallback (ptr_chip); /* hopefully, that's a safe variant */
 
     g_free(p_uname);
 #endif
--
Comment 3 Fabian Nowak editbugs 2017-02-16 22:42:58 CET
Thanks again, sorry for the trouble. Committed and pushed (95481be..1796bf8).

Bug #13354

Reported by:
poma
Reported on: 2017-02-14
Last modified on: 2017-02-16

People

Assignee:
Fabian Nowak
CC List:
0 users

Version

Version:
unspecified

Attachments

Additional information