diff options
author | Khem Raj <raj.khem@gmail.com> | 2021-03-04 11:38:40 -0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2021-03-14 16:33:59 +0000 |
commit | eec64066073428e38d5b0b6947ff302943188f65 (patch) | |
tree | ec55d656734941dee8b2a599b588a12cc174337d /meta/recipes-core/glib-2.0/glib-2.0/0010-kqueue-Fix-unlocked-access-to-shared-variable.patch | |
parent | 8a74a7deca45ceef351f47a9f160df9bafc0f546 (diff) | |
download | poky-eec64066073428e38d5b0b6947ff302943188f65.tar.gz |
glib-2.0: Drop volatile qualifier
Fixes
glib/gatomic.h:112:5: error: argument 2 of '__atomic_load' discards 'volatile' qualifier [-Werror=incompatible-pointer-types]
(From OE-Core rev: 06ac55a06f2300fa5442ec73a28c3f52022cc640)
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/glib-2.0/glib-2.0/0010-kqueue-Fix-unlocked-access-to-shared-variable.patch')
-rw-r--r-- | meta/recipes-core/glib-2.0/glib-2.0/0010-kqueue-Fix-unlocked-access-to-shared-variable.patch | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/meta/recipes-core/glib-2.0/glib-2.0/0010-kqueue-Fix-unlocked-access-to-shared-variable.patch b/meta/recipes-core/glib-2.0/glib-2.0/0010-kqueue-Fix-unlocked-access-to-shared-variable.patch new file mode 100644 index 0000000000..e52b709422 --- /dev/null +++ b/meta/recipes-core/glib-2.0/glib-2.0/0010-kqueue-Fix-unlocked-access-to-shared-variable.patch | |||
@@ -0,0 +1,51 @@ | |||
1 | From e4e88688a0722237effc56cc21438d0c8e82de88 Mon Sep 17 00:00:00 2001 | ||
2 | From: Philip Withnall <pwithnall@endlessos.org> | ||
3 | Date: Wed, 11 Nov 2020 18:29:26 +0000 | ||
4 | Subject: [PATCH 10/29] kqueue: Fix unlocked access to shared variable | ||
5 | MIME-Version: 1.0 | ||
6 | Content-Type: text/plain; charset=UTF-8 | ||
7 | Content-Transfer-Encoding: 8bit | ||
8 | |||
9 | And drop the `volatile` qualifier because it doesn’t help. | ||
10 | |||
11 | Signed-off-by: Philip Withnall <pwithnall@endlessos.org> | ||
12 | |||
13 | Helps: #600 | ||
14 | Upstream-Status: Backport [https://gitlab.gnome.org/GNOME/glib/-/merge_requests/1719] | ||
15 | --- | ||
16 | gio/kqueue/kqueue-missing.c | 5 +++-- | ||
17 | 1 file changed, 3 insertions(+), 2 deletions(-) | ||
18 | |||
19 | diff --git a/gio/kqueue/kqueue-missing.c b/gio/kqueue/kqueue-missing.c | ||
20 | index 37af82e5b..d1ffdf4bd 100644 | ||
21 | --- a/gio/kqueue/kqueue-missing.c | ||
22 | +++ b/gio/kqueue/kqueue-missing.c | ||
23 | @@ -34,7 +34,7 @@ static gboolean km_debug_enabled = FALSE; | ||
24 | static GSList *missing_subs_list = NULL; | ||
25 | G_LOCK_DEFINE_STATIC (missing_lock); | ||
26 | |||
27 | -static volatile gboolean scan_missing_running = FALSE; | ||
28 | +static gboolean scan_missing_running = FALSE; /* must be accessed under @missing_lock */ | ||
29 | |||
30 | |||
31 | static gboolean | ||
32 | @@ -62,7 +62,6 @@ _km_add_missing (kqueue_sub *sub) | ||
33 | |||
34 | KM_W ("adding %s to missing list\n", sub->filename); | ||
35 | missing_subs_list = g_slist_prepend (missing_subs_list, sub); | ||
36 | - G_UNLOCK (missing_lock); | ||
37 | |||
38 | if (!scan_missing_running) | ||
39 | { | ||
40 | @@ -73,6 +72,8 @@ _km_add_missing (kqueue_sub *sub) | ||
41 | g_source_attach (source, GLIB_PRIVATE_CALL (g_get_worker_context) ()); | ||
42 | g_source_unref (source); | ||
43 | } | ||
44 | + | ||
45 | + G_UNLOCK (missing_lock); | ||
46 | } | ||
47 | |||
48 | /** | ||
49 | -- | ||
50 | 2.30.1 | ||
51 | |||