Accepting request 1003109 from home:yfjiang:branches:GNOME:Factory
- Bring back 0001-gvdb-Restore-permissions-on-changed-files.patch since the useful fix was never merged to upstream (bsc#971074 bgo#758066 bsc#1203344). OBS-URL: https://build.opensuse.org/request/show/1003109 OBS-URL: https://build.opensuse.org/package/show/GNOME:Factory/dconf?expand=0&rev=117
This commit is contained in:
parent
032c8dc91c
commit
54095054b9
35
0001-gvdb-Restore-permissions-on-changed-files.patch
Normal file
35
0001-gvdb-Restore-permissions-on-changed-files.patch
Normal file
@ -0,0 +1,35 @@
|
||||
diff --git a/gvdb/gvdb-builder.c b/gvdb/gvdb-builder.c
|
||||
index 90ea50b..cf5f1f4 100644
|
||||
--- a/gvdb/gvdb-builder.c
|
||||
+++ b/gvdb/gvdb-builder.c
|
||||
@@ -21,6 +21,7 @@
|
||||
#include "gvdb-format.h"
|
||||
|
||||
#include <glib.h>
|
||||
+#include <glib/gstdio.h>
|
||||
#include <fcntl.h>
|
||||
#if !defined(G_OS_WIN32) || !defined(_MSC_VER)
|
||||
#include <unistd.h>
|
||||
@@ -509,13 +510,22 @@ gvdb_table_write_contents (GHashTable *table,
|
||||
gboolean status;
|
||||
FileBuilder *fb;
|
||||
GString *str;
|
||||
+ GStatBuf buf;
|
||||
+ gint stat_ret;
|
||||
|
||||
fb = file_builder_new (byteswap);
|
||||
file_builder_add_hash (fb, table, &root);
|
||||
str = file_builder_serialise (fb, root);
|
||||
|
||||
+ stat_ret = g_stat (filename, &buf);
|
||||
+
|
||||
status = g_file_set_contents (filename, str->str, str->len, error);
|
||||
g_string_free (str, TRUE);
|
||||
|
||||
+ if (stat_ret == 0)
|
||||
+ g_chmod (filename, buf.st_mode);
|
||||
+ else
|
||||
+ g_chmod (filename, 0644);
|
||||
+
|
||||
return status;
|
||||
}
|
@ -1,3 +1,10 @@
|
||||
-------------------------------------------------------------------
|
||||
Tue Sep 13 06:33:51 UTC 2022 - Yifan Jiang <yfjiang@suse.com>
|
||||
|
||||
- Bring back 0001-gvdb-Restore-permissions-on-changed-files.patch
|
||||
since the useful fix was never merged to upstream (bsc#971074
|
||||
bgo#758066 bsc#1203344).
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Mar 18 14:20:52 UTC 2021 - Dominique Leuenberger <dimstar@opensuse.org>
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package dconf
|
||||
#
|
||||
# Copyright (c) 2021 SUSE LLC
|
||||
# Copyright (c) 2022 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -25,6 +25,8 @@ Group: System/Libraries
|
||||
URL: https://live.gnome.org/dconf
|
||||
Source0: https://download.gnome.org/sources/dconf/0.40/%{name}-%{version}.tar.xz
|
||||
Source99: baselibs.conf
|
||||
# PATCH-FIX-UPSTREAM 0001-gvdb-Restore-permissions-on-changed-files.patch bsc#971074 bgo#758066 bsc#1203344 fezhang@suse.com -- Restore permissions on files changed by dconf update.
|
||||
Patch0: 0001-gvdb-Restore-permissions-on-changed-files.patch
|
||||
BuildRequires: docbook-xsl-stylesheets
|
||||
BuildRequires: gtk-doc
|
||||
BuildRequires: meson
|
||||
|
Loading…
Reference in New Issue
Block a user