don't use function-equal in nadvice
[bpt/emacs.git] / src / gfilenotify.c
index 4e684d1..aea6c83 100644 (file)
@@ -1,5 +1,5 @@
 /* Filesystem notifications support with glib API.
-   Copyright (C) 2013 Free Software Foundation, Inc.
+   Copyright (C) 2013-2014 Free Software Foundation, Inc.
 
 This file is part of GNU Emacs.
 
@@ -173,7 +173,7 @@ will be reported only in case of the 'moved' event.  */)
   CHECK_STRING (file);
   file = Fdirectory_file_name (Fexpand_file_name (file, Qnil));
   if (NILP (Ffile_exists_p (file)))
-    report_file_error ("File does not exists", Fcons (file, Qnil));
+    report_file_error ("File does not exist", file);
 
   CHECK_LIST (flags);
 
@@ -249,20 +249,19 @@ WATCH-DESCRIPTOR should be an object returned by `gfile-add-watch'.  */)
 void
 globals_of_gfilenotify (void)
 {
+#if ! GLIB_CHECK_VERSION (2, 36, 0)
   g_type_init ();
+#endif
   watch_list = Qnil;
 }
 
 void
 syms_of_gfilenotify (void)
 {
+#include "gfilenotify.x"
 
   DEFSYM (Qgfile_add_watch, "gfile-add-watch");
-  defsubr (&Sgfile_add_watch);
-
   DEFSYM (Qgfile_rm_watch, "gfile-rm-watch");
-  defsubr (&Sgfile_rm_watch);
-
   DEFSYM (Qwatch_mounts, "watch-mounts");
   DEFSYM (Qsend_moved, "send-moved");
   DEFSYM (Qchanged, "changed");