international/mule-cmds.el (select-safe-coding-system): Remove a superfluous conditio...
authorKenichi Handa <handa@gnu.org>
Sun, 13 Oct 2013 09:25:29 +0000 (18:25 +0900)
committerKenichi Handa <handa@gnu.org>
Sun, 13 Oct 2013 09:25:29 +0000 (18:25 +0900)
lisp/ChangeLog
lisp/international/mule-cmds.el

index c3d57e8..f4508b7 100644 (file)
@@ -1,3 +1,9 @@
+2013-10-13  Kenichi Handa  <handa@gnu.org>
+
+       * international/mule-cmds.el (select-safe-coding-system): Remove a
+       superfluous condition in chekcing whether a coding system is safe
+       or not.
+
 2013-10-11  Stefan Monnier  <monnier@iro.umontreal.ca>
 
        * progmodes/sh-script.el: Provide simpl(e|istic) completion.
index 588460b..63cbfc8 100644 (file)
@@ -976,13 +976,17 @@ It is highly recommended to fix it before writing to a file."
 
        ;; Classify the defaults into safe, rejected, and unsafe.
        (dolist (elt default-coding-system)
-         (if (or (eq (coding-system-type (car elt)) 'undecided)
-                 (memq (cdr elt) codings))
+         (if (memq (cdr elt) codings)
+             ;; This is safe.  Is it acceptable?
              (if (and (functionp accept-default-p)
                       (not (funcall accept-default-p (cdr elt))))
+                 ;; No, not acceptable.
                  (push (car elt) rejected)
+               ;; Yes, acceptable.
                (push (car elt) safe))
+           ;; This is not safe.
            (push (car elt) unsafe)))
+       ;; If there are safe ones, the first one is what we want.
        (if safe
            (setq coding-system (car safe))))