emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r111860: gnus-registry.el (gnus-regis


From: Katsumi Yamaoka
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r111860: gnus-registry.el (gnus-registry-save): Provide class name when calling `eieio-persistent-read' to avoid "unsafe call" warning Use `condition-case' to stay compatible with older EIEIO versions which only accept one argument
Date: Fri, 22 Feb 2013 22:54:37 +0000
User-agent: Bazaar (2.5.0)

------------------------------------------------------------
revno: 111860
author: David Engster <address@hidden>
committer: Katsumi Yamaoka <address@hidden>
branch nick: trunk
timestamp: Fri 2013-02-22 22:54:37 +0000
message:
  gnus-registry.el (gnus-registry-save): Provide class name when calling 
`eieio-persistent-read' to avoid "unsafe call" warning  Use `condition-case' to 
stay compatible with older EIEIO versions which only accept one argument
modified:
  lisp/gnus/ChangeLog
  lisp/gnus/gnus-registry.el
=== modified file 'lisp/gnus/ChangeLog'
--- a/lisp/gnus/ChangeLog       2013-02-17 12:46:28 +0000
+++ b/lisp/gnus/ChangeLog       2013-02-22 22:54:37 +0000
@@ -1,3 +1,10 @@
+2013-02-22  David Engster  <address@hidden>
+
+       * gnus-registry.el (gnus-registry-save): Provide class name when
+       calling `eieio-persistent-read' to avoid "unsafe call" warning.  Use
+       `condition-case' to stay compatible with older EIEIO versions which
+       only accept one argument.
+
 2013-02-17  Daiki Ueno  <address@hidden>
 
        * mml2015.el (epg-key-user-id-list, epg-user-id-string)

=== modified file 'lisp/gnus/gnus-registry.el'
--- a/lisp/gnus/gnus-registry.el        2013-01-02 16:13:04 +0000
+++ b/lisp/gnus/gnus-registry.el        2013-02-22 22:54:37 +0000
@@ -296,8 +296,14 @@
     (condition-case nil
         (progn
           (gnus-message 5 "Reading Gnus registry from %s..." file)
-          (setq gnus-registry-db (gnus-registry-fixup-registry
-                                  (eieio-persistent-read file)))
+          (setq gnus-registry-db
+               (gnus-registry-fixup-registry
+                (condition-case nil
+                    (with-no-warnings
+                      (eieio-persistent-read file 'registry-db))
+                  ;; Older EIEIO versions do not check the class name.
+                  ('wrong-number-of-arguments
+                   (eieio-persistent-read file)))))
           (gnus-message 5 "Reading Gnus registry from %s...done" file))
       (error
        (gnus-message


reply via email to

[Prev in Thread] Current Thread [Next in Thread]