diff options
author | Andreas Schwab <schwab@linux-m68k.org> | 2015-10-03 14:21:48 +0200 |
---|---|---|
committer | Andreas Schwab <schwab@linux-m68k.org> | 2015-10-03 14:50:50 +0200 |
commit | b235ceaaf69345a5c79ec96ce0ca61b29fb232e1 (patch) | |
tree | 0b116e6b34ebbcf325e2a58e518260822d014faa /src/coding.c | |
parent | 272ca096356e30c67ce337855da7531994040255 (diff) | |
download | emacs-b235ceaaf69345a5c79ec96ce0ca61b29fb232e1.tar.gz |
More validatation of coding systems
* src/fileio.c (Finsert_file_contents): Remove redundant
coding-system check.
(choose_write_coding_system): Likewise.
* src/coding.c (complement_process_encoding_system): Check
argument for valid coding system.
Diffstat (limited to 'src/coding.c')
-rw-r--r-- | src/coding.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/coding.c b/src/coding.c index d2655310cd3..31bffeab5c9 100644 --- a/src/coding.c +++ b/src/coding.c @@ -6004,7 +6004,8 @@ coding_inherit_eol_type (Lisp_Object coding_system, Lisp_Object parent) if (NILP (coding_system)) coding_system = Qraw_text; - CHECK_CODING_SYSTEM (coding_system); + else + CHECK_CODING_SYSTEM (coding_system); spec = CODING_SYSTEM_SPEC (coding_system); eol_type = AREF (spec, 2); if (VECTORP (eol_type)) @@ -6051,6 +6052,7 @@ complement_process_encoding_system (Lisp_Object coding_system) coding_system = CDR_SAFE (Vdefault_process_coding_system); else if (i == 2) coding_system = preferred_coding_system (); + CHECK_CODING_SYSTEM (coding_system); spec = CODING_SYSTEM_SPEC (coding_system); if (NILP (spec)) continue; |