bpt/emacs.git
10 years agoBe simpler and more consistent about reporting I/O errors.
Paul Eggert [Tue, 16 Jul 2013 18:30:52 +0000 (11:30 -0700)]
Be simpler and more consistent about reporting I/O errors.

* fileio.c (Fcopy_file, Finsert_file_contents, Fwrite_region):
Say "Read error" and "Write error", rather than "I/O error", or
"IO error reading", or "IO error writing", when a read or write
error occurs.
* process.c (Fmake_network_process, wait_reading_process_output)
(send_process, Fprocess_send_eof, wait_reading_process_output):
Capitalize diagnostics consistently.  Put "failed foo" at the
start of the diagnostic, so that we don't capitalize the
function name "foo".  Consistently say "failed" for such
diagnostics.
* sysdep.c, w32.c (serial_open): Now accepts Lisp string, not C string.
All callers changed.  This is so it can use report_file_error.
* sysdep.c (serial_open, serial_configure): Capitalize I/O
diagnostics consistently as above.

10 years ago* fileio.c (report_file_errno): Fix errno reporting bug.
Paul Eggert [Tue, 16 Jul 2013 16:39:42 +0000 (09:39 -0700)]
* fileio.c (report_file_errno): Fix errno reporting bug.

If the file name is neither null nor a pair, package it up as a
singleton list.  All callers changed, both to this function and to
report_file_error.  This fixes a bug where the memory allocator
invoked by list1 set errno so that the immediately following
report_file_error reported the wrong errno value.

10 years agoFix minor problems found by --enable-gcc-warnings.
Paul Eggert [Tue, 16 Jul 2013 14:52:22 +0000 (07:52 -0700)]
Fix minor problems found by --enable-gcc-warnings.

* frame.c (Fhandle_focus_in, Fhandle_focus_out): Return a value.
* keyboard.c (kbd_buffer_get_event): Remove unused local.

10 years ago* lisp/progmodes/ruby-mode.el (ruby-font-lock-keywords): Do not
Dmitry Gutov [Tue, 16 Jul 2013 14:47:23 +0000 (18:47 +0400)]
* lisp/progmodes/ruby-mode.el (ruby-font-lock-keywords): Do not
highlight question marks in the method names as strings.

10 years agoStop cursor blink after blink-cursor-blinks (10), stop timers when not blinking.
Jan Djärv [Tue, 16 Jul 2013 11:41:06 +0000 (13:41 +0200)]
Stop cursor blink after blink-cursor-blinks (10), stop timers when not blinking.

* etc/NEWS: Document blink-cursor-blinks and blink timers stopped.

* lisp/frame.el (blink-cursor-blinks): New defcustom.
(blink-cursor-blinks-done): New defvar.
(blink-cursor-start): Set blink-cursor-blinks-done to 1.
(blink-cursor-timer-function): Check if number of blinks has been
done on X and NS.
(blink-cursor-suspend, blink-cursor-check): New defuns.

* src/frame.c (Fhandle_focus_in, Fhandle_focus_out): New functions.
(Fhandle_switch_frame): Call Fhandle_focus_in.
(syms_of_frame): defsubr handle-focus-in/out.

* src/keyboard.c (Qfocus_in, Qfocus_out): New static objects.
(make_lispy_focus_in, make_lispy_focus_out): Declare and define.
(kbd_buffer_get_event): For FOCUS_IN, make a focus_in event if no
switch frame event is made.  Check ! NILP (event->arg) if X11 (moved
from xterm.c). Make focus_out event for FOCUS_OUT_EVENT if NS or X11
and there is a focused frame.
(head_table): Add focus-in and focus-out.
(keys_of_keyboard): Add focus-in and focus-out to Vspecial_event_map,
bind to handle-focus-in/out.

* src/nsterm.m (windowDidResignKey): If this is the focused frame, generate
FOCUS_OUT_EVENT.

* src/termhooks.h (enum event_kind): Add FOCUS_OUT_EVENT.

* src/xterm.c (x_focus_changed): Always generate FOCUS_IN_EVENT.
Set event->arg to Qt if switch-event shall be generated.
Generate FOCUS_OUT_EVENT for FocusOut if this is the focused frame.

10 years agoFix porting bug to older POSIXish platforms.
Paul Eggert [Tue, 16 Jul 2013 07:05:41 +0000 (00:05 -0700)]
Fix porting bug to older POSIXish platforms.

* sysdep.c (emacs_pipe): New function, that implements
pipe2 (fd, O_CLOEXEC) even on hosts that lack O_CLOEXEC.
This should port better to CentOS 5 and to Mac OS X 10.6.
All calls to pipe2 changed.

Fixes: debbugs:14862

10 years agoFix the introduction of `set-frame-selected-window''s arguments.
Xue Fuqiao [Tue, 16 Jul 2013 06:45:01 +0000 (14:45 +0800)]
Fix the introduction of `set-frame-selected-window''s arguments.

