File: gdm-settings-utils-rename-variable-to-fix-build-with-gcc-.patch

package info (click to toggle)
gdm3 48.0-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 9,852 kB
  • sloc: ansic: 30,730; sh: 1,709; xml: 539; makefile: 82
file content (51 lines) | stat: -rw-r--r-- 2,417 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
From: =?utf-8?q?Zbigniew_J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
Date: Mon, 27 Jan 2025 14:01:23 +0100
Subject: gdm-settings-utils: rename variable to fix build with gcc 15

In GNU23 C, bool is a keyword. Rename the variable to avoid syntax error.

Origin: upstream, 49.alpha.0, commit:2fbc2ac50b9f143eb594e5f77a8051222ffbd2c9
Bug-Debian: https://bugs.debian.org/1096689
---
 common/gdm-settings-utils.c | 8 ++++----
 common/gdm-settings-utils.h | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/common/gdm-settings-utils.c b/common/gdm-settings-utils.c
index 636be3a..da4c7ae 100644
--- a/common/gdm-settings-utils.c
+++ b/common/gdm-settings-utils.c
@@ -287,16 +287,16 @@ gdm_settings_parse_boolean_as_value  (gboolean boolval)
 /* adapted from GKeyFile */
 gboolean
 gdm_settings_parse_value_as_boolean (const char *value,
-                                     gboolean   *bool)
+                                     gboolean   *boolval)
 {
         g_return_val_if_fail (value != NULL, FALSE);
-        g_return_val_if_fail (bool != NULL, FALSE);
+        g_return_val_if_fail (boolval != NULL, FALSE);
 
         if (g_ascii_strcasecmp (value, "true") == 0 || strcmp (value, "1") == 0) {
-                *bool = TRUE;
+                *boolval = TRUE;
                 return TRUE;
         } else if (g_ascii_strcasecmp (value, "false") == 0 || strcmp (value, "0") == 0) {
-                *bool = FALSE;
+                *boolval = FALSE;
                 return TRUE;
         } else {
                 return FALSE;
diff --git a/common/gdm-settings-utils.h b/common/gdm-settings-utils.h
index 4f2362c..734d625 100644
--- a/common/gdm-settings-utils.h
+++ b/common/gdm-settings-utils.h
@@ -44,7 +44,7 @@ gboolean                  gdm_settings_parse_schemas           (const char  *fil
                                                                 GSList     **list);
 
 gboolean                  gdm_settings_parse_value_as_boolean  (const char *value,
-                                                                gboolean   *bool);
+                                                                gboolean   *boolval);
 gboolean                  gdm_settings_parse_value_as_integer  (const char *value,
                                                                 int        *intval);
 gboolean                  gdm_settings_parse_value_as_double   (const char *value,