-2014-09-21 David Caldwell <david@porkrind.org> (tiny change)
+ 2014-09-22 Dmitry Antipov <dmantipov@yandex.ru>
+
+ On OSX, do not free font-specific data more than once (Bug#18501).
+ * macfont.m (macfont_close): Release and free font-specific data
+ only if it wasn't previously freed.
+
-2014-09-18 Juri Linkov <juri@jurta.org>
++2014-09-22 David Caldwell <david@porkrind.org> (tiny change)
+
+ * unexmacosx.c (dump_it): Improve error message.
+
-2014-09-18 Eli Zaretskii <eliz@gnu.org>
++2014-09-22 Juri Linkov <juri@jurta.org>
+
+ * image.c (imagemagick_load_image): Add delay to imagemagick metadata.
+ (Bug#10747, bug#18334)
+
-2014-09-16 Eli Zaretskii <eliz@gnu.org>
++2014-09-22 Eli Zaretskii <eliz@gnu.org>
+
+ * frame.c (Fmouse_position, Fset_mouse_position): Clarify the
+ units in which the position is measured. (Bug#18493)
+
+ * xdisp.c (redisplay_internal): Force redisplay of all windows
+ that show a buffer whose narrowing has changed. (Bug#18490)
+
-2014-09-16 Dmitry Antipov <dmantipov@yandex.ru>
++2014-09-22 Eli Zaretskii <eliz@gnu.org>
+
+ * xterm.c (x_draw_hollow_cursor, x_draw_bar_cursor):
+ * w32term.c (x_draw_hollow_cursor, x_draw_bar_cursor): In R2L
+ lines, draw the hollow-box and hbar cursors on the right side of
+ cursor-glyph. Thanks to martin rudalics <rudalics@gmx.at> for
+ testing on X.
+
+ * xterm.c (x_draw_stretch_glyph_string):
+ * w32term.c (x_draw_stretch_glyph_string): Fix a thinko that
+ caused the block cursor to disappear on a TAB in R2L lines in
+ every window except the leftmost one. Reported by Martin Rudalics
+ <rudalics@gmx.at>.
+
-2014-09-15 Eli Zaretskii <eliz@gnu.org>
++2014-09-22 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Always use matched specpdl entry to record call arguments (Bug#18473).
+ * lisp.h (record_in_backtrace): Adjust prototype.
+ * eval.c (record_in_backtrace): Return current specpdl level.
+ (set_backtrace_args, set_backtrace_nargs): Merge. Adjust all users.
+ (eval_sub, Ffuncall): Record call arguments in matched specpdl
+ entry and use that entry in call to backtrace_debug_on_exit.
+ (apply_lambda): Likewise. Get current specpdl level as 3rd arg.
+ (do_debug_on_call): Get current specpdl level as 2nd arg.
+
+ Prefer ptrdiff_t to int and avoid integer overflows.
+ * fileio.c (make_temp_name):
+ * font.c (font_parse_family_registry): Avoid integer
+ overflow on string size calculation.
+ * data.c (Faset): Likewise for byte index.
+
-2014-09-14 Eli Zaretskii <eliz@gnu.org>
++2014-09-22 Eli Zaretskii <eliz@gnu.org>
+
+ Fix display of R2L lines in partial-width windows.
+ * xdisp.c (init_iterator): Don't use it->bidi_p before it is
+ assigned the correct value.
+ (extend_face_to_end_of_line): Account for truncation and
+ continuation glyphs in R2L rows when one of the fringes is not
+ displayed.
+ (display_line): Don't assign negative X offset to a row if we are
+ going to produce a truncation glyph for it. When handling
+ truncated R2L rows, consider the width of the left fringe instead
+ of the right one.
+ (produce_special_glyphs): Fix bogus assignments.
+
++2014-09-22 Eli Zaretskii <eliz@gnu.org>
++
++ * w32.c (fcntl): Support O_NONBLOCK fcntl on the write side of pipes.
++
+2014-09-22 Eli Zaretskii <eliz@gnu.org>
+
+ * fileio.c (Fexpand_file_name) [DOS_NT]: Make sure newdirlim is
+ always set to a valid value. Make sure the size passed to alloca
+ is always positive. (Bug#18516)
+
+2014-09-22 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Avoid extra call to oblookup when interning symbols.
+ * lisp.h (intern_driver): Add prototype.
+ * lread.c (intern_driver): New function.
+ (intern1, intern_c_string_1, Fintern):
+ * font.c (font_intern_prop):
+ * w32font.c (intern_font_name): Use it.
+
+2014-09-21 Paul Eggert <eggert@cs.ucla.edu>
+
+ Minor improvements to new stack-allocated Lisp objects.
+ * frame.h (FRAME_PARAMETER):
+ Prefer scoped_list1 to local_list1 where either would do.
+ * lisp.h (scoped_list4): New macro.
+ (local_cons, local_list1, local_list2, local_list3, local_list4)
+ (make_local_vector, make_local_string, build_local_string):
+ Prefer functions to macros where either would do.
+ * xdisp.c (build_desired_tool_bar_string):
+ Prefer scoped_list4 to local_list4 where either would do.
+
+2014-09-18 Dmitry Antipov <dmantipov@yandex.ru>
+
+ More and more stack-allocated Lisp objects if USE_LOCAL_ALLOCATORS.
+ * lisp.h (local_list4) [USE_LOCAL_ALLOCATORS]: New macro.
+ [!USE_LOCAL_ALLOCATORS]: Fall back to regular list4.
+ * frame.h (FRAME_PARAMETER): New macro.
+ * dispnew.c (init_display):
+ * fontset.c (Fset_fontset_font):
+ * frame.c (x_default_parameter):
+ * xfaces.c (set_font_frame_param, Finternal_merge_in_global_face):
+ * xfns.c (x_default_scroll_bar_color_parameter)
+ (x_default_font_parameter, x_create_tip_frame): Use it.
+ * editfns.c (Fpropertize): Use local_cons.
+ * process.c (status_message): Use build_local_string.
+ * xfont.c (xfont_open): Use make_local_string.
+ * xdisp.c (build_desired_tool_bar_string): Use local_list4.
+
+2014-09-18 Paul Eggert <eggert@cs.ucla.edu>
+
+ Port USE_LOCAL_ALLOCATORS code to clang 3.4 x86-64.
+ * lisp.h (USE_LOCAL_ALLOCATORS): Define only if __GNUC__ &&
+ !__clang__. This works with GCC and with clang and is safer for
+ compilers we don't know about.
+ (local_cons): Rename parameter to make capture less likely.
+
+2014-09-17 Samuel Bronson <naesten@gmail.com>
+
+ * unexmacosx.c (copy_data_segment): Port to GCC 4.6+ (Bug#9927).
+
+2014-09-17 Paul Eggert <eggert@cs.ucla.edu>
+
+ Fix minor problems found by static checking.
+ * alloc.c, lisp.h (SAVE_TYPE_INT_OBJ, make_save_int_obj):
+ Remove; now unused.
+ * buffer.h (decode_buffer): Doc and indentation fixes.
+ * fns.c (Qstring_collate_lessp, Qstring_collate_equalp): Now static.
+
+2014-09-17 Dmitry Antipov <dmantipov@yandex.ru>
- * w32.c (fcntl): Support O_NONBLOCK fcntl on the write side of
- pipes.
+ Avoid clang-specific warnings.
+ * buffer.c (init_buffer): Shut up -Wself-assign.
+ * process.c (server_accept_connection): Shut up -Wunsequenced.
+
+2014-09-16 Daniel Colascione <dancol@dancol.org>
+
+ * fns.c (sxhash): For symbols, use address as hash code.
+
+2014-09-16 Dmitry Antipov <dmantipov@yandex.ru>
+
+ If USE_LOCAL_ALLOCATORS, allocate even more Lisp objects on stack.
+ * charset.c (load_charset_map_from_file): Use scoped_list2
+ and build_local_string.
+ * buffer.c (Fother_buffer, other_buffer_safely, init_buffer):
+ * emacs.c (init_cmdargs, decode_env_path):
+ * fileio.c (Fexpand_file_name):
+ * fns.c (maybe_resize_hash_table) [ENABLE_CHECKING]:
+ * frame.c (x_get_arg):
+ * keyboard.c (safe_run_hooks_error):
+ * lread.c (load_warn_old_style_backquotes):
+ * xdisp.c (Fcurrent_bidi_paragraph_direction):
+ * xfns.c (x_default_scroll_bar_color_parameter, select_visual):
+ * xselect.c (x_clipboard_manager_error_1)
+ (x_clipboard_manager_save_all):
+ * xterm.c (x_term_init): Use build_local_string.
+
+ Avoid more integer overflows on string size calculations.
+ * category.c (Fmake_category_set):
+ * xdisp.c (get_overlay_arrow_glyph_row):
+ * w32font.c (intern_font_name): Prefer ptrdiff_t to int.
+
+2014-09-15 Eli Zaretskii <eliz@gnu.org>
+
+ * sound.c [WINDOWSNT]: Include w32common.h and mbstring.h.
+ (SOUND_WARNING) [WINDOWSNT]: Include in do..while and improve the
+ error message format. Use message_with_string to have non-ASCII
+ file names properly displayed.
+ (do_play_sound) [WINDOWSNT]: Use Unicode APIs to play sound files
+ when w32-unicode-filenames is non-nil, but not on Windows 9X,
- where these APIs are not available even in UNICOWS.DLL. Improve
- the format of error messages and include the file name in them
++ where these APIs are not available even in UNICOWS.DLL.
++ Improve the format of error messages and include the file name in them
+ where appropriate.
+ (Fplay_sound_internal) [WINDOWSNT]: Make the MS-Windows branch
+ call play-sound-functions, per documentation.
+
- * w32.c (w32_get_long_filename, w32_get_short_filename): Constify
- the input file name arguments.
++ * w32.c (w32_get_long_filename, w32_get_short_filename):
++ Constify the input file name arguments.
+
- * w32.h (w32_get_long_filename, w32_get_short_filename): Update
- prototypes.
++ * w32.h (w32_get_long_filename, w32_get_short_filename):
++ Update prototypes.
+
+2014-09-15 Dmitry Antipov <dmantipov@yandex.ru>
+
+ If USE_LOCAL_ALLOCATORS, allocate some Lisp objects on stack.
+ * lisp.h (local_cons, local_list1, local_list2, local_list3)
+ [USE_LOCAL_ALLOCATORS]: New macros.
+ [!USE_LOCAL_ALLOCATORS]: Fall back to regular functions.
+ (build_local_string): Avoid argument name expansion clash with
+ make_local_string.
+ * alloc.c (toplevel)
+ [USE_LOCAL_ALLOCATORS && GC_MARK_STACK != GC_MAKE_GCPROS_NOOPS]:
+ Preprocessor guard to avoid impossible configuration.
+ * charset.c (Ffind_charset_region, Ffind_charset_string):
+ Use make_local_vector.
+ * lread.c (read1, substitute_object_recurse): Use scoped_cons.
+ * textprop.c (Fput_text_property, Fadd_face_text_property):
+ Use scoped_list2.
+ (copy_text_properties): Use local_cons and local_list3.
+ * chartab.c (uniprop_table):
+ * data.c (wrong_choice, wrong_range):
+ * doc.c (get_doc_string):
+ * editfns.c (format2):
+ * fileio.c (Fexpand_file_name, auto_save_error):
+ * fns.c (Fyes_or_no_p):
+ * font.c (font_parse_xlfd, font_parse_family_registry, font_add_log):
+ * fontset.c (Fset_fontset_font):
+ * keyboard.c (echo_add_key, echo_dash, parse_menu_item)
+ (read_char_minibuf_menu_prompt):
+ * keymap.c (silly_event_symbol_error, describe_vector):
+ * menu.c (single_menu_item):
+ * minibuf.c (Fread_buffer):
+ * process.c (status_message, Fformat_network_address)
+ (server_accept_connection): Use make_local_string and
+ build_local_string. Prefer compound literals where appropriate.
+
+2014-09-15 Daniel Colascione <dancol@dancol.org>
+
+ * fns.c (Fsort): Tweak sort docstring.
+
+2014-09-15 Eli Zaretskii <eliz@gnu.org>
+
+ * w32.c (fcntl): Support O_NONBLOCK fcntl on the write side of pipes.
(sys_write): When a write to a non-blocking pipe returns ENOSPC,
set errno to EAGAIN instead, to allow the caller to retry the
write after some waiting. Fixes deadlocks when Emacs exchanges a
iterator to another screen line. This fixes off-by-one errors in
the reported row in some rare cases.
-2014-09-07 Eli Zaretskii <eliz@gnu.org>
+2014-09-14 Jan Djärv <jan.h.d@swipnet.se>
+
+ * callproc.c (init_callproc): Fix bug introduced at
+ 2014-09-07 (Bug#18474).
+
+2014-09-13 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Prefer ptrdiff_t to int and avoid integer overflows.
+ * fileio.c (make_temp_name):
+ * font.c (font_parse_family_registry): Avoid integer
+ overflow on string size calculation.
+ * data.c (Faset): Likewise for byte index.
+
+2014-09-12 Detlev Zundel <dzu@member.fsf.org>
+
+ * buffer.c (syms_of_buffer): DEFSYM Qchoice (Bug#18337).
+
+2014-09-11 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * lisp.h (make_local_string): Nitpick indent.
+ * print.c (Fprin1_to_string): Remove unused GCPROs.
+
+ More debugging aids around GCPROs.
+ * lisp.h (struct gcpro) [DEBUG_GCPRO]: Add extra members.
+ (GCPRO1, GCPRO2, GCPRO3, GCPRO4, GCPRO5, GCPRO6, GCPRO7):
+ Minor restyle. If DEBUG_GCPRO, initialize extra fields.
+
+ * lread.c (readevalloop_eager_expand_eval): Add GCPRO and fix
+ bootstrap broken if GC_MARK_STACK == GC_USE_GCPROS_AS_BEFORE.
+
- Remove redundant GCPROs around Ffuncall and Fapply calls. This
- is safe because Ffuncall protects all of its arguments by itself.
++ Remove redundant GCPROs around Ffuncall and Fapply calls.
++ This is safe because Ffuncall protects all of its arguments by itself.
+ * charset.c (map_charset_for_dump): Remove redundant GCPRO.
+ * eval.c (Fapply, apply1, call0, call1, call2, call3, call4, call5)
+ (call6, call7): Likewise. Use compound literals where applicable.
+ (run_hook_with_args_2): Use compound literal.
+
+2014-09-11 Paul Eggert <eggert@cs.ucla.edu>
+
+ Pacify --enable-gcc-warnings when no window system is used.
+ These warnings found that subscript error, so they seem worthwhile.
+ * composite.c (char_composable_p): Simplify a bit.
+ * frame.c (x_set_frame_parameters): Add an IF_LINT.
+ * frame.c (x_set_horizontal_scroll_bars, x_set_scroll_bar_height):
+ * frame.h (FRAME_HAS_HORIZONTAL_SCROLL_BARS):
+ * window.c (set_window_scroll_bars):
+ Use USE_HORIZONTAL_SCROLL_BARS for simplicity.
+ * frame.h [! USE_HORIZONTAL_SCROLL_BARS]:
+ Ignore -Wsuggest-attribute=const.
+ * window.h (USE_HORIZONTAL_SCROLL_BARS): New macro.
+ (WINDOW_HAS_HORIZONTAL_SCROLL_BAR): Use it.
+
+2014-09-10 Paul Eggert <eggert@penguin.cs.ucla.edu>
+
+ * charset.c (Fget_unused_iso_final_char): Fix subscript error.
+ Use check_iso_charset_parameter instead of doing the checks by hand.
+ (check_iso_charset_parameter): Move up. Check parameters a bit
+ more carefully, and return true for 96-char sets. All callers changed.
+
+2014-09-10 Paul Eggert <eggert@cs.ucla.edu>
+
+ Simplify lisp.h by removing the __COUNTER__ business.
+ Problem reported by Dmitry Antipov in:
+ http://lists.gnu.org/archive/html/emacs-devel/2014-09/msg00220.html
+ * lisp.h (make_local_vector, make_local_string)
+ (build_local_string): Simplify by not bothering with __COUNTER__.
+ The __COUNTER__ business wasn't working properly, and was needed
+ only for hypothetical future expansion anyway.
+
+2014-09-10 Alp Aker <alp.tekin.aker@gmail.com>
+
+ * nsterm.m (ns_draw_fringe_bitmap): Use the same logic as other
+ terms to determine bitmap color. (Bug#18437)
+
+2014-09-10 Eli Zaretskii <eliz@gnu.org>
+
+ * w32.c (sys_write): Use SAFE_NALLOCA for the NL -> CRLF
+ translation buffer.
+
+2014-09-10 Paul Eggert <eggert@cs.ucla.edu>
+
+ * xterm.c (handle_one_xevent): Add braces to pacify gcc -Wall.
+
+2014-09-10 Jan Djärv <jan.h.d@swipnet.se>
+
+ * xterm.c (handle_one_xevent): Detect iconified by looking at
+ _NET_WM_STATE_HIDDEN.
+
+2014-09-10 Paul Eggert <eggert@cs.ucla.edu>
+
+ * lisp.h (DEFINE_GDB_SYMBOL_ENUM): Remove.
+ These can generate a constant with the correct value but the wrong
+ width, which doesn't work as a printf argument. All uses removed.
+ Problem reported by Dmitry Antipov in:
+ http://lists.gnu.org/archive/html/emacs-devel/2014-09/msg00213.html
+ (ENUMABLE): Remove; no longer needed.
+ (ARRAY_MARK_FLAG_val, PSEUDOVECTOR_FLAG_val, VALMASK_val):
+ Remove; no longer needed because of the above change.
+ Each definiens moved to the only use.
+
+ Improve the experimental local and scoped allocation.
+ * alloc.c (local_string_init, local_vector_init):
+ New functions, defined if USE_LOCAL_ALLOCATORS.
+ Mostly, these are moved here from lisp.h, as it's not
+ clear it's worth making them inline.
+ * lisp.h (USE_STACK_LISP_OBJECTS): Default to false.
+ (GCALIGNED): Depend on HAVE_STRUCT_ATTRIBUTE_ALIGNED and
+ USE_STACK_LISP_OBJECTS, not on a laundry list.
+ (local_string_init, local_vector_init): New decls.
+ (union Aligned_Cons): New type.
+ (scoped_cons): Use it. Give up on the char trick, as it's a too
+ much of a maintenance hassle; if someone wants this speedup
+ they'll just need to convince their compiler to align properly.
+ Conversely, use the speedup if struct Lisp_Cons happens to
+ be aligned even without a directive. Better yet, help it along
+ by using union Aligned_Cons rather than struct Lisp_Cons.
+ (pointer_valid_for_lisp_object): Remove. This check is not
+ necessary, since make_lisp_ptr is already doing it. All uses removed.
+ (local_vector_init, local_string_init): Move to alloc.c.
+ (build_local_vector): Remove this awkward macro, replacing with ...
+ (make_local_vector): New macro, which acts more like a function.
+ Use statement expressions and use __COUNTER__ to avoid macro
+ capture. Fall back on functions if these features are not supported.
+ (build_local_string, make_local_string): Likewise.
+
+2014-09-09 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * xterm.c (x_term_init): Consolidate duplicated code.
+ [USE_LUCID]: Revert 2014-04-02 change (Bug#18403). Add comment.
+ (x_delete_terminal): Do not close X connection fd (Bug#18403).
+ Add eassert and mark dpyinfo as dead only if it was alive.
+
+ Add macros to allocate temporary Lisp objects with alloca.
+ Respect MAX_ALLOCA and fall back to regular GC for large objects.
+ * character.h (parse_str_as_multibyte): Move prototype to ...
+ * lisp.h (parse_str_as_multibyte): ... here.
+ (struct Lisp_Cons): Add GCALIGNED attribute if supported.
+ (scoped_cons, scoped_list2, build_local_vector, build_local_string):
+ New macros.
+ (scoped_cons_init, pointer_valid_for_lisp_object, local_vector_init)
+ (local_string_init): New functions.
+ * alloc.c (verify_alloca) [ENABLE_CHECKING]: New function.
+ (init_alloc_once): Call it.
+
+ Cleanup last change and make all new stuff conditional.
+ * lisp.h (build_local_string): Rename to ...
+ (make_local_string): ... this macro.
+ (build_local_string, scoped_list1, scoped_list3): New macros.
+ (toplevel) [USE_STACK_LISP_OBJECTS]: Define all new macros
+ and functions as such, use regular fallbacks otherwise.
+ * alloc.c (verify_alloca) [USE_STACK_LISP_OBJECTS]: Define
+ conditionally.
+
+2014-09-08 Eli Zaretskii <eliz@gnu.org>
* dispnew.c (prepare_desired_row): When MODE_LINE_P is zero,
always make sure the marginal areas of the row are in sync with
existing binding of a variable, to avoid silently aborting
commands that use specbind. (Bug#18331)
-2014-09-02 Eli Zaretskii <eliz@gnu.org>
+2014-09-07 Paul Eggert <eggert@cs.ucla.edu>
+
+ Fix bug uncovered by changing alloca to auto buffer (Bug#18410).
+ * coding.c (growable_destination): New function.
+ (produce_chars): Use it for sanity checks. Do not fiddle with
+ dst_end if the source and destination are both nil, as it's
+ the caller's responsibility to avoid overlap.
+ * keyboard.c (read_decoded_event_from_main_queue):
+ The destination must be MAX_MULTIBYTE_LENGTH times the max source
+ length, not 4 times, to prevent decode_coding_c_string from trying
+ to reallocate a destination. This removes the need for the FIXME.
+
+ * callproc.c (exec_failed) [DOS_NT]: Define a dummy.
+ All callers simplified. Add a comment about exec_failed, vfork,
+ and alloca.
+
+ Adjust drag-and-drop fix when window is above top (Bug#18303).
+ * xselect.c (x_fill_property_data): Don't let sign bit of negative
+ XCDR bleed into XCAR's encoded value. Improve checks for
+ out-of-range data while we're at it.
+
+2014-09-07 Jan Djärv <jan.h.d@swipnet.se>
+
+ * xselect.c (x_fill_property_data): Handle negative XCDR when data
+ is CONSP (Bug#18303).
+
+2014-09-07 Eli Zaretskii <eliz@gnu.org>
+
+ * callproc.c (child_setup) [WINDOWSNT]: Don't call exec_failed if
+ 'alloca' gets passed arguments larger than MAX_ALLOCA.
+
+ * font.c (MAX): Define if not defined elsewhere.
+
+2014-09-07 Paul Eggert <eggert@cs.ucla.edu>
+
+ * keyboard.c (read_decoded_event_from_main_queue): Reinstitute alloca
+ here for destination buffer, to work around what appears to be a
+ bug in decode_coding_c_string when the source and destination are
+ both C strings.
+
+ Use SAFE_ALLOCA etc. to avoid unbounded stack allocation (Bug#18410).
+ This follows up on the recent thread in emacs-devel on alloca; see:
+ http://lists.gnu.org/archive/html/emacs-devel/2014-09/msg00042.html
+ This patch also cleans up alloca-related glitches noted while
+ examining the code looking for unbounded alloca.
+ * alloc.c (listn):
+ * callproc.c (init_callproc):
+ Rewrite to avoid need for alloca.
+ * buffer.c (mouse_face_overlay_overlaps)
+ (report_overlay_modification):
+ * buffer.h (GET_OVERLAYS_AT):
+ * coding.c (make_subsidiaries):
+ * doc.c (Fsnarf_documentation):
+ * editfns.c (Fuser_full_name):
+ * fileio.c (Ffile_name_directory, Fexpand_file_name)
+ (search_embedded_absfilename, Fsubstitute_in_file_name):
+ * fns.c (Fmake_hash_table):
+ * font.c (font_vconcat_entity_vectors, font_update_drivers):
+ * fontset.c (fontset_pattern_regexp, Ffontset_info):
+ * frame.c (Fmake_terminal_frame, x_set_frame_parameters)
+ (xrdb_get_resource, x_get_resource_string):
+ * ftfont.c (ftfont_get_charset, ftfont_check_otf, ftfont_drive_otf):
+ * ftxfont.c (ftxfont_draw):
+ * image.c (xbm_load, xpm_load, jpeg_load_body):
+ * keyboard.c (echo_add_key, menu_bar_items, tool_bar_items)
+
+ * keymap.c (Fdescribe_buffer_bindings, describe_map):
+ * lread.c (openp):
+ * menu.c (digest_single_submenu, find_and_call_menu_selection)
+ (find_and_return_menu_selection):
+ * print.c (PRINTFINISH):
+ * process.c (Fformat_network_address):
+ * scroll.c (do_scrolling, do_direct_scrolling, scrolling_1):
+ * search.c (search_buffer, Fmatch_data, Fregexp_quote):
+ * sound.c (wav_play, au_play):
+ * syntax.c (skip_chars):
+ * term.c (tty_menu_activate, tty_menu_show):
+ * textprop.c (get_char_property_and_overlay):
+ * window.c (Fset_window_configuration):
+ * xdisp.c (safe__call, next_overlay_change, vmessage)
+ (compute_overhangs_and_x, draw_glyphs, note_mouse_highlight):
+ * xfaces.c (face_at_buffer_position):
+ * xmenu.c (x_menu_show):
+ Use SAFE_ALLOCA etc. instead of plain alloca, since the
+ allocation size isn't bounded.
+ * callint.c (Fcall_interactively): Redo memory_full check
+ so that it can be done at compile-time on some platforms.
+ * coding.c (MAX_LOOKUP_MAX): New constant.
+ (get_translation_table): Use it.
+ * callproc.c (call_process): Use SAFE_NALLOCA instead of
+ SAFE_ALLOCA, to catch integer overflows on size calculation.
+ (exec_failed) [!DOS_NT]: New function.
+ (child_setup) [!DOS_NT]: Use it.
+ * editfns.c (Ftranspose_regions):
+ Hoist USE_SAFE_ALLOC + SAFE_FREE out of 'if'.
+ * editfns.c (check_translation):
+ Allocate larger buffers on the heap.
+ * eval.c (internal_lisp_condition_case):
+ Check for MAX_ALLOCA overflow.
+ * fns.c (sort_vector): Use SAFE_ALLOCA_LISP rather than Fmake_vector.
+ (Fbase64_encode_region, Fbase64_decode_region):
+ Avoid unnecessary calls to SAFE_FREE before 'error'.
+ * buffer.c (mouse_face_overlay_overlaps):
+ * editfns.c (Fget_pos_property, check_translation):
+ * eval.c (Ffuncall):
+ * font.c (font_unparse_xlfd, font_find_for_lface):
+ * ftfont.c (ftfont_drive_otf):
+ * keyboard.c (echo_add_key, read_decoded_event_from_main_queue)
+ (menu_bar_items, tool_bar_items):
+ * sound.c (Fplay_sound_internal):
+ * xdisp.c (load_overlay_strings, dump_glyph_row):
+ Use an ordinary auto buffer rather than alloca, since the
+ allocation size is fixed and small.
+ * ftfont.c: Include <c-strcase.h>.
+ (matching_prefix): New function.
+ (get_adstyle_property): Use it, to avoid need for alloca.
+ * keyboard.c (echo_add_key):
+ * keymap.c (describe_map): Use ptrdiff_t, not int.
+ * keyboard.c (echo_add_key): Prefer sizeof to strlen.
+ * keymap.c (Fdescribe_buffer_bindings): Use SBYTES, not SCHARS,
+ when counting bytes.
+ * lisp.h (xlispstrdupa): Remove, replacing with ...
+ (SAFE_ALLOCA_STRING): ... new macro with different API.
+ This fixes a portability problem, namely, alloca result
+ passed to another function. All uses changed.
+ (SAFE_ALLOCA, SAFE_ALLOCA_LISP): Check for MAX_ALLOCA,
+ not MAX_ALLOCA - 1.
+ * regex.c (REGEX_USE_SAFE_ALLOCA, REGEX_SAFE_FREE)
+ (REGEX_ALLOCATE): New macros.
+ (REGEX_REALLOCATE, REGEX_ALLOCATE_STACK, REGEX_REALLOCATE_STACK)
+ (REGEX_FREE_STACK, FREE_VARIABLES, re_match_2_internal):
+ Use them.
+ * xdisp.c (message3): Use SAFE_ALLOCA_STRING rather than doing it
+ by hand.
+ (decode_mode_spec_coding): Store directly into buf rather than
+ into an alloca temporary and copying the temporary to the buf.
+
+2014-09-06 Eli Zaretskii <eliz@gnu.org>
+
+ * Makefile.in (EMACS_HEAPSIZE): Remove, no longer used. (Bug#18416)
+
+2014-09-04 Jan D <jhd@f20.localdomain>
+
+ * xterm.c (x_term_init): Don't call x_session_initialize if running
+ as a daemon (Bug#18375).
+
+ * xsmfns.c: Initialize ice_fd.
+
+2014-09-04 Paul Eggert <eggert@cs.ucla.edu>
+
+ Less chatter in 'make' output.
+ * Makefile.in (AM_V_GEN, am__v_GEN_, am__v_GEN_0, am__v_GEN_1, AM_V_at)
+ (am__v_at_, am__v_at_0, am__v_at_1): New macros, taken from Automake.
+ ($(etc)/DOC, buildobj.h, gl-stamp): Use them.
+
+2014-09-03 Martin Rudalics <rudalics@gmx.at>
+
+ * buffer.c (scroll-bar-height): Fix typo in doc-string.
- * frame.c (Vdefault_frame_horizontal_scroll_bars): Remove
- variable.
++ * frame.c (Vdefault_frame_horizontal_scroll_bars):
++ Remove variable.
+ * nsfns.m (Fx_create_frame):
+ * w32fns.c (Fx_create_frame):
+ * xfns.c (Fx_create_frame): Default horizontal scroll bars to
+ nil.
+
+2014-09-03 Eli Zaretskii <eliz@gnu.org>
* dispnew.c (buffer_posn_from_coords): Fix an off-by-one error in
the reported row in the case of a window with a header line, by
when HPOS is negative, for the benefit of R2L glyph rows whose
newline overflows into the fringe.
-2014-08-30 Ken Brown <kbrown@cornell.edu>
+2014-09-03 Ken Brown <kbrown@cornell.edu>
- * conf_post.h (strnicmp) [CYGWIN && HAVE_NTGUI]: Define.
- (Bug#18366)
+ * conf_post.h (strnicmp) [CYGWIN && HAVE_NTGUI]: Define. (Bug#18366)
-2014-08-28 Eli Zaretskii <eliz@gnu.org>
+2014-09-02 Paul Eggert <eggert@cs.ucla.edu>
- * syntax.c (scan_lists): Don't examine positions before BEGV.
- (Bug#18339)
+ Minor cleanup of recent strlen-avoiding patch.
+ * fileio.c (CHECK_LENGTH): Remove.
+ Rewrite callers so that they don't need it.
+ (Fexpand_file_name) [DOS_NT]: Fix a case where directory length
+ variable wasn't set.
+
+2014-09-02 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * fileio.c (CHECK_LENGTH): New macro.
+ (Fexpand_file_name): Use it and get rid of a few more calls
+ to strlen and strcat.
+ * callproc.c (egetenv_internal): Add arg and rename from egetenv ...
+ * lisp.h (egetenv): ... because of a new inline function used to
+ avoid calls to strlen for a compile-time constants.
+
+ * buffer.h (decode_buffer): New function.
+ * buffer.c (Fbuffer_name, Fbuffer_file_name, Fbuffer_base_buffer)
+ (Fbuffer_local_variables, Fbuffer_modified_p, Fbuffer_modified_tick)
+ (Fbuffer_chars_modified_tick, Fdelete_all_overlays):
+ * data.c (Flocal_variables_p):
+ * fileio.c (Fverify_visited_file_modtime):
+ * marker.c (live_buffer): Use it.
+
+2014-09-01 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Avoid extra calls to strlen in filesystem I/O routines.
+ * fileio.c (Fexpand_file_name): Avoid calls to strlen if
+ the length of 'newdir' is known or may be precalculated.
+ (file_accessible_directory_p): Prefer to pass Lisp_Object,
+ not 'char *', and so use precalculated length.
+ (Ffile_accessible_directory_p):
+ * callproc.c (encode_current_directory, init_callproc):
+ * charset.c (init_charset):
+ * lread.c (load_path_check, load_path_default): Adjust users.
+ * lisp.h (file_accessible_directory_p): Tweak prototype.
+
+2014-09-01 Eli Zaretskii <eliz@gnu.org>
+
+ * w32proc.c (w32_compare_strings): Support "C" and "POSIX"
+ locales.
+
+2014-09-01 Paul Eggert <eggert@cs.ucla.edu>
+
+ --enable-silent-rules now suppresses more chatter.
+ * Makefile.in (AM_DEFAULT_VERBOSITY, AM_V_CC, am__v_CC_)
+ (am__v_CC_0, am__v_CC_1, AM_V_CCLD, am__v_CCLD_, am__v_CCLD_0)
+ (am__v_CCLD_1): New macros, taken from Automake.
+ (.c.o, .m.o, temacs$(EXEEXT)): Use them.
+
+ Clean up extern decls a bit.
+ * bytecode.c: Include blockinput.h and keyboard.h rather
+ than rolling their APIs by hand.
+ * emacs.c: Include regex.h and rely on its and lisp.h's API
+ rather than rolling them by hand.
+ * lastfile.c: Include lisp.h, to check this file's API.
+ * lisp.h (lisp_eval_depth, my_edata, my_endbss, my_endbss_static):
+ New decls.
+ * regex.h (re_max_failures): New decl.
+ * unexcw.c, unexmacosx.c, unexw32.c:
+ Rely on lisp.h's API rather than rolling it by hand.
+ * vm-limit.c (__after_morecore_hook, __morecore, real_morecore):
+ Declare at top level, to pacify GCC -Wnested-externs.
-2014-08-25 Eli Zaretskii <eliz@gnu.org>
+2014-08-31 Eli Zaretskii <eliz@gnu.org>
- * conf_post.h (_GL_EXECINFO_INLINE) [MSDOS]: Don't define.
+ * xdisp.c (get_glyph_string_clip_rects): Don't let the width of a
+ clipping rectangle become negative (i.e. large positive, since
+ it's an unsigned data type). This can happen in R2L hscrolled
+ glyph rows, and caused us to draw the cursor glyph on the fringe.
+ For the details, see
+ http://lists.gnu.org/archive/html/emacs-devel/2014-08/msg00543.html.
+
+2014-08-31 Ken Brown <kbrown@cornell.edu>
-2014-08-18 Eli Zaretskii <eliz@gnu.org>
+ * gmalloc.c: Don't include <stdlib.h>. Declare system malloc and
+ friends before defining hybrid_malloc and friends if HYBRID_MALLOC
+ is defined. (Bug#18368)
+
+2014-08-30 Paul Eggert <eggert@cs.ucla.edu>
+
+ Vector-sorting fixes (Bug#18361).
+ It's not safe to call qsort or qsort_r, since they have undefined
+ behavior if the user-specified predicate is not a total order.
+ Also, watch out for garbage-collection while sorting vectors.
+ * fns.c: Include <vla.h>.
+ (sort_vector_predicate) [!HAVE_QSORT_R]: Remove.
+ (sort_vector_compare): Remove, replacing with ....
+ (inorder, merge_vectors, sort_vector_inplace, sort_vector_copy):
+ ... these new functions.
+ (sort_vector): Rewrite to use the new functions.
+ GCPRO locals, since the predicate can invoke the GC.
+ Since it's in-place return void; caller changed.
+ (merge): Use 'inorder', for clarity.
+
+ * sysdep.c (str_collate): Clear errno just before wcscoll(_l).
+ One can't hoist this out of the 'if', because intervening calls to
+ newlocale, twolower, etc. can change errno.
+
+2014-08-30 Eli Zaretskii <eliz@gnu.org>
+
+ * sysdep.c (str_collate) [__STDC_ISO_10646__]: Improve the
+ wording of the error messages.
+ (str_collate) [WINDOWSNT]: Signal an error if w32_compare_strings
+ sets errno.
+
+ * w32proc.c (get_lcid_callback): Accept locale specifications
+ without the country part, as in "enu" vs "enu_USA".
+ (w32_compare_strings): Signal an error if a locale was specified,
+ but couldn't be translated into a valid LCID.
+
+2014-08-29 Michael Albinus <michael.albinus@gmx.de>
+
+ * sysdep.c (str_collate) [__STDC_ISO_10646__]: Move up setting errno.
+
+2014-08-29 Paul Eggert <eggert@cs.ucla.edu>
+
+ * sysdep.c (str_collate) [__STDC_ISO_10646__]: Do not look at
+ errno after towlower_l. errno's value is not specified after
+ towlower_l. Instead, assume that towlower_l returns its argument
+ on failure, which is portable in practice.
+
+2014-08-29 Eli Zaretskii <eliz@gnu.org>
+
+ * fns.c (Fstring_collate_lessp, Fstring_collate_equalp): Doc fix.
+
+ * w32proc.c (w32_compare_strings): Accept additional argument
+ IGNORE_CASE. Set up the flags for CompareStringW to ignore case
+ if requested. If w32-collate-ignore-punctuation is non-nil, add
+ NORM_IGNORESYMBOLS to the flags.
+ (LINGUISTIC_IGNORECASE): Define if not already defined.
+ (syms_of_ntproc) <Vw32_collate_ignore_punctuation>: New variable.
+
+ * sysdep.c (str_collate) [WINDOWSNT]: Adapt to the interface
+ change.
+
+2014-08-29 Michael Albinus <michael.albinus@gmx.de>
+
+ * sysdep.c (LC_CTYPE, LC_CTYPE_MASK, towlower_l):
+ Define substitutes for platforms that lack them.
+ (str_collate): Add arguments locale and ignore_case.
+
+ * fns.c (Fstring_collate_lessp, Fstring_collate_equalp):
+ Add optional arguments LOCALE and IGNORE-CASE.
+
+ * lisp.h (str_collate): Adapt argument list.
+
+2014-08-29 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Add vectors support to Fsort.
+ * fns.c (sort_vector, sort_vector_compare): New functions.
+ (sort_list): Likewise, refactored out of ...
+ (Fsort): ... adjusted user. Mention vectors in docstring.
+ (sort_vector_predicate) [!HAVE_QSORT_R]: New variable.
+ * alloc.c (make_save_int_obj): New function.
+ * lisp.h (enum Lisp_Save_Type): New member SAVE_TYPE_INT_OBJ.
+ (make_save_int_obj): Add prototype.
+
+ Fix last change to support Darwin/OSX and FreeBSD (Bug#18354).
+ * sysdep.c (sort_vector_compare) [DARWIN_OS || __FreeBSD__]:
+ Conditionally define to match system's qsort_r signature.
+ (sort_vector) [DARWIN_OS || __FreeBSD__]: Likewise in call to qsort_r.
+
+2014-08-28 Ken Brown <kbrown@cornell.edu>
+
+ Add support for HYBRID_MALLOC, allowing the use of gmalloc before
+ dumping and the system malloc after dumping. (Bug#18222)
+
+ * conf_post.h (malloc, realloc, calloc, free) [HYBRID_MALLOC]:
+ Define as macros, expanding to hybrid_malloc, etc.
+ (HYBRID_GET_CURRENT_DIR_NAME): New macro.
+ (get_current_dir_name) [HYBRID_GET_CURRENT_DIR_NAME]: Define as
+ macro.
+ * gmalloc.c: Set up the infrastructure for HYBRID_MALLOC, with a
+ full implementation on Cygwin. Remove Cygwin-specific code that
+ is no longer needed.
+ (malloc, realloc, calloc, free, aligned_alloc) [HYBRID_MALLOC]:
+ Redefine as macros expanding to gmalloc, grealloc, etc.
+ (DUMPED, ALLOCATED_BEFORE_DUMPING) [CYGWIN]: New macros.
+ (get_current_dir_name) [HYBRID_GET_CURRENT_DIR_NAME]: Undefine.
+ (USE_PTHREAD, posix_memalign) [HYBRID_MALLOC]: Don't define.
+ (hybrid_malloc, hybrid_calloc, hybrid_free, hybrid_realloc)
+ [HYBRID_MALLOC]:
+ (hybrid_get_current_dir_name) [HYBRID_GET_CURRENT_DIR_NAME]:
+ (hybrid_aligned_alloc) [HYBRID_MALLOC && (HAVE_ALIGNED_ALLOC ||
+ HAVE_POSIX_MEMALIGN)]: New functions.
+ * alloc.c (aligned_alloc) [HYBRID_MALLOC && (ALIGNED_ALLOC ||
+ HAVE_POSIX_MEMALIGN)]: Define as macro expanding to
+ hybrid_aligned_alloc; declare.
+ (USE_ALIGNED_ALLOC) [HYBRID_MALLOC && (ALIGNED_ALLOC ||
+ HAVE_POSIX_MEMALIGN)]: Define.
+ (refill_memory_reserve) [HYBRID_MALLOC]: Do nothing.
+ * sysdep.c (get_current_dir_name) [HYBRID_GET_CURRENT_DIR_NAME]:
+ Define as macro, expanding to gget_current_dir_name, and define
+ the latter.
+ * emacs.c (main) [HYBRID_MALLOC]: Don't call memory_warnings() or
+ malloc_enable_thread(). Don't initialize malloc.
+ * lisp.h (NONPOINTER_BITS) [CYGWIN]: Define (because GNU_MALLOC is
+ no longer defined on Cygwin).
+ (refill_memory_reserve) [HYBRID_MALLOC]: Don't declare.
+ * sheap.c (bss_sbrk_buffer_end): New variable.
+ * unexcw.c (__malloc_initialized): Remove variable.
+ * ralloc.c: Throughout, treat HYBRID_MALLOC the same as
+ SYSTEM_MALLOC.
+ * xdisp.c (decode_mode_spec) [HYBRID_MALLOC]: Don't check
+ Vmemory_full.
+
+2014-08-28 Martin Rudalics <rudalics@gmx.at>
+
- * w32term.c (w32_horizontal_scroll_bar_handle_click): In
- `event->y' return entire range (the size of the scroll bar minus
++ * w32term.c (w32_horizontal_scroll_bar_handle_click):
++ In `event->y' return entire range (the size of the scroll bar minus
+ that of the thumb).
+ * xterm.c (xm_scroll_callback, xaw_jump_callback): In `whole'
+ return entire range (the scaled size of the scroll bar minus
+ that of the slider). In `portion' return the scaled position of
+ the slider.
+ (xaw_jump_callback): Restore part of code for vertical scroll
+ bar broken in change from 2014-07-27.
+ (xaw_scroll_callback): Provide incremental scrolling with
+ horizontal scroll bars.
- * xdisp.c (handle_stop): Improve commentary.
+2014-08-28 Eli Zaretskii <eliz@gnu.org>
+
+ * conf_post.h (_GL_EXECINFO_INLINE) [MSDOS]: Don't define.
* indent.c (Fvertical_motion): Fix vertical motion up through a
display property after a newline. (Bug#18276)
-2014-08-17 Eli Zaretskii <eliz@gnu.org>
-
* xdisp.c (display_line): Don't assume that the call to
reseat_at_next_visible_line_start ends up at a character
-- immediately following the newline on the previous line. Avoids
-- setting the ends_at_zv_p flag on screen lines that are not at or
++ immediately following the newline on the previous line.
++ Avoids setting the ends_at_zv_p flag on screen lines that are not at or
beyond ZV, which causes infloop in redisplay. For the details, see
http://lists.gnu.org/archive/html/emacs-devel/2014-08/msg00368.html.
* dispnew.c (buffer_posn_from_coords): Fix mirroring of X
coordinate for hscrolled R2L screen lines. (Bug#18277)
-2014-08-11 Ken Brown <kbrown@cornell.edu>
+2014-08-28 Paul Eggert <eggert@cs.ucla.edu>
+
+ * sysdep.c (LC_COLLATE, LC_COLLATE_MASK): Give individual defaults
+ (Bug#18051).
+
+2014-08-27 Eli Zaretskii <eliz@gnu.org>
+
+ * syntax.c (scan_lists): Don't examine positions before BEGV.
+ (Bug#18339)
+
+2014-08-27 Paul Eggert <eggert@cs.ucla.edu>
+
+ Improve robustness of new string-collation code (Bug#18051).
+ * sysdep.c (LC_COLLATE, LC_COLLATE_MASK, freelocale, locale_t)
+ (newlocale, wcscoll_l): Define substitutes for platforms that
+ lack them, so as to simplify the mainline code.
+ (str_collate): Simplify the code by assuming the above definitions.
- Use wcscoll_l, not uselocale, as uselocale is too fragile. For
- example, the old version left the Emacs in the wrong locale if
++ Use wcscoll_l, not uselocale, as uselocale is too fragile.
++ For example, the old version left the Emacs in the wrong locale if
+ wcscoll reported an error. Use 'int', not ptrdiff_t, for the int
+ result. Report an error if newlocale fails.
+
+2014-08-27 Michael Albinus <michael.albinus@gmx.de>
+
+ * lisp.h (str_collate):
+ * sysdep.c (str_collate): Return int.
+ (str_collate) [__STDC_ISO_10646__]: Propagate error of wcscoll.
+
+2014-08-27 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Fix some glitches in previous change.
+ * sysdep.c (stack_direction): Replace stack_grows_down
+ to simplify calculation of stack boundaries.
+ (handle_sigsegv): Check whether we really crash somewhere near
+ to stack boundary, and handle fatal signal as usual if not.
+ (init_sigsegv): Adjust accordingly.
+ * keyboard.c (Vtop_level_message): Rename to
+ Vinternal__top_level_message, as suggested by Stefan Monnier in
+ http://lists.gnu.org/archive/html/emacs-devel/2014-08/msg00493.html
+ All related users changed.
+
+2014-08-26 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Handle C stack overflow caused by too nested Lisp evaluation.
+ * lisp.h (toplevel) [HAVE_STACK_OVERFLOW_HANDLING]: Declare
+ siglongjmp point to transfer control from SIGSEGV handler.
+ * keyboard.c (return_to_command_loop, recover_top_level_message)
+ [HAVE_STACK_OVERFLOW_HANDLING]: New variables.
+ (regular_top_level_message): New variable.
+ (command_loop) [HAVE_STACK_OVERFLOW_HANDLING]: Handle non-local
+ exit from SIGSEGV handler and adjust message displayed by Vtop_level
+ if appropriate.
+ (syms_of_keyboard): DEFVAR Vtop_level_message and initialize
+ new variables described above.
+ * sysdep.c [HAVE_SYS_RESOURCE_H]: Include sys/resource.h as such.
+ (stack_grows_down, sigsegv_stack, handle_sigsegv)
+ [HAVE_STACK_OVERFLOW_HANDLING]: New variables and function.
+ (init_sigsegv): New function.
+ (init_signals): Use it.
+
+2014-08-25 Ken Brown <kbrown@cornell.edu>
+
+ * emacs.c (main): Remove use of obsolete macro
+ G_SLICE_ALWAYS_MALLOC.
+
+2014-08-25 Eli Zaretskii <eliz@gnu.org>
+
+ Implement locale-sensitive string collation for MS-Windows.
+ * w32proc.c (get_lcid_callback, get_lcid, w32_compare_strings):
+ New functions. (Bug#18051)
+
+ * w32.h (w32_compare_strings): Add prototype.
+
+ * w32.c <g_b_init_compare_string_w>: New global flag.
+ (globals_of_w32): Initialize it.
+
+ * sysdep.c (str_collate) [WINDOWSNT]: Implementation for MS-Windows.
+
+ * fns.c (Fstring_collate_lessp, Fstring_collate_equalp)
+ [WINDOWSNT]: Call str_collate on MS-Windows.
+
+2014-08-25 Dmitry Antipov <dmantipov@yandex.ru>
+
+ One more minor cleanup of font subsystem.
+ * font.h (struct font_driver): Convert text_extents to
+ return void because returned value is never actually used.
+ * macfont.m (macfont_text_extents):
+ * w32font.c (w32font_text_extents):
+ * xftfont.c (xftfont_text_extents): Adjust to return void
+ and assume that 'metrics' argument is always non-NULL.
+ * ftfont.c (ftfont_text_extents):
+ * xfont.c (xfont_text_extents): Likewise. Avoid redundant memset.
+
+2014-08-25 Paul Eggert <eggert@cs.ucla.edu>
+
+ Minor cleanups of str_collate fix (Bug#18051).
+ * fns.c (str_collate): Move decl from here ...
+ * lisp.h (str_collate): ... to here.
+ * sysdep.c (str_collate): Prune away some of the forest of ifdefs.
+ Remove unnecessary casts. Use SAFE_NALLOCA to avoid
+ potential problems with integer overflow. Don't assume
+ setlocale succeeds. Remove unnecessary test before restoring
+ locale via setlocale, and free the copied setlocale string
+ when done with it.
+
+2014-08-24 Michael Albinus <michael.albinus@gmx.de>
+
+ * fns.c (Fstring_collate_lessp, Fstring_collate_equalp): New DEFUNs.
+
+ * sysdep.c (str_collate): New function. (Bug#18051)
+
+2014-08-23 Karol Ostrovsky <karol.ostrovsky@gmail.com> (tiny change)
+
+ * Makefile.in (emacs$(EXEEXT)): Retry deletion of bootstrap-emacs
+ if the initial "rm -f" fails. This is for MinGW builds, where
+ MS-Windows will not allow deleting the executable file of a
+ running program.
+
+2014-08-20 Eli Zaretskii <eliz@gnu.org>
+
+ * w32term.c (w32_scroll_bar_handle_click)
+ (w32_horizontal_scroll_bar_handle_click)
+ (x_scroll_bar_report_motion)
+ (x_horizontal_scroll_bar_report_motion): For SB_THUMBPOSITION and
+ SB_THUMBTRACK, use the 32-bit position information returned by
+ GetScrollInfo, not the 16-bit information returned in the Windows
+ message sent to us.
+
+2014-08-19 Eli Zaretskii <eliz@gnu.org>
+
+ * w32term.c (w32_horizontal_scroll_bar_handle_click): Fix the
+ second coordinate ('y') reported for dragging the horizontal
+ scroll bar thumb.
+
+2014-08-19 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
+
+ * xdisp.c (erase_phys_cursor): Fix confusion between window-relative
+ and text area-relative x-coordinates.
+
+2014-08-17 Eli Zaretskii <eliz@gnu.org>
+
+ Avoid overwriting the reversed_p flags in the glyph matrices when
+ init_iterator or start_display are called.
+ * xdisp.c (init_iterator): Don't initialize the reversed_p flag of
+ the glyph row here.
+ (tool_bar_height, redisplay_tool_bar, try_window)
+ (try_window_reusing_current_matrix, try_window_id)
+ (get_overlay_arrow_glyph_row, display_menu_bar): Initialize the
+ reversed_p flag of the iterator's glyph row where the glyph row
+ is going to be redrawn.
+
+2014-08-16 Paul Eggert <eggert@cs.ucla.edu>
+
+ * xdisp.c (set_horizontal_scroll_bar): Don't use uninitialized local.
+
+2014-08-16 Martin Rudalics <rudalics@gmx.at>
+
+ * w32term.c (w32_horizontal_scroll_bar_handle_click): In y part
+ of emacs_event return length from si.nPage to si.nMax.
+ * xdisp.c (set_horizontal_scroll_bar): For right-to-left text
+ interchange start and end of thumb.
+
+2014-08-15 Ken Brown <kbrown@cornell.edu>
* gmalloc.c (_malloc_mutex, _aligned_blocks_mutex) [CYGWIN]: Use
ERRORCHECK mutexes. (Bug#18222)
* buffer.c (Fmake_indirect_buffer): Initialize undo list with the
base buffer's undo list.
-2014-08-03 Dmitry Antipov <dmantipov@yandex.ru>
+2014-08-10 Reuben Thomas <rrt@sc3d.org>
+
+ Fix a couple of recent inadvertent breaks of the MSDOS port.
+ * msdos.c: include required menu.h
+ * term.c: set correct menu_show_hook on MSDOS.
- Fix bug with an attempt to select uninitialized frame (Bug#18161).
- * xfns.c (Fx_create_frame): Move call to change_frame_size to
- a section where Lisp evaluation is disabled. This way a pointer
- to uninitialized frame is not accessible from Lisp, which becomes
- critical if following call to x_figure_window_size throws an error.
+2014-08-10 Martin Rudalics <rudalics@gmx.at>
+
+ Fix handling of menu bar line on TTY frames (Bug#18136)
+ (Bug#18196).
+ * dispnew.c (handle_window_change_signal):
+ * keyboard.c (Fsuspend_emacs): Call change_frame_size with
+ frame's menu bar lines subtracted from height.
+ * frame.c (frame_inhibit_resize): Inhibit resizing of TTY
+ frames.
+ (adjust_frame_size): Count in menu bar when setting FrameRows.
+ (make_terminal_frame): When setting up the frame's lines and
+ text height don't count in the menu bar.
+ (Fmake_terminal_frame): Call adjust_frame_size with menu bar
+ lines subtracted from height.
+ (do_switch_frame): Set tty's FrameRows to number of total lines
+ of frame.
+ (Fframe_pixel_height, Fframe_pixel_width): If no window system
+ is used, return total number of lines and columns.
+ * menu.c (emulate_dialog_with_menu): Use FRAME_TOTAL_LINES instead
+ of FRAME_LINES.
+ * term.c (OUTPUT, tty_set_terminal_modes)
+ (tty_set_terminal_window, tty_set_scroll_region)
+ (tty_clear_to_end, tty_write_glyphs, tty_write_glyphs_with_face)
- (tty_ins_del_lines, tty_menu_display, tty_menu_activate): Use
- FRAME_TOTAL_LINES instead of FRAME_LINES.
++ (tty_ins_del_lines, tty_menu_display, tty_menu_activate):
++ Use FRAME_TOTAL_LINES instead of FRAME_LINES.
+ (Fresume_tty): Use FRAME_TOTAL_LINES instead of FRAME_LINES.
+ Call change_frame_size with frame's menu bar lines subtracted
+ from height.
+ * w32console.c (w32con_clear_to_end, w32con_clear_frame)
+ (w32con_ins_del_lines): Use FRAME_TOTAL_LINES instead of
+ FRAME_LINES.
-2014-08-02 Paul Eggert <eggert@cs.ucla.edu>
+2014-08-09 Reuben Thomas <rrt@sc3d.org>
+
+ * alloc.c (Fmemory_info): Remove a stray brace.
+
+ * process.c: Fix a comment typo.
+
+ * msdos.c, dosfns.c (init_dosfns): Remove support for DJGPP < 2.02.
+
+2014-08-09 Jan Djärv <jan.h.d@swipnet.se>
+
+ * widgetprv.h (EmacsFramePart): Remove font.
+
+ * widget.c (DEFAULT_FACE_FONT, EmacsFrameSetValues, setup_frame_gcs)
+ (resources, setup_frame_cursor_bits): Remove unused variables and
+ functions, esp. wrt. font (Bug#18227).
+
+2014-08-07 Paul Eggert <eggert@cs.ucla.edu>
+
+ * xterm.c (x_delete_terminal): Plug file descriptor leak (Bug#17691).
+
+2014-08-07 Reuben Thomas <rrt@sc3d.org>
+
+ Refer to MS-DOS using the same name everywhere.
+
+ * editfns.c: Fix a couple of ``MS-DOG''s missed in the previous
+ commit.
+ * xfaces.c: ditto.
+
+2014-08-05 Martin Rudalics <rudalics@gmx.at>
+
+ * w32term.c (w32_redeem_scroll_bar):
+ * xterm.c (XTredeem_scroll_bar): Revert part of last change by
+ not redeeming scroll bars that have been turned off.
+
+2014-08-05 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * keyboard.c (safe_run_hooks): Follow the convenient style to bind
+ inhibit-quit to t and pass 2 args to safe_run_hook_funcall. See
+ <http://lists.gnu.org/archive/html/emacs-devel/2014-08/msg00077.html>.
+ (safe_run_hook_funcall): Adjust accordingly.
+
+2014-08-04 Martin Rudalics <rudalics@gmx.at>
+
- * frame.h (FRAME_HAS_HORIZONTAL_SCROLL_BARS): Condition
- correctly according to toolkit used.
++ * frame.h (FRAME_HAS_HORIZONTAL_SCROLL_BARS):
++ Condition correctly according to toolkit used.
+ * frame.c (make_initial_frame, make_terminal_frame)
+ (x_set_horizontal_scroll_bars, x_set_scroll_bar_height)
+ (Vdefault_frame_horizontal_scroll_bars): Correctly condition
+ assignments according to presence of toolkit scrollbars.
- * window.h (WINDOW_HAS_HORIZONTAL_SCROLL_BAR): Condition
- correctly according to toolkit used.
++ * window.h (WINDOW_HAS_HORIZONTAL_SCROLL_BAR):
++ Condition correctly according to toolkit used.
+ * window.c (set_window_scroll_bars): Set horizontal scroll bar
+ only if toolkit supports it.
+ * w32term.c (w32_redeem_scroll_bar): Always redeem scroll bar if
+ present.
+ * xterm.c (x_scroll_bar_create): Initialize horizontal slot for
+ non-toolkit builds.
+ (XTredeem_scroll_bar): Always redeem scroll bar if present.
+
+2014-08-04 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * keyboard.c (safe_run_hook_funcall): Avoid consing around
+ Vinhibit_quit and prefer internal_condition_case_n to pass args.
+ (safe_run_hooks_error, safe_run_hooks_1): Adjust accordingly.
+ (safe_run_hooks): Remove comment which is not relevant any more.
+
+2014-08-03 Paul Eggert <eggert@cs.ucla.edu>
+
+ Don't let big frames overrun the stack.
+ * dispnew.c (mirrored_line_dance, mirror_line_dance, scrolling):
+ Use SAFE_NALLOCA, not alloca.
Fix bug with clang + directory_files_internal + GC (Bug#16986).
* dired.c (directory_files_internal): Use a volatile variable
left_col, and top_line are C integers (and has been so for the
last 1.5 years).
-2014-07-20 Jan Djärv <jan.h.d@swipnet.se>
+ * .gdbinit (xsubchartable): The members 'depth' and 'min_char' are
+ now C integers.
+
+2014-07-28 Dmitry Antipov <dmantipov@yandex.ru>
+
+ On GNU/Linux, use timerfd for asynchronous timers.
+ * atimer.c (toplevel) [HAVE_TIMERFD]: Include sys/timerfd.h.
+ (toplevel): Rename alarm_timer_ok to special_timer_available.
+ [HAVE_TIMERFD]: Declare timerfd.
+ [HAVE_CLOCK_GETRES]: Declare resolution.
+ (start_atimer) [HAVE_CLOCK_GETRES]: Round up timestamp to
+ system timer resolution.
+ (set_alarm) [HAVE_TIMERFD]: Use timerfd_settime.
+ (timerfd_callback) [HAVE_TIMERFD]: New function.
+ (atimer_result, debug_timer_callback, Fdebug_timer_check)
+ [ENABLE_CHECKING]: New function for the sake of automated tests.
+ (init_atimer) [HAVE_TIMERFD]: Setup timerfd.
+ [HAVE_CLOCK_GETRES]: Likewise for system timer resolution.
+ [ENABLE_CHECKING]: Defsubr test function.
+ * atimer.h (timerfd_callback) [HAVE_TIMERFD]: Add prototype.
+ * lisp.h (add_timer_wait_descriptor) [HAVE_TIMERFD]: Likewise.
+ * process.c (add_timer_wait_descriptor) [HAVE_TIMERFD]: New function.
+
+ Fix --without-x build and pacify --enable-gcc-warnings.
+ Problems reported in Bug#18122 and Bug#18124.
+ * frame.c (get_frame_param): Define even if !HAVE_WINDOW_SYSTEM.
+ (frame_windows_min_size): Now static.
+ * frame.h (FRAME_HAS_HORIZONTAL_SCROLL_BARS) [!HAVE_WINDOW_SYSTEM]:
+ Define as no-op.
+ (adjust_frame_size): Always declare prototype.
+
+ Fix Gnus-related issues reported by David Kastrup <dak@gnu.org> in
+ <http://lists.gnu.org/archive/html/emacs-devel/2014-07/msg00370.html>.
+ * atimer.c (timerfd_callback): Always read expiration data.
+ Add comment.
+ (turn_on_atimers) [HAVE_TIMERFD]: Disarm timerfd timer.
+ * process.c (add_timer_wait_descriptor): Add timer descriptor
+ to input_wait_mask and non_process_wait_mask as well.
+
+2014-07-28 Paul Eggert <eggert@cs.ucla.edu>
+
+ * frame.c (x_set_frame_parameters): Don't use uninitialized locals.
+
+2014-07-27 Jan Djärv <jan.h.d@swipnet.se>
+
+ * nsterm.m (applicationDidFinishLaunching antialiasThresholdDidChange):
+ Reinstate code removed by the prevoius commit to this file.
+
+2014-07-27 Martin Rudalics <rudalics@gmx.at>
+
+ * buffer.h (struct buffer): New fields scroll_bar_height and
+ horizontal_scroll_bar_type.
+ * buffer.c (bset_scroll_bar_height)
+ (bset_horizontal_scroll_bar_type): New functions.
+ (Fbuffer_swap_text): Handle old_pointm field.
+ (init_buffer_once): Set defaults for scroll_bar_height and
+ horizontal_scroll_bar_type.
+ (syms_of_buffer): New variables scroll_bar_height and
+ horizontal_scroll_bar_type.
+ * dispextern.h (window_part): Rename ON_SCROLL_BAR to
+ ON_VERTICAL_SCROLL_BAR. Add ON_HORIZONTAL_SCROLL_BAR.
+ (set_vertical_scroll_bar): Remove prototype.
+ (x_change_tool_bar_height): Add prototype.
+ * dispnew.c (adjust_frame_glyphs_for_frame_redisplay)
+ (window_to_frame_vpos, update_frame_1, scrolling, init_display):
+ Use FRAME_TOTAL_COLS and FRAME_TOTAL_LINES instead of FRAME_COLS
+ and FRAME_LINES.
+ (adjust_frame_glyphs_for_window_redisplay): Rearrange lines.
+ (update_window): Start mode_line_row->y after horizontal scroll
+ bar.
+ (change_frame_size_1): Call adjust_frame_size.
+ (init_display): When changing the size of a tty frame do not
+ pass height of menu bar.
+ (Qframe_windows_min_size): New symbol.
+ * frame.h (struct frame): List tool bar fields after menu bar
+ fields. Add official, total_lines, horizontal_scroll_bars,
+ config_scroll_bar_height and config_scroll_bar_lines fields.
+ (FRAME_HAS_HORIZONTAL_SCROLL_BARS)
+ (FRAME_CONFIG_SCROLL_BAR_HEIGHT, FRAME_CONFIG_SCROLL_BAR_LINES)
+ (FRAME_SCROLL_BAR_AREA_HEIGHT, FRAME_SCROLL_BAR_COLS)
+ (FRAME_SCROLL_BAR_LINES, FRAME_TOTAL_LINES, SET_FRAME_LINES)
+ (FRAME_WINDOWS_HEIGHT): New macros.
+ (SET_FRAME_HEIGHT, FRAME_TEXT_LINES_TO_PIXEL_HEIGHT)
+ (FRAME_PIXEL_Y_TO_LINE, FRAME_PIXEL_HEIGHT_TO_TEXT_LINES)
+ (FRAME_TEXT_TO_PIXEL_HEIGHT): Separately count top margin and
+ horizontal scroll bar.
+ (frame_inhibit_resize, adjust_frame_size)
+ (frame_windows_min_size): Add declarations.
+ (Qscroll_bar_height, Qhorizontal_scroll_bars)
+ (x_set_scroll_bar_default_height, x_set_left_fringe)
+ (x_set_right_fringe, x_set_vertical_scroll_bars)
+ (x_set_horizontal_scroll_bars, x_set_scroll_bar_width)
+ (x_set_scroll_bar_height): Add external declarations.
+ * frame.c: (frame_inhibit_resize, frame_windows_min_size)
+ (adjust_frame_size): New functions.
- (make_frame): Initial horizontal_scroll_bars field. Use
- SET_FRAME_LINES. Don't allow horizontal scroll bar in
++ (make_frame): Initial horizontal_scroll_bars field.
++ Use SET_FRAME_LINES. Don't allow horizontal scroll bar in
+ minibuffer window.
+ (make_initial_frame, make_terminal_frame): No horizontal scroll
+ bar in initial and terminal frames. Use adjust_frame_size.
+ (Fframe_total_cols): Fix doc-string.
+ (Fframe_total_lines, Fscroll_bar_height): New Lisp functions.
- (Fset_frame_height, Fset_frame_width, Fset_frame_size): Rewrite
- using adjust_frame_size.
++ (Fset_frame_height, Fset_frame_width, Fset_frame_size):
++ Rewrite using adjust_frame_size.
+ (Qscroll_bar_height, Qhorizontal_scroll_bars)
+ (Qframe_windows_min_size): New symbols.
+ (x_set_frame_parameters): Remove call of check_frame_size.
+ (x_report_frame_params): Return scroll_bar_height value.
+ (x_set_left_fringe, x_set_right_fringe): New functions.
+ (adjust_frame_height, x_set_internal_border_width)
+ (x_set_fringe_width): Remove.
+ (x_set_internal_border_width, x_set_vertical_scroll_bars)
+ (x_set_scroll_bar_width, x_set_right_divider_width)
+ (x_set_bottom_divider_width): Rewrite using adjust_frame_size.
- (x_set_horizontal_scroll_bars, x_set_scroll_bar_height): New
- functions.
++ (x_set_horizontal_scroll_bars, x_set_scroll_bar_height):
++ New functions.
+ (x_figure_window_size): Rewrite to make frame display the
+ expected number of lines.
+ (Vdefault_frame_scroll_bars): Rewrite doc-string.
+ (Vdefault_frame_horizontal_scroll_bars)
+ (Vframe_initial_frame_tool_bar_height)
+ (frame_inhibit_implied_resize): New variables.
+ * fringe.c (compute_fringe_widths): Remove.
+ * gtkutil.h (YG_SB_MIN, YG_SB_MAX, YG_SB_RANGE): Define.
+ (xg_create_horizontal_scroll_bar)
+ (xg_update_horizontal_scrollbar_pos)
+ (xg_set_toolkit_horizontal_scroll_bar_thumb)
+ (xg_get_default_scrollbar_height)
+ (xg_clear_under_internal_border): Extern.
+ * gtkutil.c (xg_frame_resized): Don't call
+ do_pending_window_change.
+ (xg_frame_set_char_size): Use adjust_frame_size.
+ (style_changed_cb): Call update_theme_scrollbar_height and
+ x_set_scroll_bar_default_height.
+ (x_wm_set_size_hint): Don't call check_frame_size.
+ (update_theme_scrollbar_height)
+ (xg_get_default_scrollbar_height)
+ (xg_create_horizontal_scroll_bar)
+ (xg_update_horizontal_scrollbar_pos)
+ (xg_set_toolkit_horizontal_scroll_bar_thumb): New functions.
+ (xg_create_scroll_bar): Set horizontal slot of bar.
+ (xg_initialize): Call update_theme_scrollbar_height.
+ (xg_clear_under_internal_border): No more static.
+ * insdel.c (adjust_suspend_auto_hscroll): New function.
+ (adjust_markers_for_delete, adjust_markers_for_insert)
+ (adjust_markers_for_replace): Call adjust_suspend_auto_hscroll.
+ * keyboard.c (readable_events, discard_mouse_events)
+ (make_lispy_event): Handle horizontal scroll bar click events.
+ (Fsuspend_emacs): When changing the size of a tty frame do not
+ pass height of menu bar.
+ (Qbefore_handle, Qhorizontal_handle, Qafter_handle, Qleft)
+ (Qright, Qleftmost, Qrightmost): New symbols.
+ * menu.c (Fx_popup_dialog): Use FRAME_TOTAL_LINES instead of
+ FRAME_LINES.
+ * minibuf.c (read_minibuf): Initialize suspend_auto_hscroll.
+ * nsfns.m (x_set_internal_border_width): New function.
+ * nsterm.m (ns_draw_fringe_bitmap, ns_set_vertical_scroll_bar):
+ Remove extended fringe code.
+ (x_set_window_size, x_new_font): Don't call
+ compute_fringe_widths.
+ * term.c (Fresume_tty): When changing the size of a tty frame do
+ not pass height of menu bar.
- (clear_tty_hooks, set_tty_hooks): Clear
- horizontal_scroll_bar_hook.
++ (clear_tty_hooks, set_tty_hooks):
++ Clear horizontal_scroll_bar_hook.
+ (init_tty): Frame has no horizontal scroll bars.
+ * termhooks.h (enum scroll_bar_part): Add scroll_bar_move_ratio,
+ scroll_bar_before_handle, scroll_bar_horizontal_handle,
+ scroll_bar_after_handle, scroll_bar_left_arrow,
+ scroll_bar_right_arrow, scroll_bar_to_leftmost and
+ scroll_bar_to_rightmost entries.
+ (enum event_kind): Add HORIZONTAL_SCROLL_BAR_CLICK_EVENT
+ (struct terminal): Add set_horizontal_scroll_bar_hook.
- * w32console.c (initialize_w32_display): Clear
- horizontal_scroll_bar_hook.
++ * w32console.c (initialize_w32_display):
++ Clear horizontal_scroll_bar_hook.
+ * w32fns.c (x_set_mouse_color): Use FRAME_W32_DISPLAY instead of
+ FRAME_X_DISPLAY.
+ (x_clear_under_internal_border, x_set_internal_border_width):
+ New functions.
- (x_set_menu_bar_lines): Rewrite using frame_inhibit_resize. Set
- windows_or_buffers_changed when adding the menu bar.
++ (x_set_menu_bar_lines): Rewrite using frame_inhibit_resize.
++ Set windows_or_buffers_changed when adding the menu bar.
+ (x_set_tool_bar_lines): Rewrite using adjust_frame_size.
+ (x_change_tool_bar_height, x_set_scroll_bar_default_height)
+ (w32_createhscrollbar): New functions.
+ (w32_createscrollbar): Rename to w32_createvscrollbar.
+ (w32_createwindow): Init WND_HSCROLLBAR_INDEX.
+ (w32_name_of_message): Replace WM_EMACS_CREATESCROLLBAR by
- WM_EMACS_CREATEVSCROLLBAR and WM_EMACS_CREATEHSCROLLBAR. Add
- WM_EMACS_SHOWCURSOR.
++ WM_EMACS_CREATEVSCROLLBAR and WM_EMACS_CREATEHSCROLLBAR.
++ Add WM_EMACS_SHOWCURSOR.
+ (w32_wnd_proc): Handle WM_HSCROLL case. In WM_WINDOWPOSCHANGING
- case do not artificially impose WM size hints. Handle
- WM_EMACS_SHOWCURSOR case. Replace WM_EMACS_CREATESCROLLBAR case
++ case do not artificially impose WM size hints.
++ Handle WM_EMACS_SHOWCURSOR case. Replace WM_EMACS_CREATESCROLLBAR case
+ by WM_EMACS_CREATEVSCROLLBAR and WM_EMACS_CREATEHSCROLLBAR
+ cases.
+ (my_create_tip_window): Replace WND_SCROLLBAR_INDEX by
+ WND_VSCROLLBAR_INDEX and WND_HSCROLLBAR_INDEX.
+ (unwind_create_frame_1): Remove.
+ (Fx_create_frame): Make both scrollbars the system standard
+ width and height. Use official field of frame structure to
+ inhibit running window-configuration-change-hook.
+ (x_create_tip_frame): Call SET_FRAME_LINES and change_frame_size
+ pixelwise. Handle frame's official field.
+ (w32_frame_parm_handlers): Remove x_set_fringe_width
+ entries. Add x_set_scroll_bar_height,
+ x_set_horizontal_scroll_bars, x_set_left_fringe and
+ x_set_right_fringe.
+ * w32inevt.c (resize_event, maybe_generate_resize_event): Do not
+ pass height of menu bar to change_frame_size.
+ * w32menu.c (set_frame_menubar): Rewrite using
+ frame_inhibit_resize.
- * w32term.h (struct w32_display_info): Add
- horizontal_scroll_bar_cursor and cursor_display_counter.
++ * w32term.h (struct w32_display_info):
++ Add horizontal_scroll_bar_cursor and cursor_display_counter.
+ (struct scroll_bar): Add horizontal.
+ (HORIZONTAL_SCROLL_BAR_INSIDE_HEIGHT)
+ (HORIZONTAL_SCROLL_BAR_LEFT_RANGE)
+ (HORIZONTAL_SCROLL_BAR_INSIDE_WIDTH)
+ (HORIZONTAL_SCROLL_BAR_LEFT_BORDER)
+ (HORIZONTAL_SCROLL_BAR_RIGHT_BORDER)
+ (HORIZONTAL_SCROLL_BAR_TOP_BORDER)
+ (HORIZONTAL_SCROLL_BAR_BOTTOM_BORDER)
+ (HORIZONTAL_SCROLL_BAR_MIN_HANDLE): New macros.
- (WM_EMACS_CREATEVSCROLLBAR, WM_EMACS_CREATEHSCROLLBAR): Define
- instead of WM_EMACS_CREATESCROLLBAR.
++ (WM_EMACS_CREATEVSCROLLBAR, WM_EMACS_CREATEHSCROLLBAR):
++ Define instead of WM_EMACS_CREATESCROLLBAR.
+ (WND_VSCROLLBAR_INDEX, WND_HSCROLLBAR_INDEX): Define instead of
+ WND_SCROLLBAR_INDEX.
+ * w32term.c (horizontal_scroll_bar_min_handle)
+ (horizontal_scroll_bar_left_border)
+ (horizontal_scroll_bar_right_border): New integers.
+ (x_set_frame_alpha): Replace x_highlight_frame by
+ w32_focus_frame.
+ (x_window_to_scroll_bar): New argument "type". Update callers
+ accordingly.
+ (w32_set_horizontal_scroll_bar_thumb)
+ (x_horizontal_scroll_bar_report_motion)
+ (w32_set_horizontal_scroll_bar)
+ (w32_horizontal_scroll_bar_handle_click)
+ (x_horizontal_scroll_bar_report_motion): New functions.
+ (w32_mouse_position): Discriminate horizontal and vertical
+ scrollbar cases.
+ (my_create_scrollbar): Replace with two new functions
+ my_create_vscrollbar and my_create_hscrollbar.
- (x_scroll_bar_create): New argument "horizontal". Update
- callers accordingly.
++ (x_scroll_bar_create): New argument "horizontal".
++ Update callers accordingly.
+ (x_scroll_bar_remove, w32_condemn_scroll_bars)
+ (w32_redeem_scroll_bar, x_scroll_bar_clear): Handle horizontal
+ scroll bar case.
+ (w32_read_socket): Handle WM_HSCROLL cae.
- (x_new_font): Don't recompute fringe widths. Use
- frame_inhibit_resize. Calculate new menu bar height iff we
++ (x_new_font): Don't recompute fringe widths.
++ Use frame_inhibit_resize. Calculate new menu bar height iff we
+ build without toolkit. Always clear under internal border.
+ (x_set_window_size): Don't check frame size or recompute
- fringes. Reset fullscreen status before applying sizes. Always
- resize as requested by pixelwise argument. Don't call
++ fringes. Reset fullscreen status before applying sizes.
++ Always resize as requested by pixelwise argument. Don't call
+ do_pending_window_change.
+ (x_wm_set_size_hint): Add call for FRAME_SCROLL_BAR_AREA_HEIGHT.
+ (w32_initialize_display_info): Initialize dpyinfo's
+ horizontal_scroll_bar_cursor entry.
+ (w32_create_terminal): Add set_horizontal_scroll_bar_hook.
+ (w32_initialize): Init horizontal_scroll_bar_min_handle and
+ horizontal_scroll_bar_left_border.
+ (w32fullscreen_hook): Intermittently resize window to normal
+ when switching from fullscreen to maximized state.
+ (run_window_configuration_change_hook): Don't run it if frame is
+ not official yet.
+ (unwind_change_frame): Remove.
+ (Fset_window_configuration): Rewrite using frame's official field.
+ * widget.c (set_frame_size): Don't call compute_fringe_widths.
+ (EmacsFrameSetCharSize): Obey frame_inhibit_resize.
+ * window.h (struct window): New fields old_pointm,
+ horizontal_scroll_bar, horizontal_scroll_bar_type, hscroll_whole,
+ scroll_bar_height and suspend_auto_hscroll.
+ (wset_horizontal_scroll_bar, wset_horizontal_scroll_bar_type):
+ New functions.
+ (sanitize_window_sizes): Extern.
+ (MINI_NON_ONLY_WINDOW_P, MINI_ONLY_WINDOW_P, WINDOW_PSEUDO_P)
+ (WINDOW_TOPMOST_P, WINDOW_HAS_HORIZONTAL_SCROLL_BAR)
+ (WINDOW_CONFIG_SCROLL_BAR_HEIGHT)
+ (WINDOW_CONFIG_SCROLL_BAR_LINES)
- (WINDOW_SCROLL_BAR_LINES, WINDOW_SCROLL_BAR_AREA_HEIGHT): New
- macros.
++ (WINDOW_SCROLL_BAR_LINES, WINDOW_SCROLL_BAR_AREA_HEIGHT):
++ New macros.
+ (WINDOW_LEFT_FRINGE_COLS, WINDOW_RIGHT_FRINGE_COLS)
+ (WINDOW_FRINGE_COLS, WINDOW_FRINGE_EXTENDED_P): Remove macros.
+ (WINDOW_VERTICAL_SCROLL_BAR_TYPE)
+ (WINDOW_HAS_VERTICAL_SCROLL_BAR_ON_LEFT)
+ (WINDOW_HAS_VERTICAL_SCROLL_BAR_ON_RIGHT)
+ (WINDOW_HAS_VERTICAL_SCROLL_BAR): Minor rewrite.
+ (WINDOW_BOX_HEIGHT_NO_MODE_LINE, WINDOW_BOX_TEXT_HEIGHT)
+ (WINDOW_SCROLL_BAR_AREA_Y): Count in scroll bar height.
+ * window.c (wset_old_pointm, Fwindow_scroll_bar_height)
+ (Fwindow_old_point, sanitize_window_sizes): New functions.
+ (Qwindow_sanitize_window_sizes): New symbol.
+ (window_body_height): Count in horizontal scroll bar.
- (set_window_hscroll, Fscroll_left, Fscroll_right): Set
- suspend_auto_hscroll slot.
++ (set_window_hscroll, Fscroll_left, Fscroll_right):
++ Set suspend_auto_hscroll slot.
+ (Fwindow_inside_edges): Count fringes pixelwise.
- (coordinates_in_window, Fcoordinates_in_window_p): Consider
- horizontal scroll bar.
++ (coordinates_in_window, Fcoordinates_in_window_p):
++ Consider horizontal scroll bar.
+ (check_frame_size, adjust_window_margins): Remove functions and
+ corresponding calls.
+ (set_window_buffer): Initialize old_pointm and horizontal scroll
+ bars.
+ (temp_output_buffer_show): Reset hscroll related fields.
+ Initialize old_pointm.
+ (make_parent_window): Initialize old_pointm.
+ (make_window): Initialize old_pointm, horizontal scroll bar type,
+ and scroll bar height.
+ (resize_frame_windows): Don't count top margin in new sizes.
+ Don't use safe sizes when shrinking a frame; let the window
+ manager do the clipping.
+ (Fsplit_window_internal): Inherit horizontal scroll bar type and
+ height.
+ (Fdelete_window_internal): Unchain old_pointm marker.
- (window_scroll_pixel_based, Fscroll_other_window): Adjust
- old_pointm.
++ (window_scroll_pixel_based, Fscroll_other_window):
++ Adjust old_pointm.
+ (Fwindow_text_width, Fwindow_text_height): New argument
+ "pixelwise".
+ (struct saved_window): New fields, old_pointm, hscroll_whole,
+ suspend_auto_hscroll, scroll_bar_height and
+ horizontal_scroll_bar_type.
+ (Fset_window_configuration, save_window_save): Set new fields of
+ saved_window.
+ (apply_window_adjustment): Don't call adjust_window_margins.
+ (set_window_margins): Don't change margins if new sizes don't
+ fit into window.
+ (set_window_scroll_bars): New argument "horizontal_type".
+ Handle horizontal scroll bars. Don't change scroll bars if they
+ don't fit into window.
+ (Fset_window_scroll_bars): New argument "horizontal_type".
+ (Fwindow_scroll_bars): Return values for horizontal scroll bars.
+ (compare_window_configurations): Compare horizontal scroll bar
+ settings.
+ * xdisp.c (window_text_bottom_y, window_box_height): Count in
+ horizontal scroll bar height.
+ (pixel_to_glyph_coords, init_xdisp): Use FRAME_TOTAL_LINES
+ instead of FRAME_LINES.
+ (remember_mouse_glyph): Case ON_SCROLL_BAR changed to
+ ON_VERTICAL_SCROLL_BAR.
+ (with_echo_area_buffer): Initialize old_pointm.
+ (with_echo_area_buffer_unwind_data): Store old_pointm values in
+ vector.
+ (unwind_with_echo_area_buffer): Handle old_pointm.
+ (update_tool_bar): Set do_update when the tool bar window has at
+ least one line (since this is what the user sets).
+ (MAX_FRAME_TOOL_BAR_HEIGHT): Remove macro.
+ (redisplay_tool_bar): Return early when toolbar has zero lines.
+ Call x_change_tool_bar_height. Don't use max_tool_bar_height.
+ (hscroll_window_tree): Handle suspension of auto_hscroll and
+ old_pointm.
+ (set_horizontal_scroll_bar): New function.
+ (redisplay_window): Set ignore_mouse_drag_p when tool bar has
+ more than one line. Handle horizontal scroll bars.
+ (note_mouse_highlight): Handle horizontal scrol bars.
+ (expose_frame): Set dimensions of XRectangle from frame's text
+ sizes.
+ (Vvoid_text_area_pointer): Update doc-string.
+ * xfns.c (x_set_menu_bar_lines): Use adjust_frame_size.
+ (x_change_tool_bar_height, x_set_scroll_bar_default_height)
+ (x_set_internal_border_width): New functions.
+ (x_set_tool_bar_lines): Call x_change_tool_bar_height.
+ (unwind_create_frame_1): Remove.
+ (Fx_create_frame): Handle horizontal scroll bars. Use official
+ field of frame structure to inhibit running
+ window-configuration-change-hook.
+ (x_create_tip_frame): Call SET_FRAME_LINES and change_frame_size
+ pixelwise. Handle frame's official field.
+ (x_frame_parm_handlers): Add x_set_scroll_bar_height,
+ x_set_horizontal_scroll_bars, x_set_left_fringe,
+ x_set_right_fringe.
- * xmenu.c (update_frame_menubar, free_frame_menubar): Use
- adjust_frame_size.
- * xterm.h (struct x_display_info): Add
- horizontal_scroll_bar_cursor and Xatom_Horizontal_Scrollbar
++ * xmenu.c (update_frame_menubar, free_frame_menubar):
++ Use adjust_frame_size.
++ * xterm.h (struct x_display_info):
++ Add horizontal_scroll_bar_cursor and Xatom_Horizontal_Scrollbar
+ slots.
+ (struct scroll_bar): Add horizontal slot.
+ (HORIZONTAL_SCROLL_BAR_INSIDE_HEIGHT)
+ (HORIZONTAL_SCROLL_BAR_LEFT_RANGE)
+ (HORIZONTAL_SCROLL_BAR_INSIDE_WIDTH): New macros.
+ (HORIZONTAL_SCROLL_BAR_LEFT_BORDER)
+ (HORIZONTAL_SCROLL_BAR_RIGHT_BORDER)
+ (HORIZONTAL_SCROLL_BAR_TOP_BORDER)
+ (HORIZONTAL_SCROLL_BAR_BOTTOM_BORDER)
+ (HORIZONTAL_SCROLL_BAR_MIN_HANDLE): Define.
+ (x_clear_under_internal_border): Remove.
+ * xterm.c (XTmouse_position): Handle horizontal scroll bars.
+ (x_window_to_scroll_bar): New argument TYPE. Update callers.
+ (x_send_scroll_bar_event, x_scroll_bar_create): New arguments
+ HORIZONTAL. Update callers.
+ (horizontal_action_hook_id): New action hook id.
+ (x_horizontal_scroll_bar_to_input_event)
+ (x_create_horizontal_toolkit_scroll_bar)
+ (xt_horizontal_action_hook)
+ (x_set_toolkit_horizontal_scroll_bar_thumb)
+ (XTset_horizontal_scroll_bar, x_net_wm_state)
+ (x_horizontal_scroll_bar_report_motion): New functions.
- (xg_scroll_callback, x_scroll_bar_handle_click): Handle
- horizontal scroll bars.
++ (xg_scroll_callback, x_scroll_bar_handle_click):
++ Handle horizontal scroll bars.
+ (SCROLL_BAR_HORIZONTAL_NAME): Define.
+ (XTset_vertical_scroll_bar): Attempt to clear areas not covered
+ by scroll bar.
- (XTcondemn_scroll_bars, XTredeem_scroll_bar): Rewrite. Handle
- horizontal scroll bars.
- (handle_one_xevent): Handle horizontal scroll bar events. Call
- x_net_wm_state.
++ (XTcondemn_scroll_bars, XTredeem_scroll_bar): Rewrite.
++ Handle horizontal scroll bars.
++ (handle_one_xevent): Handle horizontal scroll bar events.
++ Call x_net_wm_state.
+ (x_set_window_size_1, x_wm_set_size_hint): Don't call
+ check_frame_size.
+ (x_set_window_size): Don't call check_frame_size and
+ do_pending_window_change.
+ (x_term_init): Init horizontal_scroll_bar_cursor display info.
+ (x_create_terminal): Add set_horizontal_scroll_bar_hook.
+ (x_scroll_bar_set_handle): Add some checks when calling
+ x_clear_area.
+
+2014-07-26 Paul Eggert <eggert@cs.ucla.edu>
+
+ Revert previous change.
+ There is certainly nothing wrong with writing code like 'lo <= i
+ && i <= hi', even if LO happens to a constant. There isn't even
+ anything wrong in general with writing 'a <= b' if A happens to
+ be a constant. At any rate stylistic changes shouldn't
+ be done like this without discussion.
+
+2014-07-26 Andreas Schwab <schwab@linux-m68k.org>
+
+ * alloc.c (xnmalloc, xnrealloc, xpalloc, make_save_value)
+ (Fgarbage_collect): Reorder conditions that are written backwards.
+ * data.c (cons_to_unsigned): Likewise.
+ * dispnew.c (update_frame_1, sit_for): Likewise.
+ * fileio.c (file_offset): Likewise.
+ * filelock.c (read_lock_data, lock_file): Likewise.
+ * fns.c (larger_vector, make_hash_table, Fmake_hash_table):
+ Likewise.
+ * font.c (font_intern_prop, font_style_symbolic): Likewise.
+ * lisp.h (FIXNUM_OVERFLOW_P): Likewise.
+ * lread.c (read1): Likewise.
+ * minibuf.c (read_minibuf_noninteractive): Likewise.
+ * nsterm.m (x_set_frame_alpha): Likewise.
+ * process.c (wait_reading_process_output): Likewise.
+ * region-cache.c (delete_cache_boundaries): Likewise.
+ * xterm.c (x_set_frame_alpha): Likewise.
+
+2014-07-25 Paul Eggert <eggert@cs.ucla.edu>
+
+ * dispextern.h, xdisp.c (hourglass_shown_p, hourglass_atimer):
+ Now static.
+
+2014-07-26 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * atimer.c (set_alarm) [HAVE_ITIMERSPEC]: Use TIMER_ABSTIME
+ because atimer expiration is absolute rather than relative.
+
+2014-07-25 Eli Zaretskii <eliz@gnu.org>
+
- * w32term.h (current_popup_menu, menubar_in_use): Move
- declarations from w32term.c.
++ * w32term.h (current_popup_menu, menubar_in_use):
++ Move declarations from w32term.c.
+
+2014-07-25 Martin Rudalics <rudalics@gmx.at>
+
+ * w32fns.c (menubar_in_use): No more static.
+ * w32term.c (current_popup_menu, menubar_in_use): Declare.
+
+2014-07-25 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Move hourglass machinery to RIF.
+ * dispextern.h (struct redisplay_interface): New members
+ show_hourglass and hide_hourglass. Indent comments.
+ (show_hourglass, hide_hourglass): Remove prototypes.
+ * nsterm.m (show_hourgass, hide_hourglass): Refactor to ...
+ (ns_show_hourglass, ns_hide_hourglass): ... new no-ops.
+ (ns_redisplay_interface): Add them.
+ * w32fns.c (show_hourglass, hide_hourglass): Refactor to ...
+ * w32term.c (w32_show_hourglass, w32_hide_hourglass): ... these.
+ (w32_arrow_cursor): New function to hack around non-GUI frames.
+ (w32_redisplay_interface): Add new functions.
+ * w32term.h (w32_arror_cursor): Add prototype.
+ * xdisp.c (show_hourglass): New function, refactored out from
+ platform-dependent code.
+ (cancel_hourglass): Now call to RIF function.
+ * xfns.c (show_hourglass, hide_hourglass): Refactor to ...
+ * xterm.c (x_show_hourglass, x_hide_hourglass): ... these.
+ (x_redisplay_interface): Add new functions.
+
+2014-07-24 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Fix error reported by Angelo Graziosi <angelo.graziosi@alice.it> in
+ <http://lists.gnu.org/archive/html/emacs-devel/2014-07/msg00274.html>
+ and complete previous change.
+ * frame.c (adjust_frame_height): New function.
+ (Fset_frame_height, Fset_frame_size): Use it.
+ (x_set_frame_parameters): Take frame top margin into account.
+
+2014-07-23 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * frame.c (Fset_frame_height): Take frame top margin into account.
+ Incorrect behavior was reported by Martin Rudalics <rudalics@gmx.at> in
+ <http://lists.gnu.org/archive/html/emacs-devel/2014-07/msg00258.html>
+
+2014-07-22 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * xterm.h (struct x_output) [USE_X_TOOLKIT || USE_GTK]: Define
+ menubar_height as such. Tweak comment.
+ [USE_LUCID && USE_TOOLKIT_SCROLL_BARS]: Likewise for
+ scroll_bar_top_shadow_pixel and scroll_bar_bottom_shadow_pixel.
+ All related users changed.
+ (FRAME_MENUBAR_HEIGHT) [!USE_X_TOOLKIT && !USE_GTK]: No-op.
+ * xterm.c (handle_one_xevent):
+ * gtkutil.c (xg_event_is_for_menubar):
+ * xfns.c (x_window) [USE_X_TOOLKIT]:
- * xmenu.c (set_frame_menubar, free_frame_menubar): Prefer
- to use FRAME_MENUBAR_HEIGHT.
++ * xmenu.c (set_frame_menubar, free_frame_menubar):
++ Prefer to use FRAME_MENUBAR_HEIGHT.
+
+2014-07-21 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * frame.c (Fframe_parameters): Always report frame height without
+ menu and tool bar lines.
+
+2014-07-21 Jan Djärv <jan.h.d@swipnet.se>
* nsterm.m (applicationDidFinishLaunching:): Call
antialiasThresholdDidChange, register for antialias changes (Bug#17534).
* macfont.h (macfont_update_antialias_threshold): Declare.
-2014-07-17 Eli Zaretskii <eliz@gnu.org>
+2014-07-21 Eli Zaretskii <eliz@gnu.org>
-- * w32select.c (setup_windows_coding_system): Apply
-- CODING_ANNOTATION_MASK to the common_flags member of struct
++ * w32select.c (setup_windows_coding_system):
++ Apply CODING_ANNOTATION_MASK to the common_flags member of struct
coding_system. Reported by martin rudalics <rudalics@gmx.at>.
-- * w16select.c (Fw16_get_clipboard_data): Apply
-- CODING_ANNOTATION_MASK to the common_flags member of struct
++ * w16select.c (Fw16_get_clipboard_data):
++ Apply CODING_ANNOTATION_MASK to the common_flags member of struct
coding_system.
* xdisp.c (init_iterator): Initialize it->stop_charpos to the
(handle_invisible_prop): Record in it->stop_charpos the position
where the invisible text ends. (Bug#18035)
(hscroll_window_tree): Don't try hscrolling windows whose cursor
-- row has zero buffer position as their start position. Reported by
-- martin rudalics <rudalics@gmx.at>.
-
-2014-07-16 Eli Zaretskii <eliz@gnu.org>
++ row has zero buffer position as their start position.
++ Reported by martin rudalics <rudalics@gmx.at>.
* xdisp.c (move_it_vertically_backward, move_it_by_lines): Prevent
infinite looping in redisplay when display lines don't have enough
are in sync with what the window wants.
(Bug#17892)
-- * xdisp.c (display_line, display_mode_line): Call
-- prepare_desired_row with additional arguments, as appropriate.
++ * xdisp.c (display_line, display_mode_line):
++ Call prepare_desired_row with additional arguments, as appropriate.
* dispextern.h (prepare_desired_row): Adjust prototype.
* coding.c (encode_coding_utf_8): Correctly count produced_chars
also in unibyte case. (Bug#17865)
-2014-06-25 Glenn Morris <rgm@gnu.org>
-
- * puresize.h (BASE_PURESIZE): Increase a bit. (Bug#17846)
+2014-06-28 K. Handa <handa@gnu.org>
+
- * coding.c (MAX_CHARBUF_SIZE): Renamed from CHARBUF_SIZE.
++ * coding.c (MAX_CHARBUF_SIZE): Rename from CHARBUF_SIZE.
+ (MIN_CHARBUF_SIZE): New macro.
+ (ALLOC_CONVERSION_WORK_AREA): New arg SIZE. Callers changed.
+
+2014-06-27 Glenn Morris <rgm@gnu.org>
+
+ * Makefile.in: Replace BOOTSTRAPEMACS sleight-of-hand
+ with an order-only dependence on bootstrap-emacs. (Bug#2151)
+ (.el.elc): Replace suffix rule with pattern rule.
+ (%.elc): New pattern rule, with order-only prerequisite.
+ ($(lisp)): No more need to depend on BOOTSTRAPEMACS.
+ ($(lispsource)/loaddefs.el): Use an order-only prerequisite
+ in place of BOOTSTRAPEMACS.
+
+2014-06-26 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * fns.c (Fcompare_strings): Use FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE.
+
+2014-06-25 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Consistently use validate_subarray to verify substring.
+ * fns.c (validate_substring): Not static any more. Adjust to
+ use ptrdiff_t, not EMACS_INT, because string and vector limits
+ can't exceed ptrdiff_t even if EMACS_INT is wider.
+ (Fcompare_strings, Fsubstring, Fsubstring_no_properties)
+ (secure_hash): Adjust user.
+ * lisp.h (validate_subarray): Add prototype.
+ * coding.c (Fundecodable_char_position):
+ * composite.c (Fcomposition_get_gstring, Fcompose_string_internal):
+ Use validate_subarray. Adjust comment to mention substring.
+
+2014-06-25 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Do not allow out-of-range character position in Fcompare_strings.
+ * fns.c (validate_subarray): Add prototype.
+ (Fcompare_substring): Use validate_subarray to check ranges.
+ Adjust comment to mention that the semantics was changed. Also see
+ http://lists.gnu.org/archive/html/emacs-devel/2014-06/msg00447.html.
+
+2014-06-24 Paul Eggert <eggert@cs.ucla.edu>
+
+ Be more consistent about the 'Qfoo' naming convention.
+ * image.c (Fimagemagick_types):
+ * lisp.h (lisp_h_CHECK_TYPE, CHECK_TYPE, CHECK_ARRAY):
+ * process.c (Fmake_network_process):
+ Rename C local identifier 'Qfoo to avoid giving the false
+ impression that it stands for the symbol 'foo'.
+
+2014-06-23 Dmitry Antipov <dmantipov@yandex.ru>
+
+ Simplify and cleanup character conversion stuff.
+ * lisp.h (multibyte_char_to_unibyte, multibyte_char_to_unibyte_safe):
+ Remove prototypes.
+ * character.c (multibyte_char_to_unibyte)
+ (multibyte_char_to_unibyte_safe): Remove; no longer used.
+ * character.h (make_char): Remove; unused.
+ (CHAR_TO_BYTE8, CHAR_TO_BYTE_SAFE): Simplify.
+ (ASCII_BYTE_P): Remove; ASCII_CHAR_P does the same thing.
+ * buffer.c, charset.c, charset.h, cmds.c, coding.c, editfns.c:
+ * fileio.c, indent.c, insdel.c, keyboard.c, lread.c, print.c:
+ * search.c, term.c, xdisp.c, xterm.c: Related users changed.
+
+2014-06-22 Mario Lang <mlang@delysid.org>
+
+ * w32fns.c (Fw32_shell_execute): The the -> the.
+
+2014-06-22 Dmitry Antipov <dmantipov@yandex.ru>
+
+ * xmenu.c (mouse_position_for_popup):
+ * xselect.c (mouse_position_for_drop): Do not duplicate ...
+ * xfns.c (x_relative_mouse_position): ... and prefer this function.
+ * menu.c (Fx_popup_menu):
+ * xselect.c (x_handle_dnd_message): Adjust users.
+ * menu.h (mouse_position_for_popup): Remove prototype.
+ * xterm.h (x_relative_mouse_position): Add prototype.
+ * xterm.c (x_find_topmost_parent): Break from the loop and do not
+ call XFree if XQueryTree returns zero.
2014-06-21 Eli Zaretskii <eliz@gnu.org>