* doc/lispref/windows.texi (Selecting Windows): Fix the introduction of `set-frame-selected-window''s arguments.

10 years agoPrefer list1 (X) to Fcons (X, Qnil) when building lists.
Paul Eggert [Tue, 16 Jul 2013 06:39:49 +0000 (23:39 -0700)]
Prefer list1 (X) to Fcons (X, Qnil) when building lists.

This makes the code easier to read and the executable a bit smaller.
Do not replace all calls to Fcons that happen to create lists,
just calls that are intended to create lists.  For example, when
creating an alist that maps FOO to nil, use list1 (Fcons (FOO, Qnil))
rather than list1 (list1 (FOO)) or Fcons (Fcons (FOO, Qnil), Qnil).
Similarly for list2 through list5.
* buffer.c (Fget_buffer_create, Fmake_indirect_buffer):
* bytecode.c (exec_byte_code):
* callint.c (quotify_arg, Fcall_interactively):
* callproc.c (Fcall_process, create_temp_file):
* charset.c (load_charset_map_from_file)
(Fdefine_charset_internal, init_charset):
* coding.c (get_translation_table, detect_coding_system)
(Fcheck_coding_systems_region)
(Fset_terminal_coding_system_internal)
(Fdefine_coding_system_internal, Fdefine_coding_system_alias):
* composite.c (update_compositions, Ffind_composition_internal):
* dired.c (directory_files_internal, file_name_completion)
(Fsystem_users):
* dispnew.c (Fopen_termscript, bitch_at_user, init_display):
* doc.c (Fsnarf_documentation):
* editfns.c (Fmessage_box):
* emacs.c (main):
* eval.c (do_debug_on_call, signal_error, maybe_call_debugger)
(Feval, eval_sub, Ffuncall, apply_lambda):
* fileio.c (make_temp_name, Fcopy_file, Faccess_file)
(Fset_file_selinux_context, Fset_file_acl, Fset_file_modes)
(Fset_file_times, Finsert_file_contents)
(Fchoose_write_coding_system, Fwrite_region):
* fns.c (Flax_plist_put, Fyes_or_no_p, syms_of_fns):
* font.c (font_registry_charsets, font_parse_fcname)
(font_prepare_cache, font_update_drivers, Flist_fonts):
* fontset.c (Fset_fontset_font, Ffontset_info, syms_of_fontset):
* frame.c (make_frame, Fmake_terminal_frame)
(x_set_frame_parameters, x_report_frame_params)
(x_default_parameter, Fx_parse_geometry):
* ftfont.c (syms_of_ftfont):
* image.c (gif_load):
* keyboard.c (command_loop_1):
* keymap.c (Fmake_keymap, Fmake_sparse_keymap, access_keymap_1)
(Fcopy_keymap, append_key, Fcurrent_active_maps)
(Fminor_mode_key_binding, accessible_keymaps_1)
(Faccessible_keymaps, Fwhere_is_internal):
* lread.c (read_emacs_mule_char):
* menu.c (find_and_return_menu_selection):
* minibuf.c (get_minibuffer):
* nsfns.m (Fns_perform_service):
* nsfont.m (ns_script_to_charset):
* nsmenu.m (ns_popup_dialog):
* nsselect.m (ns_get_local_selection, ns_string_from_pasteboard)
(Fx_own_selection_internal):
* nsterm.m (append2):
* print.c (Fredirect_debugging_output)
(print_prune_string_charset):
* process.c (Fdelete_process, Fprocess_contact)
(Fformat_network_address, set_socket_option)
(read_and_dispose_of_process_output, write_queue_push)
(send_process, exec_sentinel):
* sound.c (Fplay_sound_internal):
* textprop.c (validate_plist, add_properties)
(Fput_text_property, Fadd_face_text_property)
(copy_text_properties, text_property_list, syms_of_textprop):
* unexaix.c (report_error):
* unexcoff.c (report_error):
* unexsol.c (unexec):
* xdisp.c (redisplay_tool_bar, store_mode_line_string)
(Fformat_mode_line, syms_of_xdisp):
* xfaces.c (set_font_frame_param)
(Finternal_lisp_face_attribute_values)
(Finternal_merge_in_global_face, syms_of_xfaces):
* xfns.c (x_default_scroll_bar_color_parameter)
(x_default_font_parameter, x_create_tip_frame):
* xfont.c (xfont_supported_scripts):
* xmenu.c (Fx_popup_dialog, xmenu_show, xdialog_show)
(menu_help_callback, xmenu_show):
* xml.c (make_dom):
* xterm.c (set_wm_state):
Prefer list1 (FOO) to Fcons (FOO, Qnil) when creating a list,
and similarly for list2 through list5.

10 years agoSpelling fixes for "does not exists".
Paul Eggert [Tue, 16 Jul 2013 04:39:23 +0000 (21:39 -0700)]
Spelling fixes for "does not exists".

10 years ago* lisp/edmacro.el (edmacro-format-keys): Fix previous change.
Glenn Morris [Mon, 15 Jul 2013 19:45:22 +0000 (15:45 -0400)]
* lisp/edmacro.el (edmacro-format-keys): Fix previous change.

10 years ago* callproc.c (Fcall_process_region): Fix minor race and tune.
Paul Eggert [Mon, 15 Jul 2013 02:56:17 +0000 (19:56 -0700)]
* callproc.c (Fcall_process_region): Fix minor race and tune.

(create_temp_file): New function, with the temp-file-creation part
of the old Fcall_process_region.  Use Fcopy_sequence to create the
temp file name, rather than alloca + build_string, for simplicity.
Don't bother to block input around the temp file creation;
shouldn't be needed.  Simplify use of mktemp.  Use
record_unwind_protect immediately after creating the temp file;
this closes an unlikely race where the temp file was not removed.
Use memcpy rather than an open-coded loop.
(Fcall_process_region): Use the new function.  If the input is
empty, redirect from /dev/null rather than from a newly created
empty temp file; this avoids unnecessary file system traffic.

10 years ago* shell.el (explicit-bash-args): Remove obsolete hack for Bash 1.x.
Paul Eggert [Mon, 15 Jul 2013 02:33:54 +0000 (19:33 -0700)]
* shell.el (explicit-bash-args): Remove obsolete hack for Bash 1.x.

The hack didn't work outside English locales anyway.

10 years agolisp/simple.el (define-alternatives): Rename from alternatives-define.
Juanma Barranquero [Mon, 15 Jul 2013 00:49:22 +0000 (02:49 +0200)]
lisp/simple.el (define-alternatives): Rename from alternatives-define.

10 years agolisp/desktop.el (desktop-restore-frames): Change default to t.
Juanma Barranquero [Mon, 15 Jul 2013 00:07:51 +0000 (02:07 +0200)]
lisp/desktop.el (desktop-restore-frames): Change default to t.
(desktop-restore-in-current-display): Now offer more options.
(desktop-restoring-reuses-frames): New customization option.
(desktop--saved-states): Doc fix.
(desktop-filter-parameters-alist): New variable, renamed and expanded from
desktop--excluded-frame-parameters.
(desktop--target-display): New variable.
(desktop-switch-to-gui-p, desktop-switch-to-tty-p, desktop--filter-tty*)
(desktop--filter-*-color, desktop--filter-minibuffer)
(desktop--filter-restore-desktop-parm, desktop--filter-save-desktop-parm)
(desktop-restore-in-original-display-p): New functions.
(desktop--filter-frame-parms): Use new desktop-filter-parameters-alist.
(desktop--save-minibuffer-frames): New function, inspired by a similar
function from Martin Rudalics.
(desktop--save-frames): Call it; play nice with desktop-globals-to-save.
(desktop--restore-in-this-display-p): Remove.
(desktop--find-frame): Rename from desktop--find-frame-in-display and add
predicate argument.
(desktop--make-full-frame): Remove, integrated into desktop--make-frame.
(desktop--reuse-list): New variable.
(desktop--select-frame, desktop--make-frame, desktop--sort-states):
New functions.
(desktop--restore-frames): Add support for "minibuffer-special" frames.

10 years ago* filelock.c (create_lock_file) [!HAVE_MKOSTEMP && !HAVE_MKSTEMP]:
Paul Eggert [Sun, 14 Jul 2013 23:12:42 +0000 (16:12 -0700)]
* filelock.c (create_lock_file) [!HAVE_MKOSTEMP && !HAVE_MKSTEMP]:

Simplify by making this case like the other two.  This is a bit
slower on obsolete hosts, but the extra complexity isn't worth it.

10 years ago* net/tramp-sh.el (tramp-sh-handle-vc-registered): Use `ignore-error'.
Michael Albinus [Sun, 14 Jul 2013 18:45:50 +0000 (20:45 +0200)]
* net/tramp-sh.el (tramp-sh-handle-vc-registered): Use `ignore-error'.

10 years agoSpelling fixes.
Paul Eggert [Sun, 14 Jul 2013 05:18:48 +0000 (22:18 -0700)]
Spelling fixes.

10 years ago* callproc.c (child_setup, relocate_fd) [!DOS_NT]:
Paul Eggert [Sun, 14 Jul 2013 00:30:45 +0000 (17:30 -0700)]
* callproc.c (child_setup, relocate_fd) [!DOS_NT]:

* process.c (create_process) [!DOS_NT]:
Remove now-unnecessary calls to emacs_close.

10 years ago* lisp/progmodes/ruby-mode.el (ruby-font-lock-keywords): Highlight
Dmitry Gutov [Sat, 13 Jul 2013 19:10:19 +0000 (23:10 +0400)]
* lisp/progmodes/ruby-mode.el (ruby-font-lock-keywords): Highlight
conversion methods on Kernel.

10 years agoprogmodes/cc-engine.el (c-forward-decl-or-cast-1): Label CASE 13
Alan Mackenzie [Sat, 13 Jul 2013 17:45:07 +0000 (17:45 +0000)]
progmodes/cc-engine.el (c-forward-decl-or-cast-1): Label CASE 13
and comment it out.  This out-commenting enables certain C++
declarations to be parsed correctly.

10 years agoPrevent leak in GDI objects (bug #14850).
Eli Zaretskii [Sat, 13 Jul 2013 14:21:01 +0000 (17:21 +0300)]
Prevent leak in GDI objects (bug #14850).

 src/w32term.c (x_draw_hollow_cursor): Delete the brush object when
 returning early.

10 years agoImprove the documentation of prefer-utf-8 and related issues.
Eli Zaretskii [Sat, 13 Jul 2013 10:55:21 +0000 (13:55 +0300)]
Improve the documentation of prefer-utf-8 and related issues.

 lisp/international/mule.el (define-coding-system): Doc fix.

 etc/NEWS: Document prefer-utf-8 coding-system and the new attributes
 :inhibit-null-byte-detection, :inhibit-iso-escape-detection, and
 :prefer-utf-8.

10 years agoFix bug #14822 with decoding when inhibit-null-byte-detection is non-nil.
Eli Zaretskii [Sat, 13 Jul 2013 10:29:15 +0000 (13:29 +0300)]
Fix bug #14822 with decoding when inhibit-null-byte-detection is non-nil.

 src/coding.c (syms_of_coding): Set up inhibit-null-byte-detection
 and inhibit-iso-escape-detection attributes of 'undecided'.

10 years agoAuto-commit of generated files.
Glenn Morris [Sat, 13 Jul 2013 10:17:35 +0000 (06:17 -0400)]
Auto-commit of generated files.

10 years ago* deps.mk (sysdep.o): Remove dependency on ../lib/ignore-value.h.
Paul Eggert [Sat, 13 Jul 2013 09:32:45 +0000 (02:32 -0700)]
* deps.mk (sysdep.o): Remove dependency on ../lib/ignore-value.h.

Reported by Herbert J. Skuhra in
<http://lists.gnu.org/archive/html/emacs-devel/2013-07/msg00455.html>.

10 years agoFix bug #14838 with slow scrolling with certain fonts.
Eli Zaretskii [Sat, 13 Jul 2013 07:26:43 +0000 (10:26 +0300)]
Fix bug #14838 with slow scrolling with certain fonts.

 lisp/simple.el (default-font-height): Don't call font-info if the
 frame's default font didn't change since the frame was created.

10 years ago* ido.el (ido-read-file-name): Guard against non-symbol value.
Leo Liu [Sat, 13 Jul 2013 04:44:19 +0000 (12:44 +0800)]
* ido.el (ido-read-file-name): Guard against non-symbol value.

10 years ago* lisp/progmodes/python.el (python-imenu--build-tree): Fix corner case
Fabián Ezequiel Gallina [Sat, 13 Jul 2013 01:55:58 +0000 (22:55 -0300)]
* lisp/progmodes/python.el (python-imenu--build-tree): Fix corner case
in nested defuns.

* test/automated/python-tests.el (python-imenu-create-index-2)
(python-imenu-create-index-3): New tests.

10 years ago* NEWS: Mention new value for ido-use-virtual-buffers.
Leo Liu [Sat, 13 Jul 2013 01:30:36 +0000 (09:30 +0800)]
* NEWS: Mention new value for ido-use-virtual-buffers.

10 years ago* ido.el (ido-exhibit): Handle ido-enter-matching-directory before
Leo Liu [Sat, 13 Jul 2013 00:57:47 +0000 (08:57 +0800)]
* ido.el (ido-exhibit): Handle ido-enter-matching-directory before
ido-set-matches call.

Fixes: debbugs:6852

10 years agoDon't lose top specpdl entry when memory is exhausted.
Paul Eggert [Sat, 13 Jul 2013 00:24:38 +0000 (17:24 -0700)]
Don't lose top specpdl entry when memory is exhausted.

* eval.c (grow_specpdl): Increment specpdl top by 1 and check for
specpdl overflow here, to simplify callers; all callers changed.
Always reserve an unused entry at the stack top; this avoids
losing the top entry's information when memory is exhausted.

10 years ago* configure.ac: Simplify --with-file-notification handling.
Paul Eggert [Sat, 13 Jul 2013 00:01:43 +0000 (17:01 -0700)]
* configure.ac: Simplify --with-file-notification handling.

10 years agoChangeLog fix
Glenn Morris [Fri, 12 Jul 2013 23:55:01 +0000 (19:55 -0400)]
ChangeLog fix

10 years ago* progmodes/ruby-mode.el (ruby-font-lock-keywords): Simplify the last
Dmitry Gutov [Fri, 12 Jul 2013 23:36:14 +0000 (03:36 +0400)]
* progmodes/ruby-mode.el (ruby-font-lock-keywords): Simplify the last
  change.

10 years ago* configure.ac: Further fix.
Glenn Morris [Fri, 12 Jul 2013 23:15:20 +0000 (19:15 -0400)]
* configure.ac: Further fix.

10 years ago* configure.ac: Fix goofs in previous.
Glenn Morris [Fri, 12 Jul 2013 23:14:20 +0000 (19:14 -0400)]
* configure.ac: Fix goofs in previous.

10 years ago* lisp/progmodes/ruby-mode.el (ruby-percent-literals-beg-re):
Dmitry Gutov [Fri, 12 Jul 2013 20:28:53 +0000 (00:28 +0400)]
* lisp/progmodes/ruby-mode.el (ruby-percent-literals-beg-re):
(ruby-syntax-expansion-allowed-p): Support array of symbols, for
Ruby 2.0.
(ruby-font-lock-keywords): Distinguish calls to functions with
module-like names from module references.  Highlight character
literals.

10 years agoFix last lisp/ChangeLog entry.
Sergio Durigan Junior [Fri, 12 Jul 2013 18:19:10 +0000 (21:19 +0300)]
Fix last lisp/ChangeLog entry.

Fixes: debbugs:14847

10 years agoFix bug #14847 with continued GDB command lines in gdb-mi.el.
Sergio Durigan Junior [Fri, 12 Jul 2013 18:17:17 +0000 (21:17 +0300)]
Fix bug #14847 with continued GDB command lines in gdb-mi.el.

 lisp/progmodes/gdb-mi.el (gdb-strip-string-backslash): New function.
 (gdb-send): Handle continued commands.

10 years ago* configure.ac: If with-file-notification=yes, if gfile not found,
Glenn Morris [Fri, 12 Jul 2013 17:36:42 +0000 (13:36 -0400)]
* configure.ac: If with-file-notification=yes, if gfile not found,
go on to try inotify (not on MS Windows or Nextstep).

* etc/NEWS: Copyedits.

10 years agoClean up errno reporting and fix some errno-reporting bugs.
Paul Eggert [Fri, 12 Jul 2013 17:30:48 +0000 (10:30 -0700)]
Clean up errno reporting and fix some errno-reporting bugs.

* callproc.c (Fcall_process):
* fileio.c (Fcopy_file, Finsert_file_contents, Fwrite_region):
* process.c (create_process, Fmake_network_process):
* unexaix.c (report_error):
* unexcoff.c (report_error):
Be more careful about reporting the errno of failed operations.
The code previously reported the wrong errno sometimes.
Also, prefer report_file_errno to setting errno + report_file_error.
(Fcall_process): Look at openp return value rather than at path,
as that's a bit faster and clearer when there's a numeric predicate.
* fileio.c (report_file_errno): New function, with most of the
old contents of report_file_error.
(report_file_error): Use it.
(Ffile_exists_p, Ffile_accessible_directory_p):
Set errno to 0 when it is junk.
* fileio.c (Faccess_file):
* image.c (x_create_bitmap_from_file):
Use faccessat rather than opening the file, to avoid the hassle of
having a file descriptor open.
* lisp.h (report_file_errno): New decl.
* lread.c (Flocate_file_internal): File descriptor 0 is valid, too.

10 years agoMinor EBADF fixes.
Paul Eggert [Fri, 12 Jul 2013 14:31:42 +0000 (07:31 -0700)]
Minor EBADF fixes.

* process.c (create_process, wait_reading_process_output) [AIX]:
Remove obsolete SIGHUP-related  code, as Emacs no longer disables
SIGHUP, so EBADF is no longer acceptable here (it wouldn't work in
a multithreaded environment anyway).
* sysdep.c (emacs_close): It's not dangerous to invoke emacs_close (-1).

10 years agolisp/desktop.el: Minor fixes.
Juanma Barranquero [Fri, 12 Jul 2013 11:21:01 +0000 (13:21 +0200)]
lisp/desktop.el: Minor fixes.
(desktop--v2s): Remove unused local variable.
(desktop-save-buffer): Make defvar-local; adjust docstring.
(desktop-auto-save-timeout, desktop-owner): Use ignore-errors.
(desktop-clear, desktop-save-buffer-p): Use string-match-p.

10 years agoAuto-commit of generated files.
Glenn Morris [Fri, 12 Jul 2013 10:17:37 +0000 (06:17 -0400)]
Auto-commit of generated files.

10 years agoRemove lisp/emacs-lisp/.gitignore
Andreas Schwab [Fri, 12 Jul 2013 09:33:10 +0000 (11:33 +0200)]
Remove lisp/emacs-lisp/.gitignore

10 years ago* emacs-lisp/map-ynp.el (map-y-or-n-p): Fix last change.
Andreas Schwab [Fri, 12 Jul 2013 09:33:09 +0000 (11:33 +0200)]
* emacs-lisp/map-ynp.el (map-y-or-n-p): Fix last change.

10 years ago* image.c (x_find_image_file): Don't close a remote file handle.
Andreas Schwab [Fri, 12 Jul 2013 09:02:30 +0000 (11:02 +0200)]
* image.c (x_find_image_file): Don't close a remote file handle.

10 years agoMinor followup to previous commit.
Eli Zaretskii [Fri, 12 Jul 2013 08:35:42 +0000 (11:35 +0300)]
Minor followup to previous commit.

 lisp/simple.el (next-line, previous-line): Document TRY-VSCROLL and ARG.

Fixes: debbugs:14842

10 years agoFix bug #14842 with doc strings of next-line and previous-line.
Eli Zaretskii [Fri, 12 Jul 2013 08:33:14 +0000 (11:33 +0300)]
Fix bug #14842 with doc strings of next-line and previous-line.

 lisp/simple.el (next-line, previous-line): Document TRY-VSCROLL.

10 years ago* admin/admin.el (manual-style-string): Use non-abbreviated url.
Glenn Morris [Fri, 12 Jul 2013 06:45:04 +0000 (23:45 -0700)]
* admin/admin.el (manual-style-string): Use non-abbreviated url.

10 years agoRemove some more reimplementations of cl-lib functions
Glenn Morris [Fri, 12 Jul 2013 03:54:57 +0000 (20:54 -0700)]
Remove some more reimplementations of cl-lib functions

* lisp/doc-view.el: Require cl-lib at runtime too.
(doc-view-remove-if): Remove.
(doc-view-search-next-match, doc-view-search-previous-match):
Use cl-remove-if.

* lisp/edmacro.el: Require cl-lib at runtime too.
(edmacro-format-keys, edmacro-parse-keys): Use cl-mismatch, cl-subseq.
(edmacro-mismatch, edmacro-subseq): Remove.

* lisp/filesets.el: Comments.

* lisp/shadowfile.el: Require cl-lib.
(shadow-remove-if): Remove.
(shadow-set-cluster, shadow-shadows-of-1, shadow-remove-from-todo):
Use cl-remove-if.

* lisp/wid-edit.el: Require cl-lib.
(widget-choose): Use cl-remove-if.
(widget-remove-if): Remove.

* lisp/progmodes/ebrowse.el: Require cl-lib at runtime too.
(ebrowse-delete-if-not): Remove.
(ebrowse-browser-buffer-list, ebrowse-member-buffer-list)
(ebrowse-tree-buffer-list, ebrowse-same-tree-member-buffer-list):
Use cl-delete-if-not.

10 years agoFix races with threads and file descriptors.
Paul Eggert [Fri, 12 Jul 2013 02:03:47 +0000 (19:03 -0700)]
Fix races with threads and file descriptors.

* configure.ac (PTY_TTY_NAME_SPRINTF): Use emacs_close, not close.
* src/callproc.c (Fcall_process_region):
* src/dired.c (open_directory):
* src/emacs.c (main, Fdaemon_initialized):
* src/image.c (x_find_image_file):
* src/inotify.c (Finotify_rm_watch):
* src/lread.c (Flocate_file_internal):
* src/process.c (Fnetwork_interface_list, Fnetwork_interface_info):
* src/term.c (term_mouse_moveto, init_tty):
* src/termcap.c (tgetent):
* src/unexaix.c, src/unexcoff.c (report_error, report_error_1, adjust_lnnoptrs)
* src/unexaix.c, src/unexcoff.c, src/unexcw.c, src/unexelf.c (unexec):
* src/unexhp9k800.c, src/unexmacosx.c (unexec):
* src/callproc.c (Fcall_process_region):
Use emacs_close, not close.
* src/sysdep.c (POSIX_CLOSE_RESTART, posix_close) [!POSIX_CLOSE_RESTART]:
New macro and function, which emulates the POSIX_CLOSE_RESTART macro
and posix_close function on current platforms (which all lack them).
(emacs_close): Use it.  This should fix the races on GNU/Linux and
on AIX and on future platforms that support POSIX_CLOSE_RESTART,
and it should avoid closing random victim file descriptors on
other platforms.

10 years agolisp/emacs-lisp/cl-macs.el: Fix typos in docstrings.
Juanma Barranquero [Fri, 12 Jul 2013 01:11:22 +0000 (03:11 +0200)]
lisp/emacs-lisp/cl-macs.el: Fix typos in docstrings.

10 years ago* ido.el (dired-do-copy, dired): Set 'ido property.
Leo Liu [Fri, 12 Jul 2013 01:01:53 +0000 (09:01 +0800)]
* ido.el (dired-do-copy, dired): Set 'ido property.

Fixes: debbugs:11954

10 years ago* inotify.c (uninitialized): Remove. All uses replaced by -1.
Paul Eggert [Thu, 11 Jul 2013 17:28:58 +0000 (10:28 -0700)]
* inotify.c (uninitialized): Remove.  All uses replaced by -1.

(Finotify_add_watch): Simplify, since -1 means uninitialized now.
Touch up doc a bit.

10 years agoChangeLog fix
Glenn Morris [Thu, 11 Jul 2013 17:27:27 +0000 (13:27 -0400)]
ChangeLog fix

10 years agoChangeLog fixes
Glenn Morris [Thu, 11 Jul 2013 17:18:48 +0000 (13:18 -0400)]
ChangeLog fixes

10 years agoRemove some reimplementations of cl-gensym
Glenn Morris [Thu, 11 Jul 2013 17:16:19 +0000 (13:16 -0400)]
Remove some reimplementations of cl-gensym

* lisp/thumbs.el: Require cl-lib at run-time too.
(thumbs-gensym-counter, thumbs-gensym):
Remove reimplementation of cl-gensym.
(thumbs-temp-file): Use cl-gensym.

* lisp/emacs-lisp/edebug.el: Require cl-lib at run-time too.
(edebug-gensym-index, edebug-gensym):
Remove reimplementation of cl-gensym.
(edebug-make-enter-wrapper, edebug-make-form-wrapper): Use cl-gensym.

10 years ago* admin/notes/changelogs: Explain "there is no need".
Glenn Morris [Thu, 11 Jul 2013 16:15:57 +0000 (09:15 -0700)]
* admin/notes/changelogs: Explain "there is no need".

10 years agoStop reimplementing a bunch of cl- functions in ert
Glenn Morris [Thu, 11 Jul 2013 16:13:38 +0000 (09:13 -0700)]
Stop reimplementing a bunch of cl- functions in ert

* lisp/emacs-lisp/ert.el: Require cl-lib at runtime too.
(ert--cl-do-remf, ert--remprop, ert--remove-if-not)
(ert--intersection, ert--set-difference, ert--set-difference-eq)
(ert--union, ert--gensym-counter, ert--gensym-counter)
(ert--coerce-to-vector, ert--remove*, ert--string-position)
(ert--mismatch, ert--subseq): Remove reimplementations of cl funcs.
(ert-make-test-unbound, ert--expand-should-1)
(ert--expand-should, ert--should-error-handle-error)
(should-error, ert--explain-equal-rec)
(ert--plist-difference-explanation, ert-select-tests)
(ert--make-stats, ert--remove-from-list, ert--string-first-line):
Use cl-lib functions rather than reimplementations.

* test/automated/ert-tests.el: Require cl-lib at runtime too.
(ert-test-special-operator-p): Use cl-gensym rather than ert-- version.
(ert-test-remprop, ert-test-remove-if-not, ert-test-remove*)
(ert-test-set-functions, ert-test-gensym)
(ert-test-coerce-to-vector, ert-test-string-position)
(ert-test-mismatch): Remove tests.

* test/automated/cl-lib.el: New, split from ert-tests.el.

10 years agoAdding :safe property to a defcustom does not merit a :version bump
Glenn Morris [Thu, 11 Jul 2013 16:07:00 +0000 (09:07 -0700)]
Adding :safe property to a defcustom does not merit a :version bump

10 years agoQuieten ruby-mode-tests.el compilation
Glenn Morris [Thu, 11 Jul 2013 16:04:56 +0000 (09:04 -0700)]
Quieten ruby-mode-tests.el compilation

* test/automated/ruby-mode-tests.el (ruby-deftest-move-to-block):
Goto point-min.
(works-on-do, zero-is-noop, ok-with-three, ok-with-minus-two)
(ruby-move-to-block-skips-percent-literal)
(ruby-move-to-block-skips-heredoc)
(ruby-move-to-block-moves-from-else-to-if)
(ruby-beginning-of-defun-does-not-fold-case)
(ruby-end-of-defun-skips-to-next-line-after-the-method):
Replace goto-line with forward-line/goto-char.
(ruby-move-to-block-does-not-fold-case): Remove unneeded end-of-buffer.

10 years agoSilence package-test.el compilation
Glenn Morris [Thu, 11 Jul 2013 16:01:26 +0000 (09:01 -0700)]
Silence package-test.el compilation

* test/automated/package-test.el (makeinfo-buffer): Autoload.
(compilation-in-progress, tar-parse-info, tar-header-name): Declare.
(package-test-install-texinfo): Don't require makeinfo.

10 years ago* test/automated/files.el: Stop "local variables" confusion.
Glenn Morris [Thu, 11 Jul 2013 16:00:05 +0000 (09:00 -0700)]
* test/automated/files.el: Stop "local variables" confusion.

10 years ago* automated/flymake-tests.el (flymake-tests): Remove unused group.
Glenn Morris [Thu, 11 Jul 2013 15:58:15 +0000 (08:58 -0700)]
* automated/flymake-tests.el (flymake-tests): Remove unused group.

10 years agoSilence icalendar-tests.el compilation
Glenn Morris [Thu, 11 Jul 2013 15:57:45 +0000 (08:57 -0700)]
Silence icalendar-tests.el compilation

* test/automated/icalendar-tests.el (icalendar-tests--do-test-cycle):
Use with-current-buffer.

10 years ago* undo-tests.el (undo-test-buffer-modified, undo-test-file-modified): New tests.
Glenn Morris [Thu, 11 Jul 2013 15:56:41 +0000 (08:56 -0700)]
* undo-tests.el (undo-test-buffer-modified, undo-test-file-modified): New tests.

10 years ago* net/tramp.el (tramp-methods): Extend docstring.
Michael Albinus [Thu, 11 Jul 2013 09:52:54 +0000 (11:52 +0200)]
* net/tramp.el (tramp-methods): Extend docstring.
(tramp-connection-timeout): New defcustom.
(tramp-error-with-buffer): Reset timestamp only when appropriate.
(with-tramp-progress-reporter): Simplify.
(tramp-process-actions): Improve messages.

* net/tramp-gvfs.el (tramp-gvfs-maybe-open-connection):
* net/tramp-sh.el (tramp-maybe-open-connection):
Use `tramp-connection-timeout'.
(tramp-methods) [su, sudo, ksu]: Add method specific timeouts.  (Bug#14808)

10 years ago* eval.c (backtrace_function, backtrace_args): Now EXTERNALLY_VISIBLE.
Paul Eggert [Thu, 11 Jul 2013 07:17:23 +0000 (00:17 -0700)]
* eval.c (backtrace_function, backtrace_args): Now EXTERNALLY_VISIBLE.

This is for .gdbinit xbacktrace.

10 years ago* ido.el (ido-read-file-name): Conform to the requirements of
Leo Liu [Thu, 11 Jul 2013 02:59:54 +0000 (10:59 +0800)]
* ido.el (ido-read-file-name): Conform to the requirements of
read-file-name.
(ido-read-directory-name): Conform to the requirements of
read-directory-name.

Fixes: debbugs:11861

10 years ago* sysdep.c, term.c, termcap.c, terminal.c: Integer-related minor fixes.
Paul Eggert [Thu, 11 Jul 2013 02:17:47 +0000 (19:17 -0700)]
* sysdep.c, term.c, termcap.c, terminal.c: Integer-related minor fixes.

* sysdep.c (emacs_get_tty): Return void, since nobody uses the value.
(emacs_set_tty): Now static.
* sysdep.c (emacs_set_tty, tabs_safe_p, emacs_close):
* term.c (tty_capable_p, tty_default_color_capabilities)
(get_tty_terminal, term_mouse_movement)
(handle_one_term_event, init_tty, maybe_fatal):
* termcap.c (tgetst1, struct termcap_buffer, valid_filename_p)
(tgetent, scan_file, name_match, compare_contin):
* terminal.c (get_terminal):
Use bool for boolean.
* sysdep.c (init_system_name): Don't overflow stack on huge hostname.
Prefer char to unsigned char if either will do.
* term.c (OUTPUT, turn_on_face): Omit unnecessary casts to int.
(tty_write_glyphs): Prefer int to unsigned.
(produce_glyphless_glyph): Remove 2nd (unused) int arg.
All callers changed.
* termcap.c (tprint, main) [TEST]: Remove non-working test.

10 years agolisp/subr.el (delay-warning): New function.
Juanma Barranquero [Thu, 11 Jul 2013 01:49:17 +0000 (03:49 +0200)]
lisp/subr.el (delay-warning): New function.

10 years agoPort to C89.
Paul Eggert [Wed, 10 Jul 2013 23:23:57 +0000 (16:23 -0700)]
Port to C89.

* lib-src/ebrowse.c (USAGE): Remove macro with too-long string literal ...
(usage_message): ... and replace it with this new static constant
containing multiple literals.  All uses changed.
* lib-src/emacsclient.c (print_help_and_exit):
Rewrite to avoid string literals longer than the C89 limits.
(start_daemon_and_retry_set_socket):
Rewrite to avoid non-constant array initializer.
* lib-src/make-docfile.c (enum global_type): Omit trailing comma.
* src/bytecode.c (BYTE_CODE_THREADED): Do not define if __STRICT_ANSI__.
(B__dummy__): New dummy symbol, to pacify C89.
* src/dbusbind.c (XD_DEBUG_MESSAGE): Omit debugging on C89 hosts, since
they can't grok varargs macros.
* src/dispnew.c (add_window_display_history)
(add_frame_display_history):
* src/print.c (print_object):
* src/xdisp.c (debug_method_add):
Use %p printf format only for void pointers.
* src/emacs.c (usage_message): New constant, replacing ...
(USAGE1, USAGE2, USAGE3): Remove; they were too long for C89.
(main): Adjust to usage reorg.
* src/fns.c (syms_of_fns):
* src/profiler.c (syms_of_profiler):
Don't use non-constant struct initializers.
* src/gnutls.h (gnutls_initstage_t):
* src/lisp.h (enum Lisp_Fwd_Type):
* src/lread.c (lisp_file_lexically_bound_p):
* src/xsettings.c (anonymous enum):
Remove trailing comma.
* src/xsettings.c (apply_xft_settings): Use %f, not %lf; %lf is a C99ism.
* src/lisp.h (ENUM_BF): Use unsigned if pedantic.
(DEFUN_FUNCTION_INIT): New macro, that falls back on a cast if pre-C99.
(DEFUN): Use it.
* src/regex.c (const_re_char): New type, to pacify strict C89.
All uses of 'const re_char' replaced to use it.
* src/regex.h (_Restrict_): Rename from __restrict, to avoid clash
with glibc when strict C89.  This change is imported from gnulib.
All uses changed.
(_Restrict_arr_): Rename from __restrict_arr, similarly.
* src/sysdep.c (time_from_jiffies) [!HAVE_LONG_LONG_INT]:
Omit GNU_LINUX implementation, since it requires long long.
* src/xterm.c (x_draw_underwave):
Do not assume the traditional order of struct's members.
(x_term_init): Rewrite to avoid the need for non-constant structure
initializers.

10 years agognus-start.el (gnus-clean-old-newsrc): Always remove 'unexist' marks if `gnus-newsrc...
David Engster [Wed, 10 Jul 2013 22:17:07 +0000 (22:17 +0000)]
gnus-start.el (gnus-clean-old-newsrc): Always remove 'unexist' marks if `gnus-newsrc-file-version' does not match `gnus-version'.  This fixes a bug in Emacs trunk where the 'unexist' marks were always removed at startup because "Gnus v5.13" was considered smaller than "Ma Gnus v0.03".

10 years agognus.el (gnus-summary-line-format): Docfix
Tassilo Horn [Wed, 10 Jul 2013 22:16:03 +0000 (22:16 +0000)]
gnus.el (gnus-summary-line-format): Docfix

10 years agoImprove scrolling when line-spacing != 0 and scroll-step = 1.
Eli Zaretskii [Wed, 10 Jul 2013 16:18:17 +0000 (19:18 +0300)]
Improve scrolling when line-spacing != 0 and scroll-step = 1.

 lisp/simple.el (default-line-height): New function.
 (line-move-partial, line-move): Use it instead of computing the
 line height inline.
 (line-move-partial): Always compute ROWH.  If the last line is
 partially-visible, but its text is completely visible, allow
 cursor to enter such a partially-visible line.

10 years agoSyntax cleanup, mostly replacing macros with functions.
Paul Eggert [Wed, 10 Jul 2013 16:11:09 +0000 (09:11 -0700)]
Syntax cleanup, mostly replacing macros with functions.

This removes the need for the syntax_temp hack.
* search.c: Include syntax.h after buffer.h, since syntax.h uses BVAR.
* syntax.c (SYNTAX_INLINE): New macro.
(SYNTAX_FLAGS_COMSTART_FIRST, SYNTAX_FLAGS_COMSTART_SECOND)
(SYNTAX_FLAGS_COMEND_FIRST, SYNTAX_FLAGS_COMEND_SECOND)
(SYNTAX_FLAGS_PREFIX, SYNTAX_FLAGS_COMMENT_STYLEB)
(SYNTAX_FLAGS_COMMENT_STYLEC, SYNTAX_FLAGS_COMMENT_STYLEC2)
(SYNTAX_FLAGS_COMMENT_NESTED, SYNTAX_FLAGS_COMMENT_STYLE)
(SYNTAX_COMEND_FIRST): Now functions, not macros.
(ST_COMMENT_STYLE, ST_STRING_STYLE, INTERVALS_AT_ONCE):
Now constants, not macros.
(syntax_temp) [!__GNUC__]: Remove.
(SYNTAX_PREFIX): Remove; all uses replaced by syntax_prefix_flag_p.
(syntax_prefix_flag_p): Move implementation of SYNTAX_PREFIX here.
(SET_RAW_SYNTAX_ENTRY, SET_RAW_SYNTAX_ENTRY_RANGE, SYNTAX_MATCH)
(SETUP_SYNTAX_TABLE, SETUP_SYNTAX_TABLE_FOR_OBJECT):
Move here from syntax.h; now functions, not macros.  Except for the
last function, these are static since only syntax.c uses them.
(syntax_multibyte): Rename from SYNTAX_WITH_MULTIBYTE_CHECK.
All uses changed.  Now a function, not a macro; use this fact
to simplify the code.
(scan_lists, scan_sexps_forward): Remove workarounds for ancient
compiler bugs; no longer relevant.
* syntax.h: Use INLINE_HEADER_BEGIN, INLINE_HEADER_END.
(SYNTAX_INLINE): New macro.
(struct gl_state_s, gl_state): Move earlier, so that it's in scope
for the new functions.  Use bool for boolean member.
(SYNTAX_ENTRY, SYNTAX, SYNTAX_WITH_FLAGS, SYNTAX_MATCH)
(SYNTAX_TABLE_BYTE_TO_CHAR, UPDATE_SYNTAX_TABLE_FORWARD)
(UPDATE_SYNTAX_TABLE_BACKWARD, UPDATE_SYNTAX_TABLE)
(SETUP_BUFFER_SYNTAX_TABLE):
Now extern inline functions, not macros.
(CURRENT_SYNTAX_TABLE, SYNTAX_ENTRY_INT):
Remove; all uses replaced by implementation.
(syntax_temp) [!__GNUC__]: Remove decl.
(SETUP_SYNTAX_TABLE_FOR_OBJECT): New decl.

10 years agoFix last patch.
Michael Albinus [Wed, 10 Jul 2013 15:18:39 +0000 (17:18 +0200)]
Fix last patch.

10 years agoImprove error messages. (Bug#14808)
Michael Albinus [Wed, 10 Jul 2013 14:58:26 +0000 (16:58 +0200)]
Improve error messages.  (Bug#14808)

* net/tramp.el (tramp-current-connection): New defvar, moved from
tramp-sh.el.
(tramp-message-show-progress-reporter-message): Removed, not
needed anymore.
(tramp-error-with-buffer): Show message in minibuffer.  Discard
input before waiting.  Reset connection timestamp.
(with-tramp-progress-reporter): Improve messages.
(tramp-process-actions): Use progress reporter.  Delete process in
case of error.  Improve messages.

* net/tramp-sh.el (tramp-barf-if-no-shell-prompt): Use
condition-case.  Call `tramp-error-with-buffer' with vector and buffer.
(tramp-current-connection): Removed.
(tramp-maybe-open-connection): The car of
`tramp-current-connection' are the first 3 slots of the vector.

10 years ago* progmodes/cfengine.el: Do not indent inside continued strings.
Ted Zlatanov [Wed, 10 Jul 2013 14:34:13 +0000 (10:34 -0400)]
* progmodes/cfengine.el: Do not indent inside continued strings.

10 years agoAdd comment.
Michael Albinus [Wed, 10 Jul 2013 14:07:17 +0000 (16:07 +0200)]
Add comment.

10 years ago* emacs.c (main): Fix syntax error.
Jan Djärv [Wed, 10 Jul 2013 11:27:15 +0000 (13:27 +0200)]
* emacs.c (main): Fix syntax error.

10 years agoAuto-commit of generated files.
Glenn Morris [Wed, 10 Jul 2013 10:17:38 +0000 (06:17 -0400)]
Auto-commit of generated files.

10 years ago* Makefile.in (removenullpaths): Remove adjacent null paths.
Paul Eggert [Wed, 10 Jul 2013 06:41:37 +0000 (23:41 -0700)]
* Makefile.in (removenullpaths): Remove adjacent null paths.

Fixes: debbugs:14835

10 years agoTimestamp fixes for undo.
Paul Eggert [Wed, 10 Jul 2013 06:26:23 +0000 (23:26 -0700)]
Timestamp fixes for undo.

* doc/lispref/text.texi (Undo):
Document (t . 0) and (t . -1) in buffer-undo-list.
* etc/NEWS: Changes to visited-file-modtime, set-visited-file-modtime.
* lisp/files.el (clear-visited-file-modtime): Move here from fileio.c.
* src/atimer.c (schedule_atimer):
* src/fileio.c (Ffile_newer_than_file_p):
Minor cleanup: use EMACS_TIME_LT so that we can remove EMACS_TIME_GT.
* src/buffer.c (buffer-undo-list): Document (t . 0) and (t . -1).
* src/fileio.c (Fclear_visited_file_modtime): Move to lisp/files.el.
(syms_of_fileio): Remove Sclear_visited_file_name.
(Fvisited_file_modtime): Return -1, not (-1 ...), when the visited
file doesn't exist; this avoids an ambiguity with negative timestamps.
(Fset_visited_file_modtime): Accept -1 and 0 as time-list arg.
* src/systime.h (make_emacs_time, invalid_emacs_time):
Don't assume struct timespec layout; POSIX doesn't guarantee it.
(EMACS_TIME_NE, EMACS_TIME_GT, EMACS_TIME_GE): Remove.
* src/undo.c (record_first_change): Push (visited-file-modtime) onto
undo list rather than reimplementing it by hand, incorrectly.

Fixes: debbugs:14824

10 years ago* files.el (require-final-newline): Allow safe local value.
Leo Liu [Wed, 10 Jul 2013 03:10:27 +0000 (11:10 +0800)]
* files.el (require-final-newline): Allow safe local value.

Fixes: debbugs:14834

10 years agoAvoid nexted functions in AC_LANG_PROGRAM test for Windows headers.
Peter Rosin [Tue, 9 Jul 2013 18:06:25 +0000 (21:06 +0300)]
Avoid nexted functions in AC_LANG_PROGRAM test for Windows headers.

 configure.ac (HAVE_W32): Avoid nested functions (the second
 argument of AC_LANG_PROGRAM is already expanded inside a
 function).

Fixes: debbugs:14830

10 years agoPort recent close-on-exec changes to Cygwin.
Paul Eggert [Tue, 9 Jul 2013 17:16:21 +0000 (10:16 -0700)]
Port recent close-on-exec changes to Cygwin.

* lib/binary-io.c, lib/binary-io.h: New files.
Merge from gnulib, incorporating:
2013-07-09 accept4, dup3, pipe2: port to Cygwin
* lib/pipe2.c: Update from gnulib, as part of this merge.
* lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.

Fixes: debbugs:14821

10 years ago* src/sheap.c (STATIC_HEAP_SIZE) [__x86_64__]: Increase to 18MB.
Ken Brown [Tue, 9 Jul 2013 13:56:47 +0000 (09:56 -0400)]
* src/sheap.c (STATIC_HEAP_SIZE) [__x86_64__]: Increase to 18MB.

10 years agoAuto-commit of generated files.
Glenn Morris [Tue, 9 Jul 2013 10:17:37 +0000 (06:17 -0400)]
Auto-commit of generated files.

10 years agosrc/makefile.w32-in ($(BLD)/emacs.$(O), $(BLD)/sysdep.$(O)): Update.
Juanma Barranquero [Tue, 9 Jul 2013 09:53:00 +0000 (11:53 +0200)]
src/makefile.w32-in ($(BLD)/emacs.$(O), $(BLD)/sysdep.$(O)): Update.

10 years ago* automated/file-notify-tests.el (file-notify-test00-availability):
Michael Albinus [Tue, 9 Jul 2013 07:52:25 +0000 (09:52 +0200)]
* automated/file-notify-tests.el (file-notify-test00-availability):
Set :expected-result.
(file-notify-test01-add-watch, file-notify-test01-add-watch-remote)
(file-notify-test02-events, file-notify-test02-events-remote)
(file-notify-test03-autorevert, file-notify-test03-autorevert-remote):
Skip when `file-notify-support' is nil.  (Bug#14823)

10 years ago* automated/inotify-test.el (inotify-add-watch, inotify-rm-watch): Declare.
Glenn Morris [Tue, 9 Jul 2013 07:43:12 +0000 (00:43 -0700)]
* automated/inotify-test.el (inotify-add-watch, inotify-rm-watch): Declare.
(inotify-file-watch-simple): Silence compiler.

10 years ago* test/automated/python-tests.el (python-indent-block-enders):
Glenn Morris [Tue, 9 Jul 2013 07:35:26 +0000 (00:35 -0700)]
* test/automated/python-tests.el (python-indent-block-enders):
Make it actually test something.

10 years agoChangeLog fix
Glenn Morris [Tue, 9 Jul 2013 07:14:39 +0000 (00:14 -0700)]
ChangeLog fix

10 years agoExplictly require ert in some test/automated/*.el files
Glenn Morris [Tue, 9 Jul 2013 07:11:50 +0000 (00:11 -0700)]
Explictly require ert in some test/automated/*.el files

* automated/add-log-tests.el, automated/advice-tests.el:
* automated/imenu-test.el, automated/python-tests.el:
* automated/ruby-mode-tests.el, automated/xml-parse-tests.el:
Explictly require ert.

10 years agoHandle errno and exit status a bit more carefully.
Paul Eggert [Tue, 9 Jul 2013 07:04:48 +0000 (00:04 -0700)]
Handle errno and exit status a bit more carefully.

* lib/ignore-value.h: Remove this gnulib-imported file.
* lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
* admin/merge-gnulib (GNULIB_MODULES): Remove ignore-value.
* src/callproc.c (child_setup) [!DOS_NT]: Don't try to stuff an error
number into an exit status.  Instead, use EXIT_CANCELED.
(child_setup) [!MSDOS]: Avoid possible deadlock with vfork.
* src/callproc.c (relocate_fd):
* src/emacs.c (close_output_streams, main):
* src/process.c (create_process):
* src/sysdep.c (sys_subshell) [!DOS_NT || !WINDOWSNT]:
Use emacs_perror for simplicity.
* src/callproc.c (relocate_fd, main):
* src/sysdep.c (sys_subshell):
Exit with EXIT_CANCELED etc., not 1, when exec setup fails.
(shut_down_emacs): Use emacs_write, not write.
* src/emacs.c, src/sysdep.c: Don't include <ignore-value.h>.
* src/fileio.c (Fcopy_file, e_write):
* src/nsterm.m (ns_select):
* src/process.c (send_process):
* src/sound.c (vox_write):
Use emacs_write_sig, not emacs_write.
* src/lisp.h (emacs_write_sig, emacs_perror): New decls.
* src/process.h (EXIT_CANCELED), EXIT_CANNOT_INVOKE, EXIT_ENOENT):
New constants.
* src/sysdep.c (emacs_backtrace): Use emacs_write, not ignore_value
of write.
(emacs_full_write): New function.
(emacs_write): Rewrite to use it.
(emacswrite_sig, emacs_perror): New functions.
* src/xrdb.c (fatal): Don't invoke perror, since errno might be garbage.

10 years agoChangeLog fix
Glenn Morris [Tue, 9 Jul 2013 06:59:45 +0000 (23:59 -0700)]
ChangeLog fix

10 years ago* filelock.c: Fix comment to match code.
Paul Eggert [Tue, 9 Jul 2013 06:29:29 +0000 (23:29 -0700)]
* filelock.c: Fix comment to match code.

10 years ago* ido.el (ido-add-virtual-buffers-to-list): Robustify. (Bug#14552)
Leo Liu [Tue, 9 Jul 2013 05:09:45 +0000 (13:09 +0800)]
* ido.el (ido-add-virtual-buffers-to-list): Robustify.  (Bug#14552)