| 1 | 2011-07-11 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 2 | |
| 3 | * term.c (init_tty): Remove support for supdup, c10 and perq |
| 4 | terminals, which are no longer supported (bug#1482). |
| 5 | |
| 6 | 2011-07-10 Johan Bockgård <bojohan@gnu.org> |
| 7 | |
| 8 | * xdisp.c (Ftool_bar_lines_needed): Fix WINDOWP check. |
| 9 | |
| 10 | 2011-07-10 Jan Djärv <jan.h.d@swipnet.se> |
| 11 | |
| 12 | * xmenu.c (menu_highlight_callback): Only pass frame to show_help_event |
| 13 | for non-popups (Bug#3642). |
| 14 | |
| 15 | 2011-07-10 Andreas Schwab <schwab@linux-m68k.org> |
| 16 | |
| 17 | * alloc.c (reset_malloc_hooks): Protoize. |
| 18 | * buffer.c (mmap_init, mmap_find, mmap_free_1, mmap_enlarge) |
| 19 | (mmap_set_vars, mmap_alloc, mmap_free, mmap_realloc): Likewise. |
| 20 | * cm.c (losecursor): Likewise. |
| 21 | * data.c (fmod): Likewise. |
| 22 | * dispnew.c (swap_glyphs_in_rows): Likewise. |
| 23 | * emacs.c (memory_warning_signal): Likewise. |
| 24 | * floatfns.c (float_error): Likewise. |
| 25 | * font.c (check_gstring, check_otf_features, otf_tag_symbol) |
| 26 | (otf_open, font_otf_capability, generate_otf_features) |
| 27 | (font_otf_DeviceTable, font_otf_ValueRecord, font_otf_Anchor): |
| 28 | Likewise. |
| 29 | * image.c (pbm_read_file): Likewise. |
| 30 | * indent.c (string_display_width): Likewise. |
| 31 | * intervals.c (check_for_interval, search_for_interval) |
| 32 | (inc_interval_count, count_intervals, root_interval) |
| 33 | (adjust_intervals_for_insertion, make_new_interval): Likewise. |
| 34 | * lread.c (defalias): Likewise. |
| 35 | * ralloc.c (r_alloc_check): Likewise. |
| 36 | * regex.c (set_image_of_range_1, set_image_of_range) |
| 37 | (regex_grow_registers): Likewise. |
| 38 | * sysdep.c (strerror): Likewise. |
| 39 | * termcap.c (valid_filename_p, tprint, main): Likewise. |
| 40 | * tparam.c (main): Likewise. |
| 41 | * unexhp9k800.c (run_time_remap, save_data_space) |
| 42 | (update_file_ptrs, read_header, write_header, calculate_checksum) |
| 43 | (copy_file, copy_rest, display_header): Likewise. |
| 44 | * widget.c (mark_shell_size_user_specified, create_frame_gcs): |
| 45 | Likewise. |
| 46 | * xdisp.c (check_it): Likewise. |
| 47 | * xfaces.c (register_color, unregister_color, unregister_colors): |
| 48 | Likewise. |
| 49 | * xfns.c (print_fontset_result): Likewise. |
| 50 | * xrdb.c (member, fatal, main): Likewise. |
| 51 | |
| 52 | 2011-07-10 Paul Eggert <eggert@cs.ucla.edu> |
| 53 | |
| 54 | Fix minor problems found by static checking (Bug#9031). |
| 55 | * chartab.c (char_table_set_range, map_sub_char_table): |
| 56 | Remove unused locals. |
| 57 | (uniprop_table): Now static. |
| 58 | * composite.c (_work_char): Remove unused static var. |
| 59 | |
| 60 | 2011-07-09 Juanma Barranquero <lekktu@gmail.com> |
| 61 | |
| 62 | * chartab.c (uniprop_table_uncompress): Remove unused local variable. |
| 63 | |
| 64 | 2011-07-09 Jan Djärv <jan.h.d@swipnet.se> |
| 65 | |
| 66 | * gtkutil.c (qttip_cb): Remove code without function. |
| 67 | |
| 68 | 2011-07-09 Eli Zaretskii <eliz@gnu.org> |
| 69 | |
| 70 | * w32.c (pthread_sigmask): New stub. |
| 71 | |
| 72 | 2011-07-08 Paul Eggert <eggert@cs.ucla.edu> |
| 73 | |
| 74 | Use pthread_sigmask, not sigprocmask (Bug#9010). |
| 75 | sigprocmask is portable only for single-threaded applications, and |
| 76 | Emacs can be multi-threaded when it uses GTK. |
| 77 | * Makefile.in (LIB_PTHREAD_SIGMASK): New macro. |
| 78 | (LIBES): Use it. |
| 79 | * callproc.c (Fcall_process): |
| 80 | * process.c (create_process): |
| 81 | * sysdep.c (sys_sigblock, sys_sigunblock, sys_sigsetmask): |
| 82 | Use pthread_sigmask, not sigprocmask. |
| 83 | |
| 84 | 2011-07-08 Jan Djärv <jan.h.d@swipnet.se> |
| 85 | |
| 86 | * gtkutil.c (qttip_cb): Set line wrap to FALSE for tooltip widget. |
| 87 | (xg_prepare_tooltip): Revert text in x->ttip_lbl, margins was |
| 88 | wrong (Bug#8591). |
| 89 | |
| 90 | 2011-07-08 Jan Djärv <jan.h.d@swipnet.se> |
| 91 | |
| 92 | * gtkutil.c (xg_prepare_tooltip): Fix indentation and comment. |
| 93 | Put text in x->ttip_lbl instead of gtk_tooltip_set_text (Bug#8591). |
| 94 | (xg_hide_tooltip): Fix comment. |
| 95 | |
| 96 | * nsterm.m (initFrameFromEmacs): Don't use ns_return_types |
| 97 | in registerServicesMenuSendTypes. |
| 98 | (validRequestorForSendType): Don't check ns_return_types. |
| 99 | |
| 100 | * nsfns.m (Fx_open_connection): Put NSStringPboardType into |
| 101 | ns_return_type. |
| 102 | |
| 103 | 2011-07-08 Jason Rumney <jasonr@gnu.org> |
| 104 | |
| 105 | * w32fns.c (w32_wnd_proc) [WM_TIMER, WM_SET_CURSOR]: Avoid using |
| 106 | frame struct members of non-existent frames (Bug#6284). |
| 107 | |
| 108 | 2011-07-08 Jan Djärv <jan.h.d@swipnet.se> |
| 109 | |
| 110 | * nsterm.m (keyDown): Call to wantsToDelayTextChangeNotifications and |
| 111 | variable firstTime not needed on OSX >= 10.6. |
| 112 | (setPosition): setFloatValue:knobProportion: is deprecated on OSX |
| 113 | >= 10.5. Use setKnobProportion, setDoubleValue. |
| 114 | |
| 115 | * nsterm.h (MAC_OS_X_VERSION_10_3, MAC_OS_X_VERSION_10_4) |
| 116 | (MAC_OS_X_VERSION_10_5): Define if not defined. |
| 117 | (EmacsView, EmacsTooltip): Implements NSWindowDelegate on OSX >= 10.6. |
| 118 | (EmacsMenu): Implements NSMenuDelegate on OSX >= 10.6. |
| 119 | (EmacsToolbar): Implements NSToolbarDelegate on OSX >= 10.6. |
| 120 | |
| 121 | * nsselect.m (ns_string_from_pasteboard): Don't use deprecated methods |
| 122 | cString and lossyCString on OSX >= 10.4 |
| 123 | |
| 124 | * nsmenu.m (fillWithWidgetValue): Don't use depercated method |
| 125 | sizeToFit on OSX >= 10.2. |
| 126 | |
| 127 | * nsimage.m (allocInitFromFile): Don't use deprecated method |
| 128 | bestRepresentationForDevice on OSX >= 10.6. |
| 129 | |
| 130 | * nsfns.m (check_ns_display_info): Cast to long and use %ld in error |
| 131 | to avoid warning. |
| 132 | |
| 133 | * emacs.c: Declare unexec_init_emacs_zone. |
| 134 | |
| 135 | * nsgui.h: Fix compiler warning about gnulib redefining verify. |
| 136 | |
| 137 | * nsselect.m (ns_get_local_selection): Change to extern (Bug#8842). |
| 138 | |
| 139 | * nsmenu.m (ns_update_menubar): Remove useless setDelegate call |
| 140 | on svcsMenu (Bug#8842). |
| 141 | |
| 142 | * nsfns.m (Fx_open_connection): Remove NSStringPboardType from |
| 143 | ns_return_types. |
| 144 | (Fns_list_services): Just return Qnil on 10.6, code not working there. |
| 145 | |
| 146 | * nsterm.m (QUTF8_STRING): Declare. |
| 147 | (initFrameFromEmacs): Call registerServicesMenuSendTypes. |
| 148 | (validRequestorForSendType): Return type is (id). |
| 149 | Change indexOfObjectIdenticalTo to indexOfObject. |
| 150 | Check if we have local selection before returning self (Bug#8842). |
| 151 | (writeSelectionToPasteboard): Put local selection into paste board |
| 152 | if we have a local selection (Bug#8842). |
| 153 | (syms_of_nsterm): DEFSYM QUTF8_STRING. |
| 154 | |
| 155 | * nsterm.h (MAC_OS_X_VERSION_10_6): Define here instead of nsterm.m. |
| 156 | (ns_get_local_selection): Declare. |
| 157 | |
| 158 | 2011-07-07 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 159 | |
| 160 | * keymap.c (describe_map_tree): Don't insert a double newline at |
| 161 | the end of the buffer (bug#1169) and return whether we inserted |
| 162 | something. |
| 163 | |
| 164 | * callint.c (Fcall_interactively): Change "reading args" to |
| 165 | "providing args" to try to clarify what it does (bug#1010). |
| 166 | |
| 167 | 2011-07-07 Kenichi Handa <handa@m17n.org> |
| 168 | |
| 169 | * composite.c (composition_compute_stop_pos): Ignore a static |
| 170 | composition starting before CHARPOS (Bug#8915). |
| 171 | |
| 172 | * xdisp.c (handle_composition_prop): Likewise. |
| 173 | |
| 174 | 2011-07-07 Eli Zaretskii <eliz@gnu.org> |
| 175 | |
| 176 | * term.c (produce_glyphs) <xassert>: Allow IT_GLYPHLESS in it->what. |
| 177 | (Bug#9015) |
| 178 | |
| 179 | 2011-07-07 Kenichi Handa <handa@m17n.org> |
| 180 | |
| 181 | * character.h (unicode_category_t): New enum type. |
| 182 | |
| 183 | * chartab.c (uniprop_decoder_t, uniprop_encoder_t): New types. |
| 184 | (Qchar_code_property_table): New variable. |
| 185 | (UNIPROP_TABLE_P, UNIPROP_GET_DECODER) |
| 186 | (UNIPROP_COMPRESSED_FORM_P): New macros. |
| 187 | (char_table_ascii): Uncompress the compressed values. |
| 188 | (sub_char_table_ref): New arg is_uniprop. Callers changed. |
| 189 | Uncompress the compressed values. |
| 190 | (sub_char_table_ref_and_range): Likewise. |
| 191 | (char_table_ref_and_range): Uncompress the compressed values. |
| 192 | (sub_char_table_set): New arg is_uniprop. Callers changed. |
| 193 | Uncompress the compressed values. |
| 194 | (sub_char_table_set_range): Args changed. Callers changed. |
| 195 | (char_table_set_range): Adjuted for the above change. |
| 196 | (map_sub_char_table): Delete args default_val and parent. Add arg |
| 197 | top. Give decoded values to a Lisp function. |
| 198 | (map_char_table): Adjusted for the above change. Give decoded |
| 199 | values to a Lisp function. Gcpro more variables. |
| 200 | (uniprop_table_uncompress) |
| 201 | (uniprop_decode_value_run_length): New functions. |
| 202 | (uniprop_decoder, uniprop_decoder_count): New variables. |
| 203 | (uniprop_get_decoder, uniprop_encode_value_character) |
| 204 | (uniprop_encode_value_run_length, uniprop_encode_value_numeric): |
| 205 | New functions. |
| 206 | (uniprop_encoder, uniprop_encoder_count): New variables. |
| 207 | (uniprop_get_encoder, uniprop_table) |
| 208 | (Funicode_property_table_internal, Fget_unicode_property_internal) |
| 209 | (Fput_unicode_property_internal): New functions. |
| 210 | (syms_of_chartab): DEFSYM Qchar_code_property_table, defsubr |
| 211 | Sunicode_property_table_internal, Sget_unicode_property_internal, |
| 212 | and Sput_unicode_property_internal. Defvar_lisp |
| 213 | char-code-property-alist. |
| 214 | |
| 215 | * composite.c (CHAR_COMPOSABLE_P): Adjusted for the change of |
| 216 | Vunicode_category_table. |
| 217 | |
| 218 | * font.c (font_range): Adjusted for the change of |
| 219 | Vunicode_category_table. |
| 220 | |
| 221 | 2011-07-07 Dan Nicolaescu <dann@ics.uci.edu> |
| 222 | |
| 223 | * m/iris4d.h: Remove file, move contents ... |
| 224 | * s/irix6-5.h: ... here. |
| 225 | |
| 226 | 2011-07-06 Paul Eggert <eggert@cs.ucla.edu> |
| 227 | |
| 228 | Remove unportable assumption about struct layout (Bug#8884). |
| 229 | * alloc.c (mark_buffer): |
| 230 | * buffer.c (reset_buffer_local_variables, Fbuffer_local_variables) |
| 231 | (clone_per_buffer_values): Don't assume that |
| 232 | sizeof (struct buffer) is a multiple of sizeof (Lisp_Object). |
| 233 | This isn't true in general, and it's particularly not true |
| 234 | if Emacs is configured with --with-wide-int. |
| 235 | * buffer.h (FIRST_FIELD_PER_BUFFER, LAST_FIELD_PER_BUFFER): |
| 236 | New macros, used in the buffer.c change. |
| 237 | |
| 238 | 2011-07-05 Jan Djärv <jan.h.d@swipnet.se> |
| 239 | |
| 240 | * xsettings.c: Use both GConf and GSettings if both are available. |
| 241 | (store_config_changed_event): Add comment. |
| 242 | (dpyinfo_valid, store_font_name_changed, map_tool_bar_style) |
| 243 | (store_tool_bar_style_changed): New functions. |
| 244 | (store_monospaced_changed): Add comment. Call dpyinfo_valid. |
| 245 | (struct xsettings): Move font inside HAVE_XFT. |
| 246 | (GSETTINGS_TOOL_BAR_STYLE, GSETTINGS_FONT_NAME): New defines. |
| 247 | (GSETTINGS_MONO_FONT): Renamed from SYSTEM_MONO_FONT. |
| 248 | Move inside HAVE_XFT. |
| 249 | (something_changed_gsettingsCB): Renamed from something_changedCB. |
| 250 | Check for changes in GSETTINGS_TOOL_BAR_STYLE and GSETTINGS_FONT_NAME |
| 251 | also. |
| 252 | (GCONF_TOOL_BAR_STYLE, GCONF_FONT_NAME): New defines. |
| 253 | (GCONF_MONO_FONT): Renamed from SYSTEM_MONO_FONT. Move inside HAVE_XFT. |
| 254 | (something_changed_gconfCB): Renamed from something_changedCB. |
| 255 | Check for changes in GCONF_TOOL_BAR_STYLE and GCONF_FONT_NAME also. |
| 256 | (parse_settings): Move check for font inside HAVE_XFT. |
| 257 | (read_settings, apply_xft_settings): Add comment. |
| 258 | (read_and_apply_settings): Add comment. Call map_tool_bar_style and |
| 259 | store_tool_bar_style_changed. Move check for font inside HAVE_XFT and |
| 260 | call store_font_name_changed. |
| 261 | (xft_settings_event): Add comment. |
| 262 | (init_gsettings): Add comment. Get values for GSETTINGS_TOOL_BAR_STYLE |
| 263 | and GSETTINGS_FONT_NAME. Move check for fonts within HAVE_XFT. |
| 264 | (init_gconf): Add comment. Get values for GCONF_TOOL_BAR_STYLE |
| 265 | and GCONF_FONT_NAME. Move check for fonts within HAVE_XFT. |
| 266 | (xsettings_initialize): Call init_gsettings last. |
| 267 | (xsettings_get_system_font, xsettings_get_system_normal_font): Add |
| 268 | comment. |
| 269 | |
| 270 | 2011-07-05 Paul Eggert <eggert@cs.ucla.edu> |
| 271 | |
| 272 | Random fixes. E.g., (random) never returned negative values. |
| 273 | * fns.c (Frandom): Use GET_EMACS_TIME for random seed, and add the |
| 274 | subseconds part to the entropy, as that's a bit more random. |
| 275 | Prefer signed to unsigned, since the signedness doesn't matter and |
| 276 | in general we prefer signed. When given a limit, use a |
| 277 | denominator equal to INTMASK + 1, not to VALMASK + 1, because the |
| 278 | latter isn't right if USE_2_TAGS_FOR_INTS. |
| 279 | * sysdep.c (get_random): Return a value in the range 0..INTMASK, |
| 280 | not 0..VALMASK. Don't discard "excess" bits that random () returns. |
| 281 | |
| 282 | 2011-07-04 Stefan Monnier <monnier@iro.umontreal.ca> |
| 283 | |
| 284 | * textprop.c (text_property_stickiness): |
| 285 | Obey Vtext_property_default_nonsticky. |
| 286 | (syms_of_textprop): Add `display' to Vtext_property_default_nonsticky. |
| 287 | * w32fns.c (syms_of_w32fns): |
| 288 | * xfns.c (syms_of_xfns): Don't Add `display' since it's there by default. |
| 289 | |
| 290 | 2011-07-04 Paul Eggert <eggert@cs.ucla.edu> |
| 291 | |
| 292 | * fileio.c (barf_or_query_if_file_exists): Use S_ISDIR. |
| 293 | This is more efficient than Ffile_directory_p and avoids a minor race. |
| 294 | |
| 295 | 2011-07-04 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 296 | |
| 297 | * buffer.c (Foverlay_put): Say what the return value is |
| 298 | (bug#7835). |
| 299 | |
| 300 | * fileio.c (barf_or_query_if_file_exists): Check first if the file |
| 301 | is a directory before asking whether to use the file name |
| 302 | (bug#7564). |
| 303 | (barf_or_query_if_file_exists): Make the "File is a directory" |
| 304 | error be more correct. |
| 305 | |
| 306 | * fns.c (Frequire): Remove the mention of the .gz files, since |
| 307 | that's installation-specific, but keep the mention of |
| 308 | `get-load-suffixes'. |
| 309 | |
| 310 | 2011-07-04 Paul Eggert <eggert@cs.ucla.edu> |
| 311 | |
| 312 | * editfns.c (Fformat_time_string): Don't assume strlen fits in int. |
| 313 | Report string overflow if the output is too long. |
| 314 | |
| 315 | 2011-07-04 Juanma Barranquero <lekktu@gmail.com> |
| 316 | |
| 317 | * gnutls.c (Fgnutls_boot): Don't mention :verify-error. |
| 318 | (syms_of_gnutls): Remove duplicate DEFSYM for |
| 319 | Qgnutls_bootprop_verify_hostname_error, an error for |
| 320 | Qgnutls_bootprop_verify_error (which is no longer used). |
| 321 | |
| 322 | * eval.c (find_handler_clause): Remove parameters `sig' and `data', |
| 323 | unused since 2011-01-26T20:02:07Z!monnier@iro.umontreal.ca. All callers changed. |
| 324 | Also (re)move comments that are misplaced or no longer relevant. |
| 325 | |
| 326 | 2011-07-03 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 327 | |
| 328 | * callint.c (Finteractive): Clarify the meaning of "@" (bug#8813). |
| 329 | |
| 330 | 2011-07-03 Chong Yidong <cyd@stupidchicken.com> |
| 331 | |
| 332 | * xfaces.c (Finternal_merge_in_global_face): Modify the foreground |
| 333 | and background color parameters if they have been changed. |
| 334 | |
| 335 | 2011-07-03 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 336 | |
| 337 | * editfns.c (Fformat): Clarify the - and 0 flags (bug#6659). |
| 338 | |
| 339 | 2011-07-03 Paul Eggert <eggert@cs.ucla.edu> |
| 340 | |
| 341 | * xsettings.c (SYSTEM_FONT): Define only when used. |
| 342 | No need to define when HAVE_GSETTINGS || !HAVE_XFT. |
| 343 | |
| 344 | * keymap.c (access_keymap_1): Now static. |
| 345 | |
| 346 | 2011-07-02 Chong Yidong <cyd@stupidchicken.com> |
| 347 | |
| 348 | * keyboard.c (command_loop_1): If a down-mouse event is unbound, |
| 349 | leave any prefix arg for the up event (Bug#1586). |
| 350 | |
| 351 | 2011-07-02 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 352 | |
| 353 | * lread.c (syms_of_lread): Mention single symbols defined by |
| 354 | `defvar' or `defconst' (bug#7154). |
| 355 | |
| 356 | * fns.c (Frequire): Mention .el.gz files (bug#7314). |
| 357 | (Frequire): Mention get-load-suffixes. |
| 358 | |
| 359 | 2011-07-02 Martin Rudalics <rudalics@gmx.at> |
| 360 | |
| 361 | * window.h (window): Remove clone_number slot. |
| 362 | * window.c (Fwindow_clone_number, Fset_window_clone_number): |
| 363 | Remove. |
| 364 | (make_parent_window, make_window, saved_window) |
| 365 | (Fset_window_configuration, save_window_save): Don't deal with |
| 366 | clone numbers. |
| 367 | * buffer.c (Qclone_number): Remove declaration. |
| 368 | (sort_overlays, overlay_strings): Don't deal with clone numbers. |
| 369 | |
| 370 | 2011-07-02 Stefan Monnier <monnier@iro.umontreal.ca> |
| 371 | |
| 372 | Add multiple inheritance to keymaps. |
| 373 | * keymap.c (Fmake_composed_keymap): New function. |
| 374 | (Fset_keymap_parent): Simplify. |
| 375 | (fix_submap_inheritance): Remove. |
| 376 | (access_keymap_1): New function extracted from access_keymap to handle |
| 377 | embedded parents and handle lists of maps. |
| 378 | (access_keymap): Use it. |
| 379 | (Fkeymap_prompt, map_keymap_internal, map_keymap, store_in_keymap) |
| 380 | (Fcopy_keymap): Handle embedded parents. |
| 381 | (Fcommand_remapping, define_as_prefix): Simplify. |
| 382 | (Fkey_binding): Simplify. |
| 383 | (syms_of_keymap): Move minibuffer-local-completion-map, |
| 384 | minibuffer-local-filename-completion-map, |
| 385 | minibuffer-local-must-match-map, and |
| 386 | minibuffer-local-filename-must-match-map to Elisp. |
| 387 | (syms_of_keymap): Defsubr make-composed-keymap. |
| 388 | * keyboard.c (menu_bar_items): Use map_keymap_canonical. |
| 389 | (parse_menu_item): Trivial simplification. |
| 390 | |
| 391 | 2011-07-01 Glenn Morris <rgm@gnu.org> |
| 392 | |
| 393 | * Makefile.in (SETTINGS_LIBS): Fix typo. |
| 394 | |
| 395 | 2011-07-01 Kazuhiro Ito <kzhr@d1.dion.ne.jp> (tiny patch) |
| 396 | |
| 397 | * coding.c (Fencode_coding_string): Record the last coding system |
| 398 | used, as the function doc string says (bug#8738). |
| 399 | |
| 400 | 2011-07-01 Jan Djärv <jan.h.d@swipnet.se> |
| 401 | |
| 402 | * xsettings.c (store_monospaced_changed): Take new font as arg and |
| 403 | check for change against current_mono_font. |
| 404 | (EMACS_TYPE_SETTINGS): Remove this and related defines. |
| 405 | (emacs_settings_constructor, emacs_settings_get_property) |
| 406 | (emacs_settings_set_property, emacs_settings_class_init) |
| 407 | (emacs_settings_init, gsettings_obj): Remove. |
| 408 | (something_changedCB): New function for HAVE_GSETTINGS. |
| 409 | (something_changedCB): HAVE_GCONF: Call store_monospaced_changed |
| 410 | with value as argument. |
| 411 | (init_gsettings): Check that GSETTINGS_SCHEMA exists before calling |
| 412 | g_settings_new (Bug#8967). Do not create gsettings_obj. |
| 413 | Remove calls to g_settings_bind. Connect something_changedCB to |
| 414 | "changed". |
| 415 | |
| 416 | * xgselect.c: Add defined (HAVE_GSETTINGS). |
| 417 | (xgselect_initialize): Ditto. |
| 418 | |
| 419 | * process.c: Add defined (HAVE_GSETTINGS) for xgselect.h |
| 420 | (wait_reading_process_output): Add defined (HAVE_GSETTINGS) for |
| 421 | xg_select. |
| 422 | |
| 423 | 2011-07-01 Paul Eggert <eggert@cs.ucla.edu> |
| 424 | |
| 425 | * eval.c (struct backtrace): Simplify and port the data structure. |
| 426 | Do not assume that "int nargs : BITS_PER_INT - 2;" produces a |
| 427 | signed bit field, as this assumption is not portable and it makes |
| 428 | Emacs crash when compiled with Sun C 5.8 on sparc. Do not use |
| 429 | "char debug_on_exit : 1" as this is not portable either; instead, |
| 430 | use the portable "unsigned int debug_on_exit : 1". Remove unused |
| 431 | member evalargs. Remove obsolete comments about cc bombing out. |
| 432 | |
| 433 | 2011-06-30 Jan Djärv <jan.h.d@swipnet.se> |
| 434 | |
| 435 | * xsettings.c: Include glib-object.h, gio/gio.h if HAVE_GSETTINGS. |
| 436 | Let HAVE_GSETTINGS override HAVE_GCONF. |
| 437 | (store_monospaced_changed): New function. |
| 438 | (EMACS_SETTINGS): A new type derived from GObject to handle |
| 439 | GSettings notifications. |
| 440 | (emacs_settings_constructor, emacs_settings_get_property) |
| 441 | (emacs_settings_set_property, emacs_settings_class_init): |
| 442 | New functions. |
| 443 | (gsettings_client, gsettings_obj): New variables. |
| 444 | (GSETTINGS_SCHEMA): New define. |
| 445 | (something_changedCB): Call store_monospaced_changed. |
| 446 | (init_gsettings): New function. |
| 447 | (xsettings_initialize): Call init_gsettings. |
| 448 | (syms_of_xsettings): Initialize gsettings_client, gsettings_obj |
| 449 | to NULL. |
| 450 | |
| 451 | * Makefile.in (SETTINGS_CFLAGS, SETTINGS_LIBS): Renamed from |
| 452 | GCONF_CFLAGS/LIBS. |
| 453 | |
| 454 | 2011-06-29 Martin Rudalics <rudalics@gmx.at> |
| 455 | |
| 456 | * window.c (resize_root_window, grow_mini_window) |
| 457 | (shrink_mini_window): Rename Qresize_root_window to |
| 458 | Qwindow_resize_root_window and Qresize_root_window_vertically to |
| 459 | Qwindow_resize_root_window_vertically. |
| 460 | |
| 461 | 2011-06-28 Paul Eggert <eggert@cs.ucla.edu> |
| 462 | |
| 463 | * gnutls.c (Qgnutls_bootprop_verify_error): Remove unused var. |
| 464 | |
| 465 | 2011-06-27 Juanma Barranquero <lekktu@gmail.com> |
| 466 | |
| 467 | * makefile.w32-in: Redesign dependencies so they reflect more |
| 468 | clearly which files are directly included by each source file, |
| 469 | and not through other includes. |
| 470 | |
| 471 | 2011-06-27 Martin Rudalics <rudalics@gmx.at> |
| 472 | |
| 473 | * buffer.c (Qclone_number): Declare static and DEFSYM it. |
| 474 | (sort_overlays, overlay_strings): When an overlay's clone number |
| 475 | matches the window's clone number process the overlay even if |
| 476 | the overlay's window property doesn't match the current window. |
| 477 | |
| 478 | * window.c (Fwindow_vchild): Rename to Fwindow_top_child. |
| 479 | (Fwindow_hchild): Rename to Fwindow_left_child. |
| 480 | (Fwindow_next): Rename to Fwindow_next_sibling. |
| 481 | (Fwindow_prev): Rename to Fwindow_prev_sibling. |
| 482 | (resize_window_check): Rename to window_resize_check. |
| 483 | (resize_window_apply): Rename to window_resize_apply. |
| 484 | (Fresize_window_apply): Rename to Fwindow_resize_apply. |
| 485 | (Fdelete_other_windows_internal, resize_frame_windows) |
| 486 | (Fsplit_window_internal, Fdelete_window_internal) |
| 487 | (grow_mini_window, shrink_mini_window) |
| 488 | (Fresize_mini_window_internal): Fix callers accordingly. |
| 489 | |
| 490 | 2011-06-26 Jan Djärv <jan.h.d@swipnet.se> |
| 491 | |
| 492 | * emacsgtkfixed.h: State that this is only used with Gtk+3. |
| 493 | (emacs_fixed_set_min_size): Remove. |
| 494 | (emacs_fixed_new): Take frame as argument. |
| 495 | |
| 496 | * emacsgtkfixed.c: State that this is only used with Gtk+3. |
| 497 | (_EmacsFixedPrivate): Remove minwidth/height. |
| 498 | Add struct frame *f. |
| 499 | (emacs_fixed_init): Initialize priv->f. |
| 500 | (get_parent_class, emacs_fixed_set_min_size): Remove. |
| 501 | (emacs_fixed_new): Set priv->f to argument. |
| 502 | (emacs_fixed_get_preferred_width) |
| 503 | (emacs_fixed_get_preferred_height): Use min_width/height from |
| 504 | frames size_hint to set minimum and natural (Bug#8919). |
| 505 | (XSetWMSizeHints, XSetWMNormalHints): Override these functions |
| 506 | and use min_width/height from frames size_hint to set |
| 507 | min_width/height (Bug#8919). |
| 508 | |
| 509 | * gtkutil.c (xg_create_frame_widgets): Pass f to emacs_fixed_new. |
| 510 | (x_wm_set_size_hint): Remove call to emacs_fixed_set_min_size. |
| 511 | Fix indentation. |
| 512 | |
| 513 | 2011-06-26 Eli Zaretskii <eliz@gnu.org> |
| 514 | |
| 515 | * bidi.c (bidi_paragraph_init): Test for ZV_BYTE before calling |
| 516 | bidi_at_paragraph_end, since fast_looking_at doesn't like to be |
| 517 | called at ZV. |
| 518 | |
| 519 | 2011-06-26 Chong Yidong <cyd@stupidchicken.com> |
| 520 | |
| 521 | * process.c (wait_reading_process_output): Bypass select if |
| 522 | waiting for a cell while ignoring keyboard input, and input is |
| 523 | pending. Suggested by Jan Djärv (Bug#8869). |
| 524 | |
| 525 | 2011-06-25 Paul Eggert <eggert@cs.ucla.edu> |
| 526 | |
| 527 | Use gnulib's dup2 module instead of rolling our own. |
| 528 | * sysdep.c (dup2) [!HAVE_DUP2]: Remove; gnulib now does this. |
| 529 | |
| 530 | 2011-06-25 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
| 531 | |
| 532 | * dispnew.c (scrolling_window): Before scrolling, turn off a |
| 533 | mouse-highlight in the window being scrolled. |
| 534 | |
| 535 | 2011-06-24 Juanma Barranquero <lekktu@gmail.com> |
| 536 | |
| 537 | Move DEFSYM to lisp.h and use everywhere. |
| 538 | |
| 539 | * character.h (DEFSYM): Move declaration... |
| 540 | * lisp.h (DEFSYM): ...here. |
| 541 | |
| 542 | * gnutls.c: |
| 543 | * minibuf.c: |
| 544 | * w32menu.c: |
| 545 | * w32proc.c: |
| 546 | * w32select.c: Don't include character.h. |
| 547 | |
| 548 | * alloc.c (syms_of_alloc): |
| 549 | * buffer.c (syms_of_buffer): |
| 550 | * bytecode.c (syms_of_bytecode): |
| 551 | * callint.c (syms_of_callint): |
| 552 | * casefiddle.c (syms_of_casefiddle): |
| 553 | * casetab.c (init_casetab_once): |
| 554 | * category.c (init_category_once, syms_of_category): |
| 555 | * ccl.c (syms_of_ccl): |
| 556 | * cmds.c (syms_of_cmds): |
| 557 | * composite.c (syms_of_composite): |
| 558 | * dbusbind.c (syms_of_dbusbind): |
| 559 | * dired.c (syms_of_dired): |
| 560 | * dispnew.c (syms_of_display): |
| 561 | * doc.c (syms_of_doc): |
| 562 | * editfns.c (syms_of_editfns): |
| 563 | * emacs.c (syms_of_emacs): |
| 564 | * eval.c (syms_of_eval): |
| 565 | * fileio.c (syms_of_fileio): |
| 566 | * fns.c (syms_of_fns): |
| 567 | * frame.c (syms_of_frame): |
| 568 | * fringe.c (syms_of_fringe): |
| 569 | * insdel.c (syms_of_insdel): |
| 570 | * keymap.c (syms_of_keymap): |
| 571 | * lread.c (init_obarray, syms_of_lread): |
| 572 | * macros.c (syms_of_macros): |
| 573 | * msdos.c (syms_of_msdos): |
| 574 | * print.c (syms_of_print): |
| 575 | * process.c (syms_of_process): |
| 576 | * search.c (syms_of_search): |
| 577 | * sound.c (syms_of_sound): |
| 578 | * syntax.c (init_syntax_once, syms_of_syntax): |
| 579 | * terminal.c (syms_of_terminal): |
| 580 | * textprop.c (syms_of_textprop): |
| 581 | * undo.c (syms_of_undo): |
| 582 | * w32.c (globals_of_w32): |
| 583 | * window.c (syms_of_window): |
| 584 | * xdisp.c (syms_of_xdisp): |
| 585 | * xfaces.c (syms_of_xfaces): |
| 586 | * xfns.c (syms_of_xfns): |
| 587 | * xmenu.c (syms_of_xmenu): |
| 588 | * xsettings.c (syms_of_xsettings): |
| 589 | * xterm.c (syms_of_xterm): Use DEFSYM. |
| 590 | |
| 591 | 2011-06-24 Teodor Zlatanov <tzz@lifelogs.com> |
| 592 | |
| 593 | * gnutls.c (syms_of_gnutls): Use the DEFSYM macro from character.h. |
| 594 | |
| 595 | 2011-06-23 Paul Eggert <eggert@cs.ucla.edu> |
| 596 | |
| 597 | Integer and buffer overflow fixes (Bug#8873). |
| 598 | |
| 599 | * print.c (printchar, strout): Check for string overflow. |
| 600 | (PRINTPREPARE, printchar, strout): |
| 601 | Don't set size unless allocation succeeds. |
| 602 | |
| 603 | * minibuf.c (read_minibuf_noninteractive): Use ptrdiff_t, not int, |
| 604 | for sizes. Check for string overflow more accurately. |
| 605 | Simplify newline removal at end; this suppresses a GCC 4.6.0 warning. |
| 606 | |
| 607 | * macros.c: Integer and buffer overflow fixes. |
| 608 | * keyboard.h (struct keyboard.kbd_macro_bufsize): |
| 609 | * macros.c (Fstart_kbd_macro, store_kbd_macro_char): |
| 610 | Use ptrdiff_t, not int, for sizes. |
| 611 | Don't increment bufsize until after realloc succeeds. |
| 612 | Check for size-calculation overflow. |
| 613 | (Fstart_kbd_macro): Use EMACS_INT, not int, for XINT result. |
| 614 | |
| 615 | * lisp.h (DEFVAR_KBOARD): Use offsetof instead of char * finagling. |
| 616 | |
| 617 | * lread.c: Integer overflow fixes. |
| 618 | (read_integer): Radix is now EMACS_INT, not int, |
| 619 | to improve quality of diagnostics for out-of-range radices. |
| 620 | Calculate buffer size correctly for out-of-range radices. |
| 621 | (read1): Check for integer overflow in radices, and in |
| 622 | read-circle numbers. |
| 623 | (read_escape): Avoid int overflow. |
| 624 | (Fload, openp, read_buffer_size, read1) |
| 625 | (substitute_object_recurse, read_vector, read_list, map_obarray): |
| 626 | Use ptrdiff_t, not int, for sizes. |
| 627 | (read1): Use EMACS_INT, not int, for sizes. |
| 628 | Check for size overflow. |
| 629 | |
| 630 | * image.c (cache_image): Check for size arithmetic overflow. |
| 631 | |
| 632 | * lread.c: Integer overflow issues. |
| 633 | (saved_doc_string_size, saved_doc_string_length) |
| 634 | (prev_saved_doc_string_size, prev_saved_doc_string_length): |
| 635 | Now ptrdiff_t, not int. |
| 636 | (read1): Don't assume doc string length fits in int. Check for |
| 637 | out-of-range doc string lengths. |
| 638 | (read_list): Don't assume file position fits in int. |
| 639 | (read_escape): Check for hex character overflow. |
| 640 | |
| 641 | 2011-06-22 Leo Liu <sdl.web@gmail.com> |
| 642 | |
| 643 | * minibuf.c (Fcompleting_read_default, Vcompleting_read_function): |
| 644 | Move to minibuffer.el. |
| 645 | |
| 646 | 2011-06-22 Paul Eggert <eggert@cs.ucla.edu> |
| 647 | |
| 648 | Fixes for GLYPH_DEBUG found by GCC 4.6.0 static checking. |
| 649 | The following patches are for when GLYPH_DEBUG && !XASSERT. |
| 650 | * dispextern.h (trace_redisplay_p, dump_glyph_string): |
| 651 | * dispnew.c (flush_stdout): |
| 652 | * xdisp.c (dump_glyph_row, dump_glyph_matrix, dump_glyph): |
| 653 | Mark as externally visible. |
| 654 | * dispnew.c (check_window_matrix_pointers): Now static. |
| 655 | * dispnew.c (window_to_frame_vpos): |
| 656 | * xfns.c (unwind_create_frame): |
| 657 | * xterm.c (x_check_font): Remove unused local. |
| 658 | * scroll.c (CHECK_BOUNDS): |
| 659 | * xfaces.c (cache_fache): Rename local to avoid shadowing. |
| 660 | * xfns.c, w32fns.c (image_cache_refcount, dpyinfo_refcount): Now static. |
| 661 | * xdisp.c (check_window_end): Now a no-op if !XASSERTS. |
| 662 | (debug_first_unchanged_at_end_vpos, debug_last_unchanged_at_beg_vpos) |
| 663 | (debug_dvpos, debug_dy, debug_delta, debug_delta_bytes, debug_end_vpos): |
| 664 | Now static. |
| 665 | (debug_method_add): Use va_list and vsprintf rather than relying |
| 666 | on undefined behavior with wrong number of arguments. |
| 667 | (dump_glyph, dump_glyph_row, Fdump_glyph_matrix): |
| 668 | Don't assume ptrdiff_t and EMACS_INT are the same width as int. |
| 669 | In this code, it's OK to assume C99 behavior for ptrdiff_t formats |
| 670 | since we're not interested in debugging glyphs with old libraries. |
| 671 | * xfaces.c (cache_face): Move debugging code earlier; this pacifies |
| 672 | GCC 4.6.0's static checking. |
| 673 | |
| 674 | 2011-06-22 Paul Eggert <eggert@cs.ucla.edu> |
| 675 | |
| 676 | Integer overflow and signedness fixes (Bug#8873). |
| 677 | A few related buffer overrun fixes, too. |
| 678 | |
| 679 | * font.c (font_score): Use EMACS_INT, not int, to store XINT value. |
| 680 | |
| 681 | * dispextern.h (struct face.stipple): |
| 682 | * image.c (x_bitmap_height, x_bitmap_width, x_bitmap_pixmap) |
| 683 | (x_bitmap_mask, x_allocate_bitmap_record) |
| 684 | (x_create_bitmap_from_data, x_create_bitmap_from_file) |
| 685 | (x_destroy_bitmap, x_destroy_all_bitmaps, x_create_bitmap_mask) |
| 686 | (x_create_bitmap_from_xpm_data): |
| 687 | * nsterm.h (struct ns_display_info.bitmaps_size, .bitmaps_last): |
| 688 | * w32term.h (struct w32_display_info.icon_bitmap_id, .bitmaps_size) |
| 689 | (.bitmaps_last): |
| 690 | * xfaces.c (load_pixmap): |
| 691 | * xterm.c (x_bitmap_icon, x_wm_set_icon_pixmap): |
| 692 | * xterm.h (struct x_display_info.icon_bitmap_id, .bitmaps_size) |
| 693 | (.bitmaps_last, struct x_output.icon_bitmap): |
| 694 | Use ptrdiff_t, not int, for bitmap indexes. |
| 695 | (x_allocate_bitmap_record): Check for size overflow. |
| 696 | * dispextern.h, lisp.h: Adjust to API changes elsewhere. |
| 697 | |
| 698 | Use ptrdiff_t, not int, for overlay counts. |
| 699 | * buffer.h (overlays_at, sort_overlays, GET_OVERLAYS_AT): |
| 700 | * editfns.c (overlays_around, get_pos_property): |
| 701 | * textprop.c (get_char_property_and_overlay): |
| 702 | * xdisp.c (next_overlay_change, note_mouse_highlight): |
| 703 | * xfaces.c (face_at_buffer_position): |
| 704 | * buffer.c (OVERLAY_COUNT_MAX): New macro. |
| 705 | (overlays_at, overlays_in, sort_overlays, Foverlays_at) |
| 706 | (Fnext_overlay_change, Fprevious_overlay_change) |
| 707 | (mouse_face_overlay_overlaps, Foverlays_in): |
| 708 | Use ptrdiff_t, not int, for sizes. |
| 709 | (overlays_at, overlays_in): Check for size-calculation overflow. |
| 710 | |
| 711 | * xterm.c (xim_initialize, same_x_server): Strlen may not fit in int. |
| 712 | |
| 713 | * xsmfns.c (smc_save_yourself_CB, x_session_initialize): Avoid strlen. |
| 714 | (x_session_initialize): Do not assume string length fits in int. |
| 715 | |
| 716 | * xsettings.c (apply_xft_settings): Fix potential buffer overrun. |
| 717 | This is unlikely, but can occur if DPI is outlandish. |
| 718 | |
| 719 | * xsettings.c (Ffont_get_system_normal_font, Ffont_get_system_font): |
| 720 | * xselect.c (Fx_get_atom_name): Avoid need for strlen. |
| 721 | |
| 722 | * xrdb.c: Don't assume strlen fits in int; avoid some strlens. |
| 723 | * xrdb.c (magic_file_p, search_magic_path): |
| 724 | Omit last arg SUFFIX; it was always 0. All callers changed. |
| 725 | (magic_file_p): Use ptrdiff_t, not int. Check for size overflow. |
| 726 | |
| 727 | * xfont.c (xfont_match): Avoid need for strlen. |
| 728 | |
| 729 | * xfns.c: Don't assume strlen fits in int. |
| 730 | (xic_create_fontsetname, x_window): Use ptrdiff_t, not int. |
| 731 | |
| 732 | * xdisp.c (message_log_check_duplicate): Return intmax_t, |
| 733 | not unsigned long, as we prefer signed integers. All callers changed. |
| 734 | Detect integer overflow in repeat count. |
| 735 | (message_dolog): Don't assume print length fits in 39 bytes. |
| 736 | (display_mode_element): Don't assume strlen fits in int. |
| 737 | |
| 738 | * termcap.c: Don't assume sizes fit in int and never overflow. |
| 739 | (struct termcap_buffer, tgetent): Use ptrdiff_t, not int, for sizes. |
| 740 | (gobble_line): Check for size-calculation overflow. |
| 741 | |
| 742 | * minibuf.c (Fread_buffer): |
| 743 | * lread.c (intern, intern_c_string): |
| 744 | * image.c (xpm_scan) [HAVE_NS && !HAVE_XPM]: |
| 745 | Don't assume string length fits in int. |
| 746 | |
| 747 | * keyboard.c (parse_tool_bar_item): |
| 748 | * gtkutil.c (style_changed_cb): Avoid need for strlen. |
| 749 | |
| 750 | * font.c: Don't assume string length fits in int. |
| 751 | (font_parse_xlfd, font_parse_fcname, font_unparse_fcname): |
| 752 | Use ptrdiff_t, not int. |
| 753 | (font_intern_prop): Don't assume string length fits in int. |
| 754 | Don't assume integer property fits in fixnum. |
| 755 | * font.h (font_intern_prop): 2nd arg is now ptrdiff_t, not int. |
| 756 | |
| 757 | * filelock.c: Fix some buffer overrun and integer overflow issues. |
| 758 | (get_boot_time): Don't assume gzip command string fits in 100 bytes. |
| 759 | Reformulate so as not to need the command string. |
| 760 | Invoke gzip -cd rather than gunzip, as it's more portable. |
| 761 | (lock_info_type, lock_file_1, lock_file): |
| 762 | Don't assume pid_t and time_t fit in unsigned long. |
| 763 | (LOCK_PID_MAX): Remove; we now use more-reliable bounds. |
| 764 | (current_lock_owner): Prefer signed type for sizes. |
| 765 | Use memcpy, not strncpy, where memcpy is what is really wanted. |
| 766 | Don't assume (via atoi) that time_t and pid_t fit in int. |
| 767 | Check for time_t and/or pid_t out of range, e.g., via a network share. |
| 768 | Don't alloca where an auto var works fine. |
| 769 | |
| 770 | * fileio.c: Fix some integer overflow issues. |
| 771 | (file_name_as_directory, Fexpand_file_name, Fsubstitute_in_file_name): |
| 772 | Don't assume string length fits in int. |
| 773 | (directory_file_name): Don't assume string length fits in long. |
| 774 | (make_temp_name): Don't assume pid fits in int, or that its print |
| 775 | length is less than 20. |
| 776 | |
| 777 | * data.c (Fsubr_name): Rewrite to avoid a strlen call. |
| 778 | |
| 779 | * coding.c (make_subsidiaries): Don't assume string length fits in int. |
| 780 | |
| 781 | * callproc.c (child_setup): Rewrite to avoid two strlen calls. |
| 782 | |
| 783 | * process.c (Fformat_network_address): Use EMACS_INT, not EMACS_UINT. |
| 784 | We prefer signed integers, even for size calculations. |
| 785 | |
| 786 | * emacs.c: Don't assume string length fits in 'int'. |
| 787 | (DEFINE_DUMMY_FUNCTION, sort_args): Use ptrdiff_t, not int. |
| 788 | (main): Don't invoke strlen when not needed. |
| 789 | |
| 790 | * dbusbind.c (XD_ERROR): Don't arbitrarily truncate string. |
| 791 | (XD_DEBUG_MESSAGE): Don't waste a byte. |
| 792 | |
| 793 | * callproc.c (getenv_internal_1, getenv_internal) |
| 794 | (Fgetenv_internal): |
| 795 | * buffer.c (init_buffer): Don't assume string length fits in 'int'. |
| 796 | |
| 797 | * lread.c (invalid_syntax): Omit length argument. |
| 798 | All uses changed. This doesn't fix a bug, but it simplifies the |
| 799 | code away from its former Hollerith-constant appearance, and it's |
| 800 | one less 'int' to worry about when looking at integer-overflow issues. |
| 801 | (string_to_number): Simplify 2011-04-26 change by invoking xsignal1. |
| 802 | |
| 803 | * lisp.h (DEFUN): Remove bogus use of sizeof (struct Lisp_Subr). |
| 804 | This didn't break anything, but it didn't help either. |
| 805 | It's confusing to put a bogus integer in a place where the actual |
| 806 | value does not matter. |
| 807 | (LIST_END_P): Remove unused macro and its bogus comment. |
| 808 | (make_fixnum_or_float): Remove unnecessary cast to EMACS_INT. |
| 809 | |
| 810 | * lisp.h (union Lisp_Object.i): EMACS_INT, not EMACS_UINT. |
| 811 | This is for consistency with the ordinary, non-USE_LISP_UNION_TYPE, |
| 812 | implementation. |
| 813 | (struct Lisp_Bool_Vector.size): EMACS_INT, not EMACS_UINT. |
| 814 | We prefer signed types, and the value cannot exceed the EMACS_INT |
| 815 | range anyway (because otherwise the length would not be representable). |
| 816 | (XSET) [USE_LISP_UNION_TYPE]: Use uintptr_t and intptr_t, |
| 817 | not EMACS_UINT and EMACS_INT, when converting pointer to integer. |
| 818 | This avoids a GCC warning when WIDE_EMACS_INT. |
| 819 | |
| 820 | * indent.c (sane_tab_width): New function. |
| 821 | (current_column, scan_for_column, Findent_to, position_indentation) |
| 822 | (compute_motion): Use it. This is just for clarity. |
| 823 | (Fcompute_motion): Don't assume hscroll and tab offset fit in int. |
| 824 | |
| 825 | * image.c (xbm_image_p): Don't assume stated width, height fit in int. |
| 826 | |
| 827 | * lisp.h (lint_assume): New macro. |
| 828 | * composite.c (composition_gstring_put_cache): |
| 829 | * ftfont.c (ftfont_shape_by_flt): Use it to pacify GCC 4.6.0. |
| 830 | |
| 831 | * editfns.c, insdel.c: |
| 832 | Omit unnecessary forward decls, to simplify future changes. |
| 833 | |
| 834 | * ftfont.c (ftfont_shape_by_flt): Use signed integers for lengths. |
| 835 | |
| 836 | * font.c (Ffont_shape_gstring): Don't assume glyph len fits in 'int'. |
| 837 | |
| 838 | * fns.c (Ffillarray): Don't assume bool vector size fits in 'int'. |
| 839 | Use much-faster test for byte-length change. |
| 840 | Don't assume string byte-length fits in 'int'. |
| 841 | Check that character arg fits in 'int'. |
| 842 | (mapcar1): Declare byte as byte, for clarity. |
| 843 | |
| 844 | * alloc.c (Fmake_bool_vector): Avoid unnecessary multiplication. |
| 845 | |
| 846 | * fns.c (concat): Catch string overflow earlier. |
| 847 | Do not rely on integer wraparound. |
| 848 | |
| 849 | * dispextern.h (struct it.overlay_strings_charpos) |
| 850 | (struct it.selective): Now EMACS_INT, not int. |
| 851 | * xdisp.c (forward_to_next_line_start) |
| 852 | (back_to_previous_visible_line_start) |
| 853 | (reseat_at_next_visible_line_start, next_element_from_buffer): |
| 854 | Don't arbitrarily truncate the value of 'selective' to int. |
| 855 | |
| 856 | * xdisp.c (init_iterator): Use XINT, not XFASTINT; it might be < 0. |
| 857 | |
| 858 | * composite.c: Don't truncate sizes to 'int'. |
| 859 | (composition_gstring_p, composition_reseat_it) |
| 860 | (composition_adjust_point): Use EMACS_INT, not int. |
| 861 | (get_composition_id, composition_gstring_put_cache): Use EMACS_INT, |
| 862 | not EMACS_UINT, for indexes. |
| 863 | |
| 864 | * category.h (CATEGORY_SET_P): Remove unnecessary cast to EMACS_INT. |
| 865 | |
| 866 | * buffer.c: Include <verify.h>. |
| 867 | (struct sortvec.priority, struct sortstr.priority): |
| 868 | Now EMACS_INT, not int. |
| 869 | (compare_overlays, cmp_for_strings): Avoid subtraction overflow. |
| 870 | (struct sortstr.size, record_overlay_string) |
| 871 | (struct sortstrlist.size, struct sortlist.used): |
| 872 | Don't truncate size to int. |
| 873 | (record_overlay_string): Check for size-calculation overflow. |
| 874 | (init_buffer_once): Check at compile-time, not run-time. |
| 875 | |
| 876 | 2011-06-22 Jim Meyering <meyering@redhat.com> |
| 877 | |
| 878 | Don't leak an XBM-image-sized buffer |
| 879 | * image.c (xbm_load): Free the image buffer after using it. |
| 880 | |
| 881 | 2011-06-21 Paul Eggert <eggert@cs.ucla.edu> |
| 882 | |
| 883 | Port to Sun C. |
| 884 | * composite.c (find_automatic_composition): Omit needless 'return 0;' |
| 885 | that Sun C diagnosed. |
| 886 | * fns.c (secure_hash): Fix pointer signedness issue. |
| 887 | * intervals.c (static_offset_intervals): New function. |
| 888 | (offset_intervals): Use it. |
| 889 | |
| 890 | 2011-06-21 Leo Liu <sdl.web@gmail.com> |
| 891 | |
| 892 | * deps.mk (fns.o): |
| 893 | * makefile.w32-in ($(BLD)/fns.$(O)): Include sha256.h and |
| 894 | sha512.h. |
| 895 | |
| 896 | * fns.c (secure_hash): Rename from crypto_hash_function and change |
| 897 | the first arg to accept symbols. |
| 898 | (Fsecure_hash): New primitive. |
| 899 | (syms_of_fns): New symbols. |
| 900 | |
| 901 | 2011-06-20 Deniz Dogan <deniz@dogan.se> |
| 902 | |
| 903 | * process.c (Fset_process_buffer): Clarify return value in |
| 904 | docstring. |
| 905 | |
| 906 | 2011-06-18 Chong Yidong <cyd@stupidchicken.com> |
| 907 | |
| 908 | * dispnew.c (add_window_display_history): Use BVAR. |
| 909 | |
| 910 | * xdisp.c (debug_method_add): Use BVAR. |
| 911 | (check_window_end, dump_glyph_matrix, dump_glyph) |
| 912 | (dump_glyph_row, dump_glyph_string): Convert arglist to ANSI C. |
| 913 | |
| 914 | * xfaces.c (check_lface_attrs, check_lface, dump_realized_face): |
| 915 | Likewise. |
| 916 | |
| 917 | * xfns.c (Fx_create_frame, x_create_tip_frame): Delay image cache |
| 918 | check till after the cache is created in init_frame_faces. |
| 919 | |
| 920 | 2011-06-17 Stefan Monnier <monnier@iro.umontreal.ca> |
| 921 | |
| 922 | * fns.c (Fsafe_length): Yet another int/Lisp_Object mixup. |
| 923 | |
| 924 | 2011-06-16 Paul Eggert <eggert@cs.ucla.edu> |
| 925 | |
| 926 | * lisp.h: Include <limits.h>, for INT_MAX, LONG_MAX, LLONG_MAX. |
| 927 | Without this, prin1 mishandles Lisp_Misc_Save_Value printing on |
| 928 | hosts with pre-C99 libraries, because pD is wrongly defined to "t". |
| 929 | |
| 930 | Improve buffer-overflow checking (Bug#8873). |
| 931 | * fileio.c (Finsert_file_contents): |
| 932 | * insdel.c (insert_from_buffer_1, replace_range, replace_range_2): |
| 933 | Remove the old (too-loose) buffer overflow checks. |
| 934 | They weren't needed, since make_gap checks for buffer overflow. |
| 935 | * insdel.c (make_gap_larger): Catch buffer overflows that were missed. |
| 936 | The old code merely checked for Emacs fixnum overflow, and relied |
| 937 | on undefined (wraparound) behavior. The new code avoids undefined |
| 938 | behavior, and also checks for ptrdiff_t and/or size_t overflow. |
| 939 | |
| 940 | * editfns.c (Finsert_char): Don't dump core with very negative counts. |
| 941 | Tune. Don't use wider integers than needed. Don't use alloca. |
| 942 | Use a bigger 'string' buffer. Rewrite to avoid 'n > 0' test. |
| 943 | |
| 944 | * insdel.c (replace_range): Fix buf overflow when insbytes < outgoing. |
| 945 | |
| 946 | * insdel.c, lisp.h (buffer_overflow): New function. |
| 947 | (insert_from_buffer_1, replace_range, replace_range_2): |
| 948 | * insdel.c (make_gap_larger): |
| 949 | * editfns.c (Finsert_char): |
| 950 | * fileio.c (Finsert_file_contents): Use it, to normalize wording. |
| 951 | |
| 952 | * buffer.h (BUF_BYTES_MAX): Cast to ptrdiff_t so that it's signed. |
| 953 | |
| 954 | 2011-06-15 Paul Eggert <eggert@cs.ucla.edu> |
| 955 | |
| 956 | Integer overflow and signedness fixes (Bug#8873). |
| 957 | |
| 958 | * ccl.c (ASCENDING_ORDER): New macro, to work around GCC bug 43772. |
| 959 | (GET_CCL_RANGE, IN_INT_RANGE): Use it. |
| 960 | |
| 961 | * fileio.c: Don't assume EMACS_INT fits in off_t. |
| 962 | (emacs_lseek): New static function. |
| 963 | (Finsert_file_contents, Fwrite_region): Use it. |
| 964 | Use SEEK_SET, SEEK_CUR, SEEK_END as appropriate. |
| 965 | |
| 966 | * fns.c (Fload_average): Don't assume 100 * load average fits in int. |
| 967 | |
| 968 | * fns.c: Don't overflow int when computing a list length. |
| 969 | * fns.c (QUIT_COUNT_HEURISTIC): New constant. |
| 970 | (Flength, Fsafe_length): Use EMACS_INT, not int, to avoid unwanted |
| 971 | truncation on 64-bit hosts. Check for QUIT every |
| 972 | QUIT_COUNT_HEURISTIC entries rather than every other entry; that's |
| 973 | faster and is responsive enough. |
| 974 | (Flength): Report an error instead of overflowing an integer. |
| 975 | (Fsafe_length): Return a float if the value is not representable |
| 976 | as a fixnum. This shouldn't happen except in contrived situations. |
| 977 | (Fnthcdr, Fsort): Don't assume list length fits in int. |
| 978 | (Fcopy_sequence): Don't assume vector length fits in int. |
| 979 | |
| 980 | * alloc.c: Check that resized vectors' lengths fit in fixnums. |
| 981 | (header_size, word_size): New constants. |
| 982 | (allocate_vectorlike): Don't check size overflow here. |
| 983 | (allocate_vector): Check it here instead, since this is the only |
| 984 | caller of allocate_vectorlike that could cause overflow. |
| 985 | Check that the new vector's length is representable as a fixnum. |
| 986 | |
| 987 | * fns.c (next_almost_prime): Don't return a multiple of 3 or 5. |
| 988 | The previous code was bogus. For example, next_almost_prime (32) |
| 989 | returned 39, which is undesirable as it is a multiple of 3; and |
| 990 | next_almost_prime (24) returned 25, which is a multiple of 5 so |
| 991 | why was the code bothering to check for multiples of 7? |
| 992 | |
| 993 | * bytecode.c (exec_byte_code): Use ptrdiff_t, not int, for vector length. |
| 994 | |
| 995 | * eval.c, doprnt.c (SIZE_MAX): Remove; inttypes.h defines this now. |
| 996 | |
| 997 | Variadic C functions now count arguments with ptrdiff_t. |
| 998 | This partly undoes my 2011-03-30 change, which replaced int with size_t. |
| 999 | Back then I didn't know that the Emacs coding style prefers signed int. |
| 1000 | Also, in the meantime I found a few more instances where arguments |
| 1001 | were being counted with int, which may truncate counts on 64-bit |
| 1002 | machines, or EMACS_INT, which may be unnecessarily wide. |
| 1003 | * lisp.h (struct Lisp_Subr.function.aMANY) |
| 1004 | (DEFUN_ARGS_MANY, internal_condition_case_n, safe_call): |
| 1005 | Arg counts are now ptrdiff_t, not size_t. |
| 1006 | All variadic functions and their callers changed accordingly. |
| 1007 | (struct gcpro.nvars): Now size_t, not size_t. All uses changed. |
| 1008 | * bytecode.c (exec_byte_code): Check maxdepth for overflow, |
| 1009 | to avoid potential buffer overrun. Don't assume arg counts fit in 'int'. |
| 1010 | * callint.c (Fcall_interactively): Check arg count for overflow, |
| 1011 | to avoid potential buffer overrun. Use signed char, not 'int', |
| 1012 | for 'varies' array, so that we needn't bother to check its size |
| 1013 | calculation for overflow. |
| 1014 | * editfns.c (Fformat): Use ptrdiff_t, not EMACS_INT, to count args. |
| 1015 | * eval.c (apply_lambda): |
| 1016 | * fns.c (Fmapconcat): Use XFASTINT, not XINT, to get args length. |
| 1017 | (struct textprop_rec.argnum): Now ptrdiff_t, not int. All uses changed. |
| 1018 | (mapconcat): Use ptrdiff_t, not int and EMACS_INT, to count args. |
| 1019 | |
| 1020 | * callint.c (Fcall_interactively): Don't use index var as event count. |
| 1021 | |
| 1022 | * vm-limit.c (check_memory_limits): Fix incorrect extern function decls. |
| 1023 | * mem-limits.h (SIZE): Remove; no longer used. |
| 1024 | |
| 1025 | * xterm.c (x_alloc_nearest_color_1): Prefer int to long when int works. |
| 1026 | |
| 1027 | Remove unnecessary casts. |
| 1028 | * xterm.c (x_term_init): |
| 1029 | * xfns.c (x_set_border_pixel): |
| 1030 | * widget.c (create_frame_gcs): Remove casts to unsigned long etc. |
| 1031 | These aren't needed now that we assume ANSI C. |
| 1032 | |
| 1033 | * sound.c (Fplay_sound_internal): Remove cast to unsigned long. |
| 1034 | It's more likely to cause problems (due to unsigned overflow) |
| 1035 | than to cure them. |
| 1036 | |
| 1037 | * dired.c (Ffile_attributes): Don't use 32-bit hack on 64-bit hosts. |
| 1038 | |
| 1039 | * unexelf.c (unexec): Don't assume BSS addr fits in unsigned. |
| 1040 | |
| 1041 | * xterm.c (handle_one_xevent): Omit unnecessary casts to unsigned. |
| 1042 | |
| 1043 | * keyboard.c (modify_event_symbol): Don't limit alist len to UINT_MAX. |
| 1044 | |
| 1045 | * lisp.h (CHAR_TABLE_SET): Omit now-redundant test. |
| 1046 | |
| 1047 | * lread.c (Fload): Don't compare a possibly-garbage time_t value. |
| 1048 | |
| 1049 | GLYPH_CODE_FACE returns EMACS_INT, not int. |
| 1050 | * dispextern.h (merge_faces): |
| 1051 | * xfaces.c (merge_faces): |
| 1052 | * xdisp.c (get_next_display_element, next_element_from_display_vector): |
| 1053 | Don't assume EMACS_INT fits in int. |
| 1054 | |
| 1055 | * character.h (CHAR_VALID_P): Remove unused parameter. |
| 1056 | * fontset.c, lisp.h, xdisp.c: All uses changed. |
| 1057 | |
| 1058 | * editfns.c (Ftranslate_region_internal): Omit redundant test. |
| 1059 | |
| 1060 | * fns.c (concat): Minor tuning based on overflow analysis. |
| 1061 | This doesn't fix any bugs. Use int to hold character, instead |
| 1062 | of constantly refetching from Emacs object. Use XFASTINT, not |
| 1063 | XINT, for value known to be a character. Don't bother comparing |
| 1064 | a single byte to 0400, as it's always less. |
| 1065 | |
| 1066 | * floatfns.c (Fexpt): |
| 1067 | * fileio.c (make_temp_name): Omit unnecessary cast to unsigned. |
| 1068 | |
| 1069 | * editfns.c (Ftranslate_region_internal): Use int, not EMACS_INT |
| 1070 | for characters. |
| 1071 | |
| 1072 | * doc.c (get_doc_string): Omit (unsigned)c that mishandled negatives. |
| 1073 | |
| 1074 | * data.c (Faset): If ARRAY is a string, check that NEWELT is a char. |
| 1075 | Without this fix, on a 64-bit host (aset S 0 4294967386) would |
| 1076 | incorrectly succeed when S was a string, because 4294967386 was |
| 1077 | truncated before it was used. |
| 1078 | |
| 1079 | * chartab.c (Fchar_table_range): Use CHARACTERP to check range. |
| 1080 | Otherwise, an out-of-range integer could cause undefined behavior |
| 1081 | on a 64-bit host. |
| 1082 | |
| 1083 | * composite.c: Use int, not EMACS_INT, for characters. |
| 1084 | (fill_gstring_body, composition_compute_stop_pos): Use int, not |
| 1085 | EMACS_INT, for values that are known to be in character range. |
| 1086 | This doesn't fix any bugs but is the usual style inside Emacs and |
| 1087 | may generate better code on 32-bit machines. |
| 1088 | |
| 1089 | Make sure a 64-bit char is never passed to ENCODE_CHAR. |
| 1090 | This is for reasons similar to the recent CHAR_STRING fix. |
| 1091 | * charset.c (Fencode_char): Check that character arg is actually |
| 1092 | a character. Pass an int to ENCODE_CHAR. |
| 1093 | * charset.h (ENCODE_CHAR): Verify that the character argument is no |
| 1094 | wider than 'int', as a compile-time check to prevent future regressions |
| 1095 | in this area. |
| 1096 | |
| 1097 | * character.c (char_string): Remove unnecessary casts. |
| 1098 | |
| 1099 | Make sure a 64-bit char is never passed to CHAR_STRING. |
| 1100 | Otherwise, CHAR_STRING would do the wrong thing on a 64-bit platform, |
| 1101 | by silently ignoring the top 32 bits, allowing some values |
| 1102 | that were far too large to be valid characters. |
| 1103 | * character.h: Include <verify.h>. |
| 1104 | (CHAR_STRING, CHAR_STRING_ADVANCE): Verify that the character |
| 1105 | arguments are no wider than unsigned, as a compile-time check |
| 1106 | to prevent future regressions in this area. |
| 1107 | * data.c (Faset): |
| 1108 | * editfns.c (Fchar_to_string, general_insert_function, Finsert_char) |
| 1109 | (Fsubst_char_in_region): |
| 1110 | * fns.c (concat): |
| 1111 | * xdisp.c (decode_mode_spec_coding): |
| 1112 | Adjust to CHAR_STRING's new requirement. |
| 1113 | * editfns.c (Finsert_char, Fsubst_char_in_region): |
| 1114 | * fns.c (concat): Check that character args are actually |
| 1115 | characters. Without this test, these functions did the wrong |
| 1116 | thing with wildly out-of-range values on 64-bit hosts. |
| 1117 | |
| 1118 | Remove incorrect casts to 'unsigned' that lose info on 64-bit hosts. |
| 1119 | These casts should not be needed on 32-bit hosts, either. |
| 1120 | * keyboard.c (read_char): |
| 1121 | * lread.c (Fload): Remove casts to unsigned. |
| 1122 | |
| 1123 | * lisp.h (UNSIGNED_CMP): New macro. |
| 1124 | This fixes comparison bugs on 64-bit hosts. |
| 1125 | (ASCII_CHAR_P): Use it. |
| 1126 | * casefiddle.c (casify_object): |
| 1127 | * character.h (ASCII_BYTE_P, CHAR_VALID_P) |
| 1128 | (SINGLE_BYTE_CHAR_P, CHAR_STRING): |
| 1129 | * composite.h (COMPOSITION_ENCODE_RULE_VALID): |
| 1130 | * dispextern.h (FACE_FROM_ID): |
| 1131 | * keyboard.c (read_char): Use UNSIGNED_CMP. |
| 1132 | |
| 1133 | * xmenu.c (dialog_selection_callback) [!USE_GTK]: Cast to intptr_t, |
| 1134 | not to EMACS_INT, to avoid GCC warning. |
| 1135 | |
| 1136 | * xfns.c (x_set_scroll_bar_default_width): Remove unused 'int' locals. |
| 1137 | |
| 1138 | * buffer.h (PTR_BYTE_POS, BUF_PTR_BYTE_POS): Remove harmful cast. |
| 1139 | The cast incorrectly truncated 64-bit byte offsets to 32 bits, and |
| 1140 | isn't needed on 32-bit machines. |
| 1141 | |
| 1142 | * buffer.c (Fgenerate_new_buffer_name): |
| 1143 | Use EMACS_INT for count, not int. |
| 1144 | (advance_to_char_boundary): Return EMACS_INT, not int. |
| 1145 | |
| 1146 | * data.c (Qcompiled_function): Now static. |
| 1147 | |
| 1148 | * window.c (window_body_lines): Now static. |
| 1149 | |
| 1150 | * image.c (gif_load): Rename local to avoid shadowing. |
| 1151 | |
| 1152 | * lisp.h (SAFE_ALLOCA_LISP): Check for integer overflow. |
| 1153 | (struct Lisp_Save_Value): Use ptrdiff_t, not int, for 'integer' member. |
| 1154 | * alloc.c (make_save_value): Integer argument is now of type |
| 1155 | ptrdiff_t, not int. |
| 1156 | (mark_object): Use ptrdiff_t, not int. |
| 1157 | * lisp.h (pD): New macro. |
| 1158 | * print.c (print_object): Use it. |
| 1159 | |
| 1160 | * alloc.c: Use EMACS_INT, not int, to count objects. |
| 1161 | (total_conses, total_markers, total_symbols, total_vector_size) |
| 1162 | (total_free_conses, total_free_markers, total_free_symbols) |
| 1163 | (total_free_floats, total_floats, total_free_intervals) |
| 1164 | (total_intervals, total_strings, total_free_strings): |
| 1165 | Now EMACS_INT, not int. All uses changed. |
| 1166 | (Fgarbage_collect): Compute overall total using a double, so that |
| 1167 | integer overflow is less likely to be a problem. Check for overflow |
| 1168 | when converting back to an integer. |
| 1169 | (n_interval_blocks, n_string_blocks, n_float_blocks, n_cons_blocks) |
| 1170 | (n_vectors, n_symbol_blocks, n_marker_blocks): Remove. |
| 1171 | These were 'int' variables that could overflow on 64-bit hosts; |
| 1172 | they were never used, so remove them instead of repairing them. |
| 1173 | (nzombies, ngcs, max_live, max_zombies): Now EMACS_INT, not 'int'. |
| 1174 | (inhibit_garbage_collection): Set gc_cons_threshold to max value. |
| 1175 | Previously, this ceilinged at INT_MAX, but that doesn't work on |
| 1176 | 64-bit machines. |
| 1177 | (allocate_pseudovector): Don't use EMACS_INT when int would do. |
| 1178 | |
| 1179 | * alloc.c (Fmake_bool_vector): Don't assume vector size fits in int. |
| 1180 | (allocate_vectorlike): Check for ptrdiff_t overflow. |
| 1181 | (mark_vectorlike, mark_char_table, mark_object): Avoid EMACS_UINT |
| 1182 | when a (possibly-narrower) signed value would do just as well. |
| 1183 | We prefer using signed arithmetic, to avoid comparison confusion. |
| 1184 | |
| 1185 | * alloc.c: Catch some string size overflows that we were missing. |
| 1186 | (XMALLOC_OVERRUN_CHECK_SIZE) [!XMALLOC_OVERRUN_CHECK]: Define to 0, |
| 1187 | for convenience in STRING_BYTES_MAX. |
| 1188 | (STRING_BYTES_MAX): New macro, superseding the old one in lisp.h. |
| 1189 | The definition here is exact; the one in lisp.h was approximate. |
| 1190 | (allocate_string_data): Check for string overflow. This catches |
| 1191 | some instances we weren't catching before. Also, it catches |
| 1192 | size_t overflow on (unusual) hosts where SIZE_MAX <= min |
| 1193 | (PTRDIFF_MAX, MOST_POSITIVE_FIXNUM), e.g., when size_t is 32 bits |
| 1194 | and ptrdiff_t and EMACS_INT are both 64 bits. |
| 1195 | |
| 1196 | * character.c, coding.c, doprnt.c, editfns.c, eval.c: |
| 1197 | All uses of STRING_BYTES_MAX replaced by STRING_BYTES_BOUND. |
| 1198 | * lisp.h (STRING_BYTES_BOUND): Renamed from STRING_BYTES_MAX. |
| 1199 | |
| 1200 | * character.c (string_escape_byte8): Fix nbytes/nchars typo. |
| 1201 | |
| 1202 | * alloc.c (Fmake_string): Check for out-of-range init. |
| 1203 | |
| 1204 | 2011-06-15 Stefan Monnier <monnier@iro.umontreal.ca> |
| 1205 | |
| 1206 | * eval.c (Fdefvaralias): Also mark the target as variable-special-p. |
| 1207 | |
| 1208 | 2011-06-14 Jan Djärv <jan.h.d@swipnet.se> |
| 1209 | |
| 1210 | * xfns.c (x_set_scroll_bar_default_width): Remove argument to |
| 1211 | xg_get_default_scrollbar_width. |
| 1212 | |
| 1213 | * gtkutil.c: Include emacsgtkfixed.h if HAVE_GTK3. |
| 1214 | (int_gtk_range_get_value): Move to the scroll bar part of the file. |
| 1215 | (style_changed_cb): Call update_theme_scrollbar_width and call |
| 1216 | x_set_scroll_bar_default_width and xg_frame_set_char_size for |
| 1217 | all frames (Bug#8505). |
| 1218 | (xg_create_frame_widgets): Call emacs_fixed_new if HAVE_GTK3 (Bug#8505). |
| 1219 | Call gtk_window_set_resizable if HAVE_GTK3. |
| 1220 | (x_wm_set_size_hint): Call emacs_fixed_set_min_size with min width |
| 1221 | and height if HAVE_GTK3 (Bug#8505). |
| 1222 | (scroll_bar_width_for_theme): New variable. |
| 1223 | (update_theme_scrollbar_width): New function. |
| 1224 | (xg_get_default_scrollbar_width): Move code to |
| 1225 | update_theme_scrollbar_width, just return scroll_bar_width_for_theme. |
| 1226 | (xg_initialize): Call update_theme_scrollbar_width. |
| 1227 | |
| 1228 | * gtkutil.h (xg_get_default_scrollbar_width): Remove argument. |
| 1229 | |
| 1230 | * emacsgtkfixed.c, emacsgtkfixed.h: New files. |
| 1231 | |
| 1232 | 2011-06-12 Martin Rudalics <rudalics@gmx.at> |
| 1233 | |
| 1234 | * frame.c (make_frame): Call other_buffer_safely instead of |
| 1235 | other_buffer. |
| 1236 | |
| 1237 | * window.c (temp_output_buffer_show): Call display_buffer with |
| 1238 | second argument Vtemp_buffer_show_specifiers and reset latter |
| 1239 | immediately after the call. |
| 1240 | (Vtemp_buffer_show_specifiers): New variable. |
| 1241 | (auto_window_vscroll_p, next_screen_context_lines) |
| 1242 | (Vscroll_preserve_screen_position): Remove leading asterisks from |
| 1243 | doc-strings. |
| 1244 | |
| 1245 | 2011-06-12 Paul Eggert <eggert@cs.ucla.edu> |
| 1246 | |
| 1247 | Fix minor problems found by GCC 4.6.0 static checking. |
| 1248 | * buffer.c (Qclone_number): Remove for now, as it's unused. |
| 1249 | (record_buffer, Funrecord_buffer): Rename local to avoid shadowing. |
| 1250 | (record_buffer): Remove unused local. |
| 1251 | * frame.c (other_visible_frames, frame_buffer_list): Now static. |
| 1252 | (set_frame_buffer_list): Remove; unused. |
| 1253 | * frame.h (other_visible_frames): Remove decl. |
| 1254 | * keyboard.h (menu_items_inuse): Declare only if USE_GTK || USE_MOTIF. |
| 1255 | * lisp.h (frame_buffer_list, set_frame_buffer_list): Remove decls. |
| 1256 | (add_gpm_wait_descriptor, delete_gpm_wait_descriptor): Declare only |
| 1257 | if HAVE_GPM. |
| 1258 | * menu.c (menu_items_inuse): Now static unless USE_GTK || USE_MOTIF. |
| 1259 | * process.c (add_gpm_wait_descriptor, delete_gpm_wait_descriptor): |
| 1260 | Define only if HAVE_GPM. |
| 1261 | * widget.c (EmacsFrameResize, emacsFrameClassRec): Now static. |
| 1262 | (update_hints_inhibit): Remove; never set. All uses removed. |
| 1263 | * widgetprv.h (emacsFrameClassRec): Remove decl. |
| 1264 | * window.c (delete_deletable_window): Now returns void, since it |
| 1265 | wasn't returning anything. |
| 1266 | (compare_window_configurations): Remove unused locals. |
| 1267 | * xfns.c (x_set_scroll_bar_default_width): Remove unused locals. |
| 1268 | * xmenu.c (x_menu_set_in_use): Define only if USE_GTK || USE_MOTIF. |
| 1269 | (dialog_selection_callback) [!USE_GTK]: Prefer intptr_t for integers |
| 1270 | the same widths as pointers. This follows up on the 2011-05-06 patch. |
| 1271 | * xterm.c (x_alloc_lighter_color_for_widget): Define only if USE_LUCID. |
| 1272 | * xterm.h: Likewise. |
| 1273 | (x_menu_set_in_use): Declare only if USE_GTK || USE_MOTIF. |
| 1274 | |
| 1275 | 2011-06-12 Juanma Barranquero <lekktu@gmail.com> |
| 1276 | |
| 1277 | * makefile.w32-in: Update dependencies. |
| 1278 | (LISP_H): Add lib/intprops.h. |
| 1279 | |
| 1280 | 2011-06-11 Chong Yidong <cyd@stupidchicken.com> |
| 1281 | |
| 1282 | * image.c (gif_load): Add animation frame delay to the metadata. |
| 1283 | (syms_of_image): Use DEFSYM. New symbol `delay'. |
| 1284 | |
| 1285 | 2011-06-11 Martin Rudalics <rudalics@gmx.at> |
| 1286 | |
| 1287 | * window.c (delete_deletable_window): Re-add. |
| 1288 | (Fset_window_configuration): Rewrite to handle dead buffers and |
| 1289 | consequently deletable windows. |
| 1290 | (window_tree, Fwindow_tree): Remove. Supply functionality in |
| 1291 | window.el. |
| 1292 | (compare_window_configurations): Simplify code. |
| 1293 | |
| 1294 | 2011-06-11 Andreas Schwab <schwab@linux-m68k.org> |
| 1295 | |
| 1296 | * image.c (imagemagick_load_image): Fix type mismatch. |
| 1297 | (Fimagemagick_types): Likewise. |
| 1298 | |
| 1299 | * window.h (replace_buffer_in_windows): Declare. |
| 1300 | |
| 1301 | 2011-06-11 Martin Rudalics <rudalics@gmx.at> |
| 1302 | |
| 1303 | * buffer.c: New Lisp objects Qbuffer_list_update_hook and |
| 1304 | Qclone_number. Remove external declaration of Qdelete_window. |
| 1305 | (Fbuffer_list): Rewrite doc-string. Minor restructuring of |
| 1306 | code. |
| 1307 | (Fget_buffer_create, Fmake_indirect_buffer, Frename_buffer): Run |
| 1308 | Qbuffer_list_update_hook if allowed. |
| 1309 | (Fother_buffer): Rewrite doc-string. Major rewrite for new |
| 1310 | buffer list implementation. |
| 1311 | (other_buffer_safely): New function. |
| 1312 | (Fkill_buffer): Replace call to replace_buffer_in_all_windows by |
| 1313 | calls to replace_buffer_in_windows and |
| 1314 | replace_buffer_in_windows_safely. Run Qbuffer_list_update_hook |
| 1315 | if allowed. |
| 1316 | (record_buffer): Inhibit quitting and rewrite using quittable |
| 1317 | functions. Run Qbuffer_list_update_hook if allowed. |
| 1318 | (Frecord_buffer, Funrecord_buffer): New functions. |
| 1319 | (switch_to_buffer_1, Fswitch_to_buffer): Remove. Move |
| 1320 | switch-to-buffer to window.el. |
| 1321 | (bury-buffer): Move to window.el. |
| 1322 | (Vbuffer_list_update_hook): New variable. |
| 1323 | |
| 1324 | * lisp.h (other_buffer_safely): Add prototype in buffer.c |
| 1325 | section. |
| 1326 | |
| 1327 | * window.h (resize_frame_windows): Move up in code. |
| 1328 | (Fwindow_frame): Remove EXFUN. |
| 1329 | (replace_buffer_in_all_windows): Remove prototype. |
| 1330 | (replace_buffer_in_windows_safely): Add prototype. |
| 1331 | |
| 1332 | * window.c: Declare Qdelete_window static again. Move down |
| 1333 | declaration of select_count. |
| 1334 | (Fnext_window, Fprevious_window): Rewrite doc-strings. |
| 1335 | (Fother_window): Move to window.el. |
| 1336 | (window_loop): Remove DELETE_BUFFER_WINDOWS and UNSHOW_BUFFER |
| 1337 | cases. Add REPLACE_BUFFER_IN_WINDOWS_SAFELY case. |
| 1338 | (Fdelete_windows_on, Freplace_buffer_in_windows): Move to |
| 1339 | window.el. |
| 1340 | (replace_buffer_in_windows): Implement by calling |
| 1341 | Qreplace_buffer_in_windows. |
| 1342 | (replace_buffer_in_all_windows): Remove with some functionality |
| 1343 | moved into replace_buffer_in_windows_safely. |
| 1344 | (replace_buffer_in_windows_safely): New function. |
| 1345 | (select_window_norecord, select_frame_norecord): Move in front |
| 1346 | of run_window_configuration_change_hook. Remove now obsolete |
| 1347 | declarations. |
| 1348 | (Fset_window_buffer): Rewrite doc-string. Call |
| 1349 | Qrecord_window_buffer. |
| 1350 | (keys_of_window): Move binding for other-window to window.el. |
| 1351 | |
| 1352 | 2011-06-11 Chong Yidong <cyd@stupidchicken.com> |
| 1353 | |
| 1354 | * dispextern.h (struct image): Replace data member, whose int_val |
| 1355 | and ptr_val fields were not used by anything, with a single |
| 1356 | lisp_val object. |
| 1357 | |
| 1358 | * image.c (Fimage_metadata, make_image, mark_image, tiff_load) |
| 1359 | (gif_clear_image, gif_load, imagemagick_load_image) |
| 1360 | (gs_clear_image, gs_load): Callers changed. |
| 1361 | |
| 1362 | 2011-06-10 Paul Eggert <eggert@cs.ucla.edu> |
| 1363 | |
| 1364 | * buffer.h: Include <time.h>, for time_t. |
| 1365 | Needed to build on FreeBSD 8.2. Problem reported by Herbert J. Skuhra. |
| 1366 | |
| 1367 | Fix minor problems found by static checking. |
| 1368 | |
| 1369 | * image.c (PixelGetMagickColor): Declare if ImageMagick headers don't. |
| 1370 | |
| 1371 | Make identifiers static if they are not used in other modules. |
| 1372 | * data.c (Qcompiled_function, Qframe, Qvector): |
| 1373 | * image.c (QimageMagick, Qsvg): |
| 1374 | * minibuf.c (Qmetadata): |
| 1375 | * window.c (resize_window_check, resize_root_window): Now static. |
| 1376 | * window.h (resize_window_check, resize_root_window): Remove decls. |
| 1377 | |
| 1378 | * window.c (window_deletion_count, delete_deletable_window): |
| 1379 | Remove; unused. |
| 1380 | (window_body_lines): Now static. |
| 1381 | (Fdelete_other_windows_internal): Mark vars as initialized. |
| 1382 | Make sure 'resize_failed' is initialized. |
| 1383 | (run_window_configuration_change_hook): Rename local to avoid shadowing. |
| 1384 | (resize_window_apply): Remove unused local. |
| 1385 | * window.h (delete_deletable_window): Remove decl. |
| 1386 | |
| 1387 | * image.c (gif_load, svg_load_image): Rename locals to avoid shadowing. |
| 1388 | (imagemagick_load_image): Fix pointer signedness problem by changing |
| 1389 | last arg from unsigned char * to char *. All uses changed. |
| 1390 | Also, fix a local for similar reasons. |
| 1391 | Remove unused locals. Remove locals to avoid shadowing. |
| 1392 | (fn_rsvg_handle_free): Remove; unused. |
| 1393 | (svg_load, svg_load_image): Fix pointer signedness problem. |
| 1394 | (imagemagick_load_image): Don't use garbage pointer image_wand. |
| 1395 | |
| 1396 | * ftfont.c (ftfont_get_metrics, ftfont_drive_otf): Remove unused locals. |
| 1397 | |
| 1398 | 2011-06-10 Chong Yidong <cyd@stupidchicken.com> |
| 1399 | |
| 1400 | * image.c (gif_load): Fix omitted cast error introduced by |
| 1401 | 2011-06-06 change. |
| 1402 | |
| 1403 | 2011-06-10 Martin Rudalics <rudalics@gmx.at> |
| 1404 | |
| 1405 | * window.h (resize_proportionally, orig_total_lines) |
| 1406 | (orig_top_line): Remove from window structure. |
| 1407 | (set_window_height, set_window_width, change_window_heights) |
| 1408 | (Fdelete_window): Remove prototypes. |
| 1409 | (resize_frame_windows): Remove duplicate declaration. |
| 1410 | |
| 1411 | 2011-06-10 Eli Zaretskii <eliz@gnu.org> |
| 1412 | |
| 1413 | * window.h (resize_frame_windows, resize_window_check) |
| 1414 | (delete_deletable_window, resize_root_window) |
| 1415 | (resize_frame_windows): Declare prototypes. |
| 1416 | |
| 1417 | * window.c (resize_window_apply): Make definition be "static" to |
| 1418 | match the prototype. |
| 1419 | |
| 1420 | 2011-06-10 Martin Rudalics <rudalics@gmx.at> |
| 1421 | |
| 1422 | * window.c: Remove declarations of Qwindow_size_fixed, |
| 1423 | window_min_size_1, window_min_size_2, window_min_size, |
| 1424 | size_window, window_fixed_size_p, enlarge_window, delete_window. |
| 1425 | Remove static from declaration of Qdelete_window, it's |
| 1426 | temporarily needed by Fbury_buffer. |
| 1427 | (replace_window): Don't assign orig_top_line and |
| 1428 | orig_total_lines. |
| 1429 | (Fdelete_window, delete_window): Remove. Window deletion is |
| 1430 | handled by window.el. |
| 1431 | (window_loop): Remove DELETE_OTHER_WINDOWS case. Replace |
| 1432 | Fdelete_window calls with calls to Qdelete_window. |
| 1433 | (Fdelete_other_windows): Remove. Deleting other windows is |
| 1434 | handled by window.el. |
| 1435 | (window_fixed_size_p): Remove. Fixed-sizeness of windows is |
| 1436 | handled in window.el. |
| 1437 | (window_min_size_2, window_min_size_1, window_min_size): Remove. |
| 1438 | Window minimum sizes are handled in window.el. |
| 1439 | (shrink_windows, size_window, set_window_height) |
| 1440 | (set_window_width, change_window_heights, window_height) |
| 1441 | (window_width, CURBEG, CURSIZE, enlarge_window) |
| 1442 | (adjust_window_trailing_edge, Fadjust_window_trailing_edge) |
| 1443 | (Fenlarge_window, Fshrink_window): Remove. Window resizing is |
| 1444 | handled in window.el. |
| 1445 | (make_dummy_parent): Rename to make_parent_window and give it a |
| 1446 | second argument horflag. |
| 1447 | (make_window): Don't set resize_proportionally any more. |
| 1448 | (Fsplit_window): Remove. Windows are split in window.el. |
| 1449 | (save_restore_action, save_restore_orig_size) |
| 1450 | (shrink_window_lowest_first, save_restore_orig_size): Remove. |
| 1451 | Resize mini windows in window.el. |
| 1452 | (grow_mini_window, shrink_mini_window): Implement by calling |
| 1453 | Qresize_root_window_vertically, resize_window_check and |
| 1454 | resize_window_apply. |
| 1455 | (saved_window, Fset_window_configuration, save_window_save): Do |
| 1456 | not handle orig_top_line, orig_total_lines, and |
| 1457 | resize_proportionally. |
| 1458 | (window_min_height, window_min_width): Move to window.el. |
| 1459 | (keys_of_window): Move bindings for delete-other-windows, |
| 1460 | split-window, delete-window and enlarge-window to window.el. |
| 1461 | |
| 1462 | * buffer.c: Temporarily extern Qdelete_window. |
| 1463 | (Fbury_buffer): Temporarily call Qdelete_window instead of |
| 1464 | Fdelete_window (Fbury_buffer will move to window.el soon). |
| 1465 | |
| 1466 | * frame.c (set_menu_bar_lines_1): Remove code handling |
| 1467 | orig_top_line and orig_total_lines. |
| 1468 | |
| 1469 | * dispnew.c (adjust_frame_glyphs_initially): Don't use |
| 1470 | set_window_height but set heights directly. |
| 1471 | (change_frame_size_1): Use resize_frame_windows. |
| 1472 | |
| 1473 | * xdisp.c (init_xdisp): Don't use set_window_height but set |
| 1474 | heights directly. |
| 1475 | |
| 1476 | * xfns.c (x_set_menu_bar_lines, x_set_tool_bar_lines): Use |
| 1477 | resize_frame_windows instead of change_window_heights and run |
| 1478 | run_window_configuration_change_hook. |
| 1479 | |
| 1480 | * w32fns.c (x_set_tool_bar_lines): Use resize_frame_windows |
| 1481 | instead of change_window_heights and run |
| 1482 | run_window_configuration_change_hook. |
| 1483 | |
| 1484 | 2011-06-09 Martin Rudalics <rudalics@gmx.at> |
| 1485 | |
| 1486 | * window.c (replace_window): Rename second argument REPLACEMENT to |
| 1487 | NEW. New third argument SETFLAG. Rewrite. |
| 1488 | (delete_window, make_dummy_parent): Call replace_window with |
| 1489 | third argument 1. |
| 1490 | (window_list_1): Move down in code. |
| 1491 | (run_window_configuration_change_hook): Move set_buffer part |
| 1492 | before select_frame_norecord part in order to unwind correctly. |
| 1493 | Rename count1 to count. |
| 1494 | (recombine_windows, delete_deletable_window, resize_root_window) |
| 1495 | (Fdelete_other_windows_internal) |
| 1496 | (Frun_window_configuration_change_hook, make_parent_window) |
| 1497 | (resize_window_check, resize_window_apply, Fresize_window_apply) |
| 1498 | (resize_frame_windows, Fsplit_window_internal) |
| 1499 | (Fdelete_window_internal, Fresize_mini_window_internal): New |
| 1500 | functions. |
| 1501 | (syms_of_window): New variables Vwindow_splits and Vwindow_nest. |
| 1502 | |
| 1503 | 2011-06-08 Martin Rudalics <rudalics@gmx.at> |
| 1504 | |
| 1505 | * window.h (window): Add some new members to window structure - |
| 1506 | normal_lines, normal_cols, new_total, new_normal, clone_number, |
| 1507 | splits, nest, prev_buffers, next_buffers. |
| 1508 | (WINDOW_TOTAL_SIZE): Move here from window.c. |
| 1509 | (MIN_SAFE_WINDOW_WIDTH, MIN_SAFE_WINDOW_HEIGHT): Define here. |
| 1510 | |
| 1511 | * window.c (Fwindow_height, Fwindow_width, Fwindow_full_width_p): |
| 1512 | Remove. |
| 1513 | (make_dummy_parent): Set new members of windows structure. |
| 1514 | (make_window): Move down in code. Handle new members of window |
| 1515 | structure. |
| 1516 | (Fwindow_clone_number, Fwindow_splits, Fset_window_splits) |
| 1517 | (Fwindow_nest, Fset_window_nest, Fwindow_new_total) |
| 1518 | (Fwindow_normal_size, Fwindow_new_normal, Fwindow_prev_buffers) |
| 1519 | (Fset_window_prev_buffers, Fwindow_next_buffers) |
| 1520 | (Fset_window_next_buffers, Fset_window_clone_number): New |
| 1521 | functions. |
| 1522 | (Fwindow_hscroll, Fwindow_at, Fwindow_point, Fwindow_start) |
| 1523 | (Fwindow_end, Fwindow_line_height, Fset_window_dedicated_p): |
| 1524 | Doc-string fixes. |
| 1525 | (Fwindow_parameters, Fwindow_parameter, Fset_window_parameter): |
| 1526 | Argument WINDOW can be now internal window too. |
| 1527 | (Fwindow_use_time): Move up in code. |
| 1528 | (Fget_buffer_window): Rename argument FRAME to ALL-FRAMES. |
| 1529 | Rewrite doc-string. |
| 1530 | (Fset_window_configuration, saved_window) |
| 1531 | (Fcurrent_window_configuration, save_window_save): Handle new |
| 1532 | members of window structure. |
| 1533 | (WINDOW_TOTAL_SIZE, MIN_SAFE_WINDOW_WIDTH) |
| 1534 | (MIN_SAFE_WINDOW_HEIGHT): Move to window.h. |
| 1535 | (syms_of_window): New Lisp objects Qrecord_window_buffer, |
| 1536 | Qwindow_deletable_p, Qdelete_window, Qreplace_buffer_in_windows, |
| 1537 | Qget_mru_window, Qresize_root_window, |
| 1538 | Qresize_root_window_vertically, Qsafe, Qabove, Qbelow, |
| 1539 | Qauto_buffer_name; staticpro them. |
| 1540 | |
| 1541 | 2011-06-07 Martin Rudalics <rudalics@gmx.at> |
| 1542 | |
| 1543 | * window.c (Fwindow_total_size, Fwindow_left_column) |
| 1544 | (Fwindow_top_line, window_body_lines, Fwindow_body_size) |
| 1545 | (Fwindow_list_1): New functions. |
| 1546 | (window_box_text_cols): Replace with window_body_cols. |
| 1547 | (Fwindow_width, Fscroll_left, Fscroll_right): Use |
| 1548 | window_body_cols instead of window_box_text_cols. |
| 1549 | (delete_window, Fset_window_configuration): Call |
| 1550 | delete_all_subwindows with window as argument. |
| 1551 | (delete_all_subwindows): Take a window as argument and not a |
| 1552 | structure. Rewrite. |
| 1553 | (window_loop): Remove handling of GET_LRU_WINDOW and |
| 1554 | GET_LARGEST_WINDOW. |
| 1555 | (Fget_lru_window, Fget_largest_window): Move to window.el. |
| 1556 | |
| 1557 | * window.h: Extern window_body_cols instead of |
| 1558 | window_box_text_cols. delete_all_subwindows now takes a |
| 1559 | Lisp_Object as argument. |
| 1560 | |
| 1561 | * indent.c (compute_motion, Fcompute_motion): Use |
| 1562 | window_body_cols instead of window_box_text_cols. |
| 1563 | |
| 1564 | * frame.c (delete_frame): Call delete_all_subwindows with root |
| 1565 | window as argument. |
| 1566 | |
| 1567 | 2011-06-07 Daniel Colascione <dan.colascione@gmail.com> |
| 1568 | |
| 1569 | * fns.c (Fputhash): Document return value. |
| 1570 | |
| 1571 | 2011-06-06 Chong Yidong <cyd@stupidchicken.com> |
| 1572 | |
| 1573 | * image.c (gif_load): Implement gif89a spec "no disposal" method. |
| 1574 | |
| 1575 | 2011-06-06 Paul Eggert <eggert@cs.ucla.edu> |
| 1576 | |
| 1577 | Cons<->int and similar integer overflow fixes (Bug#8794). |
| 1578 | |
| 1579 | Check for overflow when converting integer to cons and back. |
| 1580 | * charset.c (Fdefine_charset_internal, Fdecode_char): |
| 1581 | Use cons_to_unsigned to catch overflow. |
| 1582 | (Fencode_char): Use INTEGER_TO_CONS. |
| 1583 | * composite.h (LGLYPH_CODE): Use cons_to_unsigned. |
| 1584 | (LGLYPH_SET_CODE): Use INTEGER_TO_CONS. |
| 1585 | * data.c (long_to_cons, cons_to_long): Remove. |
| 1586 | (cons_to_unsigned, cons_to_signed): New functions. |
| 1587 | These signal an error for invalid or out-of-range values. |
| 1588 | * dired.c (Ffile_attributes): Use INTEGER_TO_CONS. |
| 1589 | * fileio.c (Fset_visited_file_modtime): Use CONS_TO_INTEGER. |
| 1590 | * font.c (Ffont_variation_glyphs): |
| 1591 | * fontset.c (Finternal_char_font): Use INTEGER_TO_CONS. |
| 1592 | * lisp.h: Include <intprops.h>. |
| 1593 | (INTEGER_TO_CONS, CONS_TO_INTEGER): New macros. |
| 1594 | (cons_to_signed, cons_to_unsigned): New decls. |
| 1595 | (long_to_cons, cons_to_long): Remove decls. |
| 1596 | * undo.c (record_first_change): Use INTEGER_TO_CONS. |
| 1597 | (Fprimitive_undo): Use CONS_TO_INTEGER. |
| 1598 | * xfns.c (Fx_window_property): Likewise. |
| 1599 | * xselect.c: Include <limits.h>. |
| 1600 | (x_own_selection, selection_data_to_lisp_data): |
| 1601 | Use INTEGER_TO_CONS. |
| 1602 | (x_handle_selection_request, x_handle_selection_clear) |
| 1603 | (x_get_foreign_selection, Fx_disown_selection_internal) |
| 1604 | (Fx_get_atom_name, x_send_client_event): Use CONS_TO_INTEGER. |
| 1605 | (lisp_data_to_selection_data): Use cons_to_unsigned. |
| 1606 | (x_fill_property_data): Use cons_to_signed. |
| 1607 | Report values out of range. |
| 1608 | |
| 1609 | Check for buffer and string overflow more precisely. |
| 1610 | * buffer.h (BUF_BYTES_MAX): New macro. |
| 1611 | * lisp.h (STRING_BYTES_MAX): New macro. |
| 1612 | * alloc.c (Fmake_string): |
| 1613 | * character.c (string_escape_byte8): |
| 1614 | * coding.c (coding_alloc_by_realloc): |
| 1615 | * doprnt.c (doprnt): |
| 1616 | * editfns.c (Fformat): |
| 1617 | * eval.c (verror): |
| 1618 | Use STRING_BYTES_MAX, not MOST_POSITIVE_FIXNUM, |
| 1619 | since they may not be the same number. |
| 1620 | * editfns.c (Finsert_char): |
| 1621 | * fileio.c (Finsert_file_contents): |
| 1622 | Likewise for BUF_BYTES_MAX. |
| 1623 | |
| 1624 | * image.c: Use ptrdiff_t, not int, for sizes. |
| 1625 | (slurp_file): Switch from int to ptrdiff_t. |
| 1626 | All uses changed. |
| 1627 | (slurp_file): Check that file size fits in both size_t (for |
| 1628 | malloc) and ptrdiff_t (for sanity and safety). |
| 1629 | |
| 1630 | * fileio.c (Fverify_visited_file_modtime): Avoid time overflow |
| 1631 | if b->modtime has its maximal value. |
| 1632 | |
| 1633 | * dired.c (Ffile_attributes): Don't assume EMACS_INT has >32 bits. |
| 1634 | |
| 1635 | Don't assume time_t can fit into int. |
| 1636 | * buffer.h (struct buffer.modtime): Now time_t, not int. |
| 1637 | * fileio.c (Fvisited_file_modtime): No need for time_t cast now. |
| 1638 | * undo.c (Fprimitive_undo): Use time_t, not int, for time_t value. |
| 1639 | |
| 1640 | Minor fixes for signed vs unsigned integers. |
| 1641 | * character.h (MAYBE_UNIFY_CHAR): |
| 1642 | * charset.c (maybe_unify_char): |
| 1643 | * keyboard.c (read_char, reorder_modifiers): |
| 1644 | XINT -> XFASTINT, since the integer must be nonnegative. |
| 1645 | * ftfont.c (ftfont_spec_pattern): |
| 1646 | * keymap.c (access_keymap, silly_event_symbol_error): |
| 1647 | XUINT -> XFASTINT, since the integer must be nonnegative. |
| 1648 | (Fsingle_key_description, preferred_sequence_p): XUINT -> XINT, |
| 1649 | since it makes no difference and we prefer signed. |
| 1650 | * keyboard.c (record_char): Use XUINT when all the neighbors do. |
| 1651 | (access_keymap): NATNUMP -> INTEGERP, since the integer must be |
| 1652 | nonnegative. |
| 1653 | |
| 1654 | 2011-06-06 Stefan Monnier <monnier@iro.umontreal.ca> |
| 1655 | |
| 1656 | * window.h (Fwindow_frame): Declare. |
| 1657 | |
| 1658 | 2011-06-06 Paul Eggert <eggert@cs.ucla.edu> |
| 1659 | |
| 1660 | * alloc.c: Simplify handling of large-request failures (Bug#8800). |
| 1661 | (SPARE_MEMORY): Always define. |
| 1662 | (LARGE_REQUEST): Remove. |
| 1663 | (memory_full): Use SPARE_MEMORY rather than LARGE_REQUEST. |
| 1664 | |
| 1665 | 2011-06-06 Martin Rudalics <rudalics@gmx.at> |
| 1666 | |
| 1667 | * lisp.h: Move EXFUNS for Fframe_root_window, |
| 1668 | Fframe_first_window and Fset_frame_selected_window to window.h. |
| 1669 | |
| 1670 | * window.h: Move EXFUNS for Fframe_root_window, |
| 1671 | Fframe_first_window and Fset_frame_selected_window here from |
| 1672 | lisp.h. |
| 1673 | |
| 1674 | * frame.c (Fwindow_frame, Fframe_first_window) |
| 1675 | (Fframe_root_window, Fframe_selected_window) |
| 1676 | (Fset_frame_selected_window): Move to window.c. |
| 1677 | (Factive_minibuffer_window): Move to minibuf.c. |
| 1678 | (Fother_visible_frames_p): New function. |
| 1679 | |
| 1680 | * minibuf.c (Factive_minibuffer_window): Move here from frame.c. |
| 1681 | |
| 1682 | * window.c (decode_window, decode_any_window): Move up in code. |
| 1683 | (Fwindowp, Fwindow_live_p): Rewrite doc-strings. |
| 1684 | (inhibit_frame_unsplittable): Remove unused variable. |
| 1685 | (Fwindow_buffer): Move up and rewrite doc-string. |
| 1686 | (Fwindow_parent, Fwindow_vchild, Fwindow_hchild, Fwindow_next) |
| 1687 | (Fwindow_prev): New functions. |
| 1688 | (Fwindow_frame): Move here from frame.c. Accept any window as |
| 1689 | argument. |
| 1690 | (Fframe_root_window, Fframe_first_window) |
| 1691 | (Fframe_selected_window): Move here from frame.c. Accept frame |
| 1692 | or arbitrary window as argument. Update doc-strings. |
| 1693 | (Fminibuffer_window): Move up in code. |
| 1694 | (Fwindow_minibuffer_p): Move up in code and simplify. |
| 1695 | (Fset_frame_selected_window): Move here from frame.c. |
| 1696 | Marginal rewrite. |
| 1697 | (Fselected_window, select_window, Fselect_window): Move up in |
| 1698 | code. Minor doc-string fixes. |
| 1699 | |
| 1700 | 2011-06-06 Paul Eggert <eggert@cs.ucla.edu> |
| 1701 | |
| 1702 | * alloc.c (memory_full) [SYSTEM_MALLOC]: Port to MacOS (Bug#8800). |
| 1703 | Do not assume that spare memory exists; that assumption is valid |
| 1704 | only if SYSTEM_MALLOC. |
| 1705 | (LARGE_REQUEST): New macro, so that the issue of large requests |
| 1706 | is separated from the issue of spare memory. |
| 1707 | |
| 1708 | 2011-06-05 Andreas Schwab <schwab@linux-m68k.org> |
| 1709 | |
| 1710 | * editfns.c (Fformat): Correctly handle zero flag with hexadecimal |
| 1711 | format. (Bug#8806) |
| 1712 | |
| 1713 | * gtkutil.c (xg_get_default_scrollbar_width): Avoid warning. |
| 1714 | |
| 1715 | * xfns.c (x_set_scroll_bar_default_width): Move declarations |
| 1716 | before statements. |
| 1717 | |
| 1718 | 2011-06-05 Jan Djärv <jan.h.d@swipnet.se> |
| 1719 | |
| 1720 | * gtkutil.c (xg_get_default_scrollbar_width): New function. |
| 1721 | |
| 1722 | * gtkutil.h: Declare xg_get_default_scrollbar_width. |
| 1723 | |
| 1724 | * xfns.c (x_set_scroll_bar_default_width): If USE_GTK, get |
| 1725 | min width by calling x_set_scroll_bar_default_width (Bug#8505). |
| 1726 | |
| 1727 | 2011-06-05 Juanma Barranquero <lekktu@gmail.com> |
| 1728 | |
| 1729 | * xdisp.c (single_display_spec_intangible_p): Remove declaration. |
| 1730 | |
| 1731 | 2011-06-04 Chong Yidong <cyd@stupidchicken.com> |
| 1732 | |
| 1733 | * xselect.c (x_clipboard_manager_save): Remove redundant arg. |
| 1734 | (x_clipboard_manager_save): Add return value. |
| 1735 | (x_clipboard_manager_error_1, x_clipboard_manager_error_2): |
| 1736 | New error handlers. |
| 1737 | (x_clipboard_manager_save_frame, x_clipboard_manager_save_all): |
| 1738 | Obey Vx_select_enable_clipboard_manager. Catch errors in |
| 1739 | x_clipboard_manager_save (Bug#8779). |
| 1740 | (Vx_select_enable_clipboard_manager): New variable. |
| 1741 | (x_get_foreign_selection): Reduce scope of x_catch_errors (Bug#8790). |
| 1742 | |
| 1743 | 2011-06-04 Dan Nicolaescu <dann@ics.uci.edu> |
| 1744 | |
| 1745 | * emacs.c (main): Warn when starting a GTK emacs in daemon mode. |
| 1746 | |
| 1747 | 2011-06-04 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
| 1748 | |
| 1749 | * fringe.c (update_window_fringes): Don't update overlay arrow bitmap |
| 1750 | in the current matrix if keep_current_p is non-zero. |
| 1751 | |
| 1752 | 2011-06-04 Eli Zaretskii <eliz@gnu.org> |
| 1753 | |
| 1754 | * bidi.c (bidi_level_of_next_char): Fix last change. |
| 1755 | |
| 1756 | 2011-06-03 Eli Zaretskii <eliz@gnu.org> |
| 1757 | |
| 1758 | Support bidi reordering of text covered by display properties. |
| 1759 | |
| 1760 | * bidi.c (bidi_copy_it): Use offsetof instead of emulating it. |
| 1761 | (bidi_fetch_char, bidi_fetch_char_advance): New functions. |
| 1762 | (bidi_cache_search, bidi_cache_iterator_state) |
| 1763 | (bidi_paragraph_init, bidi_resolve_explicit, bidi_resolve_weak) |
| 1764 | (bidi_level_of_next_char, bidi_move_to_visually_next): |
| 1765 | Support character positions inside a run of characters covered by a |
| 1766 | display string. |
| 1767 | (bidi_paragraph_init, bidi_resolve_explicit_1) |
| 1768 | (bidi_level_of_next_char): Call bidi_fetch_char and |
| 1769 | bidi_fetch_char_advance instead of FETCH_CHAR and |
| 1770 | FETCH_CHAR_ADVANCE. |
| 1771 | (bidi_init_it): Initialize new members. |
| 1772 | (LRE_CHAR, RLE_CHAR, PDF_CHAR, LRO_CHAR, RLO_CHAR): Remove macro |
| 1773 | definitions. |
| 1774 | (bidi_explicit_dir_char): Lookup character type in bidi_type_table, |
| 1775 | instead of using explicit *_CHAR codes. |
| 1776 | (bidi_resolve_explicit, bidi_resolve_weak): |
| 1777 | Use FETCH_MULTIBYTE_CHAR instead of FETCH_CHAR, as reordering of |
| 1778 | bidirectional text is supported only in multibyte buffers. |
| 1779 | (bidi_init_it): Accept additional argument FRAME_WINDOW_P and use |
| 1780 | it to initialize the frame_window_p member of struct bidi_it. |
| 1781 | (bidi_cache_iterator_state, bidi_resolve_explicit_1) |
| 1782 | (bidi_resolve_explicit, bidi_resolve_weak) |
| 1783 | (bidi_level_of_next_char, bidi_move_to_visually_next): Abort if |
| 1784 | bidi_it->nchars is non-positive. |
| 1785 | (bidi_level_of_next_char): Don't try to lookup the cache for the |
| 1786 | next/previous character if nothing is cached there yet, or if we |
| 1787 | were just reseat()'ed to a new position. |
| 1788 | |
| 1789 | * xdisp.c (set_cursor_from_row): Set start and stop points |
| 1790 | according to the row's direction when priming the loop that looks |
| 1791 | for the glyph on which to display cursor. |
| 1792 | (single_display_spec_intangible_p): Function deleted. |
| 1793 | (display_prop_intangible_p): Reimplement to call |
| 1794 | handle_display_spec instead of single_display_spec_intangible_p. |
| 1795 | Accept 3 additional arguments needed by handle_display_spec. |
| 1796 | This fixes incorrect cursor motion across display property with complex |
| 1797 | values: lists, `(when COND...)' forms, etc. |
| 1798 | (single_display_spec_string_p): Support property values that are |
| 1799 | lists with the argument STRING its top-level element. |
| 1800 | (display_prop_string_p): Fix the condition for processing a |
| 1801 | property that is a list to be consistent with handle_display_spec. |
| 1802 | (handle_display_spec): New function, refactored from the |
| 1803 | last portion of handle_display_prop. |
| 1804 | (compute_display_string_pos): Accept additional argument |
| 1805 | FRAME_WINDOW_P. Call handle_display_spec to determine whether the |
| 1806 | value of a `display' property is a "replacing spec". |
| 1807 | (handle_single_display_spec): Accept 2 additional arguments BUFPOS |
| 1808 | and FRAME_WINDOW_P. If IT is NULL, don't set up the iterator from |
| 1809 | the display property, but just return a value indicating whether |
| 1810 | the display property will replace the characters it covers. |
| 1811 | (Fcurrent_bidi_paragraph_direction): Initialize the nchars and |
| 1812 | frame_window_p members of struct bidi_it. |
| 1813 | (compute_display_string_pos, compute_display_string_end): |
| 1814 | New functions. |
| 1815 | (push_it): Accept second argument POSITION, where pop_it should |
| 1816 | jump to continue iteration. |
| 1817 | (reseat_1): Initialize bidi_it.disp_pos. |
| 1818 | |
| 1819 | * keyboard.c (adjust_point_for_property): Adjust the call to |
| 1820 | display_prop_intangible_p to its new signature. |
| 1821 | |
| 1822 | * dispextern.h (struct bidi_it): New member frame_window_p. |
| 1823 | (bidi_init_it): Update prototypes. |
| 1824 | (display_prop_intangible_p): Update prototype. |
| 1825 | (compute_display_string_pos, compute_display_string_end): |
| 1826 | Declare prototypes. |
| 1827 | (struct bidi_it): New members nchars and disp_pos. ch_len is now |
| 1828 | EMACS_INT. |
| 1829 | |
| 1830 | 2011-06-02 Paul Eggert <eggert@cs.ucla.edu> |
| 1831 | |
| 1832 | Malloc failure behavior now depends on size of allocation. |
| 1833 | * alloc.c (buffer_memory_full, memory_full): New arg NBYTES. |
| 1834 | * lisp.h: Change signatures accordingly. |
| 1835 | * alloc.c, buffer.c, editfns.c, menu.c, minibuf.c, xterm.c: |
| 1836 | All callers changed. (Bug#8762) |
| 1837 | |
| 1838 | * gnutls.c: Use Emacs's memory allocators. |
| 1839 | Without this change, the gnutls library would invoke malloc etc. |
| 1840 | directly, which causes problems on non-SYNC_INPUT hosts, and which |
| 1841 | runs afoul of improving memory_full behavior. (Bug#8761) |
| 1842 | (fn_gnutls_global_set_mem_functions): New macro or function pointer. |
| 1843 | (emacs_gnutls_global_init): Use it to specify xmalloc, xrealloc, |
| 1844 | xfree instead of the default malloc, realloc, free. |
| 1845 | (Fgnutls_boot): No need to check for memory allocation failure, |
| 1846 | since xmalloc does that for us. |
| 1847 | |
| 1848 | Remove arbitrary limit of 2**31 entries in hash tables. (Bug#8771) |
| 1849 | * category.c (hash_get_category_set): |
| 1850 | * ccl.c (ccl_driver): |
| 1851 | * charset.c (Fdefine_charset_internal): |
| 1852 | * charset.h (struct charset.hash_index): |
| 1853 | * composite.c (get_composition_id, gstring_lookup_cache) |
| 1854 | (composition_gstring_put_cache): |
| 1855 | * composite.h (struct composition.hash_index): |
| 1856 | * dispextern.h (struct image.hash): |
| 1857 | * fns.c (next_almost_prime, larger_vector, cmpfn_eql) |
| 1858 | (cmpfn_equal, cmpfn_user_defined, hashfn_eq, hashfn_eql) |
| 1859 | (hashfn_equal, hashfn_user_defined, make_hash_table) |
| 1860 | (maybe_resize_hash_table, hash_lookup, hash_put) |
| 1861 | (hash_remove_from_table, hash_clear, sweep_weak_table, SXHASH_COMBINE) |
| 1862 | (sxhash_string, sxhash_list, sxhash_vector, sxhash_bool_vector) |
| 1863 | (Fsxhash, Fgethash, Fputhash, Fmaphash): |
| 1864 | * image.c (make_image, search_image_cache, lookup_image) |
| 1865 | (xpm_put_color_table_h): |
| 1866 | * lisp.h (struct Lisp_Hash_Table): |
| 1867 | * minibuf.c (Ftry_completion, Fall_completions, Ftest_completion): |
| 1868 | * print.c (print): Use 'EMACS_UINT' and 'EMACS_INT' |
| 1869 | for hashes and hash indexes, instead of 'unsigned' and 'int'. |
| 1870 | * alloc.c (allocate_vectorlike): |
| 1871 | Check for overflow in vector size calculations. |
| 1872 | * ccl.c (ccl_driver): |
| 1873 | Check for overflow when converting EMACS_INT to int. |
| 1874 | * fns.c, image.c: Remove unnecessary static decls that would otherwise |
| 1875 | need to be updated by these changes. |
| 1876 | * fns.c (make_hash_table, maybe_resize_hash_table): |
| 1877 | Check for integer overflow with large hash tables. |
| 1878 | (make_hash_table, maybe_resize_hash_table, Fmake_hash_table): |
| 1879 | Prefer the faster XFLOAT_DATA to XFLOATINT where either will do. |
| 1880 | (SXHASH_REDUCE): New macro. |
| 1881 | (sxhash_string, sxhash_list, sxhash_vector, sxhash_bool_vector): |
| 1882 | Use it instead of discarding useful hash info with large hash values. |
| 1883 | (sxhash_float): New function. |
| 1884 | (sxhash): Use it. No more need for "& INTMASK" due to above changes. |
| 1885 | * lisp.h (FIXNUM_BITS): New macro, useful for SXHASH_REDUCE etc. |
| 1886 | (MOST_NEGATIVE_FIXNUM, MOST_POSITIVE_FIXNUM, INTMASK): |
| 1887 | Rewrite to use FIXNUM_BITS, as this simplifies things. |
| 1888 | (next_almost_prime, larger_vector, sxhash, hash_lookup, hash_put): |
| 1889 | Adjust signatures to match updated version of code. |
| 1890 | (consing_since_gc): Now EMACS_INT, since a single hash table can |
| 1891 | use more than INT_MAX bytes. |
| 1892 | |
| 1893 | 2011-06-01 Dan Nicolaescu <dann@ics.uci.edu> |
| 1894 | |
| 1895 | Make it possible to build with GCC-4.6+ -O2 -flto. |
| 1896 | |
| 1897 | * emacs.c (__malloc_initialize_hook): Mark as EXTERNALLY_VISIBLE. |
| 1898 | |
| 1899 | 2011-06-01 Stefan Monnier <monnier@iro.umontreal.ca> |
| 1900 | |
| 1901 | * minibuf.c (get_minibuffer, read_minibuf_unwind): |
| 1902 | Call minibuffer-inactive-mode. |
| 1903 | |
| 1904 | 2011-05-31 Juanma Barranquero <lekktu@gmail.com> |
| 1905 | |
| 1906 | * makefile.w32-in ($(BLD)/data.$(O), $(BLD)/editfns.$(O)): |
| 1907 | Update dependencies. |
| 1908 | |
| 1909 | 2011-05-31 Dan Nicolaescu <dann@ics.uci.edu> |
| 1910 | |
| 1911 | * data.c (init_data): Remove code for UTS, this system is not |
| 1912 | supported anymore. |
| 1913 | |
| 1914 | 2011-05-31 Dan Nicolaescu <dann@ics.uci.edu> |
| 1915 | |
| 1916 | Don't force ./temacs to start in terminal mode. |
| 1917 | |
| 1918 | * frame.c (make_initial_frame): Initialize faces in all cases, not |
| 1919 | only when CANNOT_DUMP is defined. |
| 1920 | * dispnew.c (init_display): Remove CANNOT_DUMP condition. |
| 1921 | |
| 1922 | 2011-05-31 Dan Nicolaescu <dann@ics.uci.edu> |
| 1923 | |
| 1924 | * dispnew.c (add_window_display_history): Use const for the string |
| 1925 | pointer. Remove declaration, not needed. |
| 1926 | |
| 1927 | 2011-05-31 Paul Eggert <eggert@cs.ucla.edu> |
| 1928 | |
| 1929 | Use 'inline', not 'INLINE'. |
| 1930 | <http://lists.gnu.org/archive/html/emacs-devel/2011-05/msg00914.html> |
| 1931 | * alloc.c, fontset.c (INLINE): Remove. |
| 1932 | * alloc.c, bidi.c, charset.c, coding.c, dispnew.c, fns.c, image.c: |
| 1933 | * intervals.c, keyboard.c, process.c, syntax.c, textprop.c, w32term.c: |
| 1934 | * xdisp.c, xfaces.c, xterm.c: Replace all uses of INLINE with inline. |
| 1935 | * gmalloc.c (register_heapinfo): Use inline unconditionally. |
| 1936 | * lisp.h (LISP_MAKE_RVALUE): Use inline, not __inline__. |
| 1937 | |
| 1938 | 2011-05-31 Dan Nicolaescu <dann@ics.uci.edu> |
| 1939 | |
| 1940 | Make it possible to run ./temacs. |
| 1941 | |
| 1942 | * callproc.c (set_initial_environment): Remove CANNOT_DUMP code, |
| 1943 | syms_of_callproc does the same thing. Remove test for |
| 1944 | "initialized", do it in the caller. |
| 1945 | * emacs.c (main): Avoid calling set_initial_environment when dumping. |
| 1946 | |
| 1947 | 2011-05-31 Stefan Monnier <monnier@iro.umontreal.ca> |
| 1948 | |
| 1949 | * minibuf.c (Finternal_complete_buffer): Return `category' metadata. |
| 1950 | (read_minibuf): Use get_minibuffer. |
| 1951 | (syms_of_minibuf): Use DEFSYM. |
| 1952 | (Qmetadata): New var. |
| 1953 | * data.c (Qbuffer): Don't make it static. |
| 1954 | (syms_of_data): Use DEFSYM. |
| 1955 | |
| 1956 | 2011-05-31 Paul Eggert <eggert@cs.ucla.edu> |
| 1957 | |
| 1958 | * ccl.c (CCL_CODE_RANGE): Allow negative numbers. (Bug#8751) |
| 1959 | (CCL_CODE_MIN): New macro. |
| 1960 | |
| 1961 | 2011-05-30 Paul Eggert <eggert@cs.ucla.edu> |
| 1962 | |
| 1963 | * alloc.c (lisp_align_malloc): Omit unnecessary val==NULL tests. |
| 1964 | |
| 1965 | * eval.c (Qdebug): Now static. |
| 1966 | * lisp.h (Qdebug): Remove decl. This reverts a part of the |
| 1967 | 2011-04-26T11:26:05Z!dan.colascione@gmail.com that inadvertently undid part of |
| 1968 | 2011-04-14T06:48:41Z!eggert@cs.ucla.edu. |
| 1969 | |
| 1970 | 2011-05-29 Chong Yidong <cyd@stupidchicken.com> |
| 1971 | |
| 1972 | * image.c: Various fixes to ImageMagick code comments. |
| 1973 | (Fimagemagick_types): Doc fix. |
| 1974 | |
| 1975 | 2011-05-29 Paul Eggert <eggert@cs.ucla.edu> |
| 1976 | |
| 1977 | Minor fixes prompted by GCC 4.6.0 warnings. |
| 1978 | |
| 1979 | * xselect.c (converted_selections, conversion_fail_tag): Now static. |
| 1980 | |
| 1981 | * emacs.c [HAVE_X_WINDOWS]: Include "xterm.h". |
| 1982 | (x_clipboard_manager_save_all): Move extern decl to ... |
| 1983 | * xterm.h: ... here, so that it can be checked for consistency. |
| 1984 | |
| 1985 | 2011-05-29 Chong Yidong <cyd@stupidchicken.com> |
| 1986 | |
| 1987 | * xselect.c (x_clipboard_manager_save_frame) |
| 1988 | (x_clipboard_manager_save_all): New functions. |
| 1989 | (Fx_clipboard_manager_save): Lisp function deleted. |
| 1990 | |
| 1991 | * emacs.c (Fkill_emacs): Call x_clipboard_manager_save_all. |
| 1992 | * frame.c (delete_frame): Call x_clipboard_manager_save_frame. |
| 1993 | |
| 1994 | * xterm.h: Update prototype. |
| 1995 | |
| 1996 | 2011-05-28 William Xu <william.xwl@gmail.com> |
| 1997 | |
| 1998 | * nsterm.m (ns_term_shutdown): Synchronize user defaults before |
| 1999 | exiting (Bug#8239). |
| 2000 | |
| 2001 | 2011-05-28 Jim Meyering <meyering@redhat.com> |
| 2002 | |
| 2003 | Avoid a sign-extension bug in crypto_hash_function. |
| 2004 | * fns.c (to_uchar): Define. |
| 2005 | (crypto_hash_function): Use it to convert some newly-signed |
| 2006 | variables to unsigned, to avoid sign-extension bugs. For example, |
| 2007 | without this change, (md5 "truc") would evaluate to |
| 2008 | 45723a2aff78ff4fff7fff1114760e62 rather than the expected |
| 2009 | 45723a2af3788c4ff17f8d1114760e62. Reported by Antoine Levitt in |
| 2010 | https://lists.gnu.org/archive/html/emacs-devel/2011-05/msg00883.html. |
| 2011 | |
| 2012 | 2011-05-27 Paul Eggert <eggert@cs.ucla.edu> |
| 2013 | |
| 2014 | Integer overflow fixes. |
| 2015 | |
| 2016 | * dbusbind.c: Serial number integer overflow fixes. |
| 2017 | (CHECK_DBUS_SERIAL_GET_SERIAL): New macro. |
| 2018 | (Fdbus_call_method_asynchronously, xd_read_message_1): Use a float |
| 2019 | to hold a serial number that is too large for a fixnum. |
| 2020 | (Fdbus_method_return_internal, Fdbus_method_error_internal): |
| 2021 | Check for serial numbers out of range. Decode any serial number |
| 2022 | that was so large that it became a float. (Bug#8722) |
| 2023 | |
| 2024 | * dbusbind.c: Use XFASTINT rather than XUINT, and check for nonneg. |
| 2025 | (Fdbus_call_method, Fdbus_call_method_asynchronously): |
| 2026 | Use XFASTINT rather than XUINT when numbers are nonnegative. |
| 2027 | (xd_append_arg, Fdbus_method_return_internal): |
| 2028 | (Fdbus_method_error_internal): Likewise. Also, for unsigned |
| 2029 | arguments, check that Lisp number is nonnegative, rather than |
| 2030 | silently wrapping negative numbers around. (Bug#8722) |
| 2031 | (xd_read_message_1): Don't assume dbus_uint32_t can fit in int. |
| 2032 | (Bug#8722) |
| 2033 | |
| 2034 | * data.c (arith_driver, Flsh): Avoid unnecessary casts to EMACS_UINT. |
| 2035 | |
| 2036 | * ccl.c (ccl_driver): Redo slightly to avoid the need for 'unsigned'. |
| 2037 | |
| 2038 | ccl: add integer overflow checks |
| 2039 | * ccl.c (CCL_CODE_MAX, GET_CCL_RANGE, GET_CCL_CODE, GET_CCL_INT): |
| 2040 | (IN_INT_RANGE): New macros. |
| 2041 | (ccl_driver): Use them to check for integer overflow when |
| 2042 | decoding a CCL program. Many of the new checks are whether XINT (x) |
| 2043 | fits in int; it doesn't always, on 64-bit hosts. The new version |
| 2044 | doesn't catch all possible integer overflows, but it's an |
| 2045 | improvement. (Bug#8719) |
| 2046 | |
| 2047 | * alloc.c (make_event_array): Use XINT, not XUINT. |
| 2048 | There's no need for unsigned here. |
| 2049 | |
| 2050 | * mem-limits.h (EXCEEDS_LISP_PTR) [!USE_LSB_TAG]: EMACS_UINT -> uintptr_t |
| 2051 | This follows up to the 2011-05-06 change that substituted uintptr_t |
| 2052 | for EMACS_INT. This case wasn't caught back then. |
| 2053 | |
| 2054 | Rework Fformat to avoid integer overflow issues. |
| 2055 | * editfns.c: Include <float.h> unconditionally, as it's everywhere |
| 2056 | now (part of C89). Include <verify.h>. |
| 2057 | (MAX_10_EXP, CONVERTED_BYTE_SIZE): Remove; no longer needed. |
| 2058 | (pWIDE, pWIDElen, signed_wide, unsigned_wide): New defns. |
| 2059 | (Fformat): Avoid the prepass trying to compute sizes; it was only |
| 2060 | approximate and thus did not catch overflow reliably. Instead, walk |
| 2061 | through the format just once, formatting and computing sizes as we go, |
| 2062 | checking for integer overflow at every step, and allocating a larger |
| 2063 | buffer as needed. Keep track separately whether the format is |
| 2064 | multibyte. Keep only the most-recently calculated precision, rather |
| 2065 | than them all. Record whether each argument has been converted to |
| 2066 | string. Use EMACS_INT, not int, for byte and char and arg counts. |
| 2067 | Support field widths and precisions larger than INT_MAX. Avoid |
| 2068 | sprintf's undefined behavior with conversion specifications such as %#d |
| 2069 | and %.0c. Fix bug with strchr succeeding on '\0' when looking for |
| 2070 | flags. Fix bug with (format "%c" 256.0). Avoid integer overflow when |
| 2071 | formatting out-of-range floating point numbers with int |
| 2072 | formats. (Bug#8668) |
| 2073 | |
| 2074 | * lisp.h (FIXNUM_OVERFLOW_P): Work even if arg is a NaN. |
| 2075 | |
| 2076 | * data.c: Avoid integer truncation in expressions involving floats. |
| 2077 | * data.c: Include <intprops.h>. |
| 2078 | (arith_driver): When there's an integer overflow in an expression |
| 2079 | involving floating point, convert the integers to floating point |
| 2080 | so that the resulting value does not suffer from catastrophic |
| 2081 | integer truncation. For example, on a 64-bit host (* 4 |
| 2082 | most-negative-fixnum 0.5) should yield about -4.6e+18, not zero. |
| 2083 | Do not rely on undefined behavior after integer overflow. |
| 2084 | |
| 2085 | merge count_size_as_multibyte, parse_str_to_multibyte |
| 2086 | * character.c, character.h (count_size_as_multibyte): |
| 2087 | Rename from parse_str_to_multibyte; all uses changed. |
| 2088 | Check for integer overflow. |
| 2089 | * insdel.c, lisp.h (count_size_as_multibyte): Remove, |
| 2090 | since it's now a duplicate of the other. This is more of |
| 2091 | a character than a buffer op, so better that it's in character.c. |
| 2092 | * fns.c, print.c: Adjust to above changes. |
| 2093 | |
| 2094 | 2011-05-27 Stefan Monnier <monnier@iro.umontreal.ca> |
| 2095 | |
| 2096 | * xselect.c (x_convert_selection): Yet another int/Lisp_Object mixup. |
| 2097 | |
| 2098 | 2011-05-27 Paul Eggert <eggert@cs.ucla.edu> |
| 2099 | |
| 2100 | * xselect.c: Fix minor problems prompted by GCC 4.6.0 warnings. |
| 2101 | (x_handle_selection_request, frame_for_x_selection): Remove unused vars. |
| 2102 | (x_clipboard_manager_save): Now static. |
| 2103 | (Fx_clipboard_manager_save): Rename local to avoid shadowing. |
| 2104 | |
| 2105 | * fns.c: Fix minor problems prompted by GCC 4.6.0 warnings. |
| 2106 | (crypto_hash_function): Now static. |
| 2107 | Fix pointer signedness problems. Avoid unnecessary initializations. |
| 2108 | |
| 2109 | 2011-05-27 Chong Yidong <cyd@stupidchicken.com> |
| 2110 | |
| 2111 | * termhooks.h (Vselection_alist): Make it terminal-local. |
| 2112 | |
| 2113 | * terminal.c (create_terminal): Initialize it. |
| 2114 | |
| 2115 | * xselect.c: Support for clipboard managers. |
| 2116 | (Vselection_alist): Move to termhooks.h as terminal-local var. |
| 2117 | (LOCAL_SELECTION): New macro. |
| 2118 | (x_atom_to_symbol): Handle x_display_info_for_display fail case. |
| 2119 | (symbol_to_x_atom): Remove gratuitous arg. |
| 2120 | (x_handle_selection_request, lisp_data_to_selection_data) |
| 2121 | (x_get_foreign_selection, Fx_register_dnd_atom): Callers changed. |
| 2122 | (x_own_selection, x_get_local_selection, x_convert_selection): |
| 2123 | New arg, specifying work frame. Use terminal-local Vselection_alist. |
| 2124 | (some_frame_on_display): Delete unused function. |
| 2125 | (Fx_own_selection_internal, Fx_get_selection_internal) |
| 2126 | (Fx_disown_selection_internal, Fx_selection_owner_p) |
| 2127 | (Fx_selection_exists_p): New optional frame arg. |
| 2128 | (frame_for_x_selection, Fx_clipboard_manager_save): New functions. |
| 2129 | (x_handle_selection_clear): Don't treat other terminals with the |
| 2130 | same keyboard specially. Use the terminal-local Vselection_alist. |
| 2131 | (x_clear_frame_selections): Use Frun_hook_with_args. |
| 2132 | |
| 2133 | * xterm.c (x_term_init): Intern ATOM and CLIPBOARD_MANAGER atoms. |
| 2134 | |
| 2135 | * xterm.h: Add support for those atoms. |
| 2136 | |
| 2137 | 2011-05-26 Chong Yidong <cyd@stupidchicken.com> |
| 2138 | |
| 2139 | * xselect.c: ICCCM-compliant handling of MULTIPLE targets. |
| 2140 | (converted_selections, conversion_fail_tag): New global variables. |
| 2141 | (x_selection_request_lisp_error): Free the above. |
| 2142 | (x_get_local_selection): Remove unnecessary code. |
| 2143 | (x_reply_selection_request): Args changed; handle arbitrary array |
| 2144 | of converted selections stored in converted_selections. |
| 2145 | Separate the XChangeProperty and SelectionNotify steps. |
| 2146 | (x_handle_selection_request): Rewrite to handle MULTIPLE target. |
| 2147 | (x_convert_selection): New function. |
| 2148 | (x_handle_selection_event): Simplify. |
| 2149 | (x_get_foreign_selection): Don't ignore incoming requests while |
| 2150 | waiting for an answer; this will fail when we implement |
| 2151 | SAVE_TARGETS, and seems unnecessary anyway. |
| 2152 | (selection_data_to_lisp_data): Recognize ATOM_PAIR type. |
| 2153 | (Vx_sent_selection_functions): Doc fix. |
| 2154 | |
| 2155 | 2011-05-26 Leo Liu <sdl.web@gmail.com> |
| 2156 | |
| 2157 | * editfns.c (Ftranspose_regions): Allow empty regions. (Bug#8699) |
| 2158 | |
| 2159 | 2011-05-25 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
| 2160 | |
| 2161 | * dispextern.h (struct glyph_row): New member fringe_bitmap_periodic_p. |
| 2162 | |
| 2163 | * dispnew.c (shift_glyph_matrix, scrolling_window): Mark scrolled row |
| 2164 | for fringe update if it has periodic bitmap. |
| 2165 | (row_equal_p): Also compare left_fringe_offset, right_fringe_offset, |
| 2166 | and fringe_bitmap_periodic_p. |
| 2167 | |
| 2168 | * fringe.c (get_fringe_bitmap_data): New function. |
| 2169 | (draw_fringe_bitmap_1, update_window_fringes): Use it. |
| 2170 | (update_window_fringes): Record periodicity of fringe bitmap in glyph |
| 2171 | row. Mark glyph row for fringe update if periodicity changed. |
| 2172 | |
| 2173 | * xdisp.c (try_window_reusing_current_matrix): Don't mark scrolled row |
| 2174 | for fringe update unless it has periodic bitmap. |
| 2175 | |
| 2176 | 2011-05-25 Kenichi Handa <handa@m17n.org> |
| 2177 | |
| 2178 | * xdisp.c (get_next_display_element): Set correct it->face_id for |
| 2179 | a static composition. |
| 2180 | |
| 2181 | 2011-05-24 Leo Liu <sdl.web@gmail.com> |
| 2182 | |
| 2183 | * deps.mk (fns.o): |
| 2184 | * makefile.w32-in ($(BLD)/fns.$(O)): Include sha1.h. |
| 2185 | |
| 2186 | * fns.c (crypto_hash_function, Fsha1): New function. |
| 2187 | (Fmd5): Use crypto_hash_function. |
| 2188 | (syms_of_fns): Add Ssha1. |
| 2189 | |
| 2190 | 2011-05-22 Paul Eggert <eggert@cs.ucla.edu> |
| 2191 | |
| 2192 | * gnutls.c: Remove unused macros. |
| 2193 | (fn_gnutls_transport_set_lowat, fn_gnutls_transport_set_pull_function): |
| 2194 | (fn_gnutls_transport_set_push_function) [!WINDOWSNT]: |
| 2195 | Remove macros that are defined and never used. |
| 2196 | Caught by gcc -Wunused-macros (GCC 4.6.0, Fedora 14). |
| 2197 | |
| 2198 | 2011-05-22 Chong Yidong <cyd@stupidchicken.com> |
| 2199 | |
| 2200 | * xselect.c (syms_of_xselect): Remove unused symbol SAVE_TARGETS. |
| 2201 | (Fx_get_selection_internal): Minor cleanup. |
| 2202 | (Fx_own_selection_internal): Rename arguments for consistency with |
| 2203 | select.el. |
| 2204 | |
| 2205 | 2011-05-22 Paul Eggert <eggert@cs.ucla.edu> |
| 2206 | |
| 2207 | * xselect.c (QSAVE_TARGETS): New static var, to fix build failure. |
| 2208 | |
| 2209 | 2011-05-22 Chong Yidong <cyd@stupidchicken.com> |
| 2210 | |
| 2211 | * xselect.c (syms_of_xselect): Include character.h; use DEFSYM. |
| 2212 | |
| 2213 | 2011-05-21 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
| 2214 | |
| 2215 | * dispnew.c (scrolling_window): Don't exclude the case that the |
| 2216 | last enabled row in the desired matrix touches the bottom boundary. |
| 2217 | |
| 2218 | 2011-05-21 Glenn Morris <rgm@gnu.org> |
| 2219 | |
| 2220 | * Makefile.in ($(etc)/DOC): Make second command line even shorter. |
| 2221 | (SOME_MACHINE_OBJECTS): Replace FONT_OBJ by its maximal expansion, |
| 2222 | and add some more files. |
| 2223 | |
| 2224 | 2011-05-20 Eli Zaretskii <eliz@gnu.org> |
| 2225 | |
| 2226 | * callproc.c (Fcall_process) [MSDOS]: Fix arguments to |
| 2227 | report_file_error introduced by the change from 2011-05-07. |
| 2228 | |
| 2229 | 2011-05-20 Paul Eggert <eggert@cs.ucla.edu> |
| 2230 | |
| 2231 | * systime.h (Time): Define only if emacs is defined. |
| 2232 | This is to allow ../lib-src/profile.c to be compiled on FreeBSD, |
| 2233 | where the include path doesn't have X11/X.h by default. See |
| 2234 | <http://lists.gnu.org/archive/html/emacs-devel/2011-05/msg00561.html>. |
| 2235 | |
| 2236 | 2011-05-20 Kenichi Handa <handa@m17n.org> |
| 2237 | |
| 2238 | * composite.c (find_automatic_composition): Fix previous change. |
| 2239 | |
| 2240 | 2011-05-20 Glenn Morris <rgm@gnu.org> |
| 2241 | |
| 2242 | * lisp.mk: New file, split from Makefile.in. |
| 2243 | * Makefile.in (lisp): Move to separate file, inserted by @lisp_frag@. |
| 2244 | (shortlisp): Remove. |
| 2245 | ($(etc)/DOC): Edit lisp.mk rather than using $shortlisp. |
| 2246 | |
| 2247 | 2011-05-19 Glenn Morris <rgm@gnu.org> |
| 2248 | |
| 2249 | * Makefile.in (MSDOS_SUPPORT_REAL, MSDOS_SUPPORT, NS_SUPPORT) |
| 2250 | (REAL_MOUSE_SUPPORT, GPM_MOUSE_SUPPORT, MOUSE_SUPPORT, TOOLTIP_SUPPORT) |
| 2251 | (BASE_WINDOW_SUPPORT, X_WINDOW_SUPPORT, WINDOW_SUPPORT): Remove. |
| 2252 | (lisp): Set the order to that of loadup.el. |
| 2253 | (shortlisp): Make it a copy of $lisp. |
| 2254 | (SOME_MACHINE_LISP): Remove. |
| 2255 | ($(etc)/DOC): Depend just on $lisp, not $SOME_MACHINE_LISP too. |
| 2256 | Use just $shortlisp, not $SOME_MACHINE_LISP too. |
| 2257 | |
| 2258 | 2011-05-18 Kenichi Handa <handa@m17n.org> |
| 2259 | |
| 2260 | * composite.c (CHAR_COMPOSABLE_P): Add more check for efficiency. |
| 2261 | (BACKWARD_CHAR): Wrap the arg STOP by parenthesis. |
| 2262 | (find_automatic_composition): Mostly rewrite for efficiency. |
| 2263 | |
| 2264 | 2011-05-18 Juanma Barranquero <lekktu@gmail.com> |
| 2265 | |
| 2266 | * makefile.w32-in: Update dependencies. |
| 2267 | |
| 2268 | 2011-05-18 Christoph Scholtes <cschol2112@googlemail.com> |
| 2269 | |
| 2270 | * menu.c: Include limits.h (fixes the MS-Windows build broken by |
| 2271 | 2011-06-18T18:49:19Z!cyd@stupidchicken.com). |
| 2272 | |
| 2273 | 2011-05-18 Paul Eggert <eggert@cs.ucla.edu> |
| 2274 | |
| 2275 | Fix some integer overflow issues, such as string length overflow. |
| 2276 | |
| 2277 | * insdel.c (count_size_as_multibyte): Check for string overflow. |
| 2278 | |
| 2279 | * character.c (lisp_string_width): Check for string overflow. |
| 2280 | Use EMACS_INT, not int, for string indexes and lengths; in |
| 2281 | particular, 2nd arg is now EMACS_INT, not int. Do not crash if |
| 2282 | the resulting string length overflows an EMACS_INT; instead, |
| 2283 | report a string overflow if no precision given. When checking for |
| 2284 | precision exhaustion, use a check that cannot possibly have |
| 2285 | integer overflow. (Bug#8675) |
| 2286 | * character.h (lisp_string_width): Adjust to new signature. |
| 2287 | |
| 2288 | * alloc.c (string_overflow): New function. |
| 2289 | (Fmake_string): Use it. This doesn't change behavior, but saves |
| 2290 | a few bytes and will simplify future changes. |
| 2291 | * character.c (string_escape_byte8): Likewise. |
| 2292 | * lisp.h (string_overflow): New decl. |
| 2293 | |
| 2294 | Fixups, following up to the user-interface timestamp change. |
| 2295 | * nsterm.m (last_mouse_movement_time, ns_mouse_position): Use Time |
| 2296 | for UI timestamps, instead of unsigned long. |
| 2297 | * msdos.c (mouse_get_pos): Likewise. |
| 2298 | * w32inevt.c (movement_time, w32_console_mouse_position): Likewise. |
| 2299 | * w32gui.h (Time): Define by including "systime.h" rather than by |
| 2300 | declaring it ourselves. (Bug#8664) |
| 2301 | |
| 2302 | * dispextern.h (struct image): Don't assume time_t <= unsigned long. |
| 2303 | * image.c (clear_image_cache): Likewise. |
| 2304 | |
| 2305 | * term.c (term_mouse_position): Don't assume time_t wraparound. |
| 2306 | |
| 2307 | Be more systematic about user-interface timestamps. |
| 2308 | Before, the code sometimes used 'Time', sometimes 'unsigned long', |
| 2309 | and sometimes 'EMACS_UINT', to represent these timestamps. |
| 2310 | This change causes it to use 'Time' uniformly, as that's what X uses. |
| 2311 | This makes the code easier to follow, and makes it easier to catch |
| 2312 | integer overflow bugs such as Bug#8664. |
| 2313 | * frame.c (Fmouse_position, Fmouse_pixel_position): |
| 2314 | Use Time, not unsigned long, for user-interface timestamps. |
| 2315 | * keyboard.c (last_event_timestamp, kbd_buffer_get_event): Likewise. |
| 2316 | (button_down_time, make_lispy_position, make_lispy_movement): Likewise. |
| 2317 | * keyboard.h (last_event_timestamp): Likewise. |
| 2318 | * menu.c (Fx_popup_menu) [!HAVE_X_WINDOWS]: Likewise. |
| 2319 | * menu.h (xmenu_show): Likewise. |
| 2320 | * term.c (term_mouse_position): Likewise. |
| 2321 | * termhooks.h (struct input_event.timestamp): Likewise. |
| 2322 | (struct terminal.mouse_position_hook): Likewise. |
| 2323 | * xmenu.c (create_and_show_popup_menu, xmenu_show): Likewise. |
| 2324 | * xterm.c (XTmouse_position, x_scroll_bar_report_motion): Likewise. |
| 2325 | * systime.h (Time): New decl. Pull it in from <X11/X.h> if |
| 2326 | HAVE_X_WINDOWS, otherwise define it as unsigned long, which is |
| 2327 | what it was before. |
| 2328 | * menu.h, termhooks.h: Include "systime.h", for Time. |
| 2329 | |
| 2330 | * keyboard.c (make_lispy_event): Fix problem in integer overflow. |
| 2331 | Don't assume that the difference between two unsigned long values |
| 2332 | can fit into an integer. At this point, we know button_down_time |
| 2333 | <= event->timestamp, so the difference must be nonnegative, so |
| 2334 | there's no need to cast the result if double-click-time is |
| 2335 | nonnegative, as it should be; check that it's nonnegative, just in |
| 2336 | case. This bug is triggered when events are more than 2**31 ms |
| 2337 | apart (about 25 days). (Bug#8664) |
| 2338 | |
| 2339 | * xselect.c (last_event_timestamp): Remove duplicate decl. |
| 2340 | (x_own_selection): Remove needless cast to unsigned long. |
| 2341 | |
| 2342 | * xmenu.c (set_frame_menubar): Use int, not EMACS_UINT, for indexes |
| 2343 | that always fit in int. Use a sentinel instead of a counter, to |
| 2344 | avoid a temp and to allay GCC's concerns about possible int overflow. |
| 2345 | * frame.h (struct frame): Use int for menu_bar_items_used |
| 2346 | instead of EMACS_INT, since it always fits in int. |
| 2347 | |
| 2348 | * menu.c (grow_menu_items): Check for int overflow. |
| 2349 | |
| 2350 | * xmenu.c (set_frame_menubar): Don't mishandle vectors with no nils. |
| 2351 | |
| 2352 | * xterm.c: Use EMACS_INT for Emacs modifiers, and int for X modifiers. |
| 2353 | Before, the code was not consistent. These values cannot exceed |
| 2354 | 2**31 - 1 so there's no need to make them unsigned. |
| 2355 | (x_x_to_emacs_modifiers): Accept int and return EMACS_INT. |
| 2356 | (x_emacs_to_x_modifiers): Accept EMACS_INT and return int. |
| 2357 | (x_x_to_emacs_modifiers, x_emacs_to_x_modifiers): Reject non-integers |
| 2358 | as modifiers. |
| 2359 | * xterm.h (x_x_to_emacs_modifiers): Adjust to signature change. |
| 2360 | |
| 2361 | * lisp.h (XINT) [USE_LISP_UNION_TYPE]: Cast to EMACS_INT. |
| 2362 | (XUINT) [USE_LISP_UNION_TYPE]: Cast to EMACS_UINT. |
| 2363 | Otherwise, GCC 4.6.0 warns about printf (pI, XINT (...)), |
| 2364 | presumably because the widths might not match. |
| 2365 | |
| 2366 | * window.c (size_window): Avoid needless test at loop start. |
| 2367 | |
| 2368 | 2011-05-18 Courtney Bane <emacs-bugs-7626@cbane.org> (tiny change) |
| 2369 | |
| 2370 | * term.c (Fresume_tty): Restore hooks before reinitializing (bug#8687). |
| 2371 | |
| 2372 | 2011-05-12 Drew Adams <drew.adams@oracle.com> |
| 2373 | |
| 2374 | * textprop.c (Fprevious_single_char_property_change): Doc fix (bug#8655). |
| 2375 | |
| 2376 | 2011-05-12 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
| 2377 | |
| 2378 | * w32term.c (w32_draw_fringe_bitmap): Rename local vars `left' and |
| 2379 | `width' to `bar_area_x' and `bar_area_width', respectively. |
| 2380 | (x_scroll_run): Take account of fringe background extension. |
| 2381 | |
| 2382 | * xterm.c (x_draw_fringe_bitmap) [USE_TOOLKIT_SCROLL_BARS]: |
| 2383 | Rename local vars `left' and `width' to `bar_area_x' and |
| 2384 | `bar_area_width', respectively. |
| 2385 | (x_scroll_run) [USE_TOOLKIT_SCROLL_BARS]: Take account of fringe |
| 2386 | background extension. |
| 2387 | |
| 2388 | 2011-05-10 Jim Meyering <meyering@redhat.com> |
| 2389 | |
| 2390 | * xdisp.c (x_intersect_rectangles): Fix typo "the the -> the". |
| 2391 | |
| 2392 | 2011-05-10 Juanma Barranquero <lekktu@gmail.com> |
| 2393 | |
| 2394 | * image.c (Finit_image_library): Return t for built-in image types, |
| 2395 | like pbm and xbm. (Bug#8640) |
| 2396 | |
| 2397 | 2011-05-09 Andreas Schwab <schwab@linux-m68k.org> |
| 2398 | |
| 2399 | * w32menu.c (set_frame_menubar): Fix submenu allocation. |
| 2400 | |
| 2401 | 2011-05-07 Eli Zaretskii <eliz@gnu.org> |
| 2402 | |
| 2403 | * w32console.c (Fset_screen_color): Doc fix. |
| 2404 | (Fget_screen_color): New function. |
| 2405 | (syms_of_ntterm): Defsubr it. |
| 2406 | |
| 2407 | * callproc.c (call_process_cleanup) [MSDOS]: Don't close and |
| 2408 | unlink the temporary file if Fcall_process didn't create it in the |
| 2409 | first place. |
| 2410 | (Fcall_process) [MSDOS]: Don't create tempfile if stdout of the |
| 2411 | child process will be redirected to a file specified with `:file'. |
| 2412 | Don't try to re-open tempfile in that case, and set fd[0] to -1 as |
| 2413 | cue to call_process_cleanup not to close that handle. |
| 2414 | |
| 2415 | 2011-05-07 Ben Key <bkey76@gmail.com> |
| 2416 | |
| 2417 | * makefile.w32-in: The bootstrap-temacs rule now makes use of |
| 2418 | one of two shell specific rules, either bootstrap-temacs-CMD or |
| 2419 | bootstrap-temacs-SH. The bootstrap-temacs-SH rule is identical |
| 2420 | to the previous implementation of the bootstrap-temacs rule. |
| 2421 | The bootstrap-temacs-CMD rule is similar to the previous |
| 2422 | implementation of the bootstrap-temacs rule except that it |
| 2423 | makes use of the ESC_CFLAGS variable instead of the CFLAGS |
| 2424 | variable. |
| 2425 | |
| 2426 | These changes, along with some changes to nt/configure.bat, |
| 2427 | nt/gmake.defs, and nt/nmake.defs, are required to extend my |
| 2428 | earlier fix to add support for --cflags and --ldflags options |
| 2429 | that include quotes so that it works whether make uses cmd or |
| 2430 | sh as the shell. |
| 2431 | |
| 2432 | 2011-05-06 Michael Albinus <michael.albinus@gmx.de> |
| 2433 | |
| 2434 | * dbusbind.c (QCdbus_type_unix_fd): Declare static. |
| 2435 | (xd_remove_watch): Don't check QCdbus_type_unix_fd for SYMBOLP, it |
| 2436 | is a constant. |
| 2437 | (Fdbus_init_bus, xd_read_queued_messages): Bus can be a symbol or |
| 2438 | a string. Handle both cases. |
| 2439 | (Fdbus_call_method_asynchronously, Fdbus_register_signal) |
| 2440 | (Fdbus_register_method): Use Qinvalid_function. |
| 2441 | |
| 2442 | 2011-05-06 Juanma Barranquero <lekktu@gmail.com> |
| 2443 | |
| 2444 | * makefile.w32-in: Update dependencies. |
| 2445 | (LISP_H): Add inttypes.h and stdin.h. |
| 2446 | (PROCESS_H): Add unistd.h. |
| 2447 | |
| 2448 | 2011-05-06 Eli Zaretskii <eliz@gnu.org> |
| 2449 | |
| 2450 | * lread.c: Include limits.h (fixes the MS-Windows build broken by |
| 2451 | 2011-05-06T07:13:19Z!eggert@cs.ucla.edu). |
| 2452 | |
| 2453 | 2011-05-06 Paul Eggert <eggert@cs.ucla.edu> |
| 2454 | |
| 2455 | * image.c (Finit_image_library) [!HAVE_NTGUI]: Omit unused local. |
| 2456 | |
| 2457 | * term.c (vfatal): Remove stray call to va_end. |
| 2458 | It's not needed and the C Standard doesn't allow it here anyway. |
| 2459 | |
| 2460 | Use C99's va_copy to avoid undefined behavior on x86-64 GNU/Linux. |
| 2461 | * eval.c (verror): doprnt a copy of ap, not the original. (Bug#8545) |
| 2462 | |
| 2463 | * eval.c (verror): OK to create a string of up to MOST_POSITIVE_FIXNUM |
| 2464 | bytes. |
| 2465 | |
| 2466 | * term.c: Don't include <stdarg.h>, as <lisp.h> does that. |
| 2467 | |
| 2468 | * callproc.c (Fcall_process): Use 'volatile' to avoid vfork clobbering. |
| 2469 | |
| 2470 | * process.c (Fformat_network_address): Fix typo: args2 -> *args2. |
| 2471 | |
| 2472 | * xmenu.c (set_frame_menubar): Fix typo: int * -> int (3 times). |
| 2473 | |
| 2474 | * coding.c (detect_coding_charset): Fix typo: * 2 -> *4 (Bug#8601). |
| 2475 | |
| 2476 | * charset.h (struct charset.code_space): Now has 15 elements, not 16. |
| 2477 | * charset.c (Fdefine_charset_internal): Don't initialize |
| 2478 | charset.code_space[15]. The value was garbage, on hosts with |
| 2479 | 32-bit int (Bug#8600). |
| 2480 | |
| 2481 | * lread.c (read_integer): Be more consistent with string-to-number. |
| 2482 | Use string_to_number to do the actual conversion; this avoids |
| 2483 | rounding errors and fixes some other screwups. Without this fix, |
| 2484 | for example, #x1fffffffffffffff was misread as -2305843009213693952. |
| 2485 | (digit_to_number): Move earlier, for benefit of read_integer. |
| 2486 | Return -1 if the digit is out of range for the base, -2 if it is |
| 2487 | not a digit in any supported base. (Bug#8602) |
| 2488 | |
| 2489 | * doprnt.c (doprnt): Support arbitrary pI values, such as "I64". |
| 2490 | |
| 2491 | * dispnew.c (scrolling_window): Return 1 if we scrolled, |
| 2492 | to match comment at start of function. This also removes a |
| 2493 | GCC warning about overflow in a 32+64-bit port. |
| 2494 | |
| 2495 | * lisp.h (EMACS_INT, EMACS_UINT, BITS_PER_EMACS_INT, pI): Simplify. |
| 2496 | |
| 2497 | * dbusbind.c: Do not use XPNTR on a value that may be an integer. |
| 2498 | Reported by Stefan Monnier in |
| 2499 | <http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00919.html>. |
| 2500 | (xd_remove_watch, Fdbus_init_bus, xd_read_queued_messages): |
| 2501 | Use SYMBOLP-guarded XSYMBOL, not XPNTR. |
| 2502 | |
| 2503 | * lisp.h (EMACS_INTPTR): Remove. All uses changed to intptr_t. |
| 2504 | (EMACS_UINTPTR): Likewise, with uintptr_t. |
| 2505 | |
| 2506 | * lisp.h: Prefer 64-bit EMACS_INT if available. |
| 2507 | (EMACS_INT, EMACS_UINT, BITS_PER_EMACS_INT, pI): Define to 64-bit |
| 2508 | on 32-bit hosts that have 64-bit int, so that they can access |
| 2509 | large files. |
| 2510 | However, temporarily disable this change unless the temporary |
| 2511 | symbol WIDE_EMACS_INT is defined. |
| 2512 | |
| 2513 | * lread.c, process.c: Do not include <inttypes.h>; lisp.h does it now. |
| 2514 | |
| 2515 | Prefer intptr_t/uintptr_t for integers the same widths as pointers. |
| 2516 | This removes an assumption that EMACS_INT and long are the same |
| 2517 | width as pointers. The assumption is true for Emacs porting targets |
| 2518 | now, but we want to make other targets possible. |
| 2519 | * lisp.h: Include <inttypes.h>, for INTPTR_MAX, UINTPTR_MAX. |
| 2520 | (EMACS_INTPTR, EMACS_UINTPTR): New macros. |
| 2521 | In the rest of the code, change types of integers that hold casted |
| 2522 | pointers to EMACS_INTPTR and EMACS_UINTPTR, systematically |
| 2523 | replacing EMACS_INT, long, EMACS_UINT, and unsigned long. |
| 2524 | (XTYPE): Don't cast arg to EMACS_UINT; normally is not needed. |
| 2525 | (XSET): Cast type of XTYPE arg to EMACS_INTPTR; it is needed here. |
| 2526 | No need to cast type when ORing. |
| 2527 | (XPNTR): Return a value of type EMACS_INTPTR or EMACS_UINTPTR. |
| 2528 | * alloc.c (lisp_align_malloc): Remove a no-longer-needed cast. |
| 2529 | * doc.c (store_function_docstring): Use EMACS_INTPTR, so as not to |
| 2530 | assume EMACS_INT is the same width as char *. |
| 2531 | * gtkutil.c (xg_gtk_scroll_destroy, xg_tool_bar_button_cb): |
| 2532 | (xg_tool_bar_callback, xg_tool_bar_help_callback, xg_make_tool_item): |
| 2533 | Remove no-longer-needed casts. |
| 2534 | (xg_create_scroll_bar, xg_tool_bar_button_cb, xg_tool_bar_callback): |
| 2535 | (xg_tool_bar_help_callback, xg_make_tool_item): |
| 2536 | Use EMACS_INTPTR to hold an integer |
| 2537 | that will be cast to void *; this can avoid a GCC warning |
| 2538 | if EMACS_INT is not the same width as void *. |
| 2539 | * menu.c (find_and_call_menu_selection): Remove no-longer-needed cast. |
| 2540 | * xdisp.c (display_echo_area_1, resize_mini_window_1): |
| 2541 | (current_message_1, set_message_1): |
| 2542 | Use a local to convert to proper width without a cast. |
| 2543 | * xmenu.c (dialog_selection_callback): Likewise. |
| 2544 | |
| 2545 | * sysdep.c (get_random): Don't assume EMACS_INT is no wider than long. |
| 2546 | Also, don't assume VALBITS / RAND_BITS is less than 5, |
| 2547 | and don't rely on undefined behavior when shifting a 1 left into |
| 2548 | the sign bit. |
| 2549 | * lisp.h (get_random): Change signature to match. |
| 2550 | |
| 2551 | * lread.c (hash_string): Use size_t, not int, for hash computation. |
| 2552 | Normally we prefer signed values; but hashing is special, because |
| 2553 | it's better to use unsigned division on hash table sizes so that |
| 2554 | the remainder is nonnegative. Also, size_t is the natural width |
| 2555 | for hashing into memory. The previous code used 'int', which doesn't |
| 2556 | retain enough info to hash well into very large tables. |
| 2557 | (oblookup, oblookup_last_bucket_number, Funintern): Likewise. |
| 2558 | |
| 2559 | * dbusbind.c: Don't possibly lose pointer info when converting. |
| 2560 | (xd_remove_watch, Fdbus_init_bus, xd_read_queued_messages): |
| 2561 | Use XPNTR rather than XHASH, so that the high-order bits of |
| 2562 | the pointer aren't lost when converting through void *. |
| 2563 | |
| 2564 | * eval.c (Fautoload): Don't double-shift a pointer. |
| 2565 | |
| 2566 | * fns.c (Frandom): Let EMACS_UINT be wider than unsigned long. |
| 2567 | |
| 2568 | 2011-05-06 Juanma Barranquero <lekktu@gmail.com> |
| 2569 | |
| 2570 | * gnutls.c (DEF_GNUTLS_FN): |
| 2571 | * image.c (DEF_IMGLIB_FN): Make function pointers static. |
| 2572 | |
| 2573 | 2011-05-05 Andreas Schwab <schwab@linux-m68k.org> |
| 2574 | |
| 2575 | * lread.c (lisp_file_lexically_bound_p): Stop scanning at end |
| 2576 | marker. (Bug#8610) |
| 2577 | |
| 2578 | 2011-05-05 Eli Zaretskii <eliz@gnu.org> |
| 2579 | |
| 2580 | * w32heap.c (allocate_heap) [USE_LISP_UNION_TYPE || USE_LSB_TAG]: |
| 2581 | New version that can reserve upto 2GB of heap space. |
| 2582 | |
| 2583 | 2011-05-05 Chong Yidong <cyd@stupidchicken.com> |
| 2584 | |
| 2585 | * nsfns.m (Fns_read_file_name): Doc fix (Bug#8534). |
| 2586 | |
| 2587 | 2011-05-05 Teodor Zlatanov <tzz@lifelogs.com> |
| 2588 | |
| 2589 | * gnutls.c (fn_gnutls_certificate_set_x509_key_file): Add alias to |
| 2590 | `gnutls_certificate_set_x509_key_file'. |
| 2591 | |
| 2592 | 2011-05-05 Juanma Barranquero <lekktu@gmail.com> |
| 2593 | |
| 2594 | * makefile.w32-in ($(BLD)/image.$(O), $(BLD)/process.$(O)): |
| 2595 | Update dependencies. |
| 2596 | |
| 2597 | 2011-05-04 Juanma Barranquero <lekktu@gmail.com> |
| 2598 | |
| 2599 | * gnutls.h (emacs_gnutls_write, emacs_gnutls_read): |
| 2600 | * gnutls.c (emacs_gnutls_write, emacs_gnutls_read): |
| 2601 | Remove unused parameter `fildes'. |
| 2602 | * process.c (read_process_output, send_process): Don't pass it. |
| 2603 | |
| 2604 | 2011-05-04 Juanma Barranquero <lekktu@gmail.com> |
| 2605 | |
| 2606 | Fix previous change: the library cache is defined in w32.c. |
| 2607 | * image.c (CACHE_IMAGE_TYPE) [!HAVE_NTGUI]: Define to noop. |
| 2608 | (Finit_image_library): Wrap Vlibrary_cache on "#ifdef HAVE_NTGUI". |
| 2609 | |
| 2610 | 2011-05-04 Juanma Barranquero <lekktu@gmail.com> |
| 2611 | |
| 2612 | Implement dynamic loading of GnuTLS on Windows. |
| 2613 | |
| 2614 | * gnutls.h (GNUTLS_EMACS_ERROR_NOT_LOADED): New macro. |
| 2615 | (emacs_gnutls_write, emacs_gnutls_read): Mark as extern. |
| 2616 | (emacs_gnutls_record_check_pending, emacs_gnutls_transport_set_errno): |
| 2617 | Declare. |
| 2618 | |
| 2619 | * gnutls.c (Qgnutls_dll): Define. |
| 2620 | (DEF_GNUTLS_FN, LOAD_GNUTLS_FN): New macros. |
| 2621 | (gnutls_*): Declare function pointers. |
| 2622 | (init_gnutls_functions): New function to initialize function pointers. |
| 2623 | (emacs_gnutls_handshake, Fgnutls_error_string, Fgnutls_deinit) |
| 2624 | (emacs_gnutls_global_init, Fgnutls_bye): Use function pointers. |
| 2625 | (emacs_gnutls_record_check_pending, emacs_gnutls_transport_set_errno): |
| 2626 | Wrappers for gnutls_record_check_pending and gnutls_transport_set_errno. |
| 2627 | (emacs_gnutls_write, emacs_gnutls_read) |
| 2628 | (emacs_gnutls_handle_error, Fgnutls_error_fatalp) |
| 2629 | (Fgnutls_available_p): New function. |
| 2630 | (Fgnutls_boot): Call Fgnutls_available_p. Use function pointers. |
| 2631 | (syms_of_gnutls) <Qgnutls_dll>: Initialize and staticpro it. |
| 2632 | (syms_of_gnutls) <Sgnutls_available_p>: defsubr it. |
| 2633 | |
| 2634 | * image.c: Include w32.h. |
| 2635 | (Vimage_type_cache): Delete. |
| 2636 | (syms_of_image) <Vimage_type_cache>: Don't initialize and staticpro it. |
| 2637 | (CACHE_IMAGE_TYPE, Finit_image_library): Use Vlibrary_cache instead. |
| 2638 | (w32_delayed_load): Move to w32.c. |
| 2639 | |
| 2640 | * w32.h (VlibraryCache, QCloaded_from, w32_delayed_load): Declare. |
| 2641 | |
| 2642 | * w32.c (QCloaded_from, Vlibrary_cache): Define. |
| 2643 | (w32_delayed_load): Move from image.c. When loading a library, record |
| 2644 | its filename in the :loaded-from property of the library id. |
| 2645 | (globals_of_w32) <QCloaded_from, Vlibrary_cache>: |
| 2646 | Initialize and staticpro them. |
| 2647 | (emacs_gnutls_pull, emacs_gnutls_push): Call emacs_gnutls_* functions. |
| 2648 | |
| 2649 | * process.c: Include lisp.h before w32.h, not after. |
| 2650 | (wait_reading_process_output): Call emacs_gnutls_record_check_pending |
| 2651 | instead of gnutls_record_check_pending. |
| 2652 | |
| 2653 | * callproc.c, emacs.c: Include lisp.h before w32.h, not after. |
| 2654 | |
| 2655 | 2011-05-04 Teodor Zlatanov <tzz@lifelogs.com> |
| 2656 | |
| 2657 | * gnutls.c (Fgnutls_boot): Support :keylist and :crlfiles options |
| 2658 | instead of :keyfiles. Give GnuTLS the keylist and the CRL lists |
| 2659 | as passed in. |
| 2660 | |
| 2661 | 2011-05-03 Jan Djärv <jan.h.d@swipnet.se> |
| 2662 | |
| 2663 | * xterm.c (x_set_frame_alpha): Do not set property on anything |
| 2664 | else than FRAME_X_OUTER_WINDOW (Bug#8608). |
| 2665 | |
| 2666 | 2011-05-02 Juanma Barranquero <lekktu@gmail.com> |
| 2667 | |
| 2668 | * sysdep.c (get_tty_size) [WINDOWSNT]: Implement. (Bug#8596) |
| 2669 | |
| 2670 | 2011-05-02 Juanma Barranquero <lekktu@gmail.com> |
| 2671 | |
| 2672 | * gnutls.c (Qgnutls_log_level, Qgnutls_code, Qgnutls_anon) |
| 2673 | (Qgnutls_x509pki, Qgnutls_e_interrupted, Qgnutls_e_again) |
| 2674 | (Qgnutls_e_invalid_session, Qgnutls_e_not_ready_for_handshake) |
| 2675 | (gnutls_global_initialized, Qgnutls_bootprop_priority) |
| 2676 | (Qgnutls_bootprop_trustfiles, Qgnutls_bootprop_keyfiles) |
| 2677 | (Qgnutls_bootprop_callbacks, Qgnutls_bootprop_loglevel) |
| 2678 | (Qgnutls_bootprop_hostname, Qgnutls_bootprop_verify_flags) |
| 2679 | (Qgnutls_bootprop_verify_error, Qgnutls_bootprop_verify_hostname_error) |
| 2680 | (Qgnutls_bootprop_callbacks_verify): Make static. |
| 2681 | |
| 2682 | 2011-05-01 Andreas Schwab <schwab@linux-m68k.org> |
| 2683 | |
| 2684 | * callproc.c: Indentation fixup. |
| 2685 | |
| 2686 | * sysdep.c (wait_for_termination_1): Make static. |
| 2687 | (wait_for_termination, interruptible_wait_for_termination): |
| 2688 | Move after wait_for_termination_1. |
| 2689 | |
| 2690 | 2011-05-01 Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 2691 | |
| 2692 | * sysdep.c (interruptible_wait_for_termination): New function |
| 2693 | which is like wait_for_termination, but allows keyboard |
| 2694 | interruptions. |
| 2695 | |
| 2696 | * callproc.c (Fcall_process): Add (:file "file") as an option for |
| 2697 | the STDOUT buffer. |
| 2698 | (Fcall_process_region): Ditto. |
| 2699 | |
| 2700 | 2011-04-30 Eli Zaretskii <eliz@gnu.org> |
| 2701 | |
| 2702 | * dosfns.c (Fint86, Fdos_memget, Fdos_memput): Use `ASIZE (FOO)' |
| 2703 | rather than `XVECTOR (FOO)->size'. |
| 2704 | |
| 2705 | * process.c: Remove HAVE_INTTYPES_H condition from inclusion of |
| 2706 | inttypes.h, as a gnulib replacement is used if it not available in |
| 2707 | system headers. |
| 2708 | |
| 2709 | 2011-04-21 Eli Zaretskii <eliz@gnu.org> |
| 2710 | |
| 2711 | Lift the MOST_POSITIVE_FIXNUM/4 limitation on visited files. |
| 2712 | * fileio.c (Finsert_file_contents): Don't limit file size to 1/4 |
| 2713 | of MOST_POSITIVE_FIXNUM. (Bug#8528) |
| 2714 | |
| 2715 | * coding.c (coding_alloc_by_realloc): Error out if destination |
| 2716 | will grow beyond MOST_POSITIVE_FIXNUM. |
| 2717 | (decode_coding_emacs_mule): Abort if there isn't enough place in |
| 2718 | charbuf for the composition carryover bytes. Reserve an extra |
| 2719 | space for up to 2 characters produced in a loop. |
| 2720 | (decode_coding_iso_2022): Abort if there isn't enough place in |
| 2721 | charbuf for the composition carryover bytes. |
| 2722 | |
| 2723 | 2011-04-21 Eli Zaretskii <eliz@gnu.org> |
| 2724 | |
| 2725 | * doprnt.c (doprnt) [!HAVE_LONG_LONG_INT]: Error out instead of |
| 2726 | aborting when %lld or %lll format is passed. |
| 2727 | [!HAVE_UNSIGNED_LONG_LONG_INT]: Error out instead of aborting when |
| 2728 | %llo or %llx format is passed. (Bug#8545) |
| 2729 | |
| 2730 | * window.c (window_scroll_line_based): Use a marker instead of |
| 2731 | simple variables to record original value of point. (Bug#7952) |
| 2732 | |
| 2733 | * doprnt.c (doprnt): Fix the case where a multibyte sequence |
| 2734 | produced by %s or %c overflows available buffer space. (Bug#8545) |
| 2735 | |
| 2736 | 2011-04-28 Paul Eggert <eggert@cs.ucla.edu> |
| 2737 | |
| 2738 | * doprnt.c (doprnt): Omit useless test; int overflow check (Bug#8545). |
| 2739 | (SIZE_MAX): Move defn after all includes, as they might #define it. |
| 2740 | |
| 2741 | 2011-04-28 Juanma Barranquero <lekktu@gmail.com> |
| 2742 | |
| 2743 | * w32.c (init_environment): Warn about defaulting HOME to C:\. |
| 2744 | |
| 2745 | 2011-04-28 Juanma Barranquero <lekktu@gmail.com> |
| 2746 | |
| 2747 | * keyboard.c (Qdelayed_warnings_hook): Define. |
| 2748 | (command_loop_1): Run `delayed-warnings-hook' |
| 2749 | if Vdelayed_warnings_list is non-nil. |
| 2750 | (syms_of_keyboard) <delayed-warnings-hook>: DEFSYM it. |
| 2751 | (syms_of_keyboard) <delayed-warnings-list>: DEFVAR_LISP it. |
| 2752 | |
| 2753 | 2011-04-28 Eli Zaretskii <eliz@gnu.org> |
| 2754 | |
| 2755 | * doprnt.c (doprnt): Don't return value smaller than the buffer |
| 2756 | size if the message was truncated. (Bug#8545). |
| 2757 | |
| 2758 | 2011-04-28 Juanma Barranquero <lekktu@gmail.com> |
| 2759 | |
| 2760 | * w32fns.c (Fx_change_window_property, Fx_delete_window_property) |
| 2761 | (Fx_window_property): #if-0 the whole functions, not just the bodies. |
| 2762 | |
| 2763 | 2011-04-27 Paul Eggert <eggert@cs.ucla.edu> |
| 2764 | |
| 2765 | * doprnt.c (doprnt): Support "ll" length modifier, for long long. |
| 2766 | |
| 2767 | 2011-04-27 Juanma Barranquero <lekktu@gmail.com> |
| 2768 | |
| 2769 | * makefile.w32-in: Update dependencies. |
| 2770 | |
| 2771 | 2011-04-27 Eli Zaretskii <eliz@gnu.org> |
| 2772 | |
| 2773 | Improve `doprnt' and its usage. (Bug#8545) |
| 2774 | * doprnt.c (doprnt): Make sure `format' is never accessed beyond |
| 2775 | `format_end'. Remove support for %l as a conversion specifier. |
| 2776 | Don't use xrealloc. Improve diagnostics when the %l size modifier |
| 2777 | is used. Update the commentary. |
| 2778 | |
| 2779 | * eval.c (verror): Simplify calculation of size_t. |
| 2780 | |
| 2781 | * coding.c (Ffind_operation_coding_system): Fix diagnostic error |
| 2782 | messages. |
| 2783 | |
| 2784 | 2011-04-27 Yoshiaki Kasahara <kasahara@nc.kyushu-u.ac.jp> (tiny change) |
| 2785 | |
| 2786 | * buffer.c (init_buffer) [USE_MMAP_FOR_BUFFERS]: Adjust to aliasing |
| 2787 | change. |
| 2788 | |
| 2789 | 2011-04-27 Paul Eggert <eggert@cs.ucla.edu> |
| 2790 | |
| 2791 | * nsmenu.m: Replace all uses of XVECTOR with ASIZE and AREF. |
| 2792 | This makes this file independent of the recent pseudovector change. |
| 2793 | |
| 2794 | 2011-04-26 Paul Eggert <eggert@cs.ucla.edu> |
| 2795 | |
| 2796 | * keyboard.c (handle_user_signal): Fix pointer signedness problem. |
| 2797 | |
| 2798 | * gnutls.c (emacs_gnutls_handle_error): Remove unused local. |
| 2799 | (Fgnutls_boot): gnutls_certificate_verify_peers2 wants unsigned *. |
| 2800 | Remove unused local. |
| 2801 | (emacs_gnutls_write): Don't use uninitialized rtnval if nbyte <= 0. |
| 2802 | |
| 2803 | * lisp.h: Fix a problem with aliasing and vector headers. (Bug#8546) |
| 2804 | GCC 4.6.0 optimizes based on type-based alias analysis. |
| 2805 | For example, if b is of type struct buffer * and v of type struct |
| 2806 | Lisp_Vector *, then gcc -O2 was incorrectly assuming that &b->size |
| 2807 | != &v->size, and therefore "v->size = 1; b->size = 2; return |
| 2808 | v->size;" must therefore return 1. This assumption is incorrect |
| 2809 | for Emacs, since it type-puns struct Lisp_Vector * with many other |
| 2810 | types. To fix this problem, this patch adds a new type struct |
| 2811 | vectorlike_header that documents the constraints on layout of vectors |
| 2812 | and pseudovectors, and helps optimizing compilers not get fooled |
| 2813 | by Emacs's type punning. It also adds the macros XSETTYPED_PVECTYPE |
| 2814 | XSETTYPED_PSEUDOVECTOR, TYPED_PSEUDOVECTORP, for similar reasons. |
| 2815 | * lisp.h (XSETTYPED_PVECTYPE): New macro, specifying the name of |
| 2816 | the size member. |
| 2817 | (XSETPVECTYPE): Rewrite in terms of new macro. |
| 2818 | (XSETPVECTYPESIZE): New macro, specifying both type and size. |
| 2819 | This is a bit clearer, and further avoids the possibility of |
| 2820 | undesirable aliasing. |
| 2821 | (XSETTYPED_PSEUDOVECTOR): New macro, specifying the size. |
| 2822 | (XSETPSEUDOVECTOR): Rewrite in terms of XSETTYPED_PSEUDOVECTOR. |
| 2823 | (XSETSUBR): Rewrite in terms of XSETTYPED_PSEUDOVECTOR and XSIZE, |
| 2824 | since Lisp_Subr is a special case (no "next" field). |
| 2825 | (ASIZE): Now uses header.size rather than size. |
| 2826 | All previous uses of XVECTOR (foo)->size replaced to use this macro, |
| 2827 | to avoid the hassle of writing XVECTOR (foo)->header.size. |
| 2828 | (struct vectorlike_header): New type. |
| 2829 | (TYPED_PSEUDOVECTORP): New macro, also specifying the C type of the |
| 2830 | object, to help avoid aliasing. |
| 2831 | (PSEUDOVECTORP): Rewrite in terms of TYPED_PSEUDOVECTORP. |
| 2832 | (SUBRP): Likewise, since Lisp_Subr is a special case. |
| 2833 | * lisp.h (struct Lisp_Vector, struct Lisp_Char_Table): |
| 2834 | (struct Lisp_Sub_Char_Table, struct Lisp_Bool_Vector): |
| 2835 | (struct Lisp_Hash_Table): Combine first two members into a single |
| 2836 | struct vectorlike_header member. All uses of "size" and "next" members |
| 2837 | changed to be "header.size" and "header.next". |
| 2838 | * buffer.h (struct buffer): Likewise. |
| 2839 | * font.h (struct font_spec, struct font_entity, struct font): Likewise. |
| 2840 | * frame.h (struct frame): Likewise. |
| 2841 | * process.h (struct Lisp_Process): Likewise. |
| 2842 | * termhooks.h (struct terminal): Likewise. |
| 2843 | * window.c (struct save_window_data, struct saved_window): Likewise. |
| 2844 | * window.h (struct window): Likewise. |
| 2845 | * alloc.c (allocate_buffer, Fmake_bool_vector, allocate_pseudovector): |
| 2846 | Use XSETPVECTYPESIZE, not XSETPVECTYPE, to avoid aliasing problems. |
| 2847 | * buffer.c (init_buffer_once): Likewise. |
| 2848 | * lread.c (defsubr): Use XSETTYPED_PVECTYPE, since Lisp_Subr is a |
| 2849 | special case. |
| 2850 | * process.c (Fformat_network_address): Use local var for size, |
| 2851 | for brevity. |
| 2852 | |
| 2853 | * bytecode.c (exec_byte_code): Don't use XVECTOR before CHECK_VECTOR. |
| 2854 | |
| 2855 | Make the Lisp reader and string-to-float more consistent (Bug#8525) |
| 2856 | * data.c (atof): Remove decl; no longer used or needed. |
| 2857 | (digit_to_number): Move to lread.c. |
| 2858 | (Fstring_to_number): Use new string_to_number function, to be |
| 2859 | consistent with how the Lisp reader treats infinities and NaNs. |
| 2860 | Do not assume that floating-point numbers represent EMACS_INT |
| 2861 | without losing information; this is not true on most 64-bit hosts. |
| 2862 | Avoid double-rounding errors, by insisting on integers when |
| 2863 | parsing non-base-10 numbers, as the documentation specifies. |
| 2864 | * lisp.h (string_to_number): New decl, replacing ... |
| 2865 | (isfloat_string): Remove. |
| 2866 | * lread.c: Include <inttypes.h>, for uintmax_t and strtoumax. |
| 2867 | (read1): Do not accept +. and -. as integers; this |
| 2868 | appears to have been a coding error. Similarly, do not accept |
| 2869 | strings like +-1e0 as floating point numbers. Do not report |
| 2870 | overflow for integer overflows unless the base is not 10 which |
| 2871 | means we have no simple and reliable way to continue. |
| 2872 | Break out the floating-point parsing into a new |
| 2873 | function string_to_number, so that Fstring_to_number parses |
| 2874 | floating point numbers consistently with the Lisp reader. |
| 2875 | (digit_to_number): Move here from data.c. Make it static inline. |
| 2876 | (E_CHAR, EXP_INT): Remove, replacing with ... |
| 2877 | (E_EXP): New macro, to solve the "1.0e+" problem mentioned below. |
| 2878 | (string_to_number): New function, replacing isfloat_string. |
| 2879 | This function checks for valid syntax and produces the resulting |
| 2880 | Lisp float number too. Rework it so that string-to-number |
| 2881 | no longer mishandles examples like "1.0e+". Use strtoumax, |
| 2882 | so that overflow for non-base-10 numbers is reported only when |
| 2883 | there's no portable and simple way to convert to floating point. |
| 2884 | |
| 2885 | * textprop.c (set_text_properties_1): Rewrite for clarity, |
| 2886 | and to avoid GCC warning about integer overflow. |
| 2887 | |
| 2888 | * intervals.h (struct interval): Use EMACS_INT for members |
| 2889 | where EMACS_UINT might cause problems. See |
| 2890 | <http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00514.html>. |
| 2891 | (CHECK_TOTAL_LENGTH): Remove cast to EMACS_INT; no longer needed. |
| 2892 | * intervals.c (interval_deletion_adjustment): Now returns EMACS_INT. |
| 2893 | All uses changed. |
| 2894 | (offset_intervals): Tell GCC not to worry about length overflow |
| 2895 | when negating a negative length. |
| 2896 | |
| 2897 | * alloc.c (overrun_check_malloc, overrun_check_realloc): Now static. |
| 2898 | (overrun_check_free): Likewise. |
| 2899 | |
| 2900 | * alloc.c (SDATA_SIZE) [!GC_CHECK_STRING_BYTES]: Avoid runtime check |
| 2901 | in the common case where SDATA_DATA_OFFSET is a multiple of Emacs |
| 2902 | word size. |
| 2903 | |
| 2904 | * gnutls.c: Fix problems found by GCC 4.6.0 on Ubuntu 10.10. |
| 2905 | (gnutls_make_error): Rename local to avoid shadowing. |
| 2906 | (gnutls_emacs_global_deinit): ifdef out; not used. |
| 2907 | (Fgnutls_boot): Use const for pointer to readonly storage. |
| 2908 | Comment out unused local. Fix pointer signedness problems. |
| 2909 | |
| 2910 | * lread.c (openp): Don't stuff size_t into an 'int'. |
| 2911 | Use <= on length, not < on length + 1, to avoid GCC 4.6.0 warning |
| 2912 | about possible signed overflow. |
| 2913 | |
| 2914 | * gtkutil.c: Fix problems found by GCC 4.6.0 on Ubuntu 10.10. |
| 2915 | (GDK_KEY_g): Don't define if already defined. |
| 2916 | (xg_prepare_tooltip): Avoid pointer signedness problem. |
| 2917 | (xg_set_toolkit_scroll_bar_thumb): Redo to avoid two casts. |
| 2918 | |
| 2919 | * process.c (Fnetwork_interface_info): Avoid left-shift undefined |
| 2920 | behavior with 1 << 31. GCC 4.6.0 warns about this on 32-bit hosts. |
| 2921 | |
| 2922 | * xfns.c (Fx_window_property): Simplify a bit, |
| 2923 | to make a bit faster and to avoid GCC 4.6.0 warning. |
| 2924 | * xselect.c (x_get_window_property, x_handle_dnd_message): Likewise. |
| 2925 | |
| 2926 | * fns.c (internal_equal): Don't assume size_t fits in int. |
| 2927 | |
| 2928 | * alloc.c (compact_small_strings): Tighten assertion a little. |
| 2929 | |
| 2930 | Replace pEd with more-general pI, and fix some printf arg casts. |
| 2931 | * lisp.h (pI): New macro, generalizing old pEd macro to other |
| 2932 | conversion specifiers. For example, use "...%"pI"d..." rather |
| 2933 | than "...%"pEd"...". |
| 2934 | (pEd): Remove. All uses replaced with similar uses of pI. |
| 2935 | * src/m/amdx86-64.h, src/m/ia64.h, src/m/ibms390x.h: Likewise. |
| 2936 | * alloc.c (check_pure_size): Don't overflow by converting size to int. |
| 2937 | * bidi.c (bidi_dump_cached_states): Use pI to avoid cast. |
| 2938 | * data.c (Fnumber_to_string): Use pI instead of if-then-else-abort. |
| 2939 | * dbusbind.c (xd_append_arg): Use pI to avoid cast. |
| 2940 | (Fdbus_method_return_internal, Fdbus_method_error_internal): Likewise. |
| 2941 | * font.c (font_unparse_xlfd): Avoid potential buffer overrun on |
| 2942 | 64-bit hosts. |
| 2943 | (font_unparse_xlfd, font_unparse_fcname): Use pI to avoid casts. |
| 2944 | * keyboard.c (record_char, modify_event_symbol): Use pI to avoid casts. |
| 2945 | * print.c (safe_debug_print, print_object): Likewise. |
| 2946 | (print_object): Don't overflow by converting EMACS_INT or EMACS_UINT |
| 2947 | to int. |
| 2948 | Use pI instead of if-then-else-abort. Use %p to avoid casts, |
| 2949 | avoiding the 0 flag, which is not portable. |
| 2950 | * process.c (Fmake_network_process): Use pI to avoid cast. |
| 2951 | * region-cache.c (pp_cache): Likewise. |
| 2952 | * xdisp.c (decode_mode_spec): Likewise. |
| 2953 | * xrdb.c (x_load_resources) [USE_MOTIF]: Use pI to avoid undefined |
| 2954 | behavior on 64-bit hosts with printf arg. |
| 2955 | * xselect.c (x_queue_event): Use %p to avoid casts, avoiding 0 flag. |
| 2956 | (x_stop_queuing_selection_requests): Likewise. |
| 2957 | (x_get_window_property): Don't truncate byte count to an 'int' |
| 2958 | when tracing. |
| 2959 | |
| 2960 | * frame.c (frame_name_fnn_p): Get rid of strtol, which isn't right |
| 2961 | here, since it parses constructs like leading '-' and spaces, |
| 2962 | which are not wanted; and it overflows with large numbers. |
| 2963 | Instead, simply match F[0-9]+, which is what is wanted anyway. |
| 2964 | |
| 2965 | * alloc.c: Remove unportable assumptions about struct layout. |
| 2966 | (SDATA_SELECTOR, SDATA_DATA_OFFSET): New macros. |
| 2967 | (SDATA_OF_STRING, SDATA_SIZE, allocate_string_data): |
| 2968 | (allocate_vectorlike, make_pure_vector): Use the new macros, |
| 2969 | plus offsetof, to remove unportable assumptions about struct layout. |
| 2970 | These assumptions hold on all porting targets that I know of, but |
| 2971 | they are not guaranteed, they're easy to remove, and removing them |
| 2972 | makes further changes easier. |
| 2973 | |
| 2974 | * alloc.c (BLOCK BYTES): Fix typo by changing "ablock" to "ablocks". |
| 2975 | This doesn't fix a bug but makes the code clearer. |
| 2976 | (string_overrun_cookie): Now const. Use initializers that |
| 2977 | don't formally overflow signed char, to avoid warnings. |
| 2978 | (allocate_string_data) [GC_CHECK_STRING_OVERRUN]: Fix typo that |
| 2979 | can cause Emacs to crash when string overrun checking is enabled. |
| 2980 | (allocate_buffer): Don't assume sizeof (struct buffer) is a |
| 2981 | multiple of sizeof (EMACS_INT); it need not be, if |
| 2982 | alignof(EMACS_INT) < sizeof (EMACS_INT). |
| 2983 | (check_sblock, check_string_bytes, check_string_free_list): Protoize. |
| 2984 | |
| 2985 | 2011-04-26 Juanma Barranquero <lekktu@gmail.com> |
| 2986 | |
| 2987 | * keyboard.c (QCrtl): Rename from Qrtl. All uses changed. |
| 2988 | |
| 2989 | 2011-04-26 Teodor Zlatanov <tzz@lifelogs.com> |
| 2990 | |
| 2991 | * gnutls.c (emacs_gnutls_handshake): Return an error if we're not |
| 2992 | supposed to be handshaking. (Bug#8556) |
| 2993 | Reported by Paul Eggert <eggert@cs.ucla.edu>. |
| 2994 | |
| 2995 | 2011-04-26 Daniel Colascione <dan.colascione@gmail.com> |
| 2996 | |
| 2997 | * lisp.h (Qdebug): List symbol. |
| 2998 | * eval.c (Qdebug): Restore global linkage. |
| 2999 | * keyboard.c (debug-on-event): New variable. |
| 3000 | (handle_user_signal): Break into debugger when debug-on-event |
| 3001 | matches the current signal symbol. |
| 3002 | |
| 3003 | 2011-04-25 Dan Nicolaescu <dann@ics.uci.edu> |
| 3004 | |
| 3005 | * alloc.c (check_sblock, check_string_bytes) |
| 3006 | (check_string_free_list): Convert to standard C. |
| 3007 | |
| 3008 | 2011-04-25 Teodor Zlatanov <tzz@lifelogs.com> |
| 3009 | |
| 3010 | * w32.c (emacs_gnutls_push): Fix typo. |
| 3011 | |
| 3012 | 2011-04-25 Eli Zaretskii <eliz@gnu.org> |
| 3013 | |
| 3014 | * gnutls.c (emacs_gnutls_handshake): Avoid compiler warnings about |
| 3015 | "cast to pointer from integer of different size". |
| 3016 | |
| 3017 | Improve doprnt and its use in verror. (Bug#8545) |
| 3018 | * doprnt.c (doprnt): Document the set of format control sequences |
| 3019 | supported by the function. Use SAFE_ALLOCA instead of always |
| 3020 | using `alloca'. |
| 3021 | |
| 3022 | * eval.c (verror): Don't limit the buffer size at size_max-1, that |
| 3023 | is one byte too soon. Don't use xrealloc; instead xfree and |
| 3024 | xmalloc anew. |
| 3025 | |
| 3026 | 2011-04-24 Teodor Zlatanov <tzz@lifelogs.com> |
| 3027 | |
| 3028 | * gnutls.h: Add GNUTLS_STAGE_CALLBACKS enum to denote we're in the |
| 3029 | callbacks stage. |
| 3030 | |
| 3031 | * gnutls.c: Renamed global_initialized to |
| 3032 | gnutls_global_initialized. Added internals for the |
| 3033 | :verify-hostname-error, :verify-error, and :verify-flags |
| 3034 | parameters of `gnutls-boot' and documented those parameters in the |
| 3035 | docstring. Start callback support. |
| 3036 | (emacs_gnutls_handshake): Add Woe32 support. Retry handshake |
| 3037 | unless a fatal error occurred. Call gnutls_alert_send_appropriate |
| 3038 | on error. Return error code. |
| 3039 | (emacs_gnutls_write): Call emacs_gnutls_handle_error. |
| 3040 | (emacs_gnutls_read): Likewise. |
| 3041 | (Fgnutls_boot): Return handshake error code. |
| 3042 | (emacs_gnutls_handle_error): New function. |
| 3043 | (wsaerror_to_errno): Likewise. |
| 3044 | |
| 3045 | * w32.h (emacs_gnutls_pull): Add prototype. |
| 3046 | (emacs_gnutls_push): Likewise. |
| 3047 | |
| 3048 | * w32.c (emacs_gnutls_pull): New function for GnuTLS on Woe32. |
| 3049 | (emacs_gnutls_push): Likewise. |
| 3050 | |
| 3051 | 2011-04-24 Claudio Bley <claudio.bley@gmail.com> (tiny change) |
| 3052 | |
| 3053 | * process.c (wait_reading_process_output): Check if GnuTLS |
| 3054 | buffered some data internally if no FDs are set for TLS |
| 3055 | connections. |
| 3056 | |
| 3057 | * makefile.w32-in (OBJ2): Add gnutls.$(O). |
| 3058 | (LIBS): Link to USER_LIBS. |
| 3059 | ($(BLD)/gnutls.$(0)): New target. |
| 3060 | |
| 3061 | 2011-04-24 Eli Zaretskii <eliz@gnu.org> |
| 3062 | |
| 3063 | * xdisp.c (handle_single_display_spec): Rename the |
| 3064 | display_replaced_before_p argument into display_replaced_p, to |
| 3065 | make it consistent with the commentary. Fix typos in the |
| 3066 | commentary. |
| 3067 | |
| 3068 | * textprop.c (syms_of_textprop): Remove dead code. |
| 3069 | (copy_text_properties): Delete obsolete commentary about an |
| 3070 | interface that was deleted long ago. Fix typos in the description |
| 3071 | of arguments. |
| 3072 | |
| 3073 | * msdos.c (XMenuActivate, XMenuAddSelection): Adjust argument list |
| 3074 | to changes in oldXMenu/XMenu.h from 2011-04-16. |
| 3075 | <menu_help_message, prev_menu_help_message>: Constify. |
| 3076 | (IT_menu_make_room): menu->help_text is now `const char **'; |
| 3077 | adjust. |
| 3078 | |
| 3079 | * msdos.h (XMenuActivate, XMenuAddSelection): Adjust prototypes |
| 3080 | to changes in oldXMenu/XMenu.h from 2011-04-16. |
| 3081 | (struct XMenu): Declare `help_text' `const char **'. |
| 3082 | |
| 3083 | * xfaces.c <Qunspecified>: Make extern again. |
| 3084 | |
| 3085 | * syntax.c: Include sys/types.h before including regex.h, as |
| 3086 | required by Posix. |
| 3087 | |
| 3088 | * doc.c (get_doc_string): Improve the format passed to `error'. |
| 3089 | |
| 3090 | * doprnt.c (doprnt): Improve commentary. |
| 3091 | |
| 3092 | * term.c (init_tty) [MSDOS]: Fix 1st argument to maybe_fatal. |
| 3093 | |
| 3094 | * Makefile.in (TAGS): Depend on $(M_FILE) and $(S_FILE), and scan |
| 3095 | them with etags. |
| 3096 | |
| 3097 | * makefile.w32-in (globals.h): Add a dummy recipe, to make any |
| 3098 | changes in globals.h immediately force recompilation. |
| 3099 | (TAGS): Depend on $(CURDIR)/m/intel386.h and |
| 3100 | $(CURDIR)/s/ms-w32.h. |
| 3101 | (TAGS-gmake): Scan $(CURDIR)/m/intel386.h and $(CURDIR)/s/ms-w32.h. |
| 3102 | |
| 3103 | * character.c (Fchar_direction): Function deleted. |
| 3104 | (syms_of_character): Don't defsubr it. |
| 3105 | <char-direction-table>: Deleted. |
| 3106 | |
| 3107 | 2011-04-23 Eli Zaretskii <eliz@gnu.org> |
| 3108 | |
| 3109 | Fix doprnt so it could be used again safely in `verror'. (Bug#8435) |
| 3110 | * doprnt.c: Include limits.h. |
| 3111 | (SIZE_MAX): New macro. |
| 3112 | (doprnt): Return a size_t value. 2nd arg is now size_t. |
| 3113 | Many local variables are now size_t instead of int or unsigned. |
| 3114 | Improve overflow protection. Support `l' modifier for integer |
| 3115 | conversions. Support %l conversion. Don't assume an EMACS_INT |
| 3116 | argument for integer conversions and for %c. |
| 3117 | |
| 3118 | * lisp.h (doprnt): Restore prototype. |
| 3119 | |
| 3120 | * makefile.w32-in ($(BLD)/callint.$(O)): Depend on |
| 3121 | $(SRC)/character.h. |
| 3122 | |
| 3123 | * Makefile.in (base_obj): Add back doprnt.o. |
| 3124 | |
| 3125 | * deps.mk (doprnt.o): Add back prerequisites. |
| 3126 | (callint.o): Depend on character.h. |
| 3127 | |
| 3128 | * eval.c (internal_lisp_condition_case): Include the handler |
| 3129 | representation in the error message. |
| 3130 | (verror): Call doprnt instead of vsnprintf. Fix an off-by-one bug |
| 3131 | when breaking from the loop. |
| 3132 | |
| 3133 | * xdisp.c (vmessage): Call doprnt instead of vsnprintf. |
| 3134 | |
| 3135 | * callint.c (Fcall_interactively): When displaying error message |
| 3136 | about invalid control letter, pass the character's codepoint, not |
| 3137 | a pointer to its multibyte form. Improve display of the character |
| 3138 | in octal and display also its hex code. |
| 3139 | |
| 3140 | * character.c (char_string): Use %x to display the (unsigned) |
| 3141 | codepoint of an invalid character, to avoid displaying a bogus |
| 3142 | negative value. |
| 3143 | |
| 3144 | * font.c (check_otf_features): Pass SDATA of SYMBOL_NAME to |
| 3145 | `error', not SYMBOL_NAME itself. |
| 3146 | |
| 3147 | * coding.c (Fencode_sjis_char, Fencode_big5_char): Use %c for |
| 3148 | character arguments to `error'. |
| 3149 | |
| 3150 | * charset.c (check_iso_charset_parameter): Fix incorrect argument |
| 3151 | to `error' in error message about FINAL_CHAR argument. Make sure |
| 3152 | FINAL_CHAR is a character, and use %c when it is passed as |
| 3153 | argument to `error'. |
| 3154 | |
| 3155 | 2011-04-23 Eli Zaretskii <eliz@gnu.org> |
| 3156 | |
| 3157 | * s/ms-w32.h (localtime): Redirect to sys_localtime. |
| 3158 | |
| 3159 | * w32.c: Include <time.h>. |
| 3160 | (sys_localtime): New function. |
| 3161 | |
| 3162 | 2011-04-23 Chong Yidong <cyd@stupidchicken.com> |
| 3163 | |
| 3164 | * xdisp.c (init_xdisp): Initialize echo_area_window (Bug#6451). |
| 3165 | |
| 3166 | * buffer.c (syms_of_buffer): Doc fix (Bug#6902). |
| 3167 | |
| 3168 | 2011-04-23 Samuel Thibault <sthibault@debian.org> (tiny change) |
| 3169 | |
| 3170 | * sysdep.c (wait_for_termination): On GNU Hurd, kill returns -1 on |
| 3171 | zombies (Bug#8467). |
| 3172 | |
| 3173 | 2011-04-19 Eli Zaretskii <eliz@gnu.org> |
| 3174 | |
| 3175 | * syntax.h (SETUP_SYNTAX_TABLE_FOR_OBJECT): Fix setting of |
| 3176 | gl_state.e_property when gl_state.object is Qt. |
| 3177 | |
| 3178 | * insdel.c (make_gap_larger): Remove limitation of buffer size |
| 3179 | to <= INT_MAX. |
| 3180 | |
| 3181 | 2011-04-18 Chong Yidong <cyd@stupidchicken.com> |
| 3182 | |
| 3183 | * xdisp.c (lookup_glyphless_char_display) |
| 3184 | (produce_glyphless_glyph): Handle cons cell entry in |
| 3185 | glyphless-char-display. |
| 3186 | (Vglyphless_char_display): Document it. |
| 3187 | |
| 3188 | * term.c (produce_glyphless_glyph): Handle cons cell entry in |
| 3189 | glyphless-char-display. |
| 3190 | |
| 3191 | 2011-04-17 Chong Yidong <cyd@stupidchicken.com> |
| 3192 | |
| 3193 | * xdisp.c (get_next_display_element): Remove unnecessary ifdefs. |
| 3194 | |
| 3195 | * termhooks.h (FRAME_WINDOW_P): Remove duplicated definitions. |
| 3196 | |
| 3197 | * dispextern.h (FACE_SUITABLE_FOR_ASCII_CHAR_P): Add missing |
| 3198 | definition for no-X builds. |
| 3199 | |
| 3200 | 2011-04-16 Paul Eggert <eggert@cs.ucla.edu> |
| 3201 | |
| 3202 | Static checks with GCC 4.6.0 and non-default toolkits. |
| 3203 | |
| 3204 | * s/sol2-6.h, s/unixware.h (PTY_TTY_NAME_SPRINTF): Protoize decl. |
| 3205 | |
| 3206 | * process.c (keyboard_bit_set): Define only if SIGIO. |
| 3207 | (send_process_trap): Mark it with NO_RETURN if it doesn't return. |
| 3208 | (send_process): Repair possible setjmp clobbering. |
| 3209 | |
| 3210 | * s/usg5-4-common.h (SETUP_SLAVE_PTY): Don't pass extra arg to 'fatal'. |
| 3211 | |
| 3212 | * eval.c: Include <stdio.h>, for vsnprintf on non-GNU/Linux hosts. |
| 3213 | |
| 3214 | * data.c (arith_error): Mark with NO_RETURN if it doesn't return. |
| 3215 | |
| 3216 | * alloc.c (bytes_used_when_full, SPARE_MEMORY, BYTES_USED): |
| 3217 | Define only if needed. |
| 3218 | |
| 3219 | * sysdep.c (_FILE_OFFSET_BITS): Make this hack even uglier |
| 3220 | by pacifying GCC about it. Maybe it's time to retire it? |
| 3221 | * xfaces.c (USG, __TIMEVAL__): Likewise. |
| 3222 | |
| 3223 | * dispextern.h (struct redisplay_interface): Rename param |
| 3224 | to avoid shadowing. |
| 3225 | * termhooks.h (struct terminal): Likewise. |
| 3226 | * xterm.c (xembed_send_message): Likewise. |
| 3227 | |
| 3228 | * insdel.c (make_gap_smaller): Define only if |
| 3229 | USE_MMAP_FOR_BUFFERS || REL_ALLOC || DOUG_LEA_MALLOC. |
| 3230 | |
| 3231 | * keyboard.c (read_char): Make a var volatile so longjmp won't clobber |
| 3232 | it. |
| 3233 | |
| 3234 | * emacs.c (MAX_HEAP_BSS_DIFF, my_edata): Move to where they're used, |
| 3235 | so that we aren't warned about unused symbols. |
| 3236 | |
| 3237 | * xfns.c (Fx_file_dialog): Rename local to avoid shadowing. |
| 3238 | |
| 3239 | * xdisp.c (x_produce_glyphs): Mark var as initialized (Bug#8512). |
| 3240 | |
| 3241 | * xfns.c (x_real_positions): Mark locals as initialized. |
| 3242 | |
| 3243 | * xmenu.c (xmenu_show): Don't use uninitialized vars. |
| 3244 | |
| 3245 | * xterm.c: Fix problems found by static analysis with other toolkits. |
| 3246 | (toolkit_scroll_bar_interaction): Define and use only if USE_X_TOOLKIT. |
| 3247 | (x_dispatch_event): Declare static if USE_GTK, and |
| 3248 | define if USE_GTK || USE_X_TOOLKIT. |
| 3249 | (SET_SAVED_BUTTON_EVENT): Define only if USE_X_TOOLKIT || USE_GTK. |
| 3250 | * xterm.h (x_dispatch_event): Extern only if USE_X_TOOLKIT. |
| 3251 | * xterm.c, xterm.h (x_mouse_leave): Bring this function back, but only |
| 3252 | if defined HAVE_MENUS && !defined USE_X_TOOLKIT && !defined USE_GTK. |
| 3253 | |
| 3254 | * xmenu.c (menu_help_callback): Pointer type fixes. |
| 3255 | Use const pointers when pointing at readonly data. Avoid pointer |
| 3256 | signedness clashes. |
| 3257 | (FALSE): Remove unused macro. |
| 3258 | (update_frame_menubar): Remove unused decl. |
| 3259 | |
| 3260 | * xfns.c (Fx_hide_tip): Move locals to avoid shadowing. |
| 3261 | |
| 3262 | * menu.c (push_submenu_start, push_submenu_end): Do not define unless |
| 3263 | USE_X_TOOLKIT || USE_GTK || HAVE_NS || defined HAVE_NTGUI. |
| 3264 | (single_menu_item): Rename local to avoid shadowing. |
| 3265 | |
| 3266 | * keyboard.c (make_lispy_event): Remove unused local var. |
| 3267 | |
| 3268 | * frame.c, frame.h (x_get_resource_string): Bring this back, but |
| 3269 | only if HAVE_X_WINDOWS && !USE_X_TOOLKIT. |
| 3270 | |
| 3271 | * bitmaps: Change bitmaps from unsigned char back to the X11 |
| 3272 | compatible char. Avoid the old compiler warnings about |
| 3273 | out-of-range initializers by using, for example, '\xab' rather |
| 3274 | than 0xab. |
| 3275 | |
| 3276 | * xgselect.c (xgselect_initialize): Check vs interface |
| 3277 | even if ! (defined (USE_GTK) || defined (HAVE_GCONF)). |
| 3278 | |
| 3279 | * xmenu.c (xmenu_show): Rename parm to avoid shadowing. |
| 3280 | |
| 3281 | * xterm.c (x_create_toolkit_scroll_bar): Use const * for pointers |
| 3282 | to read-only memory. |
| 3283 | |
| 3284 | * fns.c (vector): Remove; this old hack is no longer needed. |
| 3285 | |
| 3286 | * xsmfns.c (create_client_leader_window): Rename shadowing arg. |
| 3287 | Remove unused var. |
| 3288 | (gdk_x11_set_sm_client_id) [!USE_GTK]: Don't define. |
| 3289 | |
| 3290 | * xrdb.c (x_load_resources): Omit unused local. |
| 3291 | |
| 3292 | * xfns.c (free_frame_menubar, atof): Remove duplicate decls. |
| 3293 | (x_window): Rename locals to avoid shadowing. |
| 3294 | (USG): Use the kludged USG macro, to pacify gcc. |
| 3295 | |
| 3296 | * xterm.c (x_alloc_nearest_color_for_widget): Remove; unused. |
| 3297 | (x_term_init): Remove local to avoid shadowing. |
| 3298 | |
| 3299 | * xfns.c, xterm.c (_XEditResCheckMessages): Protoize decl. |
| 3300 | |
| 3301 | * xdisp.c, dispextern.h (set_vertical_scroll_bar): Now extern if |
| 3302 | USE_TOOLKIT_SCROLL_BARS && !USE_GTK, as xterm.c needs it then. |
| 3303 | |
| 3304 | 2011-04-16 Eli Zaretskii <eliz@gnu.org> |
| 3305 | |
| 3306 | * gnutls.c (Fgnutls_boot): Don't pass Lisp_Object to `error'. |
| 3307 | |
| 3308 | Fix regex.c, syntax.c and friends for buffers > 2GB. |
| 3309 | * syntax.h (struct gl_state_s): Declare character position members |
| 3310 | EMACS_INT. |
| 3311 | |
| 3312 | * syntax.c (update_syntax_table): Declare 2nd argument EMACS_INT. |
| 3313 | |
| 3314 | * textprop.c (verify_interval_modification, interval_of): |
| 3315 | Declare arguments EMACS_INT. |
| 3316 | |
| 3317 | * intervals.c (adjust_intervals_for_insertion): Declare arguments |
| 3318 | EMACS_INT. |
| 3319 | |
| 3320 | * intervals.h (CHECK_TOTAL_LENGTH): Cast to EMACS_INT, not `int'. |
| 3321 | |
| 3322 | * indent.c (Fvertical_motion): Local variable it_start is now |
| 3323 | EMACS_INT. |
| 3324 | |
| 3325 | * regex.c (re_match, re_match_2, re_match_2_internal) |
| 3326 | (bcmp_translate, regcomp, regexec, print_double_string) |
| 3327 | (group_in_compile_stack, re_search, re_search_2, regex_compile) |
| 3328 | (re_compile_pattern, re_exec): Declare arguments and local |
| 3329 | variables `size_t' and `ssize_t' and return values `regoff_t', as |
| 3330 | appropriate. |
| 3331 | (POP_FAILURE_REG_OR_COUNT) <pfreg>: Declare `long'. |
| 3332 | (CHECK_INFINITE_LOOP) <failure>: Declare `ssize_t'. |
| 3333 | <compile_stack_type>: `size' and `avail' are now `size_t'. |
| 3334 | |
| 3335 | * regex.h <regoff_t>: Use ssize_t, not int. |
| 3336 | (re_search, re_search_2, re_match, re_match_2): Arguments that |
| 3337 | specify buffer/string position and length are now ssize_t and |
| 3338 | size_t. Return type is regoff_t. |
| 3339 | |
| 3340 | 2011-04-16 Ben Key <bkey76@gmail.com> |
| 3341 | |
| 3342 | * nsfont.m: Fixed bugs in ns_get_family and |
| 3343 | ns_descriptor_to_entity that were caused by using free to |
| 3344 | deallocate memory blocks that were allocated by xmalloc (via |
| 3345 | xstrdup). This caused Emacs to crash when compiled with |
| 3346 | XMALLOC_OVERRUN_CHECK defined (when Emacs was configured with |
| 3347 | --enable-checking=xmallocoverrun). xfree is now used to |
| 3348 | deallocate these memory blocks. |
| 3349 | |
| 3350 | 2011-04-15 Paul Eggert <eggert@cs.ucla.edu> |
| 3351 | |
| 3352 | * sysdep.c (emacs_read): Remove unnecessary check vs MAX_RW_COUNT. |
| 3353 | |
| 3354 | emacs_write: Accept and return EMACS_INT for sizes. |
| 3355 | See http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00514.html |
| 3356 | et seq. |
| 3357 | * gnutls.c, gnutls.h (emacs_gnutls_read, emacs_gnutls_write): |
| 3358 | Accept and return EMACS_INT. |
| 3359 | (emacs_gnutls_write): Return the number of bytes written on |
| 3360 | partial writes. |
| 3361 | * sysdep.c, lisp.h (emacs_read, emacs_write): Likewise. |
| 3362 | (emacs_read, emacs_write): Remove check for negative size, as the |
| 3363 | Emacs source code has been audited now. |
| 3364 | * sysdep.c (MAX_RW_COUNT): New macro, to work around kernel bugs. |
| 3365 | (emacs_read, emacs_write): Use it. |
| 3366 | * process.c (send_process): Adjust to the new signatures of |
| 3367 | emacs_write and emacs_gnutls_write. Do not attempt to store |
| 3368 | a byte offset into an 'int'; it might overflow. |
| 3369 | See http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00483.html |
| 3370 | |
| 3371 | * sound.c: Don't assume sizes fit in 'int'. |
| 3372 | (struct sound_device.period_size, alsa_period_size): |
| 3373 | Return EMACS_INT, not int. |
| 3374 | (struct sound_device.write, vox_write, alsa_write): |
| 3375 | Accept EMACS_INT, not int. |
| 3376 | (wav_play, au_play): Use EMACS_INT to store sizes and to |
| 3377 | record read return values. |
| 3378 | |
| 3379 | 2011-04-15 Ben Key <bkey76@gmail.com> |
| 3380 | |
| 3381 | * keyboard.c (Qundefined): Don't declare static since it is used |
| 3382 | in nsfns.m. |
| 3383 | * xfaces.c (Qbold, Qexpanded, Qitalic, Qcondensed): Don't declare |
| 3384 | static since they are used in nsfont.m. |
| 3385 | |
| 3386 | 2011-04-15 Stefan Monnier <monnier@iro.umontreal.ca> |
| 3387 | |
| 3388 | * process.c (Qprocessp): Don't declare static. |
| 3389 | * lisp.h (Qprocessp): Declare again. |
| 3390 | |
| 3391 | 2011-04-15 Juanma Barranquero <lekktu@gmail.com> |
| 3392 | |
| 3393 | * font.c (Qopentype): Don't make static (used from w32uniscribe.c). |
| 3394 | |
| 3395 | 2011-04-14 Paul Eggert <eggert@cs.ucla.edu> |
| 3396 | |
| 3397 | Improve C-level modularity by making more things 'static'. |
| 3398 | |
| 3399 | Don't publish debugger-only interfaces to other modules. |
| 3400 | * lisp.h (safe_debug_print, debug_output_compilation_hack): |
| 3401 | (verify_bytepos, count_markers): Move decls to the only modules |
| 3402 | that need them. |
| 3403 | * region-cache.h (pp_cache): Likewise. |
| 3404 | * window.h (check_all_windows): Likewise. |
| 3405 | * marker.c, print.c, region-cache.c, window.c: Decls moved here. |
| 3406 | |
| 3407 | * sysdep.c (croak): Now static, if |
| 3408 | defined TIOCNOTTY || defined USG5 || defined CYGWIN. |
| 3409 | * syssignal.h (croak): Declare only if not static. |
| 3410 | |
| 3411 | * alloc.c (refill_memory_reserve): Now static if |
| 3412 | !defined REL_ALLOC || defined SYSTEM_MALLOC. |
| 3413 | * lisp.h (refill_memory_reserve): Declare only if not static. |
| 3414 | |
| 3415 | * xsettings.c, xsettings.h (xsettings_get_system_normal_font): |
| 3416 | Define only if USE_LUCID. |
| 3417 | |
| 3418 | * xrdb.c (x_customization_string, x_rm_string): Now static. |
| 3419 | |
| 3420 | * xmenu.c (x_menu_wait_for_event): Export only if USE_MOTIF. |
| 3421 | * xterm.h (x_menu_wait_for_event): Declare only if USE_MOTIF. |
| 3422 | |
| 3423 | * xdisp.c (draw_row_with_mouse_face): Now static. |
| 3424 | * dispextern.h (draw_row_with_mouse_fave): Remove decl. |
| 3425 | |
| 3426 | * window.h (check_all_windows): Mark externally visible. |
| 3427 | |
| 3428 | * window.c (window_deletion_count): Now static. |
| 3429 | |
| 3430 | * undo.c: Make symbols static if they're not exported. |
| 3431 | (last_undo_buffer, last_boundary_position, pending_boundary): |
| 3432 | Now static. |
| 3433 | |
| 3434 | * textprop.c (interval_insert_behind_hooks): Now static. |
| 3435 | (interval_insert_in_front_hooks): Likewise. |
| 3436 | |
| 3437 | * term.c: Make symbols static if they're not exported. |
| 3438 | (tty_turn_off_highlight, get_tty_terminal, max_frame_cols): |
| 3439 | (max_frame_lines, tty_set_terminal_modes): |
| 3440 | (tty_reset_terminal_modes, tty_turn_off_highlight): |
| 3441 | (get_tty_terminal): Now static. |
| 3442 | (term_mouse_moveto): Do not define if HAVE_WINDOW_SYSTEM. |
| 3443 | * termhooks.h (term_mouse_moveto): Do not declare if |
| 3444 | HAVE_WINDOW_SYSTEM. |
| 3445 | * dispextern.h (tty_set_terminal_modes, tty_reset_terminal_modes): |
| 3446 | (tty_turn_off_highlight, get_tty_terminal): Remove decls. |
| 3447 | |
| 3448 | * sysdep.c: Make symbols static if they're not exported. |
| 3449 | (emacs_get_tty, emacs_set_tty, old_fcntl_flags, old_fcntl_owner): |
| 3450 | Now static. |
| 3451 | (sigprocmask_set, full_mask): Remove; unused. |
| 3452 | (wait_debugging): Mark as visible. |
| 3453 | * syssignal.h (SIGFULLMASK, full_mask): Remove decls. |
| 3454 | * systty.h (emacs_get_tty, emacs_set_tty): Remove decls. |
| 3455 | |
| 3456 | * syntax.c (syntax_temp): Define only if !__GNUC__. |
| 3457 | |
| 3458 | * sound.c (current_sound_device, current_sound): Now static. |
| 3459 | |
| 3460 | * search.c (searchbufs, searchbuf_head): Now static. |
| 3461 | |
| 3462 | * scroll.c (scroll_cost): Remove; unused. |
| 3463 | * dispextern.h (scroll_cost): Remove decl. |
| 3464 | |
| 3465 | * region-cache.h (pp_cache): Mark as externally visible. |
| 3466 | |
| 3467 | * process.c: Make symbols static if they're not exported. |
| 3468 | (process_tick, update_tick, create_process, chan_process): |
| 3469 | (Vprocess_alist, proc_buffered_char, datagram_access): |
| 3470 | (fd_callback_data, send_process_frame, process_sent_to): Now static. |
| 3471 | (deactivate_process): Mark defn as static, as well as decl. |
| 3472 | * lisp.h (create_process): Remove decl. |
| 3473 | * process.h (chan_process, Vprocess_alist): Remove decls. |
| 3474 | |
| 3475 | * print.c: Make symbols static if they're not exported. |
| 3476 | (print_depth, new_backquote_output, being_printed, print_buffer): |
| 3477 | (print_buffer_size, print_buffer_pos, print_buffer_pos_byte): |
| 3478 | (print_interval, print_number_index, initial_stderr_stream): |
| 3479 | Now static. |
| 3480 | * lisp.h (Fprinc): Remove decl. |
| 3481 | (debug_output_compilation_hack): Mark as externally visible. |
| 3482 | |
| 3483 | * sysdep.c (croak): Move decl from here to syssignal.h. |
| 3484 | * syssignal.h (croak): Put it here, so the API can be checked when |
| 3485 | 'croak' is called from dissociate_if_controlling_tty. |
| 3486 | |
| 3487 | * minibuf.c: Make symbols static if they're not exported. |
| 3488 | (minibuf_save_list, choose_minibuf_frame): Now static. |
| 3489 | * lisp.h (choose_minibuf_frame): Remove decl. |
| 3490 | |
| 3491 | * lisp.h (verify_bytepos, count_markers): Mark as externally visible. |
| 3492 | |
| 3493 | * lread.c: Make symbols static if they're not exported. |
| 3494 | (read_objects, initial_obarray, oblookup_last_bucket_number): |
| 3495 | Now static. |
| 3496 | (make_symbol): Remove; unused. |
| 3497 | * lisp.h (initial_obarray, make_symbol): Remove decls. |
| 3498 | |
| 3499 | * keyboard.c: Make symbols static if they're not exported. |
| 3500 | (single_kboard, recent_keys_index, total_keys, recent_keys): |
| 3501 | (this_command_key_count_reset, raw_keybuf, raw_keybuf_count): |
| 3502 | (this_single_command_key_start, echoing, last_auto_save): |
| 3503 | (read_key_sequence_cmd, dribble, recursive_edit_unwind): |
| 3504 | (command_loop, echo_now, keyboard_init_hook, help_char_p): |
| 3505 | (quit_throw_to_read_char, command_loop_2, top_level_1, poll_timer): |
| 3506 | (Vlispy_mouse_stem, double_click_count): |
| 3507 | Now static. |
| 3508 | (force_auto_save_soon): Define only if SIGDANGER. |
| 3509 | (ignore_mouse_drag_p): Now static if |
| 3510 | !defined HAVE_WINDOW_SYSTEM || defined USE_GTK || defined HAVE_NS. |
| 3511 | (print_help): Remove; unused. |
| 3512 | (stop_character, last_timer_event): Mark as externally visible. |
| 3513 | * keyboard.h (ignore_mouse_drag_p): Declare only if |
| 3514 | defined HAVE_WINDOW_SYSTEM && !defined USE_GTK && !defined HAVE_NS. |
| 3515 | (echo_now, help_char_p, quit_throw_to_read_char): Remove decls. |
| 3516 | * lisp.h (echoing): Remove decl. |
| 3517 | (force_auto_save_soon): Declare only if SIGDANGER. |
| 3518 | * xdisp.c (redisplay_window): Simplify code, to make it more |
| 3519 | obvious that ignore_mouse_drag_p is not accessed if !defined |
| 3520 | USE_GTK && !defined HAVE_NS. |
| 3521 | |
| 3522 | * intervals.c: Make symbols static if they're not exported. |
| 3523 | (merge_properties_sticky, merge_interval_right, delete_interval): |
| 3524 | Now static. |
| 3525 | * intervals.h (merge_interval_right, delete_interval): Remove decls. |
| 3526 | |
| 3527 | * insdel.c: Make symbols static if they're not exported. |
| 3528 | However, leave prepare_to_modify_buffer alone. It's never |
| 3529 | called from outside this function, but that appears to be a bug. |
| 3530 | (combine_after_change_list, combine_after_change_buffer): |
| 3531 | (adjust_after_replace, signal_before_change): Now static. |
| 3532 | (adjust_after_replace_noundo): Remove; unused. |
| 3533 | * lisp.h (adjust_after_replace, adjust_after_replace_noundo): |
| 3534 | (signal_before_change): Remove decls. |
| 3535 | |
| 3536 | * indent.c (val_compute_motion, val_vmotion): Now static. |
| 3537 | |
| 3538 | * image.c: Make symbols static if they're not exported. |
| 3539 | * dispextern.h (x_create_bitmap_from_xpm_data): Do not declare |
| 3540 | if USE_GTK. |
| 3541 | * image.c (x_create_bitmap_from_xpm_data): Do not define if USE_GTK. |
| 3542 | (xpm_color_cache, ct_table, ct_colors_allocated): Now static. |
| 3543 | |
| 3544 | * fringe.c (standard_bitmaps): Now static. |
| 3545 | (max_used_fringe_bitmap): Now static, unless HAVE_NS. |
| 3546 | |
| 3547 | * frame.c: Make symbols static if they're not exported. |
| 3548 | (x_report_frame_params, make_terminal_frame): Now static. |
| 3549 | (get_frame_param): Now static, unless HAVE_NS. |
| 3550 | (x_fullscreen_adjust): Define if WINDOWSNT, not if HAVE_WINDOW_SYSTEM. |
| 3551 | (x_get_resource_string): Remove; not used. |
| 3552 | * frame.h (make_terminal_frame, x_report_frame_params): |
| 3553 | (x_get_resource_string); Remove decls. |
| 3554 | (x_fullscreen_adjust): Declare only if WINDOWSNT. |
| 3555 | * lisp.h (get_frame_param): Declare only if HAVE_NS. |
| 3556 | |
| 3557 | * font.c, fontset.c: Make symbols static if they're not exported. |
| 3558 | * dispextern.h (FACE_SUITABLE_FOR_ASCII_CHAR_P): New macro. |
| 3559 | (FACE_SUITABLE_FOR_CHAR_P): Use it. |
| 3560 | * font.c (font_close_object): Now static. |
| 3561 | * font.h (font_close_object): Remove. |
| 3562 | * fontset.c (FONTSET_OBJLIST): Remove. |
| 3563 | (free_realized_fontset) #if-0 the body, which does nothing. |
| 3564 | (face_suitable_for_char_p): #if-0, as it's never called. |
| 3565 | * fontset.h (face_suitable_for_char_p): Remove decl. |
| 3566 | * xfaces.c (face_at_string_position): |
| 3567 | Use FACE_SUITABLE_FOR_ASCII_CHAR_P, not FACE_SUITABLE_FOR_CHAR_P, |
| 3568 | since 0 is always ASCII. |
| 3569 | |
| 3570 | * fns.c (weak_hash_tables): Now static. |
| 3571 | |
| 3572 | * fileio.c: Make symbols static if they're not exported. |
| 3573 | (auto_saving, auto_save_mode_bits, auto_save_error_occurred): |
| 3574 | (Vwrite_region_annotation_buffers): Now static. |
| 3575 | |
| 3576 | * eval.c: Make symbols static if they're not exported. |
| 3577 | (backtrace_list, lisp_eval_depth, when_entered_debugger): Now static. |
| 3578 | * lisp.h (backtrace_list): Remove decl. |
| 3579 | |
| 3580 | * emacs.c: Make symbols static if they're not exported. |
| 3581 | (malloc_state_ptr, malloc_using_checking, syms_of_emacs): |
| 3582 | (fatal_error_code, fatal_error_signal_hook, standard_args): |
| 3583 | Now static. |
| 3584 | (fatal_error_signal): Now static, unless FLOAT_CATCH_SIGKILL. |
| 3585 | (DEFINE_DUMMY_FUNCTION): Mark function as externally visible. |
| 3586 | (__CTOR_LIST__, __DTOR_LIST__): Now externally visible. |
| 3587 | * lisp.h (fatal_error_signal_hook): Remove decl. |
| 3588 | (fatal_error_signal): Declare only if FLOAT_CATCH_SIGKILL. |
| 3589 | |
| 3590 | * editfns.c: Move a (normally-unused) function to its only use. |
| 3591 | * editfns.c, lisp.h (get_operating_system_release): Remove. |
| 3592 | * process.c (init_process) [DARWIN_OS]: Do it inline, as it is not |
| 3593 | worth the hassle of breaking this out. |
| 3594 | |
| 3595 | * xterm.c: Make symbols static if they're not exported. |
| 3596 | (x_raise_frame, x_lower_frame, x_wm_set_window_state): |
| 3597 | (x_wm_set_icon_pixmap, x_initialize, XTread_socket_fake_io_error): |
| 3598 | (x_destroy_window, x_delete_display): |
| 3599 | Now static. |
| 3600 | (x_dispatch_event): Now static if ! (USE_MOTIF || USE_X_TOOLKIT). |
| 3601 | (x_mouse_leave): Remove; unused. |
| 3602 | * xterm.h (x_display_info_for_name, x_raise_frame, x_lower_frame): |
| 3603 | (x_destroy_window, x_wm_set_window_state, x_wm_set_icon_pixmap): |
| 3604 | (x_delete_display, x_initialize, x_set_border_pixel, x_screen_planes): |
| 3605 | Remove decls. |
| 3606 | (x_mouse_leave): Declare only if WINDOWSNT. |
| 3607 | (x_dispatch_event): Declare only if USE_MOTIF or USE_X_TOOLKIT. |
| 3608 | (xic_create_fontsetname): Declare only if HAVE_X_WINDOWS && |
| 3609 | USE_X_TOOLKIT. |
| 3610 | |
| 3611 | * ftxfont.c: Make symbols static if they're not exported. |
| 3612 | (ftxfont_driver): Export only if !defined HAVE_XFT && def8ined |
| 3613 | HAVE_FREETYPE. |
| 3614 | * font.h (ftxfont_driver): Likewise. |
| 3615 | |
| 3616 | * xfns.c: Make symbols static if they're not exported. |
| 3617 | (x_last_font_name, x_display_info_for_name): |
| 3618 | (x_set_foreground_color, x_set_background_color, x_set_mouse_color): |
| 3619 | (x_set_cursor_color, x_set_border_pixel, x_set_border_color): |
| 3620 | (x_set_cursor_type, x_set_icon_type, x_set_icon_name): |
| 3621 | (x_set_scroll_bar_foreground, x_set_scroll_bar_background): |
| 3622 | (x_explicitly_set_name, x_set_title, xic_defaut_fontset, tip_timer): |
| 3623 | (last_show_tip_args): Now static. |
| 3624 | (xic_defaut_fontset, xic_create_fontsetname): Define only if |
| 3625 | defined HAVE_X_WINDOWS && defined USE_X_TOOLKIT |
| 3626 | (x_screen_planes): Remove; unused. |
| 3627 | * dispextern.h (x_screen_planes): Remove decl. |
| 3628 | |
| 3629 | * dispnew.c: Make symbols static if they're not exported. |
| 3630 | * dispextern.h (redraw_garbaged_frames, scrolling): |
| 3631 | (increment_row_positions): Remove. |
| 3632 | * dispnew.c (new_glyph_matrix, increment_row_positions, scrolling): |
| 3633 | (delayed_size_change, glyph_matrix_count, glyph_pool_count): |
| 3634 | Now static. |
| 3635 | (redraw_garbaged_frames): Remove; unused. |
| 3636 | |
| 3637 | * xfaces.c: Make symbols static if they're not exported. |
| 3638 | * dispextern.h (ascii_face_of_lisp_face, free_realized_face): |
| 3639 | Remove decls. |
| 3640 | * xterm.h (defined_color): Remove decls. |
| 3641 | (x_free_dpy_colors): Declare only if USE_X_TOOLKIT. |
| 3642 | * xfaces.c (tty_suppress_bold_inverse_default_colors_p): |
| 3643 | (menu_face_changed_default, defined_color, free_realized_face): |
| 3644 | (x_free_dpy_colors): Define only if USE_X_TOOLKIT. |
| 3645 | (ascii_face_of_lisp_face): Remove; unused. |
| 3646 | |
| 3647 | * xdisp.c: Make symbols static if they're not exported. |
| 3648 | * dispextern.h (scratch_glyph_row, window_box_edges): |
| 3649 | (glyph_to_pixel_coords, set_cursor_from_row): |
| 3650 | (get_next_display_element, set_iterator_to_next): |
| 3651 | (highlight_trailing_whitespace, frame_to_window_pixel_xy): |
| 3652 | (show_mouse_face): Remove decls |
| 3653 | * frame.h (message_buf_print): Likewise. |
| 3654 | * lisp.h (pop_message, set_message, check_point_in_composition): |
| 3655 | Likewise. |
| 3656 | * xterm.h (set_vertical_scroll_bar): Likewise. |
| 3657 | * xdisp.c (list_of_error, Vmessage_stack, line_number_displayed): |
| 3658 | (message_buf_print, scratch_glyph_row, displayed_buffer): |
| 3659 | (set_iterator_to_next, pop_message, set_message, set_cursor_from_row): |
| 3660 | (get_next_display_element, show_mouse_face, window_box_edges): |
| 3661 | (frame_to_window_pixel_xy, check_point_in_composition): |
| 3662 | (set_vertical_scroll_bar, highlight_trailing_whitespace): Now static. |
| 3663 | (glyph_to_pixel_coords): Remove; unused. |
| 3664 | |
| 3665 | * dired.c (file_name_completion): Now static. |
| 3666 | |
| 3667 | * dbusbind.c (xd_in_read_queued_messages): Now static. |
| 3668 | |
| 3669 | * lisp.h (circular_list_error, FOREACH): Remove; unused. |
| 3670 | * data.c (circular_list_error): Remove. |
| 3671 | |
| 3672 | * commands.h (last_point_position, last_point_position_buffer): |
| 3673 | (last_point_position_window): Remove decls. |
| 3674 | * keyboard.c: Make these variables static. |
| 3675 | |
| 3676 | * coding.h (coding, code_convert_region, encode_coding_gap): |
| 3677 | Remove decls. |
| 3678 | * coding.c (Vsjis_coding_system, Vbig5_coding_system): |
| 3679 | (iso_code_class, detect_coding, code_convert_region): Now static. |
| 3680 | (encode_coding_gap): Remove; unused. |
| 3681 | |
| 3682 | * chartab.c (chartab_chars, chartab_bits): Now static. |
| 3683 | |
| 3684 | * charset.h (charset_iso_8859_1): Remove decl. |
| 3685 | * charset.c (charset_iso_8859_1, charset_emacs, map_charset_for_dump): |
| 3686 | Now static. |
| 3687 | |
| 3688 | * ccl.h (check_ccl_update, Vccl_program_table): Remove decls. |
| 3689 | * ccl.c (Vccl_program_table): Now static. |
| 3690 | (check_ccl_update): Remove; unused. |
| 3691 | |
| 3692 | * category.c (SET_CATEGORY_SET, set_category_set): Move here. |
| 3693 | * category.h: ... from here. |
| 3694 | * category.c (check_category_table, set_category_set): Now static. |
| 3695 | |
| 3696 | * casetab.c (Vascii_upcase_table, Vascii_eqv_table): Now static. |
| 3697 | * lisp.h: Remove these decls. |
| 3698 | |
| 3699 | * buffer.c (buffer_count): Remove unused var. |
| 3700 | |
| 3701 | * bidi.c (bidi_dump_cached_states): Mark as externally visible, |
| 3702 | so that it's not optimized away. |
| 3703 | (bidi_ignore_explicit_marks_for_paragraph_level): Likewise. |
| 3704 | * dispextern.h (bidi_dump_cached_states): Remove, since it's |
| 3705 | exported only to the debugger. |
| 3706 | |
| 3707 | * atimer.c (alarm_signal_handler, run_all_atimers): Now static. |
| 3708 | * atimer.h (run_all_atimers): Remove; not exported. |
| 3709 | |
| 3710 | font.c: Make copy_font_spec and merge_font_spec ordinary C functions. |
| 3711 | * font.c (copy_font_spec): Rename from Fcopy_font_spec, since it |
| 3712 | was inaccessible from Lisp. |
| 3713 | (merge_font_spec): Likewise, renaming from Fmerge_font_spec. |
| 3714 | * font.c, font.h, fontset.c, xfaces.c, xfont.c: Change all uses. |
| 3715 | |
| 3716 | alloc.c: Import and export fewer symbols, and remove unused items. |
| 3717 | * lisp.h (suppress_checking, die): Declare only if ENABLE_CHECKING |
| 3718 | is defined. |
| 3719 | (suppress_checking): Add EXTERNALLY_VISIBLE attribute, so that |
| 3720 | it's not optimized away by whole-program optimization. |
| 3721 | (message_enable_multibyte, free_misc): Remove. |
| 3722 | (catchlist, handlerlist, mark_backtrace): |
| 3723 | Declare only if BYTE_MARK_STACK. |
| 3724 | (mark_byte_stack): Likewise, fixing a ifdef-vs-if typo. |
| 3725 | * alloc.c (pure): Export only if VIRT_ADDR_VARIES is defined. |
| 3726 | (message_enable_multibyte): Remove decl. |
| 3727 | (free_misc, interval_free_list, float_block, float_block_index): |
| 3728 | (n_float_blocks, float_free_list, cons_block, cons_block_index): |
| 3729 | (cons_free_list, last_marked_index): |
| 3730 | Now static. |
| 3731 | (suppress_checking, die): Define only if ENABLE_CHECKING is defined. |
| 3732 | * eval.c (catchlist, handlerlist): Export only if BYTE_MARK_STACK. |
| 3733 | (mark_backtrace): Define only if BYTE_MARK_STACK. |
| 3734 | * xdisp.c (message_enable_multibyte): Now static. |
| 3735 | |
| 3736 | Declare Lisp_Object Q* variables to be 'static' if not exported. |
| 3737 | This makes it easier for human readers (and static analyzers) |
| 3738 | to see whether these variables are used from other modules. |
| 3739 | * alloc.c, buffer.c, bytecode.c, callint.c, casetab.c, category.c: |
| 3740 | * ccl.c, character.c, charset.c, cmds.c, coding.c, composite.c: |
| 3741 | * data.c, dbusbind.c, dired.c, editfns.c, eval.c, fileio.c, fns.c: |
| 3742 | * font.c, frame.c, fringe.c, ftfont.c, image.c, keyboard.c, keymap.c: |
| 3743 | * lread.c, macros.c, minibuf.c, print.c, process.c, search.c: |
| 3744 | * sound.c, syntax.c, textprop.c, window.c, xdisp.c, xfaces.c, xfns.c: |
| 3745 | * xmenu.c, xselect.c: |
| 3746 | Declare Q* vars static if they are not used in other modules. |
| 3747 | * ccl.h, character.h, charset.h, coding.h, composite.h, font.h: |
| 3748 | * frame.h, intervals.h, keyboard.h, lisp.h, process.h, syntax.h: |
| 3749 | Remove decls of unexported vars. |
| 3750 | * keyboard.h (EVENT_HEAD_UNMODIFIED): Remove now-unused macro. |
| 3751 | |
| 3752 | * lisp.h (DEFINE_FUNC): Make sname 'static'. |
| 3753 | |
| 3754 | Make Emacs functions such as Fatom 'static' by default. |
| 3755 | This makes it easier for human readers (and static analyzers) |
| 3756 | to see whether these functions can be called from other modules. |
| 3757 | DEFUN now defines a static function. To make the function external |
| 3758 | so that it can be used in other C modules, use the new macro DEFUE. |
| 3759 | * lisp.h (Funibyte_char_to_multibyte, Fsyntax_table_p): |
| 3760 | (Finit_image_library): |
| 3761 | (Feval_region, Fbacktrace, Ffetch_bytecode, Fswitch_to_buffer): |
| 3762 | (Ffile_executable_p, Fmake_symbolic_link, Fcommand_execute): |
| 3763 | (Fget_process, Fdocumentation_property, Fbyte_code, Ffile_attributes): |
| 3764 | Remove decls, since these functions are now static. |
| 3765 | (Funintern, Fget_internal_run_time): New decls, since these functions |
| 3766 | were already external. |
| 3767 | |
| 3768 | * alloc.c, buffer.c, callint.c, callproc.c, casefiddle.c, casetab.c: |
| 3769 | * ccl.c, character.c, chartab.c, cmds.c, coding.c, data.c, dispnew.c: |
| 3770 | * doc.c, editfns.c, emacs.c, eval.c, fileio.c, filelock.c, floatfns.c: |
| 3771 | * fns.c, font.c, fontset.c, frame.c, image.c, indent.c: |
| 3772 | * keyboard.c, keymap.c, lread.c: |
| 3773 | * macros.c, marker.c, menu.c, minibuf.c, print.c, process.c, search.c: |
| 3774 | * syntax.c, term.c, terminal.c, textprop.c, undo.c: |
| 3775 | * window.c, xdisp.c, xfaces.c, xfns.c, xmenu.c, xsettings.c: |
| 3776 | Mark functions with DEFUE instead of DEFUN, |
| 3777 | if they are used in other modules. |
| 3778 | * buffer.c (Fset_buffer_major_mode, Fdelete_overlay): New forward |
| 3779 | decls for now-static functions. |
| 3780 | * buffer.h (Fdelete_overlay): Remove decl. |
| 3781 | * callproc.c (Fgetenv_internal): Mark as internal. |
| 3782 | * composite.c (Fremove_list_of_text_properties): Remove decl. |
| 3783 | (Fcomposition_get_gstring): New forward static decl. |
| 3784 | * composite.h (Fcomposite_get_gstring): Remove decl. |
| 3785 | * dired.c (Ffile_attributes): New forward static decl. |
| 3786 | * doc.c (Fdocumntation_property): New forward static decl. |
| 3787 | * eval.c (Ffetch_bytecode): New forward static decl. |
| 3788 | (Funintern): Remove extern decl; now in .h file where it belongs. |
| 3789 | * fileio.c (Fmake_symbolic_link): New forward static decl. |
| 3790 | * image.c (Finit_image_library): New forward static decl. |
| 3791 | * insdel.c (Fcombine_after_change_execute): Make forward decl static. |
| 3792 | * intervals.h (Fprevious_property_change): |
| 3793 | (Fremove_list_of_text_properties): Remove decls. |
| 3794 | * keyboard.c (Fthis_command_keys): Remove decl. |
| 3795 | (Fcommand_execute): New forward static decl. |
| 3796 | * keymap.c (Flookup_key): New forward static decl. |
| 3797 | (Fcopy_keymap): Now static. |
| 3798 | * keymap.h (Flookup_key): Remove decl. |
| 3799 | * process.c (Fget_process): New forward static decl. |
| 3800 | (Fprocess_datagram_address): Mark as internal. |
| 3801 | * syntax.c (Fsyntax_table_p): New forward static decl. |
| 3802 | (skip_chars): Remove duplicate decl. |
| 3803 | * textprop.c (Fprevious_property_change): New forward static decl. |
| 3804 | * window.c (Fset_window_fringes, Fset_window_scroll_bars): |
| 3805 | Now internal. |
| 3806 | (Fset_window_margins, Fset_window_vscroll): New forward static decls. |
| 3807 | * window.h (Fset_window_vscroll, Fset_window_margins): Remove decls. |
| 3808 | |
| 3809 | * editfns.c (Fformat): Remove unreachable code. |
| 3810 | |
| 3811 | 2011-04-14 Andreas Schwab <schwab@linux-m68k.org> |
| 3812 | |
| 3813 | * fileio.c (Finsert_file_contents): Fix typo in 2005-05-13 |
| 3814 | change. (Bug#8496) |
| 3815 | |
| 3816 | 2011-04-13 Eli Zaretskii <eliz@gnu.org> |
| 3817 | |
| 3818 | * xdisp.c (handle_invisible_prop): Don't call bidi_paragraph_init |
| 3819 | when at ZV. (Bug#8487) |
| 3820 | |
| 3821 | 2011-04-12 Andreas Schwab <schwab@linux-m68k.org> |
| 3822 | |
| 3823 | * charset.c (Fclear_charset_maps): Use xfree instead of free. |
| 3824 | (Bug#8437) |
| 3825 | * keyboard.c (parse_tool_bar_item): Likewise. |
| 3826 | * sound.c (sound_cleanup, alsa_close): Likewise. |
| 3827 | * termcap.c (tgetent): Likewise. |
| 3828 | * xfns.c (x_default_font_parameter): Likewise. |
| 3829 | * xsettings.c (read_and_apply_settings): Likewise. |
| 3830 | |
| 3831 | * alloc.c (overrun_check_malloc, overrun_check_realloc) |
| 3832 | (overrun_check_free): Protoize. |
| 3833 | |
| 3834 | 2011-04-12 Paul Eggert <eggert@cs.ucla.edu> |
| 3835 | |
| 3836 | * sysdep.c (emacs_read, emacs_write): Check for negative sizes |
| 3837 | since callers should never pass a negative size. |
| 3838 | Change the signature to match that of plain 'read' and 'write'; see |
| 3839 | <http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00397.html>. |
| 3840 | * lisp.h: Update prototypes of emacs_write and emacs_read. |
| 3841 | |
| 3842 | 2011-04-11 Eli Zaretskii <eliz@gnu.org> |
| 3843 | |
| 3844 | * xdisp.c (redisplay_window): Don't try to determine the character |
| 3845 | position of the scroll margin if the window start point w->startp |
| 3846 | is outside the buffer's accessible region. (Bug#8468) |
| 3847 | |
| 3848 | 2011-04-10 Eli Zaretskii <eliz@gnu.org> |
| 3849 | |
| 3850 | Fix write-region and its subroutines for buffers > 2GB. |
| 3851 | * fileio.c (a_write, e_write): Modify declaration of arguments and |
| 3852 | local variables to support buffers larger than 2GB. |
| 3853 | (Fcopy_file): Use EMACS_INT for return value of emacs_read. |
| 3854 | |
| 3855 | * sysdep.c (emacs_write, emacs_read): Use ssize_t for last |
| 3856 | argument, local variables, and return value. |
| 3857 | |
| 3858 | * lisp.h: Update prototypes of emacs_write and emacs_read. |
| 3859 | |
| 3860 | * sound.c (vox_write): Use ssize_t for return value of emacs_write. |
| 3861 | |
| 3862 | 2011-04-10 Paul Eggert <eggert@cs.ucla.edu> |
| 3863 | |
| 3864 | * xdisp.c (vmessage): Use memchr, not strnlen, which some hosts lack. |
| 3865 | |
| 3866 | Fix more problems found by GCC 4.6.0's static checks. |
| 3867 | |
| 3868 | * xdisp.c (vmessage): Use a better test for character truncation. |
| 3869 | |
| 3870 | * charset.c (load_charset_map): <, not <=, for optimization, |
| 3871 | and to avoid potential problems with integer overflow. |
| 3872 | * chartab.c (sub_char_table_set_range, char_table_set_range): Likewise. |
| 3873 | * casetab.c (set_identity, shuffle): Likewise. |
| 3874 | * editfns.c (Fformat): Likewise. |
| 3875 | * syntax.c (skip_chars): Likewise. |
| 3876 | |
| 3877 | * xmenu.c (set_frame_menubar): Allocate smaller local vectors. |
| 3878 | This also lets GCC 4.6.0 generate slightly better loop code. |
| 3879 | |
| 3880 | * callint.c (Fcall_interactively): <, not <=, for optimization. |
| 3881 | (Fcall_interactively): Count the number of arguments produced, |
| 3882 | not the number of arguments given. This is simpler and lets GCC |
| 3883 | 4.6.0 generate slightly better code. |
| 3884 | |
| 3885 | * ftfont.c: Distingish more carefully between FcChar8 and char. |
| 3886 | The previous code passed unsigned char * to a functions like |
| 3887 | strlen and xstrcasecmp that expect char *, which does not |
| 3888 | conform to the C standard. |
| 3889 | (get_adstyle_property, ftfont_pattern_entity): Use FcChar8 for |
| 3890 | arguments to FcPatternGetString, and explicitly cast FcChar8 * to |
| 3891 | char * when the C standard requires it. |
| 3892 | |
| 3893 | * keyboard.c (read_char): Remove unused var. |
| 3894 | |
| 3895 | * eval.c: Port to Windows vsnprintf (Bug#8435). |
| 3896 | Include <limits.h>. |
| 3897 | (SIZE_MAX): Define if the headers do not. |
| 3898 | (verror): Do not give up if vsnprintf returns a negative count. |
| 3899 | Instead, grow the buffer. This ports to Windows vsnprintf, which |
| 3900 | does not conform to C99. Problem reported by Eli Zaretskii. |
| 3901 | Also, simplify the allocation scheme, by avoiding the need for |
| 3902 | calling realloc, and removing the ALLOCATED variable. |
| 3903 | |
| 3904 | * eval.c (verror): Initial buffer size is 4000 (not 200) bytes. |
| 3905 | |
| 3906 | Remove invocations of doprnt, as Emacs now uses vsnprintf. |
| 3907 | But keep the doprint source code for now, as we might revamp it |
| 3908 | and use it again (Bug#8435). |
| 3909 | * lisp.h (doprnt): Remove. |
| 3910 | * Makefile.in (base_obj): Remove doprnt.o. |
| 3911 | * deps.mk (doprnt.o): Remove. |
| 3912 | |
| 3913 | error: Print 32- and 64-bit integers portably (Bug#8435). |
| 3914 | Without this change, on typical 64-bit hosts error ("...%d...", N) |
| 3915 | was used to print both 32- and 64-bit integers N, which relied on |
| 3916 | undefined behavior. |
| 3917 | * lisp.h, src/m/amdx86-64.h, src/m/ia64.h, src/m/ibms390x.h (pEd): |
| 3918 | New macro. |
| 3919 | * lisp.h (error, verror): Mark as printf-like functions. |
| 3920 | * eval.c (verror): Use vsnprintf, not doprnt, to do the real work. |
| 3921 | Report overflow in size calculations when allocating printf buffer. |
| 3922 | Do not truncate output string at its first null byte. |
| 3923 | * xdisp.c (vmessage): Use vsnprintf, not doprnt, to do the real work. |
| 3924 | Truncate the output at a character boundary, since vsnprintf does not |
| 3925 | do that. |
| 3926 | * charset.c (check_iso_charset_parameter): Convert internal |
| 3927 | character to string before calling 'error', since %c now has the |
| 3928 | printf meaning. |
| 3929 | * coding.c (Fdecode_sjis_char, Fdecode_big5_char): Avoid int |
| 3930 | overflow when computing char to be passed to 'error'. Do not |
| 3931 | pass Lisp_Object to 'error'; pass the integer instead. |
| 3932 | * nsfns.m (Fns_do_applescript): Use int, not long, since it's |
| 3933 | formatted with plain %d. |
| 3934 | |
| 3935 | * eval.c (internal_lisp_condition_case): Don't pass spurious arg. |
| 3936 | |
| 3937 | * keyboard.c (access_keymap_keyremap): Print func name, not garbage. |
| 3938 | |
| 3939 | * coding.c (Fdecode_sjis_char): Don't assume CODE fits in int. |
| 3940 | |
| 3941 | * xterm.c (x_catch_errors): Remove duplicate declaration. |
| 3942 | |
| 3943 | * term.c (maybe_fatal): Mark its 3rd arg as a printf format, too. |
| 3944 | |
| 3945 | * xdisp.c, lisp.h (message_nolog): Remove; unused. |
| 3946 | |
| 3947 | 2011-04-10 Jim Meyering <meyering@redhat.com> |
| 3948 | |
| 3949 | use ssize_t and size_t for read- and write-like emacs_gnutls_* functions |
| 3950 | * gnutls.c (emacs_gnutls_read): Adjust signature to be more read-like: |
| 3951 | return ssize_t not "int", and use size_t as the buffer length. |
| 3952 | (emacs_gnutls_write): Likewise, and make the buffer pointer "const". |
| 3953 | * gnutls.h: Update declarations. |
| 3954 | * process.c (read_process_output): Use ssize_t, to match. |
| 3955 | (send_process): Likewise. |
| 3956 | |
| 3957 | 2011-04-09 Chong Yidong <cyd@stupidchicken.com> |
| 3958 | |
| 3959 | * image.c (Fimagemagick_types): Doc fix, and comment cleanup. |
| 3960 | |
| 3961 | 2011-04-09 Chong Yidong <cyd@stupidchicken.com> |
| 3962 | |
| 3963 | * ftfont.c (get_adstyle_property, ftfont_pattern_entity): |
| 3964 | Use unsigned char, to match FcChar8 type definition. |
| 3965 | |
| 3966 | * xterm.c (handle_one_xevent): |
| 3967 | * xmenu.c (create_and_show_popup_menu): |
| 3968 | * xselect.c (x_decline_selection_request) |
| 3969 | (x_reply_selection_request): Avoid type-punned deref of X events. |
| 3970 | |
| 3971 | 2011-04-09 Eli Zaretskii <eliz@gnu.org> |
| 3972 | |
| 3973 | Fix some uses of `int' instead of EMACS_INT. |
| 3974 | * search.c (string_match_1, fast_string_match) |
| 3975 | (fast_c_string_match_ignore_case, fast_string_match_ignore_case) |
| 3976 | (scan_buffer, find_next_newline_no_quit) |
| 3977 | (find_before_next_newline, search_command, Freplace_match) |
| 3978 | (Fmatch_data): Make some `int' variables be EMACS_INT. |
| 3979 | |
| 3980 | * xdisp.c (display_count_lines): 3rd argument and return value now |
| 3981 | EMACS_INT. All callers changed. |
| 3982 | (pint2hrstr): Last argument is now EMACS_INT. |
| 3983 | |
| 3984 | * coding.c (detect_coding_utf_8, detect_coding_emacs_mule) |
| 3985 | (detect_coding_iso_2022, detect_coding_sjis, detect_coding_big5) |
| 3986 | (detect_coding_ccl, detect_coding_charset, decode_coding_utf_8) |
| 3987 | (decode_coding_utf_16, decode_coding_emacs_mule) |
| 3988 | (decode_coding_iso_2022, decode_coding_sjis, decode_coding_big5) |
| 3989 | (decode_coding_ccl, decode_coding_charset) |
| 3990 | <consumed_chars, consumed_chars_base>: Declare EMACS_INT. |
| 3991 | (decode_coding_iso_2022, decode_coding_emacs_mule) |
| 3992 | (decode_coding_sjis, decode_coding_big5, decode_coding_charset) |
| 3993 | <char_offset, last_offset>: Declare EMACS_INT. |
| 3994 | (encode_coding_utf_8, encode_coding_utf_16) |
| 3995 | (encode_coding_emacs_mule, encode_invocation_designation) |
| 3996 | (encode_designation_at_bol, encode_coding_iso_2022) |
| 3997 | (encode_coding_sjis, encode_coding_big5, encode_coding_ccl) |
| 3998 | (encode_coding_raw_text, encode_coding_charset) <produced_chars>: |
| 3999 | Declare EMACS_INT. |
| 4000 | (ASSURE_DESTINATION): Declare more_bytes EMACS_INT. |
| 4001 | (encode_invocation_designation): Last argument P_NCHARS is now |
| 4002 | EMACS_INT. |
| 4003 | (decode_eol): Declare pos_byte, pos, and pos_end EMACS_INT. |
| 4004 | (produce_chars): from_nchars and to_nchars are now EMACS_INT. |
| 4005 | |
| 4006 | * coding.h (struct coding_system) <head_ascii>: Declare EMACS_INT. |
| 4007 | All users changed. |
| 4008 | |
| 4009 | * ccl.c (Fccl_execute_on_string): Declare some variables |
| 4010 | EMACS_INT. |
| 4011 | |
| 4012 | 2011-04-08 Samuel Thibault <sthibault@debian.org> (tiny change) |
| 4013 | |
| 4014 | * term.c (init_tty): Fix incorrect ifdef placement (Bug#8450). |
| 4015 | |
| 4016 | 2011-03-19 Christoph Scholtes <cschol2112@googlemail.com> |
| 4017 | |
| 4018 | * process.c (Fformat_network_address): Doc fix. |
| 4019 | |
| 4020 | 2011-04-08 T.V. Raman <tv.raman.tv@gmail.com> (tiny change) |
| 4021 | |
| 4022 | * xml.c (parse_region): Avoid creating spurious whiespace nodes. |
| 4023 | |
| 4024 | 2011-04-08 Chong Yidong <cyd@stupidchicken.com> |
| 4025 | |
| 4026 | * keyboard.c (read_char): Call Lisp function help-form-show, |
| 4027 | instead of using internal_with_output_to_temp_buffer. |
| 4028 | (Qhelp_form_show): New var. |
| 4029 | (syms_of_keyboard): Use DEFSYM macro. |
| 4030 | |
| 4031 | * print.c (internal_with_output_to_temp_buffer): Function deleted. |
| 4032 | |
| 4033 | * lisp.h (internal_with_output_to_temp_buffer): Remove prototype. |
| 4034 | |
| 4035 | 2011-04-06 Chong Yidong <cyd@stupidchicken.com> |
| 4036 | |
| 4037 | * process.c (Flist_processes): Remove to Lisp. |
| 4038 | (list_processes_1): Delete. |
| 4039 | |
| 4040 | 2011-04-06 Eli Zaretskii <eliz@gnu.org> |
| 4041 | |
| 4042 | * msdos.c (careadlinkat, careadlinkatcwd): MS-DOS replacements. |
| 4043 | |
| 4044 | * w32.c (careadlinkat, careadlinkatcwd): New always-fail stubs. |
| 4045 | |
| 4046 | 2011-04-06 Paul Eggert <eggert@cs.ucla.edu> |
| 4047 | |
| 4048 | Fix more problems found by GCC 4.6.0's static checks. |
| 4049 | |
| 4050 | * xmenu.c (Fx_popup_dialog): Don't assume string is free of formats. |
| 4051 | |
| 4052 | * menu.c (Fx_popup_menu): Don't assume error_name lacks printf formats. |
| 4053 | |
| 4054 | * lisp.h (message, message_nolog, fatal): Mark as printf-like. |
| 4055 | |
| 4056 | * xdisp.c (vmessage): Mark as a printf-like function. |
| 4057 | |
| 4058 | * term.c (vfatal, maybe_fatal): Mark as printf-like functions. |
| 4059 | |
| 4060 | * sound.c (sound_warning): Don't crash if arg contains a printf format. |
| 4061 | |
| 4062 | * image.c (tiff_error_handler, tiff_warning_handler): Mark as |
| 4063 | printf-like functions. |
| 4064 | (tiff_load): Add casts to remove these marks before passing them |
| 4065 | to system-supplied API. |
| 4066 | |
| 4067 | * eval.c (Fsignal): Remove excess argument to 'fatal'. |
| 4068 | |
| 4069 | * coding.c (EMIT_ONE_BYTE, EMIT_TWO_BYTES): Use unsigned, not int. |
| 4070 | This avoids several warnings with gcc -Wstrict-overflow. |
| 4071 | (DECODE_COMPOSITION_RULE): If the rule is invalid, goto invalid_code |
| 4072 | directly, rather than having caller test rule sign. This avoids |
| 4073 | some unnecessary tests. |
| 4074 | * composite.h (COMPOSITION_ENCODE_RULE_VALID): New macro. |
| 4075 | (COMPOSITION_ENCODE_RULE): Arguments now must be valid. This |
| 4076 | affects only one use, in DECODE_COMPOSITION_RULE, which is changed. |
| 4077 | |
| 4078 | * xfont.c (xfont_text_extents): Remove var that was set but not used. |
| 4079 | (xfont_open): Avoid unnecessary tests. |
| 4080 | |
| 4081 | * composite.c (composition_gstring_put_cache): Use unsigned integer. |
| 4082 | |
| 4083 | * composite.h, composite.c (composition_gstring_put_cache): |
| 4084 | Use EMACS_INT, not int, for length. |
| 4085 | |
| 4086 | * composite.h (COMPOSITION_DECODE_REFS): New macro, |
| 4087 | breaking out part of COMPOSITION_DECODE_RULE. |
| 4088 | (COMPOSITION_DECODE_RULE): Use it. |
| 4089 | * composite.c (get_composition_id): Remove unused local vars, |
| 4090 | by using the new macro. |
| 4091 | |
| 4092 | * textprop.c (set_text_properties_1): Change while to do-while, |
| 4093 | since the condition is always true at first. |
| 4094 | |
| 4095 | * intervals.c (graft_intervals_into_buffer): Mark var as used. |
| 4096 | (interval_deletion_adjustment): Return unsigned value. |
| 4097 | All uses changed. |
| 4098 | |
| 4099 | * process.c (list_processes_1, create_pty, read_process_output): |
| 4100 | (exec_sentinel): Remove vars that were set but not used. |
| 4101 | (create_pty): Remove unnecessary "volatile"s. |
| 4102 | (Fnetwork_interface_info): Avoid possibility of int overflow. |
| 4103 | (read_process_output): Do adaptive read buffering even if carryover. |
| 4104 | (read_process_output): Simplify nbytes computation if buffered. |
| 4105 | |
| 4106 | * bytecode.c (exec_byte_code): Rename local to avoid shadowing. |
| 4107 | |
| 4108 | * syntax.c (scan_words): Remove var that was set but not used. |
| 4109 | (update_syntax_table): Use unsigned instead of int. |
| 4110 | |
| 4111 | * lread.c (lisp_file_lexically_bound_p): Use ints rather than endptrs. |
| 4112 | (lisp_file_lexically_bound_p, read1): Use unsigned instead of int. |
| 4113 | (safe_to_load_p): Make the end-of-loop test the inverse of the in-loop. |
| 4114 | |
| 4115 | * print.c (print_error_message): Avoid int overflow. |
| 4116 | |
| 4117 | * font.c (font_list_entities): Redo for clarity, |
| 4118 | so that reader need not know FONT_DPI_INDEX + 1 == FONT_SPACING_INDEX. |
| 4119 | |
| 4120 | * font.c (font_find_for_lface, Ffont_get_glyphs): Remove unused vars. |
| 4121 | (font_score): Avoid potential overflow in diff calculation. |
| 4122 | |
| 4123 | * fns.c (substring_both): Remove var that is set but not used. |
| 4124 | (sxhash): Redo loop for clarity and to avoid wraparound warning. |
| 4125 | |
| 4126 | * eval.c (funcall_lambda): Rename local to avoid shadowing. |
| 4127 | |
| 4128 | * alloc.c (mark_object_loop_halt, mark_object): Use size_t, not int. |
| 4129 | Otherwise, GCC 4.6.0 optimizes the loop check away since the check |
| 4130 | can always succeed if overflow has undefined behavior. |
| 4131 | |
| 4132 | * search.c (boyer_moore, wordify): Remove vars set but not used. |
| 4133 | (wordify): Omit three unnecessary tests. |
| 4134 | |
| 4135 | * indent.c (MULTIBYTE_BYTES_WIDTH): Don't compute wide_column. |
| 4136 | All callers changed. This avoids the need for an unused var. |
| 4137 | |
| 4138 | * casefiddle.c (casify_region): Remove var that is set but not used. |
| 4139 | |
| 4140 | * dired.c (file_name_completion): Remove var that is set but not used. |
| 4141 | |
| 4142 | * fileio.c (Finsert_file_contents): Make EOF condition clearer. |
| 4143 | |
| 4144 | * fileio.c (Finsert_file_contents): Avoid signed integer overflow. |
| 4145 | (Finsert_file_contents): Remove unnecessary code checking fd. |
| 4146 | |
| 4147 | * minibuf.c (read_minibuf_noninteractive): Use size_t for sizes. |
| 4148 | Check for integer overflow on size calculations. |
| 4149 | |
| 4150 | * buffer.c (Fprevious_overlay_change): Remove var that is set |
| 4151 | but not used. |
| 4152 | |
| 4153 | * keyboard.c (menu_bar_items, read_char_minibuf_menu_prompt): |
| 4154 | Remove vars that are set but not used. |
| 4155 | (timer_check_2): Don't assume timer-list and idle-timer-list are lists. |
| 4156 | (timer_check_2): Mark vars as initialized. |
| 4157 | |
| 4158 | * gtkutil.c (xg_get_file_with_chooser): Mark var as initialized. |
| 4159 | |
| 4160 | * image.c (lookup_image): Remove var that is set but not used. |
| 4161 | (xbm_load): Use parse_p, for gcc -Werror=unused-but-set-variable. |
| 4162 | |
| 4163 | * fontset.c (Finternal_char_font, Ffontset_info): Remove vars |
| 4164 | that are set but not used. |
| 4165 | |
| 4166 | * xfns.c (make_invisible_cursor): Don't return garbage |
| 4167 | if XCreateBitmapFromData fails (Bug#8410). |
| 4168 | |
| 4169 | * xselect.c (x_get_local_selection, x_handle_property_notify): |
| 4170 | Remove vars that are set but not used. |
| 4171 | |
| 4172 | * xfns.c (x_create_tip_frame): Remove var that is set but not used. |
| 4173 | (make_invisible_cursor): Initialize a possibly-uninitialized variable. |
| 4174 | |
| 4175 | * xterm.c (x_scroll_bar_to_input_event) [!USE_GTK]: |
| 4176 | Remove var that is set but not used. |
| 4177 | (scroll_bar_windows_size): Now size_t, not int. |
| 4178 | (x_send_scroll_bar_event): Use size_t, not int, for sizes. |
| 4179 | Check for overflow. |
| 4180 | |
| 4181 | * xfaces.c (realize_named_face): Remove vars that are set but not used. |
| 4182 | (map_tty_color) [!defined MSDOS]: Likewise. |
| 4183 | |
| 4184 | * term.c (tty_write_glyphs): Use size_t; this avoids overflow warning. |
| 4185 | |
| 4186 | * coding.c: Remove vars that are set but not used. |
| 4187 | (DECODE_COMPOSITION_RULE): Remove 2nd arg, which is unused. |
| 4188 | All callers changed. |
| 4189 | (decode_coding_utf_8, decode_coding_utf_16 decode_coding_emacs_mule): |
| 4190 | (decode_coding_iso_2022, encode_coding_sjis, encode_coding_big5): |
| 4191 | (decode_coding_charset): Remove vars that are set but not used. |
| 4192 | |
| 4193 | * bytecode.c (Fbyte_code) [!defined BYTE_CODE_SAFE]: Remove var |
| 4194 | that is set but not used. |
| 4195 | |
| 4196 | * print.c (print_object): Remove var that is set but not used. |
| 4197 | |
| 4198 | Replace 2 copies of readlink code with 1 gnulib version (Bug#8401). |
| 4199 | The gnulib version avoids calling malloc in the usual case, |
| 4200 | and on 64-bit hosts doesn't have some arbitrary 32-bit limits. |
| 4201 | * fileio.c (Ffile_symlink_p): Use emacs_readlink. |
| 4202 | * filelock.c (current_lock_owner): Likewise. |
| 4203 | * lisp.h (READLINK_BUFSIZE, emacs_readlink): New function. |
| 4204 | * sysdep.c: Include allocator.h, careadlinkat.h. |
| 4205 | (emacs_no_realloc_allocator): New static constant. |
| 4206 | (emacs_readlink): New function. |
| 4207 | * deps.mk (sysdep.o): Depend on ../lib/allocator.h and on |
| 4208 | ../lib/careadlinkat.h. |
| 4209 | |
| 4210 | 2011-04-04 Stefan Monnier <monnier@iro.umontreal.ca> |
| 4211 | |
| 4212 | * keyboard.c (safe_run_hook_funcall): Fix last change (don't stop at the |
| 4213 | first non-nil return value). |
| 4214 | |
| 4215 | 2011-04-03 Jan Djärv <jan.h.d@swipnet.se> |
| 4216 | |
| 4217 | * nsterm.m (ns_update_auto_hide_menu_bar): Define MAC_OS_X_VERSION_10_6 |
| 4218 | if not defined (Bug#8403). |
| 4219 | |
| 4220 | 2011-04-02 Juanma Barranquero <lekktu@gmail.com> |
| 4221 | |
| 4222 | * xdisp.c (display_count_lines): Remove parameter `start', |
| 4223 | unused since 1998-01-01T02:27:27Z!rms@gnu.org. All callers changed. |
| 4224 | (get_char_face_and_encoding): Remove parameter `multibyte_p', |
| 4225 | unused since 2008-05-14T01:40:23Z!handa@m17n.org. All callers changed. |
| 4226 | (fill_stretch_glyph_string): Remove parameters `row' and `area', |
| 4227 | unused at least since Kim's GUI unification at 2003-03-16T20:45:46Z!storm@cua.dk |
| 4228 | and thereabouts. All callers changed. |
| 4229 | (get_per_char_metric): Remove parameter `f', unused since |
| 4230 | 2008-05-14T01:40:23Z!handa@m17n.org. All callers changed. |
| 4231 | |
| 4232 | 2011-04-02 Jim Meyering <meyering@redhat.com> |
| 4233 | |
| 4234 | do not dereference NULL upon failed strdup |
| 4235 | * nsfont.m (ns_descriptor_to_entity): Use xstrdup, not strdup. |
| 4236 | (ns_get_family): Likewise. |
| 4237 | |
| 4238 | 2011-04-02 Juanma Barranquero <lekktu@gmail.com> |
| 4239 | |
| 4240 | * eval.c (unwind_to_catch) [DEBUG_GCPRO]: Remove redundant assignment. |
| 4241 | |
| 4242 | 2011-04-02 Jan Djärv <jan.h.d@swipnet.se> |
| 4243 | |
| 4244 | * nsterm.m (ns_update_auto_hide_menu_bar): Only for OSX 10.6 or |
| 4245 | later (Bug#8403). |
| 4246 | |
| 4247 | 2011-04-01 Stefan Monnier <monnier@iro.umontreal.ca> |
| 4248 | |
| 4249 | Add lexical binding. |
| 4250 | |
| 4251 | * window.c (Ftemp_output_buffer_show): New fun. |
| 4252 | (Fsave_window_excursion): |
| 4253 | * print.c (Fwith_output_to_temp_buffer): Move to subr.el. |
| 4254 | |
| 4255 | * lread.c (lisp_file_lexically_bound_p): New function. |
| 4256 | (Fload): Bind Qlexical_binding. |
| 4257 | (readevalloop): Remove `evalfun' arg. |
| 4258 | Bind Qinternal_interpreter_environment. |
| 4259 | (Feval_buffer): Bind Qlexical_binding. |
| 4260 | (defvar_int, defvar_bool, defvar_lisp_nopro, defvar_kboard): |
| 4261 | Mark as dynamic. |
| 4262 | (syms_of_lread): Declare `lexical-binding'. |
| 4263 | |
| 4264 | * lisp.h (struct Lisp_Symbol): New field `declared_special'. |
| 4265 | |
| 4266 | * keyboard.c (eval_dyn): New fun. |
| 4267 | (menu_item_eval_property): Use it. |
| 4268 | |
| 4269 | * image.c (parse_image_spec): Use Ffunctionp. |
| 4270 | |
| 4271 | * fns.c (concat, mapcar1): Accept byte-code-functions. |
| 4272 | |
| 4273 | * eval.c (Fsetq): Handle lexical vars. |
| 4274 | (Fdefun, Fdefmacro, Ffunction): Make closures when needed. |
| 4275 | (Fdefconst, Fdefvaralias, Fdefvar): Mark as dynamic. |
| 4276 | (FletX, Flet): Obey lexical binding. |
| 4277 | (Fcommandp): Handle closures. |
| 4278 | (Feval): New `lexical' arg. |
| 4279 | (eval_sub): New function extracted from Feval. Use it almost |
| 4280 | everywhere where Feval was used. Look up vars in lexical env. |
| 4281 | Handle closures. |
| 4282 | (Ffunctionp): Move from subr.el. |
| 4283 | (Ffuncall): Handle closures. |
| 4284 | (apply_lambda): Remove `eval_flags'. |
| 4285 | (funcall_lambda): Handle closures and new byte-code-functions. |
| 4286 | (Fspecial_variable_p): New function. |
| 4287 | (syms_of_eval): Initialize the Vinternal_interpreter_environment var, |
| 4288 | but without exporting it to Lisp. |
| 4289 | |
| 4290 | * doc.c (Fdocumentation, store_function_docstring): |
| 4291 | * data.c (Finteractive_form): Handle closures. |
| 4292 | |
| 4293 | * callint.c (Fcall_interactively): Preserve lexical-binding mode for |
| 4294 | interactive spec. |
| 4295 | |
| 4296 | * bytecode.c (Bstack_ref, Bstack_set, Bstack_set2, BdiscardN): |
| 4297 | New byte-codes. |
| 4298 | (exec_byte_code): New function extracted from Fbyte_code to handle new |
| 4299 | calling convention for byte-code-functions. Add new byte-codes. |
| 4300 | |
| 4301 | * buffer.c (defvar_per_buffer): Set new `declared_special' field. |
| 4302 | |
| 4303 | * alloc.c (Fmake_symbol): Init new `declared_special' field. |
| 4304 | |
| 4305 | 2011-03-31 Juanma Barranquero <lekktu@gmail.com> |
| 4306 | |
| 4307 | * xdisp.c (redisplay_internal): Fix prototype. |
| 4308 | |
| 4309 | 2011-03-31 Eli Zaretskii <eliz@gnu.org> |
| 4310 | |
| 4311 | * xdisp.c (SCROLL_LIMIT): New macro. |
| 4312 | (try_scrolling): Use it when setting scroll_limit. |
| 4313 | Limit scrolling to 100 screen lines. |
| 4314 | (redisplay_window): Even when falling back on "recentering", |
| 4315 | position point in the window according to scroll-conservatively, |
| 4316 | scroll-margin, and scroll-*-aggressively variables. (Bug#6671) |
| 4317 | |
| 4318 | (try_scrolling): When point is above the window, allow searching |
| 4319 | as far as scroll_max, or one screenful, to compute vertical |
| 4320 | distance from PT to the scroll margin position. This prevents |
| 4321 | try_scrolling from unnecessarily failing when |
| 4322 | scroll-conservatively is set to a value slightly larger than the |
| 4323 | window height. Clean up the case of PT below the margin at bottom |
| 4324 | of window: scroll_max can no longer be INT_MAX. When aggressive |
| 4325 | scrolling is in use, don't let point enter the opposite scroll |
| 4326 | margin as result of the scroll. |
| 4327 | (syms_of_xdisp) <scroll-conservatively>: Document the |
| 4328 | threshold of 100 lines for never-recentering scrolling. |
| 4329 | |
| 4330 | 2011-03-31 Juanma Barranquero <lekktu@gmail.com> |
| 4331 | |
| 4332 | * dispextern.h (move_it_by_lines): |
| 4333 | * xdisp.c (move_it_by_lines): Remove parameter `need_y_p', unused |
| 4334 | since 2000-12-29T14:24:09Z!gerd@gnu.org. All callers changed. |
| 4335 | (message_log_check_duplicate): Remove parameters `prev_bol' and |
| 4336 | `this_bol', unused since 1998-01-01T02:27:27Z!rms@gnu.org. All callers changed. |
| 4337 | (redisplay_internal): Remove parameter `preserve_echo_area', |
| 4338 | unused since 1999-07-21T21:43:52Z!gerd@gnu.org. All callers changed. |
| 4339 | |
| 4340 | * indent.c (Fvertical_motion): |
| 4341 | * window.c (window_scroll_pixel_based, Frecenter): |
| 4342 | Don't pass `need_y_p' to `move_it_by_lines'. |
| 4343 | |
| 4344 | 2011-03-30 Stefan Monnier <monnier@iro.umontreal.ca> |
| 4345 | |
| 4346 | * eval.c (struct backtrace): Don't cheat with negative numbers, but do |
| 4347 | steal a few bits to be more compact. |
| 4348 | (interactive_p, Fbacktrace, Fbacktrace_frame, mark_backtrace): |
| 4349 | Remove unneeded casts. |
| 4350 | |
| 4351 | * bytecode.c (Fbyte_code): CAR and CDR can GC. |
| 4352 | |
| 4353 | 2011-03-30 Zachary Kanfer <zkanfer@gmail.com> (tiny change) |
| 4354 | |
| 4355 | * keyboard.c (Fexecute_extended_command): Do log the "suggest key |
| 4356 | binding" message (bug#7967). |
| 4357 | |
| 4358 | 2011-03-30 Paul Eggert <eggert@cs.ucla.edu> |
| 4359 | |
| 4360 | Fix more problems found by GCC 4.6.0's static checks. |
| 4361 | |
| 4362 | * unexelf.c (unexec) [! (defined _SYSTYPE_SYSV || defined __sgi)]: |
| 4363 | Remove unused local var. |
| 4364 | |
| 4365 | * editfns.c (Fmessage_box): Remove unused local var. |
| 4366 | |
| 4367 | * xdisp.c (try_window_reusing_current_matrix, x_produce_glyphs): |
| 4368 | (note_mode_line_or_margin_highlight, note_mouse_highlight): |
| 4369 | Omit unused local vars. |
| 4370 | * window.c (shrink_windows): Omit unused local var. |
| 4371 | * menu.c (digest_single_submenu): Omit unused local var. |
| 4372 | * dispnew.c (update_window) [PERIODIC_PREEMPTION_CHECKING]: |
| 4373 | Omit unused local var. |
| 4374 | |
| 4375 | * keyboard.c (parse_modifiers_uncached, parse_modifiers): |
| 4376 | Don't assume string length fits in int. |
| 4377 | (keyremap_step, read_key_sequence): Use size_t for sizes. |
| 4378 | (read_key_sequence): Don't check last_real_key_start redundantly. |
| 4379 | |
| 4380 | * callproc.c (Fcall_process, Fcall_process_region): Use SAFE_ALLOCA |
| 4381 | instead of alloca (Bug#8344). |
| 4382 | |
| 4383 | * eval.c (Fbacktrace): Don't assume nargs fits in int. |
| 4384 | (Fbacktrace_frame): Don't assume nframes fits in int. |
| 4385 | |
| 4386 | * syntax.c (scan_sexps_forward): Avoid pointer wraparound. |
| 4387 | |
| 4388 | * xterm.c (x_make_frame_visible, same_x_server): Redo to avoid overflow |
| 4389 | concerns. |
| 4390 | |
| 4391 | * term.c (produce_glyphless_glyph): Remove unnecessary test. |
| 4392 | |
| 4393 | * cm.c (calccost): Turn while-do into do-while, for clarity. |
| 4394 | |
| 4395 | * keyboard.c (syms_of_keyboard): Use the same style as later |
| 4396 | in this function when indexing through an array. This also |
| 4397 | works around GCC bug 48267. |
| 4398 | |
| 4399 | * image.c (tiff_load): Fix off-by-one image count (Bug#8336). |
| 4400 | |
| 4401 | * xselect.c (x_check_property_data): Return correct size (Bug#8335). |
| 4402 | |
| 4403 | * chartab.c (sub_char_table_ref_and_range): Redo for slight |
| 4404 | efficiency gain, and to bypass a gcc -Wstrict-overflow warning. |
| 4405 | |
| 4406 | * keyboard.c, keyboard.h (num_input_events): Now size_t. |
| 4407 | This avoids undefined behavior on integer overflow, and is a bit |
| 4408 | more convenient anyway since it is compared to a size_t variable. |
| 4409 | |
| 4410 | Variadic C functions now count arguments with size_t, not int. |
| 4411 | This avoids an unnecessary limitation on 64-bit machines, which |
| 4412 | caused (substring ...) to crash on large vectors (Bug#8344). |
| 4413 | * lisp.h (struct Lisp_Subr.function.aMANY): Now takes size_t, not int. |
| 4414 | (DEFUN_ARGS_MANY, internal_condition_case_n, safe_call): Likewise. |
| 4415 | All variadic functions and their callers changed accordingly. |
| 4416 | (struct gcpro.nvars): Now size_t, not int. All uses changed. |
| 4417 | * data.c (arith_driver, float_arith_driver): Likewise. |
| 4418 | * editfns.c (general_insert_function): Likewise. |
| 4419 | * eval.c (struct backtrace.nargs, interactive_p) |
| 4420 | (internal_condition_case_n, run_hook_with_args, apply_lambda) |
| 4421 | (funcall_lambda, mark_backtrace): Likewise. |
| 4422 | * fns.c (concat): Likewise. |
| 4423 | * frame.c (x_set_frame_parameters): Likewise. |
| 4424 | * fns.c (get_key_arg): Now accepts and returns size_t, and returns |
| 4425 | 0 if not found, not -1. All callers changed. |
| 4426 | |
| 4427 | * alloc.c (garbage_collect): Don't assume stack size fits in int. |
| 4428 | (stack_copy_size): Now size_t, not int. |
| 4429 | (stack_copy, stack_copy_size): Define only if MAX_SAVE_STACK > 0. |
| 4430 | |
| 4431 | 2011-03-28 Juanma Barranquero <lekktu@gmail.com> |
| 4432 | |
| 4433 | * coding.c (encode_designation_at_bol): Remove parameter `charbuf_end', |
| 4434 | unused since 2002-03-01T01:17:24Z!handa@m17n.org and 2008-02-01T16:01:31Z!miles@gnu.org. |
| 4435 | All callers changed. |
| 4436 | |
| 4437 | * lisp.h (multibyte_char_to_unibyte): |
| 4438 | * character.c (multibyte_char_to_unibyte): Remove parameter `rev_tbl', |
| 4439 | unused since 2002-03-01T01:16:34Z!handa@m17n.org and 2008-02-01T16:01:31Z!miles@gnu.org. |
| 4440 | * character.h (CHAR_TO_BYTE8): |
| 4441 | * cmds.c (internal_self_insert): |
| 4442 | * editfns.c (general_insert_function): |
| 4443 | * keymap.c (push_key_description): |
| 4444 | * search.c (Freplace_match): |
| 4445 | * xdisp.c (message_dolog, set_message_1): All callers changed. |
| 4446 | |
| 4447 | 2011-03-28 Stefan Monnier <monnier@iro.umontreal.ca> |
| 4448 | |
| 4449 | * keyboard.c (safe_run_hook_funcall): New function. |
| 4450 | (safe_run_hooks_1, safe_run_hooks_error, safe_run_hooks): On error, |
| 4451 | don't set the hook to nil, but remove the offending function instead. |
| 4452 | (Qcommand_hook_internal): Remove, unused. |
| 4453 | (syms_of_keyboard): Don't initialize Qcommand_hook_internal nor define |
| 4454 | Vcommand_hook_internal. |
| 4455 | |
| 4456 | * eval.c (enum run_hooks_condition): Remove. |
| 4457 | (funcall_nil, funcall_not): New functions. |
| 4458 | (run_hook_with_args): Call each function through a `funcall' argument. |
| 4459 | Remove `cond' argument, now redundant. |
| 4460 | (Frun_hooks, Frun_hook_with_args, Frun_hook_with_args_until_success) |
| 4461 | (Frun_hook_with_args_until_failure): Adjust accordingly. |
| 4462 | (run_hook_wrapped_funcall, Frun_hook_wrapped): New functions. |
| 4463 | |
| 4464 | 2011-03-28 Juanma Barranquero <lekktu@gmail.com> |
| 4465 | |
| 4466 | * dispextern.h (string_buffer_position): Remove declaration. |
| 4467 | |
| 4468 | * print.c (strout): Remove parameter `multibyte', unused since |
| 4469 | 1999-08-21T19:30:21Z!gerd@gnu.org. All callers changed. |
| 4470 | |
| 4471 | * search.c (boyer_moore): Remove parameters `len', `pos' and `lim', |
| 4472 | never used since function introduction in 1998-02-08T21:33:56Z!rms@gnu.org. |
| 4473 | All callers changed. |
| 4474 | |
| 4475 | * w32.c (_wsa_errlist): Use braces for struct initializers. |
| 4476 | |
| 4477 | * xdisp.c (string_buffer_position_lim): Remove parameter `w', |
| 4478 | never used since function introduction in 2001-03-09T18:41:50Z!gerd@gnu.org. |
| 4479 | All callers changed. |
| 4480 | (string_buffer_position): Likewise. Also, make static (it's never |
| 4481 | used outside xdisp.c). |
| 4482 | (cursor_row_p): Remove parameter `w', unused since |
| 4483 | 2000-10-17T16:08:57Z!gerd@gnu.org. All callers changed. |
| 4484 | (decode_mode_spec): Remove parameter `precision', introduced during |
| 4485 | Gerd Moellmann's rewrite at 1999-07-21T21:43:52Z!gerd@gnu.org, but never used. |
| 4486 | All callers changed. |
| 4487 | |
| 4488 | 2011-03-27 Jan Djärv <jan.h.d@swipnet.se> |
| 4489 | |
| 4490 | * nsterm.m (syms_of_nsterm): Use doc: for ns-auto-hide-menu-bar. |
| 4491 | |
| 4492 | 2011-03-27 Anders Lindgren <andlind@gmail.com> |
| 4493 | |
| 4494 | * nsterm.m (ns_menu_bar_is_hidden): New variable. |
| 4495 | (ns_constrain_all_frames, ns_menu_bar_should_be_hidden) |
| 4496 | (ns_update_auto_hide_menu_bar): New functions. |
| 4497 | (ns_update_begin): Call ns_update_auto_hide_menu_bar. |
| 4498 | (applicationDidBecomeActive): Call ns_update_auto_hide_menu_bar and |
| 4499 | ns_constrain_all_frames. |
| 4500 | (constrainFrameRect): Return at once if ns_menu_bar_should_be_hidden. |
| 4501 | (syms_of_nsterm): DEFVAR ns-auto-hide-menu-bar, init to Qnil. |
| 4502 | |
| 4503 | 2011-03-27 Jan Djärv <jan.h.d@swipnet.se> |
| 4504 | |
| 4505 | * nsmenu.m (runDialogAt): Remove argument to timer_check. |
| 4506 | |
| 4507 | 2011-03-27 Glenn Morris <rgm@gnu.org> |
| 4508 | |
| 4509 | * syssignal.h: Replace RETSIGTYPE with void. |
| 4510 | * atimer.c, data.c, dispnew.c, emacs.c, floatfns.c, keyboard.c: |
| 4511 | * keyboard.h, lisp.h, process.c, sysdep.c, xterm.c: |
| 4512 | Replace SIGTYPE with void everywhere. |
| 4513 | * s/usg5-4-common.h (SIGTYPE): Remove definition. |
| 4514 | * s/template.h (SIGTYPE): Remove commented out definition. |
| 4515 | |
| 4516 | 2011-03-26 Eli Zaretskii <eliz@gnu.org> |
| 4517 | |
| 4518 | * xdisp.c (redisplay_window): Don't check buffer's clip_changed |
| 4519 | flag as a prerequisite for invoking try_scrolling. (Bug#6671) |
| 4520 | |
| 4521 | 2011-03-26 Juanma Barranquero <lekktu@gmail.com> |
| 4522 | |
| 4523 | * w32.c (read_unc_volume): Use parameter `henum', instead of |
| 4524 | global variable `wget_enum_handle'. |
| 4525 | |
| 4526 | * keymap.c (describe_vector): Remove parameters `indices' and |
| 4527 | `char_table_depth', unused since 2002-03-01T01:43:26Z!handa@m17n.org. |
| 4528 | (describe_map, Fdescribe_vector): Adjust calls to `describe_vector'. |
| 4529 | |
| 4530 | * keyboard.h (timer_check, show_help_echo): Remove unused parameters. |
| 4531 | |
| 4532 | * keyboard.c (timer_check): Remove parameter `do_it_now', |
| 4533 | unused since 1996-04-12T06:01:29Z!rms@gnu.org. |
| 4534 | (show_help_echo): Remove parameter `ok_to_overwrite_keystroke_echo', |
| 4535 | unused since 2008-04-19T19:30:53Z!monnier@iro.umontreal.ca. |
| 4536 | |
| 4537 | * keyboard.c (read_char): |
| 4538 | * w32menu.c (w32_menu_display_help): |
| 4539 | * xmenu.c (show_help_event, menu_help_callback): |
| 4540 | Adjust calls to `show_help_echo'. |
| 4541 | |
| 4542 | * gtkutil.c (xg_maybe_add_timer): |
| 4543 | * keyboard.c (readable_events): |
| 4544 | * process.c (wait_reading_process_output): |
| 4545 | * xmenu.c (x_menu_wait_for_event): Adjust calls to `timer_check'. |
| 4546 | |
| 4547 | * insdel.c (adjust_markers_gap_motion): |
| 4548 | Remove; no-op since 1998-01-02T21:29:48Z!rms@gnu.org. |
| 4549 | (gap_left, gap_right): Don't call it. |
| 4550 | |
| 4551 | 2011-03-25 Chong Yidong <cyd@stupidchicken.com> |
| 4552 | |
| 4553 | * xdisp.c (handle_fontified_prop): Discard changes to clip_changed |
| 4554 | incurred during fontification. |
| 4555 | |
| 4556 | 2011-03-25 Juanma Barranquero <lekktu@gmail.com> |
| 4557 | |
| 4558 | * buffer.c (defvar_per_buffer): Remove unused parameter `doc'. |
| 4559 | (DEFVAR_PER_BUFFER): Don't pass it. |
| 4560 | |
| 4561 | * dispnew.c (row_equal_p, add_row_entry): Remove unused parameter `w'. |
| 4562 | (scrolling_window): Don't pass it. |
| 4563 | |
| 4564 | 2011-03-25 Juanma Barranquero <lekktu@gmail.com> |
| 4565 | |
| 4566 | * dispextern.h (glyph_matric): Use #if GLYPH_DEBUG, not #ifdef. |
| 4567 | |
| 4568 | * fileio.c (check_executable) [DOS_NT]: Remove unused variables `len' |
| 4569 | and `suffix'. |
| 4570 | (Fset_file_selinux_context) [HAVE_LIBSELINUX]: Move here declaration |
| 4571 | of variables specific to SELinux and computation of `encoded_absname'. |
| 4572 | |
| 4573 | * image.c (XPutPixel): Remove unused variable `height'. |
| 4574 | |
| 4575 | * keyboard.c (make_lispy_event): Remove unused variable `hpos'. |
| 4576 | |
| 4577 | * unexw32.c (get_section_info): Remove unused variable `section'. |
| 4578 | |
| 4579 | * w32.c (stat): Remove unused variables `drive_root' and `devtype'. |
| 4580 | (system_process_attributes): Remove unused variable `sess'. |
| 4581 | (sys_read): Remove unused variable `err'. |
| 4582 | |
| 4583 | * w32fns.c (top): Wrap variables with #if GLYPH_DEBUG, not #ifdef. |
| 4584 | (w32_wnd_proc): Remove unused variable `isdead'. |
| 4585 | (unwind_create_frame): Use #if GLYPH_DEBUG, not #ifdef. |
| 4586 | (Fx_server_max_request_size): Remove unused variable `dpyinfo'. |
| 4587 | (x_create_tip_frame): Remove unused variable `tem'. |
| 4588 | |
| 4589 | * w32inevt.c (w32_console_read_socket): |
| 4590 | Remove unused variable `no_events'. |
| 4591 | |
| 4592 | * w32term.c (x_draw_composite_glyph_string_foreground): |
| 4593 | Remove unused variable `width'. |
| 4594 | |
| 4595 | 2011-03-24 Juanma Barranquero <lekktu@gmail.com> |
| 4596 | |
| 4597 | * w32term.c (x_set_glyph_string_clipping): |
| 4598 | Don't pass uninitialized region to CombineRgn. |
| 4599 | |
| 4600 | 2011-03-23 Juanma Barranquero <lekktu@gmail.com> |
| 4601 | |
| 4602 | * w32fns.c (x_set_menu_bar_lines): Remove unused variable `olines'. |
| 4603 | (w32_wnd_proc): Pass NULL to Windows API, not uninitialized buffer. |
| 4604 | (Fx_close_connection): Remove unused variable `i'. |
| 4605 | |
| 4606 | * w32font.c (w32font_draw): Return number of glyphs. |
| 4607 | (w32font_open_internal): Remove unused variable `i'. |
| 4608 | (w32font_driver): Add missing initializer. |
| 4609 | |
| 4610 | * w32menu.c (utf8to16): Remove unused variable `utf16'. |
| 4611 | (fill_in_menu): Remove unused variable `items_added'. |
| 4612 | |
| 4613 | * w32term.c (last_mouse_press_frame): Remove static global variable. |
| 4614 | (w32_clip_to_row): Remove unused variable `f'. |
| 4615 | (x_delete_terminal): Remove unused variable `i'. |
| 4616 | |
| 4617 | * w32uniscribe.c (uniscribe_shape): Remove unused variable `nclusters'. |
| 4618 | (NOTHING): Remove unused static global variable. |
| 4619 | (uniscribe_check_otf): Remove unused variable `table'. |
| 4620 | (uniscribe_font_driver): Add missing initializers. |
| 4621 | |
| 4622 | 2011-03-23 Julien Danjou <julien@danjou.info> |
| 4623 | |
| 4624 | * term.c (Fsuspend_tty, Fresume_tty): |
| 4625 | * minibuf.c (read_minibuf, run_exit_minibuf_hook): |
| 4626 | * window.c (temp_output_buffer_show): |
| 4627 | * insdel.c (signal_before_change): |
| 4628 | * frame.c (Fhandle_switch_frame): |
| 4629 | * fileio.c (Fdo_auto_save): |
| 4630 | * emacs.c (Fkill_emacs): |
| 4631 | * editfns.c (save_excursion_restore): |
| 4632 | * cmds.c (internal_self_insert): |
| 4633 | * callint.c (Fcall_interactively): |
| 4634 | * buffer.c (Fkill_all_local_variables): |
| 4635 | * keyboard.c (Fcommand_execute, Fsuspend_emacs, safe_run_hooks_1): |
| 4636 | Use Frun_hooks. |
| 4637 | (command_loop_1): Use Frun_hooks. Call safe_run_hooks |
| 4638 | unconditionnaly since it does the check itself. |
| 4639 | |
| 4640 | 2011-03-23 Paul Eggert <eggert@cs.ucla.edu> |
| 4641 | |
| 4642 | Fix more problems found by GCC 4.5.2's static checks. |
| 4643 | |
| 4644 | * coding.c (encode_coding_raw_text): Avoid unnecessary test |
| 4645 | the first time through the loop, since we know p0 < p1 then. |
| 4646 | This also avoids a gcc -Wstrict-overflow warning. |
| 4647 | |
| 4648 | * lisp.h (SAFE_ALLOCA, SAFE_ALLOCA_LISP): Avoid 'int' overflow |
| 4649 | leading to a memory leak, possible in functions like |
| 4650 | load_charset_map_from_file that can allocate an unbounded number |
| 4651 | of objects (Bug#8318). |
| 4652 | |
| 4653 | * xmenu.c (set_frame_menubar): Use EMACS_UINT, not int, for indexes |
| 4654 | that could (at least in theory) be that large. |
| 4655 | |
| 4656 | * xdisp.c (message_log_check_duplicate): Return unsigned long, not int. |
| 4657 | This is less likely to overflow, and avoids undefined behavior if |
| 4658 | overflow does occur. All callers changed. Use strtoul to scan |
| 4659 | for the unsigned long integer. |
| 4660 | (pint2hrstr): Simplify and tune code slightly. |
| 4661 | This also avoids a (bogus) GCC warning with gcc -Wstrict-overflow. |
| 4662 | |
| 4663 | * scroll.c (do_scrolling): Work around GCC bug 48228. |
| 4664 | See <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48228>. |
| 4665 | |
| 4666 | * frame.c (Fmodify_frame_parameters): Simplify loop counter. |
| 4667 | This also avoids a warning with gcc -Wstrict-overflow. |
| 4668 | (validate_x_resource_name): Simplify count usage. |
| 4669 | This also avoids a warning with gcc -Wstrict-overflow. |
| 4670 | |
| 4671 | * fileio.c (Fcopy_file): Report error if fchown or fchmod |
| 4672 | fail (Bug#8306). |
| 4673 | |
| 4674 | * emacs.c (Fdaemon_initialized): Do not ignore I/O errors (Bug#8303). |
| 4675 | |
| 4676 | * process.c (Fmake_network_process): Use socklen_t, not int, |
| 4677 | where POSIX says socklen_t is required in portable programs. |
| 4678 | This fixes a porting bug on hosts like 64-bit HP-UX, where |
| 4679 | socklen_t is wider than int (Bug#8277). |
| 4680 | (Fmake_network_process, server_accept_connection): |
| 4681 | (wait_reading_process_output, read_process_output): |
| 4682 | Likewise. |
| 4683 | |
| 4684 | * process.c: Rename or move locals to avoid shadowing. |
| 4685 | (list_processes_1, Fmake_network_process): |
| 4686 | (read_process_output_error_handler, exec_sentinel_error_handler): |
| 4687 | Rename or move locals. |
| 4688 | (Fmake_network_process): Define label "retry_connect" only if needed. |
| 4689 | (Fnetwork_interface_info): Fix pointer signedness. |
| 4690 | (process_send_signal): Add cast to avoid pointer signedness problem. |
| 4691 | (FIRST_PROC_DESC, IF_NON_BLOCKING_CONNECT): Remove unused macros. |
| 4692 | (create_process): Use 'volatile' to avoid vfork clobbering (Bug#8298). |
| 4693 | |
| 4694 | Make tparam.h and terminfo.c consistent. |
| 4695 | * cm.c (tputs, tgoto, BC, UP): Remove extern decls. |
| 4696 | Include tparam.h instead, since it declares them. |
| 4697 | * cm.h (PC): Remove extern decl; tparam.h now does this. |
| 4698 | * deps.mk (cm.o, terminfo.o): Depend on tparam.h. |
| 4699 | * terminfo.c: Include tparam.h, to check interfaces. |
| 4700 | (tparm): Make 1st arg a const pointer in decl. Put it at top level. |
| 4701 | (tparam): Adjust signature to match interface in tparam.h; |
| 4702 | this removes some undefined behavior. Check that outstring and len |
| 4703 | are zero, which they always are with Emacs. |
| 4704 | * tparam.h (PC, BC, UP): New extern decls. |
| 4705 | |
| 4706 | * xftfont.c (xftfont_shape): Now static, and defined only if needed. |
| 4707 | (xftfont_open): Rename locals to avoid shadowing. |
| 4708 | |
| 4709 | * ftfont.c (ftfont_resolve_generic_family): Fix pointer signedness. |
| 4710 | (ftfont_otf_capability, ftfont_shape): Omit decls if not needed. |
| 4711 | (OTF_TAG_SYM): Omit macro if not needed. |
| 4712 | (ftfont_list): Remove unused local. |
| 4713 | (get_adstyle_property, ftfont_pattern_entity): |
| 4714 | (ftfont_lookup_cache, ftfont_open, ftfont_anchor_point): |
| 4715 | Rename locals to avoid shadowing. |
| 4716 | |
| 4717 | * xfont.c (xfont_list_family): Mark var as initialized. |
| 4718 | |
| 4719 | * xml.c (make_dom): Now static. |
| 4720 | |
| 4721 | * composite.c (composition_compute_stop_pos): Rename local to |
| 4722 | avoid shadowing. |
| 4723 | (composition_reseat_it): Remove unused locals. |
| 4724 | (find_automatic_composition, composition_adjust_point): Likewise. |
| 4725 | (composition_update_it): Mark var as initialized. |
| 4726 | (find_automatic_composition): Mark vars as initialized, |
| 4727 | with a FIXME (Bug#8290). |
| 4728 | |
| 4729 | character.h: Rename locals to avoid shadowing. |
| 4730 | * character.h (PREV_CHAR_BOUNDARY, FETCH_STRING_CHAR_ADVANCE): |
| 4731 | (FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE, FETCH_CHAR_ADVANCE): |
| 4732 | (FETCH_CHAR_ADVANCE_NO_CHECK, INC_POS, DEC_POS, BUF_INC_POS): |
| 4733 | (BUF_DEC_POS): Be more systematic about renaming local temporaries |
| 4734 | to avoid shadowing. |
| 4735 | |
| 4736 | * textprop.c (property_change_between_p): Remove; unused. |
| 4737 | |
| 4738 | * intervals.c (interval_start_pos): Now static. |
| 4739 | |
| 4740 | * intervals.h (CHECK_TOTAL_LENGTH): Avoid empty "else". |
| 4741 | |
| 4742 | * atimer.c (start_atimer, append_atimer_lists, set_alarm): |
| 4743 | Rename locals to avoid shadowing. |
| 4744 | |
| 4745 | * sound.c (wav_play, au_play, Fplay_sound_internal): |
| 4746 | Fix pointer signedness. |
| 4747 | (alsa_choose_format): Remove unused local var. |
| 4748 | (wav_play): Initialize a variable to 0, to prevent undefined |
| 4749 | behavior (Bug#8278). |
| 4750 | |
| 4751 | * region-cache.c (insert_cache_boundary): Redo var to avoid shadowing. |
| 4752 | |
| 4753 | * region-cache.h (pp_cache): New decl, for gcc -Wmissing-prototypes. |
| 4754 | |
| 4755 | * callproc.c (Fcall_process): Use 'volatile' to avoid vfork |
| 4756 | clobbering (Bug#8298). |
| 4757 | * sysdep.c (sys_subshell): Likewise. |
| 4758 | Previously, the sys_subshell 'volatile' was incorrectly IF_LINTted out. |
| 4759 | |
| 4760 | * lisp.h (child_setup): Now NO_RETURN unless DOS_NT. |
| 4761 | This should get cleaned up, so that child_setup has the |
| 4762 | same signature on all platforms. |
| 4763 | |
| 4764 | * callproc.c (call_process_cleanup): Now static. |
| 4765 | (relocate_fd): Rename locals to avoid shadowing. |
| 4766 | |
| 4767 | 2011-03-22 Chong Yidong <cyd@stupidchicken.com> |
| 4768 | |
| 4769 | * xterm.c (x_clear_frame): Remove XClearWindow call. This appears |
| 4770 | not to be necessary, and produces flickering. |
| 4771 | |
| 4772 | 2011-03-20 Glenn Morris <rgm@gnu.org> |
| 4773 | |
| 4774 | * config.in: Remove file. |
| 4775 | |
| 4776 | 2011-03-20 Juanma Barranquero <lekktu@gmail.com> |
| 4777 | |
| 4778 | * minibuf.c (Vcompleting_read_function): Don't declare, global variables |
| 4779 | are now in src/globals.h. |
| 4780 | (syms_of_minibuf): Remove spurious & from previous change. |
| 4781 | |
| 4782 | 2011-03-20 Leo <sdl.web@gmail.com> |
| 4783 | |
| 4784 | * minibuf.c (completing-read-function): New variable. |
| 4785 | (completing-read-default): Rename from completing-read. |
| 4786 | (completing-read): Call completing-read-function. |
| 4787 | |
| 4788 | 2011-03-19 Juanma Barranquero <lekktu@gmail.com> |
| 4789 | |
| 4790 | * xfaces.c (Fx_load_color_file): |
| 4791 | Read color file from absolute filename (bug#8250). |
| 4792 | |
| 4793 | 2011-03-19 Juanma Barranquero <lekktu@gmail.com> |
| 4794 | |
| 4795 | * makefile.w32-in: Update dependencies. |
| 4796 | |
| 4797 | 2011-03-17 Eli Zaretskii <eliz@gnu.org> |
| 4798 | |
| 4799 | * makefile.w32-in ($(BLD)/unexw32.$(O)): Depend on $(SRC)/unexec.h. |
| 4800 | |
| 4801 | 2011-03-17 Paul Eggert <eggert@cs.ucla.edu> |
| 4802 | |
| 4803 | Fix more problems found by GCC 4.5.2's static checks. |
| 4804 | |
| 4805 | * process.c (make_serial_process_unwind, send_process_trap): |
| 4806 | (sigchld_handler): Now static. |
| 4807 | |
| 4808 | * process.c (allocate_pty): Let PTY_ITERATION declare iteration vars. |
| 4809 | That way, the code declares only the vars that it needs. |
| 4810 | * s/aix4-2.h (PTY_ITERATION): Declare iteration vars. |
| 4811 | * s/cygwin.h (PTY_ITERATION): Likewise. |
| 4812 | * s/darwin.h (PTY_ITERATION): Likewise. |
| 4813 | * s/gnu-linux.h (PTY_ITERATION): Likewise. |
| 4814 | |
| 4815 | * s/irix6-5.h (PTY_OPEN): Declare stb, to loosen coupling. |
| 4816 | * process.c (allocate_pty): Don't declare stb unless it's needed. |
| 4817 | |
| 4818 | * bytecode.c (MAYBE_GC): Rewrite so as not to use empty "else". |
| 4819 | (CONSTANTLIM): Remove; unused. |
| 4820 | (METER_CODE, Bscan_buffer, Bread_char, Bset_mark): |
| 4821 | Define only if needed. |
| 4822 | |
| 4823 | * unexelf.c (unexec): Name an expression, |
| 4824 | to avoid gcc -Wbad-function-cast warning. |
| 4825 | Use a different way to cause a compilation error if anyone uses |
| 4826 | n rather than nn, a way that does not involve shadowing. |
| 4827 | (ELF_BSS_SECTION_NAME, OLD_PROGRAM_H): Remove; unused. |
| 4828 | |
| 4829 | * deps.mk (unexalpha.o): Remove; unused. |
| 4830 | |
| 4831 | New file unexec.h, the (simple) interface for unexec (Bug#8267). |
| 4832 | * unexec.h: New file. |
| 4833 | * deps.mk (emacs.o, unexaix.o, unexcw.o, unexcoff.o, unexelf.o): |
| 4834 | (unexhp9k800.o, unexmacosx.o, unexsol.o, unexw32.o): |
| 4835 | Depend on unexec.h. |
| 4836 | * emacs.c [!defined CANNOT_DUMP]: Include unexec.h. |
| 4837 | * unexaix.c, unexcoff.c, unexcw.c, unexelf.c, unexhp9k800.c: |
| 4838 | * unexmacosx.c, unexsol.c, unexw32.c: Include unexec.h. |
| 4839 | Change as necessary to match prototype in unexec.h. |
| 4840 | |
| 4841 | * syntax.c (Fforward_comment, scan_lists): Rename locals to avoid |
| 4842 | shadowing. |
| 4843 | (back_comment, skip_chars): Mark vars as initialized. |
| 4844 | |
| 4845 | * character.h (FETCH_STRING_CHAR_ADVANCE_NO_CHECK, BUF_INC_POS): |
| 4846 | Rename locals to avoid shadowing. |
| 4847 | |
| 4848 | * lread.c (read1): Rewrite so as not to use empty "else". |
| 4849 | (Fload, readevalloop, read1): Rename locals to avoid shadowing. |
| 4850 | |
| 4851 | * print.c (Fredirect_debugging_output): Fix pointer signedess. |
| 4852 | |
| 4853 | * lisp.h (debug_output_compilation_hack): Add decl here, to avoid |
| 4854 | warning when compiling print.c. |
| 4855 | |
| 4856 | * font.c (font_unparse_fcname): Abort in an "impossible" situation |
| 4857 | instead of using an uninitialized var. |
| 4858 | (font_sort_entities): Mark var as initialized. |
| 4859 | |
| 4860 | * character.h (FETCH_CHAR_ADVANCE): Rename locals to avoid shadowing. |
| 4861 | |
| 4862 | * font.c (font_unparse_xlfd): Don't mix pointers to variables with |
| 4863 | pointers to constants. |
| 4864 | (font_parse_fcname): Remove unused vars. |
| 4865 | (font_delete_unmatched): Now static. |
| 4866 | (font_get_spec): Remove; unused. |
| 4867 | (font_style_to_value, font_prop_validate_style, font_unparse_fcname): |
| 4868 | (font_update_drivers, Ffont_get_glyphs, font_add_log): |
| 4869 | Rename or move locals to avoid shadowing. |
| 4870 | |
| 4871 | * fns.c (require_nesting_list, require_unwind): Now static. |
| 4872 | (Ffillarray): Rename locals to avoid shadowing. |
| 4873 | |
| 4874 | * floatfns.c (domain_error2): Define only if needed. |
| 4875 | (Ffrexp, Fldexp): Rename locals to avoid shadowing. |
| 4876 | |
| 4877 | * alloc.c (mark_backtrace): Move decl from here ... |
| 4878 | * lisp.h: ... to here, so that it can be checked. |
| 4879 | |
| 4880 | * eval.c (call_debugger, do_debug_on_call, grow_specpdl): Now static. |
| 4881 | (Fdefvar): Rewrite so as not to use empty "else". |
| 4882 | (lisp_indirect_variable): Name an expression, |
| 4883 | to avoid gcc -Wbad-function-cast warning. |
| 4884 | (Fdefvar): Rename locals to avoid shadowing. |
| 4885 | |
| 4886 | * callint.c (quotify_arg, quotify_args): Now static. |
| 4887 | (Fcall_interactively): Rename locals to avoid shadowing. |
| 4888 | Use const pointer when appropriate. |
| 4889 | |
| 4890 | * lisp.h (get_system_name, get_operating_system_release): |
| 4891 | Move decls here, to check interfaces. |
| 4892 | * process.c (get_operating_system_release): Move decl to lisp.h. |
| 4893 | * xrdb.c (get_system_name): Likewise. |
| 4894 | * editfns.c (init_editfns, Fuser_login_name, Fuser_uid): |
| 4895 | (Fuser_real_uid, Fuser_full_name): Remove unnecessary casts, |
| 4896 | some of which prompt warnings from gcc -Wbad-function-cast. |
| 4897 | (Fformat_time_string, Fencode_time, Finsert_char): |
| 4898 | (Ftranslate_region_internal, Fformat): |
| 4899 | Rename or remove local vars to avoid shadowing. |
| 4900 | (Ftranslate_region_internal): Mark var as initialized. |
| 4901 | |
| 4902 | * doc.c (Fdocumentation, Fsnarf_documentation): Move locals to |
| 4903 | avoid shadowing. |
| 4904 | |
| 4905 | * lisp.h (eassert): Check that the argument compiles, even if |
| 4906 | ENABLE_CHECKING is not defined. |
| 4907 | |
| 4908 | * data.c (Findirect_variable): Name an expression, to avoid |
| 4909 | gcc -Wbad-function-cast warning. |
| 4910 | (default_value, arithcompare, arith_driver, arith_error): Now static. |
| 4911 | (store_symval_forwarding): Rename local to avoid shadowing. |
| 4912 | (Fmake_variable_buffer_local, Fmake_local_variable): |
| 4913 | Mark variables as initialized. |
| 4914 | (do_blv_forwarding, do_symval_forwarding): Remove; unused. |
| 4915 | |
| 4916 | * alloc.c (check_cons_list): Do not define unless GC_CHECK_CONS_LIST. |
| 4917 | (Fmake_vector, Fvector, Fmake_byte_code, Fgarbage_collect): |
| 4918 | Rename locals to avoid shadowing. |
| 4919 | (mark_stack): Move local variables into the #ifdef region where |
| 4920 | they're used. |
| 4921 | (BLOCK_INPUT_ALLOC, UNBLOCK_INPUT_ALLOC): Define only if |
| 4922 | ! defined SYSTEM_MALLOC && ! defined SYNC_INPUT, as they are not |
| 4923 | needed otherwise. |
| 4924 | (CHECK_ALLOCATED): Define only if GC_CHECK_MARKED_OBJECTS. |
| 4925 | (GC_STRING_CHARS): Remove; not used. |
| 4926 | (Fmemory_limit): Cast sbrk's returned value to char *. |
| 4927 | |
| 4928 | * lisp.h (check_cons_list): Declare if GC_CHECK_CONS_LIST; this |
| 4929 | avoids undefined behavior in theory. |
| 4930 | |
| 4931 | * regex.c (IF_LINT): Add defn, for benefit of ../lib-src. |
| 4932 | |
| 4933 | Use functions, not macros, for up- and down-casing (Bug#8254). |
| 4934 | * buffer.h (DOWNCASE_TABLE, UPCASE_TABLE, DOWNCASE, UPPERCASEP): |
| 4935 | (NOCASEP, LOWERCASEP, UPCASE, UPCASE1): Remove. All callers changed |
| 4936 | to use the following functions instead of these macros. |
| 4937 | (downcase): Adjust to lack of DOWNCASE_TABLE. Return int, not |
| 4938 | EMACS_INT, since callers assume the returned value fits in int. |
| 4939 | (upcase1): Likewise, for UPCASE_TABLE. |
| 4940 | (uppercasep, lowercasep, upcase): New static inline functions. |
| 4941 | * editfns.c (Fchar_equal): Remove no-longer-needed workaround for |
| 4942 | the race-condition problem in the old DOWNCASE. |
| 4943 | |
| 4944 | * regex.c (CHARSET_LOOKUP_RANGE_TABLE_RAW, POP_FAILURE_REG_OR_COUNT): |
| 4945 | Rename locals to avoid shadowing. |
| 4946 | (regex_compile, re_match_2_internal): Move locals to avoid shadowing. |
| 4947 | (regex_compile, re_search_2, re_match_2_internal): |
| 4948 | Remove unused local vars. |
| 4949 | (FREE_VAR): Rewrite so as not to use empty "else", |
| 4950 | which gcc can warn about. |
| 4951 | (regex_compile, re_match_2_internal): Mark locals as initialized. |
| 4952 | (RETALLOC_IF): Define only if needed. |
| 4953 | (WORDCHAR_P): Likewise. This one is never needed, but is used |
| 4954 | only in a comment talking about a compiler bug, so put inside |
| 4955 | the #if 0 of that comment. |
| 4956 | (CHARSET_LOOKUP_BITMAP, FAIL_STACK_FULL, RESET_FAIL_STACK): |
| 4957 | (PUSH_FAILURE_ELT, BUF_PUSH_3, STOP_ADDR_VSTRING): |
| 4958 | Remove; unused. |
| 4959 | |
| 4960 | * search.c (boyer_moore): Rename locals to avoid shadowing. |
| 4961 | * character.h (FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE): |
| 4962 | (PREV_CHAR_BOUNDARY): Likewise. |
| 4963 | |
| 4964 | * search.c (simple_search): Remove unused var. |
| 4965 | |
| 4966 | * dired.c (compile_pattern): Move decl from here ... |
| 4967 | * lisp.h: ... to here, so that it can be checked. |
| 4968 | (struct re_registers): New forward decl. |
| 4969 | |
| 4970 | * character.h (INC_POS, DEC_POS): Rename locals to avoid shadowing. |
| 4971 | |
| 4972 | * indent.c (MULTIBYTE_BYTES_WIDTH): New args bytes, width. |
| 4973 | All uses changed. |
| 4974 | (MULTIBYTE_BYTES_WIDTH, scan_for_column, compute_motion): |
| 4975 | Rename locals to avoid shadowing. |
| 4976 | (Fvertical_motion): Mark locals as initialized. |
| 4977 | |
| 4978 | * casefiddle.c (casify_object, casify_region): Now static. |
| 4979 | (casify_region): Mark local as initialized. |
| 4980 | |
| 4981 | * cmds.c (internal_self_insert): Rename local to avoid shadowing. |
| 4982 | |
| 4983 | * lisp.h (GCPRO2_VAR, GCPRO3_VAR, GCPRO4_VAR, GCPRO5_VAR, GCPRO6_VAR): |
| 4984 | New macros, so that the caller can use some names other than |
| 4985 | gcpro1, gcpro2, etc. |
| 4986 | (GCPRO2, GCPRO3, GCPRO4, GCPRO5, GCPRO6): Reimplement in terms |
| 4987 | of the new macros. |
| 4988 | (GCPRO1_VAR, UNGCPRO_VAR): Change the meaning of the second |
| 4989 | argument, for consistency with GCPRO2_VAR, etc: it is now the |
| 4990 | prefix of the variable, not the variable itself. All uses |
| 4991 | changed. |
| 4992 | * dired.c (directory_files_internal, file_name_completion): |
| 4993 | Rename locals to avoid shadowing. |
| 4994 | |
| 4995 | Fix a race condition diagnosed by gcc -Wsequence-point (Bug#8254). |
| 4996 | An expression of the form (DOWNCASE (x) == DOWNCASE (y)), found in |
| 4997 | dired.c's scmp function, had undefined behavior. |
| 4998 | * lisp.h (DOWNCASE_TABLE, UPCASE_TABLE, DOWNCASE, UPPERCASEP): |
| 4999 | (NOCASEP, LOWERCASEP, UPCASE, UPCASE1): Move from here ... |
| 5000 | * buffer.h: ... to here, because these macros use current_buffer, |
| 5001 | and the new implementation with inline functions needs to have |
| 5002 | current_buffer in scope now, rather than later when the macros |
| 5003 | are used. |
| 5004 | (downcase, upcase1): New static inline functions. |
| 5005 | (DOWNCASE, UPCASE1): Reimplement using these functions. |
| 5006 | This avoids undefined behavior in expressions like |
| 5007 | DOWNCASE (x) == DOWNCASE (y), which previously suffered |
| 5008 | from race conditions in accessing the global variables |
| 5009 | case_temp1 and case_temp2. |
| 5010 | * casetab.c (case_temp1, case_temp2): Remove; no longer needed. |
| 5011 | * lisp.h (case_temp1, case_temp2): Remove their decls. |
| 5012 | * character.h (ASCII_CHAR_P): Move from here ... |
| 5013 | * lisp.h: ... to here, so that the inline functions mentioned |
| 5014 | above can use them. |
| 5015 | |
| 5016 | * dired.c (directory_files_internal_unwind): Now static. |
| 5017 | |
| 5018 | * fileio.c (file_name_as_directory, directory_file_name): |
| 5019 | (barf_or_query_if_file_exists, auto_save_error, auto_save_1): |
| 5020 | Now static. |
| 5021 | (file_name_as_directory): Use const pointers when appropriate. |
| 5022 | (Fexpand_file_name): Likewise. In particular, newdir might |
| 5023 | point at constant storage, so make it a const pointer. |
| 5024 | (Fmake_directory_internal, Fread_file_name): Remove unused vars. |
| 5025 | (Ffile_selinux_context, Fset_file_selinux_context): Fix pointer |
| 5026 | signedness issues. |
| 5027 | (Fset_file_times, Finsert_file_contents, auto_save_error): |
| 5028 | Rename locals to avoid shadowing. |
| 5029 | |
| 5030 | * minibuf.c (choose_minibuf_frame_1): Now static. |
| 5031 | (Ftry_completion, Fall_completions): Rename or remove locals |
| 5032 | to avoid shadowing. |
| 5033 | |
| 5034 | * marker.c (bytepos_to_charpos): Remove; unused. |
| 5035 | |
| 5036 | * lisp.h (verify_bytepos, count_markers): New decls, |
| 5037 | so that gcc does not warn that these functions aren't declared. |
| 5038 | |
| 5039 | * insdel.c (check_markers, make_gap_larger, make_gap_smaller): |
| 5040 | (reset_var_on_error, Fcombine_after_change_execute_1): Now static. |
| 5041 | (CHECK_MARKERS): Redo to avoid gcc -Wempty-body diagnostic. |
| 5042 | (copy_text): Remove unused local var. |
| 5043 | |
| 5044 | * filelock.c (within_one_second): Now static. |
| 5045 | (lock_file_1): Rename local to avoid shadowing. |
| 5046 | |
| 5047 | * buffer.c (fix_overlays_before): Mark locals as initialized. |
| 5048 | (fix_start_end_in_overlays): Likewise. This function should be |
| 5049 | simplified by using pointers-to-pointers, but that's a different |
| 5050 | matter. |
| 5051 | (switch_to_buffer_1): Now static. |
| 5052 | (Fkill_buffer, record_buffer, Fbury_buffer, Fset_buffer_multibyte): |
| 5053 | (report_overlay_modification): Rename locals to avoid shadowing. |
| 5054 | |
| 5055 | * sysdep.c (system_process_attributes): Rename vars to avoid shadowing. |
| 5056 | Fix pointer signedness issue. |
| 5057 | (sys_subshell): Mark local as volatile if checking for lint, |
| 5058 | to suppress a gcc -Wclobbered warning that does not seem to be right. |
| 5059 | (MAXPATHLEN): Define only if needed. |
| 5060 | |
| 5061 | * process.c (serial_open, serial_configure): Move decls from here ... |
| 5062 | * systty.h: ... to here, so that they can be checked. |
| 5063 | |
| 5064 | * fns.c (get_random, seed_random): Move extern decls from here ... |
| 5065 | * lisp.h: ... to here, so that they can be checked. |
| 5066 | |
| 5067 | * sysdep.c (reset_io): Now static. |
| 5068 | (wait_for_termination_signal): Remove; unused. |
| 5069 | |
| 5070 | * keymap.c (keymap_parent, keymap_memberp, map_keymap_internal): |
| 5071 | (copy_keymap_item, append_key, push_text_char_description): |
| 5072 | Now static. |
| 5073 | (Fwhere_is_internal): Don't test CONSP (sequences) unnecessarily. |
| 5074 | (DENSE_TABLE_SIZE): Remove; unused. |
| 5075 | (get_keymap, access_keymap, Fdefine_key, Fwhere_is_internal): |
| 5076 | (describe_map_tree): |
| 5077 | Rename locals to avoid shadowing. |
| 5078 | |
| 5079 | * keyboard.c: Declare functions static if they are not used elsewhere. |
| 5080 | (echo_char, echo_dash, cmd_error, top_level_2): |
| 5081 | (poll_for_input, handle_async_input): Now static. |
| 5082 | (read_char, kbd_buffer_get_event, make_lispy_position): |
| 5083 | (make_lispy_event, make_lispy_movement, apply_modifiers): |
| 5084 | (decode_keyboard_code, tty_read_avail_input, menu_bar_items): |
| 5085 | (parse_tool_bar_item, read_key_sequence, Fread_key_sequence): |
| 5086 | (Fread_key_sequence_vector): Rename locals to avoid shadowing. |
| 5087 | (read_key_sequence, read_char): Mark locals as initialized. |
| 5088 | (Fexit_recursive_edit, Fabort_recursive_edit): Mark with NO_RETURN. |
| 5089 | |
| 5090 | * keyboard.h (make_ctrl_char): New decl. |
| 5091 | (mark_kboards): Move decl here ... |
| 5092 | * alloc.c (mark_kboards): ... from here. |
| 5093 | |
| 5094 | * lisp.h (force_auto_save_soon): New decl. |
| 5095 | |
| 5096 | * emacs.c (init_cmdargs): Rename local to avoid shadowing. |
| 5097 | (DEFINE_DUMMY_FUNCTION): New macro. |
| 5098 | (__do_global_ctors, __do_global_ctors_aux, __do_global_dtors, __main): |
| 5099 | Use it. |
| 5100 | (main): Add casts to avoid warnings |
| 5101 | if GCC considers string literals to be constants. |
| 5102 | |
| 5103 | * lisp.h (fatal_error_signal): Add decl, since it's exported. |
| 5104 | |
| 5105 | * dbusbind.c: Pointer signedness fixes. |
| 5106 | (xd_signature, xd_append_arg, xd_initialize): |
| 5107 | (Fdbus_call_method, Fdbus_call_method_asynchronously): |
| 5108 | (Fdbus_method_return_internal, Fdbus_method_error_internal): |
| 5109 | (Fdbus_send_signal, xd_read_message_1, Fdbus_register_service): |
| 5110 | (Fdbus_register_signal): Use SSDATA when the context wants char *. |
| 5111 | |
| 5112 | * dbusbind.c (Fdbus_init_bus): Add cast to avoid warning |
| 5113 | if GCC considers string literals to be constants. |
| 5114 | (Fdbus_register_service, Fdbus_register_method): Remove unused vars. |
| 5115 | |
| 5116 | 2011-03-16 Stefan Monnier <monnier@iro.umontreal.ca> |
| 5117 | |
| 5118 | * print.c (PRINT_CIRCLE_CANDIDATE_P): New macro. |
| 5119 | (print_preprocess, print_object): New macro to fix last change. |
| 5120 | |
| 5121 | * print.c (print_preprocess): Don't forget font objects. |
| 5122 | |
| 5123 | 2011-03-16 Juanma Barranquero <lekktu@gmail.com> |
| 5124 | |
| 5125 | * emacs.c (USAGE3): Doc fixes. |
| 5126 | |
| 5127 | 2011-03-15 Andreas Schwab <schwab@linux-m68k.org> |
| 5128 | |
| 5129 | * coding.c (detect_coding_iso_2022): Reorganize code to clarify |
| 5130 | structure. |
| 5131 | |
| 5132 | 2011-03-14 Juanma Barranquero <lekktu@gmail.com> |
| 5133 | |
| 5134 | * lisp.h (VWindow_system, Qfile_name_history): |
| 5135 | * keyboard.h (lispy_function_keys) [WINDOWSNT]: |
| 5136 | * w32term.h (w32_system_caret_hwnd, w32_system_caret_height) |
| 5137 | (w32_system_caret_x, w32_system_caret_y): Declare extern. |
| 5138 | |
| 5139 | * w32select.c: Don't #include "keyboard.h". |
| 5140 | (run_protected): Add extern declaration for waiting_for_input. |
| 5141 | |
| 5142 | * w32.c (Qlocal, noninteractive1, inhibit_window_system): |
| 5143 | * w32console.c (detect_input_pending, read_input_pending) |
| 5144 | (encode_terminal_code): |
| 5145 | * w32fns.c (quit_char, lispy_function_keys, Qtooltip) |
| 5146 | (w32_system_caret_hwnd, w32_system_caret_height, w32_system_caret_x) |
| 5147 | (w32_system_caret_y, Qfile_name_history): |
| 5148 | * w32font.c (w32font_driver, QCantialias, QCotf, QClang): |
| 5149 | * w32inevt.c (reinvoke_input_signal, lispy_function_keys): |
| 5150 | * w32menu.c (Qmenu_bar, QCtoggle, QCradio, Qoverriding_local_map) |
| 5151 | (Qoverriding_terminal_local_map, Qmenu_bar_update_hook): |
| 5152 | * w32proc.c (Qlocal, report_file_error): |
| 5153 | * w32term.c (Vwindow_system, updating_frame): |
| 5154 | * w32uniscribe.c (initialized, uniscribe_font_driver): |
| 5155 | Remove unneeded extern declarations. |
| 5156 | |
| 5157 | 2011-03-14 Chong Yidong <cyd@stupidchicken.com> |
| 5158 | |
| 5159 | * buffer.c (Fmake_indirect_buffer): Fix incorrect assertions. |
| 5160 | |
| 5161 | 2011-03-13 Chong Yidong <cyd@stupidchicken.com> |
| 5162 | |
| 5163 | * buffer.h (BUF_BEGV, BUF_BEGV_BYTE, BUF_ZV, BUF_ZV_BYTE, BUF_PT) |
| 5164 | (BUF_PT_BYTE): Rewrite to handle indirect buffers (Bug#8219). |
| 5165 | These macros can no longer be used for assignment. |
| 5166 | |
| 5167 | * buffer.c (Fget_buffer_create, Fmake_indirect_buffer): |
| 5168 | Assign struct members directly, instead of using BUF_BEGV etc. |
| 5169 | (record_buffer_markers, fetch_buffer_markers): New functions for |
| 5170 | recording and fetching special buffer markers. |
| 5171 | (set_buffer_internal_1, set_buffer_temp): Use them. |
| 5172 | |
| 5173 | * lread.c (unreadchar): Use SET_BUF_PT_BOTH. |
| 5174 | |
| 5175 | * insdel.c (adjust_point): Use SET_BUF_PT_BOTH. |
| 5176 | |
| 5177 | * intervals.c (temp_set_point_both): Use SET_BUF_PT_BOTH. |
| 5178 | (get_local_map): Use SET_BUF_BEGV_BOTH and SET_BUF_ZV_BOTH. |
| 5179 | |
| 5180 | * xdisp.c (hscroll_window_tree): |
| 5181 | (reconsider_clip_changes): Use PT instead of BUF_PT. |
| 5182 | |
| 5183 | 2011-03-13 Eli Zaretskii <eliz@gnu.org> |
| 5184 | |
| 5185 | * makefile.w32-in ($(BLD)/editfns.$(O)): Depend on |
| 5186 | $(EMACS_ROOT)/lib/intprops.h. |
| 5187 | |
| 5188 | 2011-03-13 Paul Eggert <eggert@cs.ucla.edu> |
| 5189 | |
| 5190 | Fix more problems found by GCC 4.5.2's static checks. |
| 5191 | |
| 5192 | * gtkutil.c (xg_get_pixbuf_from_pixmap): Add cast from char * |
| 5193 | to unsigned char * to avoid compiler diagnostic. |
| 5194 | (xg_free_frame_widgets): Make it clear that a local variable is |
| 5195 | needed only if USE_GTK_TOOLTIP. |
| 5196 | (gdk_window_get_screen): Make it clear that this macro is needed |
| 5197 | only if USE_GTK_TOOLTIP. |
| 5198 | (int_gtk_range_get_value): New function, which avoids a diagnostic |
| 5199 | from gcc -Wbad-function-cast. |
| 5200 | (xg_set_toolkit_scroll_bar_thumb): Use it. |
| 5201 | (xg_tool_bar_callback, xg_tool_item_stale_p): Rewrite to avoid |
| 5202 | diagnostic from gcc -Wbad-function-cast. |
| 5203 | (get_utf8_string, xg_get_file_with_chooser): |
| 5204 | Rename locals to avoid shadowing. |
| 5205 | (create_dialog): Move locals to avoid shadowing. |
| 5206 | |
| 5207 | * xgselect.c (xg_select): Remove unused var. |
| 5208 | |
| 5209 | * image.c (four_corners_best): Mark locals as initialized. |
| 5210 | (gif_load): Initialize transparent_p to zero (Bug#8238). |
| 5211 | Mark another local as initialized. |
| 5212 | (my_png_error, my_error_exit): Mark with NO_RETURN. |
| 5213 | |
| 5214 | * image.c (clear_image_cache): Now static. |
| 5215 | (DIM, HAVE_STDLIB_H_1): Remove unused macros. |
| 5216 | (xpm_load): Redo to avoid "discards qualifiers" gcc warning. |
| 5217 | (x_edge_detection): Remove unnecessary cast that |
| 5218 | gcc -Wbad-function-cast diagnoses. |
| 5219 | (gif_load): Fix pointer signedness. |
| 5220 | (clear_image_cache, xbm_read_bitmap_data, x_detect_edges): |
| 5221 | (jpeg_load, gif_load): Rename locals to avoid shadowing. |
| 5222 | |
| 5223 | 2011-03-12 Paul Eggert <eggert@cs.ucla.edu> |
| 5224 | |
| 5225 | Improve quality of tests for time stamp overflow. |
| 5226 | For example, without this patch (encode-time 0 0 0 1 1 |
| 5227 | 1152921504606846976) returns the obviously-bogus value (-948597 |
| 5228 | 62170) on my RHEL 5.5 x86-64 host. With the patch, it correctly |
| 5229 | reports time overflow. See |
| 5230 | <http://lists.gnu.org/archive/html/emacs-devel/2011-03/msg00470.html>. |
| 5231 | * deps.mk (editfns.o): Depend on ../lib/intprops.h. |
| 5232 | * editfns.c: Include limits.h and intprops.h. |
| 5233 | (TIME_T_MIN, TIME_T_MAX): New macros. |
| 5234 | (time_overflow): Move earlier, to before first use. |
| 5235 | (hi_time, lo_time): New functions, for an accurate test for |
| 5236 | out-of-range times. |
| 5237 | (Fcurrent_time, Fget_internal_run_time, make_time): Use them. |
| 5238 | (Fget_internal_run_time): Don't assume time_t fits in int. |
| 5239 | (make_time): Use list2 instead of Fcons twice. |
| 5240 | (Fdecode_time): More accurate test for out-of-range times. |
| 5241 | (check_tm_member): New function. |
| 5242 | (Fencode_time): Use it, to test for out-of-range times. |
| 5243 | (lisp_time_argument): Don't rely on undefined left-shift and |
| 5244 | right-shift behavior when checking for time stamp overflow. |
| 5245 | |
| 5246 | * editfns.c (time_overflow): New function, refactoring common code. |
| 5247 | (Fformat_time_string, Fdecode_time, Fencode_time): |
| 5248 | (Fcurrent_time_string): Use it. |
| 5249 | |
| 5250 | Move 'make_time' to be next to its inverse 'lisp_time_argument'. |
| 5251 | * dired.c (make_time): Move to ... |
| 5252 | * editfns.c (make_time): ... here. |
| 5253 | * systime.h: Note the move. |
| 5254 | |
| 5255 | 2011-03-12 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
| 5256 | |
| 5257 | * fringe.c (update_window_fringes): Remove unused variables. |
| 5258 | |
| 5259 | * unexmacosx.c (copy_data_segment): Also copy __got section. |
| 5260 | (Bug#8223) |
| 5261 | |
| 5262 | 2011-03-12 Eli Zaretskii <eliz@gnu.org> |
| 5263 | |
| 5264 | * termcap.c [MSDOS]: Include "msdos.h". |
| 5265 | (find_capability, tgetnum, tgetflag, tgetstr, tputs, tgetent): |
| 5266 | Constify `char *' arguments and their references according to |
| 5267 | prototypes in tparam.h. |
| 5268 | |
| 5269 | * deps.mk (termcap.o): Depend on tparam.h and msdos.h. |
| 5270 | |
| 5271 | * msdos.c (XMenuAddPane): 3rd argument is `const char *' now. |
| 5272 | Adapt all references accordingly. |
| 5273 | |
| 5274 | * msdos.h (XMenuAddPane): 3rd argument is `const char *' now. |
| 5275 | |
| 5276 | 2011-03-11 Tom Tromey <tromey@redhat.com> |
| 5277 | |
| 5278 | * buffer.c (syms_of_buffer): Remove obsolete comment. |
| 5279 | |
| 5280 | 2011-03-11 Eli Zaretskii <eliz@gnu.org> |
| 5281 | |
| 5282 | * termhooks.h (encode_terminal_code): Declare prototype. |
| 5283 | |
| 5284 | * msdos.c (encode_terminal_code): Don't declare prototype. |
| 5285 | |
| 5286 | * term.c (encode_terminal_code): Now external again, used by |
| 5287 | w32console.c and msdos.c. |
| 5288 | |
| 5289 | * makefile.w32-in ($(BLD)/term.$(O), ($(BLD)/tparam.$(O)): |
| 5290 | Depend on $(SRC)/tparam.h, see 2011-03-11T07:24:21Z!eggert@cs.ucla.edu. |
| 5291 | |
| 5292 | 2011-03-11 Paul Eggert <eggert@cs.ucla.edu> |
| 5293 | |
| 5294 | Fix some minor problems found by GCC 4.5.2's static checks. |
| 5295 | |
| 5296 | * fringe.c (update_window_fringes): Mark locals as initialized |
| 5297 | (Bug#8227). |
| 5298 | (destroy_fringe_bitmap, init_fringe_bitmap): Now static. |
| 5299 | |
| 5300 | * alloc.c (mark_fringe_data): Move decl from here ... |
| 5301 | * lisp.h (mark_fringe_data) [HAVE_WINDOW_SYSTEM]: ... to here, |
| 5302 | to check its interface. |
| 5303 | (init_fringe_once): Do not declare unless HAVE_WINDOW_SYSTEM. |
| 5304 | |
| 5305 | * fontset.c (free_realized_fontset): Now static. |
| 5306 | (Fset_fontset_font): Rename local to avoid shadowing. |
| 5307 | (fontset_font): Mark local as initialized. |
| 5308 | (FONTSET_SPEC, FONTSET_REPERTORY, RFONT_DEF_REPERTORY): Remove; unused. |
| 5309 | |
| 5310 | * xrdb.c: Include "xterm.h", to check x_load_resources's interface. |
| 5311 | |
| 5312 | * xselect.c (x_disown_buffer_selections): Remove; not used. |
| 5313 | (TRACE3) [!defined TRACE_SELECTION]: Remove; not used. |
| 5314 | (x_own_selection, Fx_disown_selection_internal): Rename locals |
| 5315 | to avoid shadowing. |
| 5316 | (x_handle_dnd_message): Remove local to avoid shadowing. |
| 5317 | |
| 5318 | * lisp.h (GCPRO1_VAR, UNGCPRO_VAR): New macros, |
| 5319 | so that the caller can use some name other than gcpro1. |
| 5320 | (GCPRO1, UNGCPRO): Reimplement in terms of the new macros. |
| 5321 | * xfns.c (Fx_create_frame, x_create_tip_frame, Fx_show_tip): |
| 5322 | (Fx_backspace_delete_keys_p): |
| 5323 | Use them to avoid shadowing, and rename vars to avoid shadowing. |
| 5324 | (x_decode_color, x_set_name, x_window): Now static. |
| 5325 | (Fx_create_frame): Add braces to silence GCC warning. |
| 5326 | (Fx_file_dialog, Fx_select_font): Fix pointer signedness. |
| 5327 | (x_real_positions, xg_set_icon_from_xpm_data, x_create_tip_frame): |
| 5328 | Remove unused locals. |
| 5329 | (Fx_create_frame, x_create_tip_frame, Fx_show_tip): |
| 5330 | (Fx_backspace_delete_keys_p): Rename locals to avoid shadowing. |
| 5331 | Some of these renamings use the new GCPRO1_VAR and UNGCPRO_VAR |
| 5332 | macros. |
| 5333 | |
| 5334 | * xterm.h (x_mouse_leave): New decl. |
| 5335 | |
| 5336 | * xterm.c (x_copy_dpy_color, x_focus_on_frame, x_unfocus_frame): |
| 5337 | Remove unused functions. |
| 5338 | (x_shift_glyphs_for_insert, XTflash, XTring_bell): |
| 5339 | (x_calc_absolute_position): Now static. |
| 5340 | (XTread_socket): Don't define label "out" unless it's used. |
| 5341 | Don't declare local "event" unless it's used. |
| 5342 | (x_iconify_frame, x_free_frame_resources): Don't declare locals |
| 5343 | unless they are used. |
| 5344 | (XEMBED_VERSION, xembed_set_info): Don't define unless needed. |
| 5345 | (x_fatal_error_signal): Remove; not used. |
| 5346 | (x_draw_image_foreground, redo_mouse_highlight, XTmouse_position): |
| 5347 | (x_scroll_bar_report_motion, handle_one_xevent, x_draw_bar_cursor): |
| 5348 | (x_error_catcher, x_connection_closed, x_error_handler): |
| 5349 | (x_error_quitter, xembed_send_message, x_iconify_frame): |
| 5350 | (my_log_handler): Rename locals to avoid shadowing. |
| 5351 | (x_delete_glyphs, x_ins_del_lines): Mark with NO_RETURN. |
| 5352 | (x_connection_closed): Tell GCC not to suggest NO_RETURN. |
| 5353 | |
| 5354 | * xfaces.c (clear_face_cache, Fx_list_fonts, Fface_font): |
| 5355 | Rename or move locals to avoid shadowing. |
| 5356 | (tty_defined_color, merge_face_heights): Now static. |
| 5357 | (free_realized_faces_for_fontset): Remove; not used. |
| 5358 | (Fx_list_fonts): Mark variable that gcc -Wuninitialized |
| 5359 | does not deduce is never used uninitialized. |
| 5360 | (STRDUPA, LSTRDUPA, FONT_POINT_SIZE_QUANTUM): Remove; not used. |
| 5361 | (LFACEP): Define only if XASSERTS, as it's not needed otherwise. |
| 5362 | |
| 5363 | * terminal.c (store_terminal_param): Now static. |
| 5364 | |
| 5365 | * xmenu.c (menu_highlight_callback): Now static. |
| 5366 | (set_frame_menubar): Remove unused local. |
| 5367 | (xmenu_show): Rename parameter to avoid shadowing. |
| 5368 | (xmenu_show, xdialog_show, xmenu_show): Make local pointers "const" |
| 5369 | since they might point to immutable storage. |
| 5370 | (next_menubar_widget_id): Declare only if USE_X_TOOLKIT, |
| 5371 | since it's unused otherwise. |
| 5372 | |
| 5373 | * xdisp.c (produce_glyphless_glyph): Initialize lower_xoff. |
| 5374 | Add a FIXME, since the code still doesn't look right. (Bug#8215) |
| 5375 | (Fcurrent_bidi_paragraph_direction): Simplify slightly; this |
| 5376 | avoids a gcc -Wuninitialized diagnostic. |
| 5377 | (display_line, BUILD_COMPOSITE_GLYPH_STRING, draw_glyphs): |
| 5378 | (note_mouse_highlight): Mark variables that gcc -Wuninitialized |
| 5379 | does not deduce are never used uninitialized. |
| 5380 | |
| 5381 | * lisp.h (IF_LINT): New macro, copied from ../lib-src/emacsclient.c. |
| 5382 | |
| 5383 | * xdisp.c (redisplay_window): Rename local to avoid shadowing. |
| 5384 | * window.c (window_loop, size_window): |
| 5385 | (run_window_configuration_change_hook, enlarge_window): Likewise. |
| 5386 | |
| 5387 | * window.c (display_buffer): Now static. |
| 5388 | (size_window): Mark variables that gcc -Wuninitialized |
| 5389 | does not deduce are never used uninitialized. |
| 5390 | * window.h (check_all_windows): New decl, to forestall |
| 5391 | gcc -Wmissing-prototypes diagnostic. |
| 5392 | * dispextern.h (bidi_dump_cached_states): Likewise. |
| 5393 | |
| 5394 | * charset.h (CHECK_CHARSET_GET_CHARSET): Rename locals to avoid |
| 5395 | shadowing. |
| 5396 | * charset.c (map_charset_for_dump, Fchar_charset): Likewise. |
| 5397 | Include <limits.h>. |
| 5398 | (Fsort_charsets): Redo min/max calculation to shorten the code a bit |
| 5399 | and to avoid gcc -Wuninitialized warning. |
| 5400 | (load_charset_map): Mark variables that gcc -Wuninitialized |
| 5401 | does not deduce are never used uninitialized. |
| 5402 | (load_charset): Abort instead of using uninitialized var (Bug#8229). |
| 5403 | |
| 5404 | * coding.c (coding_set_source, coding_set_destination): |
| 5405 | Use "else { /* comment */ }" rather than "else /* comment */;" |
| 5406 | for clarity, and to avoid gcc -Wempty-body warning. |
| 5407 | (Fdefine_coding_system_internal): Don't redeclare 'i' inside |
| 5408 | a block, when the outer 'i' will do. |
| 5409 | (decode_coding_utf_8, decode_coding_utf_16, detect_coding_emacs_mule): |
| 5410 | (emacs_mule_char, decode_coding_emacs_mule, detect_coding_iso_2022): |
| 5411 | (decode_coding_iso_2022, decode_coding_sjis, decode_coding_big5): |
| 5412 | (decode_coding_raw_text, decode_coding_charset, get_translation_table): |
| 5413 | (Fdecode_sjis_char, Fdefine_coding_system_internal): |
| 5414 | Rename locals to avoid shadowing. |
| 5415 | * character.h (FETCH_STRING_CHAR_ADVANCE): Likewise. |
| 5416 | * coding.c (emacs_mule_char, encode_invocation_designation): |
| 5417 | Now static, since they're not used elsewhere. |
| 5418 | (decode_coding_iso_2022): Add "default: abort ();" as a safety check. |
| 5419 | (decode_coding_object, encode_coding_object, detect_coding_system): |
| 5420 | (decode_coding_emacs_mule): Mark variables that gcc |
| 5421 | -Wuninitialized does not deduce are never used uninitialized. |
| 5422 | (detect_coding_iso_2022): Initialize a local variable that might |
| 5423 | be used uninitialized. Leave a FIXME because it's not clear that |
| 5424 | this initialization is needed. (Bug#8211) |
| 5425 | (ISO_CODE_LF, ISO_CODE_CR, CODING_ISO_FLAG_EUC_TW_SHIFT): |
| 5426 | (ONE_MORE_BYTE_NO_CHECK, UTF_BOM, UTF_16_INVALID_P): |
| 5427 | (SHIFT_OUT_OK, ENCODE_CONTROL_SEQUENCE_INTRODUCER): |
| 5428 | (ENCODE_DIRECTION_R2L, ENCODE_DIRECTION_L2R): |
| 5429 | Remove unused macros. |
| 5430 | |
| 5431 | * category.c (hash_get_category_set): Remove unused local var. |
| 5432 | (copy_category_table): Now static, since it's not used elsewhere. |
| 5433 | * character.c (string_count_byte8): Likewise. |
| 5434 | |
| 5435 | * ccl.c (CCL_WRITE_STRING, CCL_ENCODE_CHAR, Fccl_execute_on_string): |
| 5436 | (Fregister_code_conversion_map): Rename locals to avoid shadowing. |
| 5437 | |
| 5438 | * chartab.c (copy_sub_char_table): Now static, since it's not used |
| 5439 | elsewhere. |
| 5440 | (sub_char_table_ref_and_range, char_table_ref_and_range): |
| 5441 | Rename locals to avoid shadowing. |
| 5442 | (ASET_RANGE, GET_SUB_CHAR_TABLE): Remove unused macros. |
| 5443 | |
| 5444 | * bidi.c (bidi_check_type): Now static, since it's not used elsewhere. |
| 5445 | (BIDI_BOB): Remove unused macro. |
| 5446 | |
| 5447 | * cm.c (cmgoto): Mark variables that gcc -Wuninitialized does not |
| 5448 | deduce are never used uninitialized. |
| 5449 | * term.c (encode_terminal_code): Likewise. |
| 5450 | |
| 5451 | * term.c (encode_terminal_code): Now static. Remove unused local. |
| 5452 | |
| 5453 | * tparam.h: New file. |
| 5454 | * term.c, tparam.h: Include it. |
| 5455 | * deps.mk (term.o, tparam.o): Depend on tparam.h. |
| 5456 | * term.c (tputs, tgetent, tgetflag, tgetnum, tparam, tgetstr): |
| 5457 | Move these decls to tparam.h, and make them agree with what |
| 5458 | is actually in tparam.c. The previous trick of using incompatible |
| 5459 | decls in different modules does not conform to the C standard. |
| 5460 | All callers of tparam changed to use tparam's actual API. |
| 5461 | * tparam.c (tparam1, tparam, tgoto): |
| 5462 | Use const pointers where appropriate. |
| 5463 | |
| 5464 | * cm.c (calccost, cmgoto): Use const pointers where appropriate. |
| 5465 | * cm.h (struct cm): Likewise. |
| 5466 | * dispextern.h (do_line_insertion_deletion_costs): Likewise. |
| 5467 | * scroll.c (ins_del_costs, do_line_insertion_deletion_costs): Likewise. |
| 5468 | * term.c (tty_ins_del_lines, calculate_costs, struct fkey_table): |
| 5469 | (term_get_fkeys_1, append_glyphless_glyph, produce_glyphless_glyph): |
| 5470 | (turn_on_face, init_tty): Likewise. |
| 5471 | * termchar.h (struct tty_display_info): Likewise. |
| 5472 | |
| 5473 | * term.c (term_mouse_position): Rename local to avoid shadowing. |
| 5474 | |
| 5475 | * alloc.c (mark_ttys): Move decl from here ... |
| 5476 | * lisp.h (mark_ttys): ... to here, so that it's checked against defn. |
| 5477 | |
| 5478 | 2011-03-11 Andreas Schwab <schwab@linux-m68k.org> |
| 5479 | |
| 5480 | * .gdbinit (pwinx, xbuffer): Fix access to buffer name. |
| 5481 | |
| 5482 | 2011-03-09 Juanma Barranquero <lekktu@gmail.com> |
| 5483 | |
| 5484 | * search.c (compile_pattern_1): Remove argument regp, unused since |
| 5485 | revid:rms@gnu.org-19941211082627-3x1g1wyqkjmwloig. |
| 5486 | (compile_pattern): Don't pass it. |
| 5487 | |
| 5488 | 2011-03-08 Jan Djärv <jan.h.d@swipnet.se> |
| 5489 | |
| 5490 | * xterm.h (DEFAULT_GDK_DISPLAY): New define. |
| 5491 | (GDK_WINDOW_XID, gtk_widget_get_preferred_size): New defines |
| 5492 | for ! HAVE_GTK3. |
| 5493 | (GTK_WIDGET_TO_X_WIN): Use GDK_WINDOW_XID. |
| 5494 | |
| 5495 | * xmenu.c (menu_position_func): Call gtk_widget_get_preferred_size. |
| 5496 | |
| 5497 | * gtkutil.c: Include gtkx.h if HAVE_GTK3. If ! HAVE_GTK3, define |
| 5498 | gdk_window_get_screen, gdk_window_get_geometry, |
| 5499 | gdk_x11_window_lookup_for_display and GDK_KEY_g. |
| 5500 | (xg_set_screen): Use DEFAULT_GDK_DISPLAY. |
| 5501 | (xg_get_pixbuf_from_pixmap): New function. |
| 5502 | (xg_get_pixbuf_from_pix_and_mask): Change parameters from GdkPixmap |
| 5503 | to Pixmap, take frame as parameter, remove GdkColormap parameter. |
| 5504 | Call xg_get_pixbuf_from_pixmap instead of |
| 5505 | gdk_pixbuf_get_from_drawable. |
| 5506 | (xg_get_image_for_pixmap): Do not make GdkPixmaps, call |
| 5507 | xg_get_pixbuf_from_pix_and_mask with Pixmap parameters instead. |
| 5508 | (xg_check_special_colors): Use GtkStyleContext and its functions |
| 5509 | for HAVE_GTK3. |
| 5510 | (xg_prepare_tooltip, xg_hide_tooltip): Call gdk_window_get_screen. |
| 5511 | (xg_prepare_tooltip, create_dialog, menubar_map_cb) |
| 5512 | (xg_update_frame_menubar, xg_tool_bar_detach_callback) |
| 5513 | (xg_tool_bar_attach_callback, xg_update_tool_bar_sizes): |
| 5514 | Call gtk_widget_get_preferred_size. |
| 5515 | (xg_frame_resized): gdk_window_get_geometry only takes 5 |
| 5516 | parameters. |
| 5517 | (xg_win_to_widget, xg_event_is_for_menubar): |
| 5518 | Call gdk_x11_window_lookup_for_display. |
| 5519 | (xg_set_widget_bg): New function. |
| 5520 | (delete_cb): New function. |
| 5521 | (xg_create_frame_widgets): Connect delete-event to delete_cb. |
| 5522 | Call xg_set_widget_bg. Only set backgrund pixmap for ! HAVE_GTK3 |
| 5523 | (xg_set_background_color): Call xg_set_widget_bg. |
| 5524 | (xg_set_frame_icon): Call xg_get_pixbuf_from_pix_and_mask. |
| 5525 | (xg_create_scroll_bar): vadj is a GtkAdjustment for HAVE_GTK3. |
| 5526 | Only call gtk_range_set_update_policy if ! HAVE_GTK3. |
| 5527 | (xg_make_tool_item): Only connect xg_tool_bar_item_expose_callback |
| 5528 | if ! HAVE_GTK3. |
| 5529 | (update_frame_tool_bar): Call gtk_widget_hide. |
| 5530 | (xg_initialize): Use GDK_KEY_g. |
| 5531 | |
| 5532 | * xsmfns.c (gdk_set_sm_client_id): Define to gdk_set_sm_client_id |
| 5533 | if ! HAVE_GTK3 |
| 5534 | (x_session_initialize): Call gdk_x11_set_sm_client_id. |
| 5535 | |
| 5536 | * xterm.c (XFillRectangle): Use cairo routines for HAVE_GTK3. |
| 5537 | (x_term_init): Disable Xinput(2) with GDK_CORE_DEVICE_EVENTS. |
| 5538 | Load ~/emacs.d/gtkrc only for ! HAVE_GTK3. |
| 5539 | |
| 5540 | 2011-03-08 Juanma Barranquero <lekktu@gmail.com> |
| 5541 | |
| 5542 | * w32xfns.c (select_palette): Check success of RealizePalette against |
| 5543 | GDI_ERROR, not zero. |
| 5544 | |
| 5545 | See ChangeLog.11 for earlier changes. |
| 5546 | |
| 5547 | ;; Local Variables: |
| 5548 | ;; coding: utf-8 |
| 5549 | ;; End: |
| 5550 | |
| 5551 | Copyright (C) 2011 Free Software Foundation, Inc. |
| 5552 | |
| 5553 | This file is part of GNU Emacs. |
| 5554 | |
| 5555 | GNU Emacs is free software: you can redistribute it and/or modify |
| 5556 | it under the terms of the GNU General Public License as published by |
| 5557 | the Free Software Foundation, either version 3 of the License, or |
| 5558 | (at your option) any later version. |
| 5559 | |
| 5560 | GNU Emacs is distributed in the hope that it will be useful, |
| 5561 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 5562 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 5563 | GNU General Public License for more details. |
| 5564 | |
| 5565 | You should have received a copy of the GNU General Public License |
| 5566 | along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. |