1. 04 Apr, 2012 1 commit
    • Chong Yidong's avatar
      Several miscellaneous doc changes. · 3d439cd1
      Chong Yidong authored
      * doc/lispref/display.texi (Delayed Warnings): New node.
      
      * doc/misc/gnus-faq.texi (FAQ 8-2): Mention EasyPG.
      
      * doc/misc/gnus.texi: Reduce references to obsolete pgg library.
      (Security): Note that epg is now the default.
      
      * doc/misc/message.texi (Using PGP/MIME): Note that epg is now the default.
      
      * doc/misc/nxml-mode.texi (Completion): C-RET is no longer bound to
      nxml-complete.
      
      * lisp/subr.el (delayed-warnings-hook): Doc fix.
      
      * src/keyboard.c (Vdelayed_warnings_list): Doc fix.
      3d439cd1
  2. 28 Mar, 2012 1 commit
  3. 26 Mar, 2012 1 commit
  4. 24 Feb, 2012 1 commit
  5. 04 Feb, 2012 1 commit
  6. 26 Jan, 2012 1 commit
  7. 11 Jan, 2012 2 commits
  8. 05 Jan, 2012 1 commit
  9. 05 Dec, 2011 1 commit
  10. 04 Dec, 2011 2 commits
    • Andreas Schwab's avatar
      Don't call Lisp in signal handler · 6c07aac2
      Andreas Schwab authored
      * emacs.c (Qkill_emacs): Define.
      (syms_of_emacs): Initialize it.
      * keyboard.c (interrupt_signal): Don't call Fkill_emacs here, set
      Qquit_flag to `kill-emacs' instead.
      (quit_throw_to_read_char): Add parameter `from_signal'.  All
      callers changed.  Call Fkill_emacs if requested and safe.
      * lisp.h (QUIT): Call Fkill_emacs if requested.
      6c07aac2
    • Paul Eggert's avatar
      Spelling fixes. · c80e3b4a
      Paul Eggert authored
      c80e3b4a
  11. 01 Dec, 2011 1 commit
  12. 28 Nov, 2011 1 commit
  13. 20 Nov, 2011 2 commits
  14. 19 Nov, 2011 1 commit
  15. 17 Nov, 2011 1 commit
  16. 14 Nov, 2011 2 commits
  17. 11 Nov, 2011 1 commit
  18. 06 Nov, 2011 1 commit
  19. 28 Oct, 2011 1 commit
  20. 25 Oct, 2011 1 commit
  21. 03 Oct, 2011 1 commit
  22. 09 Sep, 2011 1 commit
  23. 29 Aug, 2011 1 commit
    • Paul Eggert's avatar
      sprintf-related integer and memory overflow issues. · 62f19c19
      Paul Eggert authored
      * doprnt.c (doprnt): Support printing ptrdiff_t and intmax_t values.
      (esprintf, esnprintf, exprintf, evxprintf): New functions.
      * keyboard.c (command_loop_level): Now EMACS_INT, not int.
      (cmd_error): kbd macro iterations count is now EMACS_INT, not int.
      (modify_event_symbol): Do not assume that the length of
      name_alist_or_stem is safe to alloca and fits in int.
      (Fexecute_extended_command): Likewise for function name and binding.
      (Frecursion_depth): Wrap around reliably on integer overflow.
      * keymap.c (push_key_description): First arg is now EMACS_INT, not int,
      since some callers pass EMACS_INT values.
      (Fsingle_key_description): Don't crash if symbol name contains more
      than MAX_ALLOCA bytes.
      * minibuf.c (minibuf_level): Now EMACS_INT, not int.
      (get_minibuffer): Arg is now EMACS_INT, not int.
      * lisp.h (get_minibuffer, push_key_description): Reflect API changes.
      (esprintf, esnprintf, exprintf, evxprintf): New decls.
      * window.h (command_loop_level, minibuf_level): Reflect API changes.
      62f19c19
  24. 19 Aug, 2011 1 commit
  25. 04 Aug, 2011 1 commit
    • Jan Djärv's avatar
      Check for pthread and use it if found. · ae9e757a
      Jan Djärv authored
      * configure.in (HAVE_PTHREAD): Add check for -lpthread.
      (HAVE_GTK_AND_PTHREAD): Remove.
      
      * src/Makefile.in (LIB_PTHREAD): New variable.
      (LIBES): Add LIB_PTHREAD (Bug#9216).
      
      * src/alloc.c, src/emacs.c, src/gmalloc.c, src/gtkutil.c, src/keyboard.c, src/syssignal.h:
      Rename HAVE_GTK_AND_PTHREAD to HAVE_PTHREAD (Bug#9216).
      ae9e757a
  26. 29 Jul, 2011 1 commit
    • Paul Eggert's avatar
      * keyboard.c: Integer and memory overflow fixes. · 34db673b
      Paul Eggert authored
      (read_char, menu_bar_items, tool_bar_items, read_char_x_menu_prompt)
      (read_char_minibuf_menu_width, read_char_minibuf_menu_prompt)
      (follow_key, read_key_sequence): Use ptrdiff_t, not int, to count maps.
      (read_char_minibuf_menu_prompt): Check for overflow in size
      calculations.  Don't update size until allocation succeeds.  Redo
      calculations to avoid overflow.
      * keyboard.h: Change prototypes to match the above.
      34db673b
  27. 17 Jul, 2011 1 commit
    • Paul Eggert's avatar
      * keyboard.c: Overflow, signedness and related fixes. · b13995db
      Paul Eggert authored
      (make_lispy_movement): Use same integer type in forward decl
      that is used in the definition.
      (read_key_sequence, keyremap_step):
      Change bufsize argument back to int, undoing my 2011-03-30 change.
      We prefer signed types, and int is wide enough here.
      (parse_tool_bar_item): Don't assume tool_bar_max_label_size is less
      than TYPE_MAXIMUM (EMACS_INT) / 2.  Don't let the label size grow
      larger than STRING_BYTES_BOUND.  Use ptrdiff_t for Emacs string
      length, not size_t.  Use ptrdiff_t for index, not int.
      (keyremap_step, read_key_sequence): Redo bufsize check to avoid
      possibility of integer overflow.
      b13995db
  28. 14 Jul, 2011 1 commit
  29. 07 Jul, 2011 1 commit
  30. 02 Jul, 2011 2 commits
    • Chong Yidong's avatar
      Fix corner case in prefix-arg handling for mouse events (Bug#1586). · 7a8e04f7
      Chong Yidong authored
      * src/keyboard.c (command_loop_1): If a down-mouse event is unbound,
      leave any prefix arg for the up event.
      7a8e04f7
    • Stefan Monnier's avatar
      Add multiple inheritance to keymaps. · 3349e122
      Stefan Monnier authored
      * src/keymap.c (Fmake_composed_keymap): New function.
      (Fset_keymap_parent): Simplify.
      (fix_submap_inheritance): Remove.
      (access_keymap_1): New function extracted from access_keymap to handle
      embedded parents and handle lists of maps.
      (access_keymap): Use it.
      (Fkeymap_prompt, map_keymap_internal, map_keymap, store_in_keymap)
      (Fcopy_keymap): Handle embedded parents.
      (Fcommand_remapping, define_as_prefix): Simplify.
      (Fkey_binding): Simplify.
      (syms_of_keymap): Move minibuffer-local-completion-map,
      minibuffer-local-filename-completion-map,
      minibuffer-local-must-match-map, and
      minibuffer-local-filename-must-match-map to Elisp.
      (syms_of_keymap): Defsubr make-composed-keymap.
      * src/keyboard.c (menu_bar_items): Use map_keymap_canonical.
      (parse_menu_item): Trivial simplification.
      * lisp/subr.el (remq): Don't allocate if it's not needed.
      (keymap--menu-item-binding, keymap--menu-item-with-binding)
      (keymap--merge-bindings): New functions.
      (keymap-canonicalize): Use them to refine the canonicalization.
      * lisp/minibuffer.el (minibuffer-local-completion-map)
      (minibuffer-local-must-match-map): Move initialization from C.
      (minibuffer-local-filename-completion-map): Move initialization from C;
      don't inherit from anything here.
      (minibuffer-local-filename-must-match-map): Make obsolete.
      (completing-read-default): Use make-composed-keymap to combine
      minibuffer-local-filename-completion-map with either
      minibuffer-local-must-match-map or
      minibuffer-local-filename-completion-map.
      3349e122
  31. 20 Jun, 2011 1 commit
  32. 14 Jun, 2011 1 commit
    • Paul Eggert's avatar
      Variadic C functions now count arguments with ptrdiff_t. · f66c7cf8
      Paul Eggert authored
      This partly undoes my 2011-03-30 change, which replaced int with size_t.
      Back then I didn't know that the Emacs coding style prefers signed int.
      Also, in the meantime I found a few more instances where arguments
      were being counted with int, which may truncate counts on 64-bit
      machines, or EMACS_INT, which may be unnecessarily wide.
      * lisp.h (struct Lisp_Subr.function.aMANY)
      (DEFUN_ARGS_MANY, internal_condition_case_n, safe_call):
      Arg counts are now ptrdiff_t, not size_t.
      All variadic functions and their callers changed accordingly.
      (struct gcpro.nvars): Now size_t, not size_t.  All uses changed.
      * bytecode.c (exec_byte_code): Check maxdepth for overflow,
      to avoid potential buffer overrun.  Don't assume arg counts fit in 'int'.
      * callint.c (Fcall_interactively): Check arg count for overflow,
      to avoid potential buffer overrun.  Use signed char, not 'int',
      for 'varies' array, so that we needn't bother to check its size
      calculation for overflow.
      * editfns.c (Fformat): Use ptrdiff_t, not EMACS_INT, to count args.
      * eval.c (apply_lambda):
      * fns.c (Fmapconcat): Use XFASTINT, not XINT, to get args length.
      (struct textprop_rec.argnum): Now ptrdiff_t, not int.  All uses changed.
      (mapconcat): Use ptrdiff_t, not int and EMACS_INT, to count args.
      f66c7cf8
  33. 13 Jun, 2011 1 commit
  34. 12 Jun, 2011 2 commits
    • Paul Eggert's avatar
      Remove incorrect casts to 'unsigned' that lose info on 64-bit hosts. · d37ca623
      Paul Eggert authored
      These casts should not be needed on 32-bit hosts, either.
      * keyboard.c (read_char):
      * lread.c (Fload): Remove casts to unsigned.
      d37ca623
    • Paul Eggert's avatar
      * lisp.h (UNSIGNED_CMP): New macro. · ea204efb
      Paul Eggert authored
      This fixes comparison bugs on 64-bit hosts.
      (ASCII_CHAR_P): Use it.
      * casefiddle.c (casify_object):
      * character.h (ASCII_BYTE_P, CHAR_VALID_P):
      (SINGLE_BYTE_CHAR_P, CHAR_STRING):
      * composite.h (COMPOSITION_ENCODE_RULE_VALID):
      * dispextern.h (FACE_FROM_ID):
      * keyboard.c (read_char): Use UNSIGNED_CMP.
      ea204efb