summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGlenn Morris <rgm@gnu.org>2014-05-11 23:59:30 -0700
committerGlenn Morris <rgm@gnu.org>2014-05-11 23:59:30 -0700
commitbbbabffe06d4c763534d5be92844c48a3f8746e2 (patch)
treea6fffb13638948223f3142e5209cbce57282fbbd /src
parentffd6d9c4d321e93e301f9cafd1fe054389898978 (diff)
parent96b894717caa773aa6d98ff57385f1c7537e8972 (diff)
Merge from emacs-24; up to 2014-05-12T06:15:47Z!rgm@gnu.org
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog9
-rw-r--r--src/fileio.c4
-rw-r--r--src/xsettings.c22
3 files changed, 29 insertions, 6 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 72e78724bab..5d06882cee7 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,12 @@
+2014-05-12 Glenn Morris <rgm@gnu.org>
+
+ * fileio.c (Ffile_executable_p): Doc tweak.
+
+2014-05-12 Jan Djärv <jan.h.d@swipnet.se>
+
+ * xsettings.c (init_gsettings): Use g_settings_schema_source_lookup
+ instead of deprecated g_settings_list_schemas if possible (Bug#17434).
+
2014-05-08 Paul Eggert <eggert@cs.ucla.edu>
* minibuf.c (read_minibuf): Avoid C99ism in previous patch (Bug#17430).
diff --git a/src/fileio.c b/src/fileio.c
index 5659b6555d8..dcee70aa8b4 100644
--- a/src/fileio.c
+++ b/src/fileio.c
@@ -2546,7 +2546,9 @@ Use `file-symlink-p' to test for such links. */)
DEFUN ("file-executable-p", Ffile_executable_p, Sfile_executable_p, 1, 1, 0,
doc: /* Return t if FILENAME can be executed by you.
-For a directory, this means you can access files in that directory. */)
+For a directory, this means you can access files in that directory.
+\(It is generally better to use `file-accessible-directory-p' for that
+purpose, though.) */)
(Lisp_Object filename)
{
Lisp_Object absname;
diff --git a/src/xsettings.c b/src/xsettings.c
index 844da19f638..5f4275df545 100644
--- a/src/xsettings.c
+++ b/src/xsettings.c
@@ -795,17 +795,29 @@ init_gsettings (void)
{
#ifdef HAVE_GSETTINGS
GVariant *val;
- const gchar *const *schemas;
int schema_found = 0;
#if ! GLIB_CHECK_VERSION (2, 36, 0)
g_type_init ();
#endif
- schemas = g_settings_list_schemas ();
- if (schemas == NULL) return;
- while (! schema_found && *schemas != NULL)
- schema_found = strcmp (*schemas++, GSETTINGS_SCHEMA) == 0;
+#if GLIB_CHECK_VERSION (2, 32, 0)
+ {
+ GSettingsSchema *sc = g_settings_schema_source_lookup
+ (g_settings_schema_source_get_default (),
+ GSETTINGS_SCHEMA,
+ TRUE);
+ schema_found = sc != NULL;
+ if (sc) g_settings_schema_unref (sc);
+ }
+#else
+ {
+ const gchar *const *schemas = g_settings_list_schemas ();
+ if (schemas == NULL) return;
+ while (! schema_found && *schemas != NULL)
+ schema_found = strcmp (*schemas++, GSETTINGS_SCHEMA) == 0;
+ }
+#endif
if (!schema_found) return;
gsettings_client = g_settings_new (GSETTINGS_SCHEMA);