aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Colascione2014-02-21 16:47:42 -0800
committerDaniel Colascione2014-02-21 16:47:42 -0800
commit4e6526341d2a8a5884e760ed6815f0de22529b15 (patch)
tree1ae3f5032d97394457c0931e72230f122baaeede
parent363362c5cb752d9764cef33d3989d49687d1b4bc (diff)
downloademacs-4e6526341d2a8a5884e760ed6815f0de22529b15.tar.gz
emacs-4e6526341d2a8a5884e760ed6815f0de22529b15.zip
Additional type checking in secrets API
-rw-r--r--lisp/ChangeLog6
-rw-r--r--lisp/net/secrets.el4
2 files changed, 10 insertions, 0 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 6fb588381fe..82c24f11643 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,9 @@
12014-02-22 Daniel Colascione <dancol@dancol.org>
2
3 * net/secrets.el (secrets-create-item,secrets-search-items): Check
4 that attribute values are strings, avoiding the construction of
5 invalid dbus messages.
6
12014-02-21 Juanma Barranquero <lekktu@gmail.com> 72014-02-21 Juanma Barranquero <lekktu@gmail.com>
2 8
3 * emacs-lisp/gv.el: Avoid duplicating gv-expander and gv-setter in 9 * emacs-lisp/gv.el: Avoid duplicating gv-expander and gv-setter in
diff --git a/lisp/net/secrets.el b/lisp/net/secrets.el
index a0f30e321d5..9ba9bd0d3cc 100644
--- a/lisp/net/secrets.el
+++ b/lisp/net/secrets.el
@@ -609,6 +609,8 @@ The object paths of the found items are returned as list."
609 (while (consp (cdr attributes)) 609 (while (consp (cdr attributes))
610 (unless (keywordp (car attributes)) 610 (unless (keywordp (car attributes))
611 (error 'wrong-type-argument (car attributes))) 611 (error 'wrong-type-argument (car attributes)))
612 (unless (stringp (cadr attributes))
613 (error 'wrong-type-argument (cadr attributes)))
612 (setq props (add-to-list 614 (setq props (add-to-list
613 'props 615 'props
614 (list :dict-entry 616 (list :dict-entry
@@ -647,6 +649,8 @@ The object path of the created item is returned."
647 (while (consp (cdr attributes)) 649 (while (consp (cdr attributes))
648 (unless (keywordp (car attributes)) 650 (unless (keywordp (car attributes))
649 (error 'wrong-type-argument (car attributes))) 651 (error 'wrong-type-argument (car attributes)))
652 (unless (stringp (cadr attributes))
653 (error 'wrong-type-argument (cadr attributes)))
650 (setq props (add-to-list 654 (setq props (add-to-list
651 'props 655 'props
652 (list :dict-entry 656 (list :dict-entry