Commit | Line | Data |
---|---|---|
4fb9a543 GM |
1 | 2012-03-27 Glenn Morris <rgm@gnu.org> |
2 | ||
3 | * search.c (Fword_search_backward_lax, Fword_search_forward_lax): | |
4 | Doc fixes. | |
5 | ||
679910f1 KH |
6 | 2012-03-26 Kenichi Handa <handa@m17n.org> |
7 | ||
8 | * dispextern.h (struct glyph): Fix previous change. Change the | |
9 | bit length of glyphless.ch to 25 (Bug#11082). | |
10 | ||
90d49b7f CY |
11 | 2012-03-26 Chong Yidong <cyd@gnu.org> |
12 | ||
13 | * keyboard.c (Vselection_inhibit_update_commands): New variable. | |
14 | (command_loop_1): Use it; inhibit selection update for | |
15 | handle-select-window too (Bug#8996). | |
16 | ||
f514f6f0 FP |
17 | 2012-03-25 Fabrice Popineau <fabrice.popineau@supelec.fr> |
18 | ||
19 | * w32heap.c (_heap_init, _heap_term): Remove dead MSVC-specific | |
20 | code. | |
21 | ||
bf43fa51 KH |
22 | 2012-03-25 Kenichi Handa <handa@m17n.org> |
23 | ||
24 | * dispextern.h (struct glyph): Change the bit length of | |
25 | glyphless.ch to 22 to make the member glyphless fit in 32 bits. | |
26 | ||
8a0c01dd EZ |
27 | 2012-03-24 Eli Zaretskii <eliz@gnu.org> |
28 | ||
29 | * s/ms-w32.h (tzname): Include time.h before redirecting to | |
30 | _tzname. Fixes the MSVC build. (Bug#9960) | |
31 | ||
7d1c3a76 AS |
32 | 2012-03-24 Andreas Schwab <schwab@linux-m68k.org> |
33 | ||
8ed79523 AS |
34 | * xdisp.c (produce_glyphless_glyph): Limit length of acronym to 6 |
35 | characters. | |
36 | ||
7d1c3a76 AS |
37 | * xterm.c (XTread_socket): Only modify handling_signal if |
38 | !SYNC_INPUT. (Bug#11080) | |
39 | ||
e99a9b8b EZ |
40 | 2012-03-23 Eli Zaretskii <eliz@gnu.org> |
41 | ||
42 | * bidi.c (bidi_fetch_char): Use STRING_CHAR_AND_LENGTH instead of | |
43 | FETCH_MULTIBYTE_CHAR followed by CHAR_BYTES. Prevents crashes | |
44 | when fetching a multibyte character consumes more bytes than | |
45 | CHAR_BYTES returns, due to unification of CJK characters in | |
46 | string_char. (Bug#11073) | |
47 | ||
5063c0e1 TN |
48 | 2012-03-23 Troels Nielsen <bn.troels@gmail.com> (tiny change) |
49 | ||
50 | * process.c (wait_reading_process_output): Handle pty disconnect | |
51 | by refraining from sending oneself a SIGCHLD (bug#10933). | |
52 | ||
9f851fbd CY |
53 | 2012-03-22 Chong Yidong <cyd@gnu.org> |
54 | ||
55 | * dispextern.h (struct it): New member string_from_prefix_prop_p. | |
56 | ||
5063c0e1 | 57 | * xdisp.c (push_prefix_prop): Rename from push_display_prop. |
9f851fbd CY |
58 | Mark string as coming from a prefix property. |
59 | (handle_face_prop): Use default face for prefix strings (Bug#4281). | |
60 | (pop_it, reseat_1): Save and restore string_from_prefix_prop_p. | |
61 | ||
fb5b8aca CY |
62 | 2012-03-21 Chong Yidong <cyd@gnu.org> |
63 | ||
64 | * xfaces.c (Vface_remapping_alist): Doc fix. | |
65 | ||
62356a1b EZ |
66 | 2012-03-20 Eli Zaretskii <eliz@gnu.org> |
67 | ||
68 | * w32proc.c (Fw32_set_console_codepage) | |
5063c0e1 TN |
69 | (Fw32_set_console_output_codepage, Fw32_get_codepage_charset): |
70 | Doc fixes. | |
62356a1b | 71 | |
025de85b CY |
72 | 2012-03-20 Chong Yidong <cyd@gnu.org> |
73 | ||
74 | * dispnew.c (Fredisplay, Vredisplay_preemption_period): Update doc | |
75 | to reflect default non-nil value of redisplay-dont-pause. | |
76 | ||
4827f94e KH |
77 | 2012-03-19 Kenichi Handa <handa@m17n.org> |
78 | ||
79 | * ftfont.c (ftfont_drive_otf): Mask bits of character code to make | |
80 | it fit in a valid range (Bug#11003). | |
81 | ||
e50a24a2 EZ |
82 | 2012-03-18 Eli Zaretskii <eliz@gnu.org> |
83 | ||
84 | * xdisp.c (cursor_row_p): Even if the glyph row ends in a string | |
85 | that is not from display property, accept the row as a "cursor | |
86 | row" if one of the string's character has a non-nil `cursor' | |
87 | property. Fixes cursor positioning when there are newlines in | |
88 | overlay strings, e.g. in icomplete.el. (Bug#11035) | |
89 | ||
9af5ed87 PE |
90 | 2012-03-12 Paul Eggert <eggert@cs.ucla.edu> |
91 | ||
92 | * buffer.c (compare_overlays): Don't assume args differ (Bug#6830). | |
93 | ||
d1f55f16 CY |
94 | 2012-03-12 Chong Yidong <cyd@gnu.org> |
95 | ||
96 | * eval.c (inhibit_lisp_code): Rename from | |
97 | inhibit_window_configuration_change_hook; move from window.c. | |
98 | ||
99 | * xfns.c (unwind_create_frame_1, Fx_create_frame): | |
100 | * window.c (run_window_configuration_change_hook) | |
101 | (syms_of_window): Callers changed. | |
102 | ||
66c5eebd CY |
103 | 2012-03-11 Chong Yidong <cyd@gnu.org> |
104 | ||
413df973 CY |
105 | * keymap.c (Fkey_description): Doc fix (Bug#9700). |
106 | ||
66c5eebd CY |
107 | * editfns.c (Fconstrain_to_field): Doc fix (Bug#9452). |
108 | ||
1de11f56 CY |
109 | 2012-03-10 Chong Yidong <cyd@gnu.org> |
110 | ||
111 | * frame.c (other_visible_frames): Don't assume the selected frame | |
112 | is visible (Bug#10955). | |
113 | ||
cae07000 SM |
114 | 2012-03-09 Stefan Monnier <monnier@iro.umontreal.ca> |
115 | ||
116 | * buffer.c (compare_overlays): Avoid qsort's instability (bug#6830). | |
117 | ||
89c94350 JD |
118 | 2012-03-08 Jan Djärv <jan.h.d@swipnet.se> |
119 | ||
120 | * gtkutil.c (x_wm_set_size_hint): Use one row in call to | |
121 | FRAME_TEXT_LINES_TO_PIXEL_HEIGHT so base_height is greater than | |
122 | zero (Bug#10954). | |
123 | ||
999dd333 GM |
124 | 2012-03-03 Glenn Morris <rgm@gnu.org> |
125 | ||
01a6dcc8 | 126 | * alloc.c (Fgarbage_collect, misc-objects-consed): Doc fixes. |
999dd333 | 127 | |
de0100f2 EZ |
128 | 2012-03-02 Eli Zaretskii <eliz@gnu.org> |
129 | ||
130 | * xdisp.c (try_window_reusing_current_matrix): Don't move cursor | |
131 | position past the first glyph_row that ends at ZV. (Bug#10902) | |
b8456c5c EZ |
132 | (redisplay_window, next_element_from_string): Fix typos in |
133 | comments. | |
3e441275 EZ |
134 | (redisplay_window): Pass to move_it_vertically the margin in |
135 | pixels, not in screen lines. | |
de0100f2 | 136 | |
96a72ee9 GM |
137 | 2012-03-02 Glenn Morris <rgm@gnu.org> |
138 | ||
139 | * buffer.c (buffer-list-update-hook): Doc fix. | |
140 | ||
312508d7 EZ |
141 | 2012-02-29 Eli Zaretskii <eliz@gnu.org> |
142 | ||
143 | * xdisp.c (get_overlay_strings_1): Under bidi redisplay, call | |
144 | push_it before setting up the iterator for the first overlay | |
145 | string, even if we have an empty string loaded. | |
146 | (next_overlay_string): If there's an empty string on the iterator | |
147 | stack, pop the stack. (Bug#10903) | |
148 | ||
27f3c637 PE |
149 | 2012-02-25 Paul Eggert <eggert@cs.ucla.edu> |
150 | ||
151 | Generalize fix for crash due to non-contiguous EMACS_INT (Bug#10780). | |
152 | Suggested by Stefan Monnier in | |
153 | <http://lists.gnu.org/archive/html/emacs-devel/2012-02/msg00692.html>. | |
154 | * alloc.c (widen_to_Lisp_Object): New static function. | |
155 | (mark_memory): Also mark Lisp_Objects by fetching pointer words | |
156 | and widening them to Lisp_Objects. This would work even if | |
157 | USE_LSB_TAG is defined and wide integers are used, which might | |
158 | happen in a future version of Emacs. | |
159 | ||
3c9dfce6 CY |
160 | 2012-02-25 Chong Yidong <cyd@gnu.org> |
161 | ||
fa74b241 CY |
162 | * fileio.c (Ffile_selinux_context, Fset_file_selinux_context): |
163 | Doc fix. | |
164 | ||
3c9dfce6 CY |
165 | * xselect.c (Fx_selection_exists_p): Doc fix. |
166 | (x_clipboard_manager_save_all): Print an informative message | |
167 | before saving to clipboard manager. | |
168 | ||
9486df08 CY |
169 | 2012-02-24 Chong Yidong <cyd@gnu.org> |
170 | ||
171 | * keyboard.c (process_special_events): Handle all X selection | |
172 | requests in kbd_buffer, not just the next one (Bug#8869). | |
173 | ||
f01d3321 CY |
174 | 2012-02-23 Chong Yidong <cyd@gnu.org> |
175 | ||
176 | * xfns.c (Fx_create_frame): Avoid window-configuration-change-hook | |
177 | call when setting menu-bar-lines and tool-bar-lines parameters. | |
178 | (unwind_create_frame_1): New helper function. | |
179 | ||
180 | * window.c (inhibit_window_configuration_change_hook): New var. | |
181 | (run_window_configuration_change_hook): Obey it. | |
b2e4ca7d | 182 | (syms_of_window): Initialize it. |
f01d3321 | 183 | |
86b847b6 CY |
184 | 2012-02-22 Chong Yidong <cyd@gnu.org> |
185 | ||
186 | * xterm.c (x_draw_image_relief): Add missing type check for | |
187 | Vtool_bar_button_margin (Bug#10743). | |
188 | ||
a59225b1 CY |
189 | 2012-02-21 Chong Yidong <cyd@gnu.org> |
190 | ||
191 | * fileio.c (Vfile_name_handler_alist): Doc fix. | |
192 | ||
193 | * buffer.c (Fget_file_buffer): Protect against invalid file | |
194 | handler return value. | |
195 | ||
310f5bd4 PE |
196 | 2012-02-20 Paul Eggert <eggert@cs.ucla.edu> |
197 | ||
cb3a28cc PE |
198 | * .gdbinit (xreload): Don't assume EMACS_INT fits in 'long' |
199 | when computing $valmask. | |
200 | ||
310f5bd4 PE |
201 | Fix crash due to non-contiguous EMACS_INT (Bug#10780). |
202 | * lisp.h (VALBITS): Move definition up, so that USE_LSB_TAG can use it. | |
203 | (USE_LSB_TAG): Do not define if UINTPTR_MAX >> VALBITS == 0. | |
204 | It's useless in that case, and it can cause problems on hosts | |
205 | that allocate halves of EMACS_INT values separately. | |
206 | Reported by Dan Horák. Diagnosed by Andreas Schwab in | |
207 | <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=10780#30>. | |
208 | * mem-limits.h (EXCEEDS_LISP_PTR): Define to 0 on hosts where | |
209 | UINTPTR_MAX >> VALBITS == 0. This is required by the above change; | |
210 | it avoids undefined behavior on hosts where shifting right by more | |
211 | than the word width has undefined behavior. | |
212 | ||
2375c96a CY |
213 | 2012-02-19 Chong Yidong <cyd@gnu.org> |
214 | ||
215 | * fileio.c (Ffile_name_directory, Ffile_name_nondirectory) | |
216 | (Funhandled_file_name_directory, Ffile_name_as_directory) | |
217 | (Fdirectory_file_name, Fexpand_file_name) | |
218 | (Fsubstitute_in_file_name): Protect against invalid file handler | |
219 | return values (Bug#10845). | |
220 | ||
3eb49e71 EZ |
221 | 2012-02-18 Eli Zaretskii <eliz@gnu.org> |
222 | ||
223 | * .gdbinit (pitx): Fix incorrect references to fields of the | |
224 | iterator stack. | |
225 | ||
7b926f3f CY |
226 | 2012-02-17 Chong Yidong <cyd@gnu.org> |
227 | ||
228 | * syntax.c (Fscan_lists): Doc fix (Bug#10833). | |
229 | ||
11273115 PE |
230 | 2012-02-15 Paul Eggert <eggert@cs.ucla.edu> |
231 | ||
232 | * image.c (MAX_IMAGE_SIZE): Increase from 6.0 to 10.0; see | |
233 | <http://lists.gnu.org/archive/html/emacs-devel/2012-02/msg00540.html>. | |
234 | ||
c3a70e2b CY |
235 | 2012-02-15 Chong Yidong <cyd@gnu.org> |
236 | ||
237 | * eval.c (Fdefvar, Fdefconst): Doc fix; note that the variable is | |
238 | marked as special. Also, starting docstrings with * is obsolete. | |
239 | ||
0ca43699 AS |
240 | 2012-02-13 Andreas Schwab <schwab@linux-m68k.org> |
241 | ||
242 | * gnutls.c (emacs_gnutls_write): Fix last change. | |
243 | ||
2e8f3c56 LI |
244 | 2012-02-13 Lars Ingebrigtsen <larsi@gnus.org> |
245 | ||
246 | * gnutls.c (emacs_gnutls_write): Set errno appropriately for | |
247 | send_process. | |
248 | ||
af70074f SM |
249 | 2012-02-13 Stefan Monnier <monnier@iro.umontreal.ca> |
250 | ||
251 | * keymap.c (Fsingle_key_description): Handle char ranges. | |
252 | ||
95986d52 CY |
253 | 2012-02-12 Chong Yidong <cyd@gnu.org> |
254 | ||
afd83bd1 CY |
255 | * xdisp.c (handle_stop): Avoid assigning -1 to it->face_id here, |
256 | as that creates a dangerous corner case. | |
257 | ||
95986d52 CY |
258 | * window.c (Fdelete_window_internal): Invalidate the mouse |
259 | highlight (Bug#9904). | |
260 | ||
bd7da63e GM |
261 | 2012-02-12 Glenn Morris <rgm@gnu.org> |
262 | ||
263 | * xselect.c (Fx_own_selection_internal) | |
264 | (Fx_get_selection_internal, Fx_disown_selection_internal) | |
265 | (Fx_selection_owner_p, Fx_selection_exists_p): Doc fixes. | |
266 | * nsselect.m (Fx_own_selection_internal) | |
267 | (Fx_disown_selection_internal, Fx_selection_exists_p) | |
268 | (Fx_selection_owner_p, Fx_get_selection_internal): | |
269 | Sync docs and argument specs with the xselect.c versions. | |
270 | ||
77abcbc2 LI |
271 | 2012-02-11 Lars Ingebrigtsen <larsi@gnus.org> |
272 | ||
273 | * gnutls.c (emacs_gnutls_write): Don't infloop if sendto fails. | |
274 | ||
90b671e2 EZ |
275 | 2012-02-11 Eli Zaretskii <eliz@gnu.org> |
276 | ||
1c0ca0b7 EZ |
277 | * w32select.c (Fx_selection_exists_p): Sync doc string and |
278 | argument list with xselect.c. (Bug#10783) | |
279 | ||
280 | * w16select.c (Fx_selection_exists_p): Sync doc string and | |
281 | argument list with xselect.c. (Bug#10783) | |
90b671e2 | 282 | |
49241268 GM |
283 | 2012-02-10 Glenn Morris <rgm@gnu.org> |
284 | ||
285 | * fns.c (Fsecure_hash): Doc fix. | |
286 | ||
f998bbe7 | 287 | 2012-02-09 Kenichi Handa <handa@m17n.org> |
5c1ca13d KH |
288 | |
289 | * coding.c (produce_chars): Fix updating of src_end (Bug#10701). | |
290 | ||
0992bd9c CY |
291 | 2012-02-07 Chong Yidong <cyd@gnu.org> |
292 | ||
293 | * buffer.c (Fbuffer_local_variables) | |
294 | (buffer_lisp_local_variables): Handle unbound vars correctly; | |
295 | don't let Qunbound leak into Lisp. | |
296 | ||
af008560 GM |
297 | 2012-02-07 Glenn Morris <rgm@gnu.org> |
298 | ||
dd605cc4 GM |
299 | * image.c (Fimagemagick_types): Doc fix. |
300 | ||
af008560 GM |
301 | * image.c (imagemagick-render-type): Change it from a lisp object |
302 | to an integer. Move the doc here from the lisp manual. | |
303 | Treat all values not equal to 0 the same. | |
304 | ||
1449fa1d CY |
305 | 2012-02-06 Chong Yidong <cyd@gnu.org> |
306 | ||
307 | * doc.c (store_function_docstring): Avoid applying docstring of | |
308 | alias to base function (Bug#2603). | |
309 | ||
3723ec07 AS |
310 | 2012-02-04 Andreas Schwab <schwab@linux-m68k.org> |
311 | ||
312 | * .gdbinit (pp1, pv1): Remove redundant defines. | |
313 | (pr): Use pp. | |
314 | ||
79c1cc1e CY |
315 | 2012-02-04 Chong Yidong <cyd@gnu.org> |
316 | ||
317 | * nsterm.m: Declare a global (Bug#10694). | |
318 | ||
d7f29f8e EZ |
319 | 2012-02-04 Eli Zaretskii <eliz@gnu.org> |
320 | ||
cae07000 SM |
321 | * w32.c (get_emacs_configuration_options): |
322 | Include --enable-checking, if specified, in the return value. | |
d7f29f8e | 323 | |
3b95a6f9 MR |
324 | 2012-02-04 Martin Rudalics <rudalics@gmx.at> |
325 | ||
326 | * dispnew.c (change_frame_size_1): Calculate new_frame_total_cols | |
327 | after rounding frame sizes. (Bug#9723) | |
328 | ||
d6fa96a6 EZ |
329 | 2012-02-04 Eli Zaretskii <eliz@gnu.org> |
330 | ||
331 | * keyboard.c (adjust_point_for_property): Don't position point | |
332 | before BEGV. (Bug#10696) | |
333 | ||
df0b2940 PE |
334 | 2012-02-03 Paul Eggert <eggert@cs.ucla.edu> |
335 | ||
336 | Handle overflow when computing char display width (Bug#9496). | |
337 | * character.c (char_width): Return EMACS_INT, not int. | |
338 | (char_width, c_string_width): Check for overflow when | |
339 | computing the width; this is possible now that individual | |
340 | characters can have unbounded width. Problem introduced | |
341 | by merge from Emacs 23 on 2012-01-19. | |
342 | ||
6bee44d6 MA |
343 | 2012-02-02 Michael Albinus <michael.albinus@gmx.de> |
344 | ||
345 | * dbusbind.c (Fdbus_register_method): Mention the return value | |
346 | :ignore in the docstring. | |
347 | ||
44f92739 GM |
348 | 2012-02-02 Glenn Morris <rgm@gnu.org> |
349 | ||
1b9f60cc GM |
350 | * callproc.c (Fcall_process, Fcall_process_region): Doc fix. |
351 | ||
44f92739 GM |
352 | * nsterm.m (syms_of_nsterm) <x-toolkit-scroll-bars>: |
353 | Unconditionally set to t. (Bug#10673) | |
354 | * nsterm.m (syms_of_nsterm) <x-toolkit-scroll-bars>: | |
355 | * w32term.c (syms_of_w32term) <x-toolkit-scroll-bars>: | |
356 | * xterm.c (syms_of_xterm) <x-toolkit-scroll-bars>: Doc fix. | |
357 | ||
c5d3843c KH |
358 | 2012-02-02 Kenichi Handa <handa@m17n.org> |
359 | ||
360 | (x_produce_glyphs): Cancel previous change. If cmp->glyph_len is | |
361 | 0, do not call append_composite_glyph. | |
362 | ||
159462d4 | 363 | 2012-02-02 Kenichi Handa <handa@m17n.org> |
d2a51fd7 KH |
364 | |
365 | * xdisp.c (BUILD_COMPOSITE_GLYPH_STRING): Initialize first_s to | |
366 | NULL (Bug#6988). | |
367 | (x_produce_glyphs): If the component of a composition is a null | |
368 | string, set it->pixel_width to 1 to avoid zero-width glyph. | |
369 | ||
78cef877 EZ |
370 | 2012-02-01 Eli Zaretskii <eliz@gnu.org> |
371 | ||
372 | * ralloc.c (resize_bloc, r_alloc_sbrk): Don't call memmove if its | |
373 | first 2 arguments are identical. This makes inserting large | |
374 | output from a subprocess an order of magnitude faster on | |
375 | MS-Windows, where all sbrk'ed memory is always contiguous. | |
376 | ||
97897668 GM |
377 | 2012-01-31 Glenn Morris <rgm@gnu.org> |
378 | ||
379 | * nsterm.m (syms_of_nsterm) <x-toolkit-scroll-bars>: | |
c78c6e0b | 380 | * w32term.c (syms_of_w32term) <x-toolkit-scroll-bars>: |
97897668 GM |
381 | * xterm.c (syms_of_xterm) <x-toolkit-scroll-bars>: Sync docs. |
382 | ||
31fd3586 GM |
383 | 2012-01-29 Glenn Morris <rgm@gnu.org> |
384 | ||
385 | * gnutls.c (syms_of_gnutls): More doc (from etc/NEWS). | |
386 | ||
0e24a8b2 CY |
387 | 2012-01-28 Samuel Thibault <sthibault@debian.org> (tiny change) |
388 | ||
389 | * s/gnu.h: Define POSIX_SIGNALS (Bug#10552). | |
390 | ||
cc0adcb0 CY |
391 | 2012-01-28 Chong Yidong <cyd@gnu.org> |
392 | ||
393 | * minibuf.c (syms_of_minibuf): Doc fix (Bug#10550). | |
394 | ||
acc28cb9 CY |
395 | 2012-01-26 Chong Yidong <cyd@gnu.org> |
396 | ||
9c69cfb7 CY |
397 | * keyboard.c (Vecho_keystrokes): Document zero value (Bug#10503). |
398 | ||
acc28cb9 CY |
399 | * search.c (Fsearch_forward, Fsearch_backward): Document negative |
400 | repeat counts (Bug#10507). | |
401 | ||
48da7392 GM |
402 | 2012-01-26 Glenn Morris <rgm@gnu.org> |
403 | ||
404 | * lread.c (syms_of_lread): Doc fix. | |
405 | ||
14af5f7f CY |
406 | 2012-01-25 HIROSHI OOTA <nil@mad.dog.cx> (tiny change) |
407 | ||
408 | * coding.c (encode_designation_at_bol): Change return value to | |
409 | EMACS_INT. | |
410 | ||
0b21c100 CY |
411 | 2012-01-25 Chong Yidong <cyd@gnu.org> |
412 | ||
413 | * eval.c (Fuser_variable_p): Doc fix; mention custom-variable-p. | |
414 | ||
3c2907f7 CY |
415 | 2012-01-21 Chong Yidong <cyd@gnu.org> |
416 | ||
417 | * floatfns.c (Fcopysign): Make the second argument non-optional, | |
418 | since nil is not allowed anyway. | |
419 | ||
959ad23f AS |
420 | 2012-01-21 Andreas Schwab <schwab@linux-m68k.org> |
421 | ||
422 | * process.c (read_process_output): Use p instead of XPROCESS (proc). | |
423 | (send_process): Likewise. | |
424 | ||
34a02f46 MR |
425 | 2012-01-19 Martin Rudalics <rudalics@gmx.at> |
426 | ||
427 | * window.c (save_window_save, Fcurrent_window_configuration) | |
cae07000 SM |
428 | (Vwindow_persistent_parameters): Do not use Qstate. |
429 | Rewrite doc-strings. | |
34a02f46 | 430 | |
1259009a | 431 | 2012-01-19 Kenichi Handa <handa@m17n.org> |
25ed9e61 KH |
432 | |
433 | * character.c (char_width): New function. | |
70d4fdf6 GM |
434 | (Fchar_width, c_string_width, lisp_string_width): |
435 | Use char_width (Bug#9496). | |
25ed9e61 | 436 | |
6a6ee00d MR |
437 | 2012-01-16 Martin Rudalics <rudalics@gmx.at> |
438 | ||
439 | * window.c (Vwindow_persistent_parameters): New variable. | |
440 | (Fset_window_configuration, save_window_save): Handle persistent | |
441 | window parameters. | |
442 | ||
c85efaf7 EZ |
443 | 2012-01-14 Eli Zaretskii <eliz@gnu.org> |
444 | ||
445 | * w32fns.c (signal_user_input): Don't do a QUIT, to avoid | |
446 | thrashing the stack of the thread. (Bug#9087) | |
447 | ||
5944709e PE |
448 | 2012-01-12 Paul Eggert <eggert@cs.ucla.edu> |
449 | ||
450 | * xdisp.c (rows_from_pos_range): Add parens as per gcc -Wparentheses. | |
451 | ||
e71f5d99 EZ |
452 | 2012-01-11 Eli Zaretskii <eliz@gnu.org> |
453 | ||
454 | * xdisp.c (rows_from_pos_range): Handle the case where the | |
455 | highlight ends on a newline. (Bug#10464) | |
456 | (mouse_face_from_buffer_pos): Fix off-by-one error in calculating | |
457 | he end column for display of highlight that ends on a newline | |
458 | before a R2L line. | |
459 | ||
ce316182 GM |
460 | 2012-01-11 Glenn Morris <rgm@gnu.org> |
461 | ||
462 | * lread.c (init_lread): If no-site-lisp, remove site-lisp dirs | |
463 | from load-path also when installation-directory is nil. (Bug#10208) | |
464 | ||
5b43da69 GM |
465 | 2012-01-10 Glenn Morris <rgm@gnu.org> |
466 | ||
74cc8ff9 GM |
467 | * emacs.c (syms_of_emacs) <installation-directory>: Doc fix. |
468 | ||
7d8d6e4e GM |
469 | * epaths.in (PATH_LOADSEARCH, PATH_EXEC, PATH_DATA, PATH_DOC): |
470 | Update template values to be closer to their typical values these days. | |
5b43da69 | 471 | |
a0db8d43 EZ |
472 | 2012-01-09 Eli Zaretskii <eliz@gnu.org> |
473 | ||
474 | * xdisp.c (rows_from_pos_range): Accept additional argument | |
475 | DISP_STRING, and accept any glyph in a row whose object is that | |
476 | string as eligible for mouse highlight. Fixes mouse highlight of | |
477 | display strings from overlays. (Bug#10464) | |
478 | ||
9a0115ab | 479 | 2012-01-07 Paul Eggert <eggert@cs.ucla.edu> |
09450bae | 480 | |
b9110d6a | 481 | emacs: fix an auto-save permissions race condition (Bug#10400) |
09450bae PE |
482 | * fileio.c (auto_saving_dir_umask): New static var. |
483 | (Fmake_directory_internal): Use it. | |
484 | (do_auto_save_make_dir): Set it, instead of invoking chmod after | |
485 | creating the directory. The old code temporarily assigns | |
486 | too-generous permissions to the directory. | |
487 | (do_auto_save_eh): Clear it. | |
b9110d6a | 488 | (Fdo_auto_save): Catch all errors, not just file errors, so |
09450bae PE |
489 | that the var is always cleared. |
490 | ||
6c1bd3f3 EZ |
491 | 2012-01-07 Eli Zaretskii <eliz@gnu.org> |
492 | ||
493 | * search.c (scan_buffer): Pass character positions to | |
494 | know_region_cache, not byte positions. (Bug#6540) | |
495 | ||
069d2b50 L |
496 | 2012-01-07 LynX <_LynX@bk.ru> (tiny change) |
497 | ||
498 | * w32.c (sys_rename): Report EXDEV when rename of a directory | |
499 | fails because the target is on another logical disk. (Bug#10284) | |
500 | ||
75bf0d33 DB |
501 | 2012-01-07 David Benjamin <davidben@mit.edu> (tiny change) |
502 | ||
503 | * xterm.c (x_embed_request_focus): New function. | |
504 | ||
505 | * xterm.h: Add prototype. | |
506 | ||
507 | * xfns.c (Fx_focus_frame): Use it for embedded frames (Bug#9977). | |
508 | ||
1c6e5a32 GM |
509 | 2012-01-05 Glenn Morris <rgm@gnu.org> |
510 | ||
511 | * emacs.c (emacs_copyright): Update short copyright year to 2012. | |
512 | ||
651e947e EZ |
513 | 2012-01-01 Eli Zaretskii <eliz@gnu.org> |
514 | ||
515 | * gnutls.c (init_gnutls_functions): Load gnutls_check_version. | |
516 | Load gnutls_transport_set_lowat only if GnuTLS version is below | |
517 | 2.11.1. | |
518 | (emacs_gnutls_handshake): Call gnutls_transport_set_lowat only for | |
519 | GnuTLS versions below 2.11.1. | |
520 | ||
3778cdd8 AL |
521 | 2011-12-31 Antoine Levitt <antoine.levitt@gmail.com> |
522 | ||
523 | * xdisp.c (syms_of_xdisp) <window-scroll-functions>: Add warning | |
524 | to the doc string advising against its use for altering the way | |
525 | windows are scrolled. | |
526 | ||
0e5317f7 KH |
527 | 2011-12-28 Kenichi Handa <handa@m17n.org> |
528 | ||
529 | * coding.c (Fdefine_coding_system_internal): Make an utf-8 base | |
530 | coding-system ASCII compatible only when it does not produce BOM | |
531 | on encoding (Bug#10383). | |
532 | ||
93d5ca1f JD |
533 | 2011-12-26 Jan Djärv <jan.h.d@swipnet.se> |
534 | ||
535 | * xmenu.c (x_menu_wait_for_event): Use xg_select for Gtk3 so menus | |
536 | can scroll. | |
537 | (create_and_show_popup_menu): Always use menu_position_func for | |
538 | Gtk3 (Bug#10361). | |
539 | ||
ca22b785 AS |
540 | 2011-12-24 Andreas Schwab <schwab@linux-m68k.org> |
541 | ||
542 | * callint.c (Fcall_interactively): Don't truncate prompt string. | |
543 | ||
d048e1e6 EZ |
544 | 2011-12-23 Eli Zaretskii <eliz@gnu.org> |
545 | ||
546 | * xdisp.c (handle_invisible_prop): Handle correctly an invisible | |
547 | property that ends at ZV, so that the bidi iteration could be | |
3ba1a2ad | 548 | resumed from there (after widening). (Bug#10360) |
d048e1e6 | 549 | |
5ccaba1f JD |
550 | 2011-12-22 Jan Djärv <jan.h.d@swipnet.se> |
551 | ||
552 | * nsfont.m (ns_spec_to_descriptor): Do not autorelease fdesc. | |
553 | ||
204ee57f JD |
554 | 2011-12-21 Jan Djärv <jan.h.d@swipnet.se> |
555 | ||
b81d40f0 JB |
556 | * nsterm.m (x_free_frame_resources): |
557 | Release f->output_data.ns->miniimage. | |
204ee57f JD |
558 | (ns_index_color): Fix indentation. Do not retain |
559 | color_table->colors[i]. | |
560 | ||
561 | * nsmenu.m (ns_update_menubar): Call free_menubar_widget_value_tree | |
562 | before returning. | |
563 | ||
564 | * nsfns.m (x_set_background_color): Assign return value from | |
565 | ns_index_color to face-background instead of NSColor*. | |
566 | (ns_implicitly_set_icon_type): Fix indentation. | |
567 | Change assignment in for loop to comparison. | |
568 | ||
569 | * emacs.c (ns_pool): New variable. | |
570 | (main): Assign ns_pool. | |
571 | (Fkill_emacs): Call ns_release_autorelease_pool. | |
572 | ||
573 | * nsfont.m (ns_spec_to_descriptor): Fix indentation, | |
574 | autorelease fdesc, release fdAttrs and tdict. | |
575 | (ns_get_covering_families): Release charset. | |
576 | (ns_findfonts): Release NSFontDescriptor created with new. | |
577 | (ns_uni_to_glyphs): Fix indentation. | |
578 | (setString): Release attrStr before assigning new value. | |
579 | ||
c803b2b7 JD |
580 | 2011-12-18 Jan Djärv <jan.h.d@swipnet.se> |
581 | ||
678f4426 JD |
582 | * nsmenu.m (NSMenuDidBeginTrackingNotification): Declare if OSX < 10.5 |
583 | and NS_IMPL_COCOA. | |
584 | (trackingNotification): Surround with ifdef NS_IMPL_COCOA. | |
585 | (syms_of_nsmenu): Set trackingMenu to 1 if not NS_IMPL_COCOA. | |
586 | ||
cd394be1 | 587 | 2011-12-18 David Reitter <reitter@cmu.edu> |
678f4426 | 588 | |
5fecd5fc JD |
589 | * nsterm.m (ns_term_init): Subscribe for notifications |
590 | NSMenuDidBeginTrackingNotification and NSMenuDidEndTrackingNotification | |
591 | to method trackingNotification in EmacsMenu. | |
592 | ||
593 | * nsmenu.m (trackingMenu): New variable. | |
3771cb17 | 594 | (trackingNotification): New method (from Aquamacs). |
5fecd5fc | 595 | (menuNeedsUpdate): Expand comment and return if trackingMenu is 0, |
3771cb17 | 596 | from Aquamacs (Bug#7030). |
678f4426 JD |
597 | |
598 | 2011-12-18 Jan Djärv <jan.h.d@swipnet.se> | |
5fecd5fc | 599 | |
c803b2b7 JD |
600 | * nsselect.m (CUT_BUFFER_SUPPORT): Remove define. |
601 | (symbol_to_nsstring): Fix indentation. | |
602 | (ns_symbol_to_pb): New function. | |
cae07000 SM |
603 | (Fns_get_selection_internal): Rename from Fns_get_cut_buffer_internal. |
604 | (Fns_rotate_cut_buffers_internal): Remove. | |
605 | (Fns_store_selection_internal): Rename from | |
c803b2b7 JD |
606 | Fns_store_cut_buffer_internal. |
607 | (ns_get_foreign_selection, Fx_own_selection_internal) | |
608 | (Fx_disown_selection_internal, Fx_selection_exists_p) | |
b81d40f0 JB |
609 | (Fns_get_selection_internal, Fns_store_selection_internal): |
610 | Use ns_symbol_to_pb and check if return value is nil. | |
611 | (syms_of_nsselect): Remove ifdef CUT_BUFFER_SUPPORT. Remove defsubr | |
612 | Sns_rotate_cut_buffers_internal. Sns_get_cut_buffer_internal | |
c803b2b7 JD |
613 | renamed to Sns_get_selection_internal, Sns_store_cut_buffer_internal |
614 | renamed to Sns_store_selection_internal. | |
615 | (ns_handle_selection_request): Move code to Fx_own_selection_internal | |
616 | and remove this function. | |
617 | (ns_handle_selection_clear): Remove, never used. | |
618 | (Fx_own_selection_internal): Move code from ns_handle_selection_request | |
619 | here. | |
620 | ||
e1b01a3a KB |
621 | 2011-12-17 Ken Brown <kbrown@cornell.edu> |
622 | ||
623 | * fileio.c (check_writable) [CYGWIN]: Return non-zero if UID or | |
624 | GID is unknown (Bug#10257). | |
625 | ||
2adb6e85 PE |
626 | 2011-12-17 Paul Eggert <eggert@cs.ucla.edu> |
627 | ||
628 | * s/gnu-linux.h: Fix mark_memory typo (Bug#10286). | |
629 | (GC_MARK_SECONDARY_STACK): Omit removed 3rd arg to mark_memory, | |
630 | which caused a build failure on GNU/Linux IA-64. This problem was | |
631 | introduced by my 2011-10-07 patch. | |
632 | ||
d1d7b339 JL |
633 | 2011-12-15 Juri Linkov <juri@jurta.org> |
634 | ||
635 | * image.c (imagemagick_error): New function. (Bug#10112) | |
636 | (imagemagick_load_image): Comment out `MagickSetResolution' call. | |
637 | Use `imagemagick_error' where ImageMagick functions return | |
638 | `MagickFalse'. | |
639 | (Fimagemagick_types): Add `Fnreverse' to return the list in the | |
640 | proper order. | |
641 | ||
100d5755 KH |
642 | 2011-12-15 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
643 | ||
644 | * xftfont.c (xftfont_draw): Use the font metrics of s->font to | |
645 | fill background (Bug#8992). | |
646 | ||
454592a6 MR |
647 | 2011-12-13 Martin Rudalics <rudalics@gmx.at> |
648 | ||
649 | * window.c (Vwindow_combination_resize) | |
650 | (Vwindow_combination_limit): Use t instead of non-nil in | |
651 | doc-strings. | |
61d4b438 MR |
652 | (Vrecenter_redisplay): Add first sentence of doc-string on |
653 | separate line. | |
53524d93 | 654 | (Frecenter): Fix doc-string typo. |
454592a6 | 655 | |
3633e3aa KH |
656 | 2011-12-11 Kenichi Handa <handa@m17n.org> |
657 | ||
658 | * coding.c (Funencodable_char_position): Pay attention to the | |
659 | buffer text relocation (Bug#9389). | |
660 | ||
7b9d523a JD |
661 | 2011-12-10 Jan Djärv <jan.h.d@swipnet.se> |
662 | ||
663 | * xterm.c (x_term_init): Move call to gdk_window_add_filter before | |
664 | gtk_init (Bug#10100). | |
665 | ||
b73189c6 EZ |
666 | 2011-12-10 Eli Zaretskii <eliz@gnu.org> |
667 | ||
668 | * xdisp.c (RECORD_MAX_MIN_POS): Use IT->cmp_it.charpos only if | |
669 | IT->string is nil. (Bug#10263) | |
670 | ||
f7dfe5d6 JD |
671 | 2011-12-10 Jan Djärv <jan.h.d@swipnet.se> |
672 | ||
83faebb4 JD |
673 | * nsterm.h (x_free_frame_resources): Declare. |
674 | ||
f7dfe5d6 JD |
675 | * nsfns.m (ns_get_defaults_value): New function (Bug#10103). |
676 | (Fns_get_resource, x_get_string_resource): Call ns_get_defaults_value. | |
677 | ||
678 | * nsterm.h (ns_get_defaults_value): Declare. | |
679 | ||
680 | * nsterm.m (ns_default): Call ns_get_defaults_value. | |
681 | ||
7cd4e72c EZ |
682 | 2011-12-09 Eli Zaretskii <eliz@gnu.org> |
683 | ||
684 | * xdisp.c (try_scrolling): Don't set scroll_down_p if dy is zero. | |
685 | (Bug#10170) | |
686 | ||
b34d7317 YM |
687 | 2011-12-09 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
688 | ||
689 | * unexelf.c (unexec) [NS_IMPL_GNUSTEP]: Take account of the case | |
690 | that where the value of an _OBJC_* symbol points to is in the .bss | |
691 | section (Bug#10240). | |
692 | ||
76470ad1 KH |
693 | 2011-12-08 Kazuhiro Ito <kzhr@d1.dion.ne.jp> (tiny change) |
694 | ||
695 | * coding.c (encode_coding_ccl): Check (charbuf < charbuf_end) | |
2fac8180 | 696 | after the loop to call ccl_driver at least once (Bug#8619). |
76470ad1 | 697 | |
745fff94 KH |
698 | 2011-12-08 Kenichi Handa <handa@m17n.org> |
699 | ||
700 | * ftfont.c (get_adstyle_property): Fix previous change | |
701 | (Bug#10233). | |
702 | ||
6e44397c JB |
703 | 2011-12-07 Juanma Barranquero <lekktu@gmail.com> |
704 | ||
705 | * w32.c (init_environment): If no_site_lisp, remove site-lisp | |
706 | dirs from the default value of EMACSLOADPATH (bug#10208). | |
707 | ||
7efa6272 GM |
708 | 2011-12-07 Glenn Morris <rgm@gnu.org> |
709 | ||
710 | * lread.c (init_lread): If no_site_lisp, exclude site-lisp/ in | |
711 | installation and source directories as well. (Bug#10208) | |
712 | ||
f6fc4d87 CY |
713 | 2011-12-06 Chong Yidong <cyd@gnu.org> |
714 | ||
715 | * minibuf.c (Fread_from_minibuffer): Doc fix (Bug#10228). | |
716 | ||
2bf26180 GM |
717 | 2011-12-06 Glenn Morris <rgm@gnu.org> |
718 | ||
719 | * process.c (start_process_unwind): Treat any pid <= 0, except -2, | |
720 | as an error, not just -1. (Bug#10217) | |
721 | ||
3a6ad4f0 CY |
722 | 2011-12-05 Chong Yidong <cyd@gnu.org> |
723 | ||
724 | * keyboard.c (process_special_events): New function. | |
725 | (swallow_events, Finput_pending_p): Use it (Bug#10195). | |
726 | ||
75a3b399 PE |
727 | 2011-12-05 Paul Eggert <eggert@cs.ucla.edu> |
728 | ||
729 | * coding.c (encode_designation_at_bol): Don't use uninitialized | |
730 | local variable (Bug#9318). | |
731 | ||
c3c9e25e KH |
732 | 2011-12-05 Kenichi Handa <handa@m17n.org> |
733 | ||
734 | * ftfont.c (get_adstyle_property): If the font is not BDF nor PCF, | |
735 | return Qnil (Bug#8046, Bug#10193). | |
736 | ||
5eb05ea3 KH |
737 | 2011-12-05 Kenichi Handa <handa@m17n.org> |
738 | ||
739 | * coding.c (encode_designation_at_bol): New args charbuf_end and | |
740 | dst. Return the number of produced bytes. Callers changed. | |
a79703f5 KH |
741 | (coding_set_source): Return how many bytes coding->source was |
742 | relocated. | |
743 | (coding_set_destination): Return how many bytes | |
744 | coding->destination was relocated. | |
745 | (CODING_DECODE_CHAR, CODING_ENCODE_CHAR, CODING_CHAR_CHARSET) | |
cae07000 | 746 | (CODING_CHAR_CHARSET_P): Adjust for the avove changes. |
5eb05ea3 KH |
747 | |
748 | 2011-12-05 Kazuhiro Ito <kzhr@d1.dion.ne.jp> (tiny change) | |
749 | ||
750 | * coding.c (CODING_CHAR_CHARSET_P): New macro. | |
751 | (encode_coding_emacs_mule, encode_coding_iso_2022): Use the above | |
752 | macro (Bug#9318). | |
753 | ||
754 | 2011-12-05 Andreas Schwab <schwab@linux-m68k.org> | |
755 | ||
756 | The following changes are to fix Bug#9318. | |
757 | ||
a79703f5 | 758 | * coding.c (CODING_ENCODE_CHAR, CODING_CHAR_CHARSET): New macros. |
5eb05ea3 KH |
759 | (encode_coding_emacs_mule, ENCODE_ISO_CHARACTER) |
760 | (encode_coding_iso_2022, encode_coding_sjis) | |
a79703f5 | 761 | (encode_coding_big5, encode_coding_charset): Use the above macros. |
5eb05ea3 | 762 | |
7dbda6df JB |
763 | 2011-12-05 Juanma Barranquero <lekktu@gmail.com> |
764 | ||
765 | * lisp.h (process_quit_flag): Fix external declaration. | |
766 | ||
6d5eb5b0 SM |
767 | 2011-12-04 Stefan Monnier <monnier@iro.umontreal.ca> |
768 | ||
769 | Don't macro-inline non-performance-critical code. | |
770 | * eval.c (process_quit_flag): New function. | |
771 | * lisp.h (QUIT): Use it. | |
772 | ||
a0c3fad0 JD |
773 | 2011-12-04 Jan Djärv <jan.h.d@swipnet.se> |
774 | ||
775 | * nsfns.m (get_geometry_from_preferences): New function. | |
776 | (Fx_create_frame): Call get_geometry_from_preferences (Bug#10103). | |
777 | ||
6c07aac2 AS |
778 | 2011-12-04 Andreas Schwab <schwab@linux-m68k.org> |
779 | ||
780 | * emacs.c (Qkill_emacs): Define. | |
781 | (syms_of_emacs): Initialize it. | |
782 | * keyboard.c (interrupt_signal): Don't call Fkill_emacs here, set | |
783 | Qquit_flag to `kill-emacs' instead. | |
6d5eb5b0 SM |
784 | (quit_throw_to_read_char): Add parameter `from_signal'. |
785 | All callers changed. Call Fkill_emacs if requested and safe. | |
6c07aac2 AS |
786 | * lisp.h (QUIT): Call Fkill_emacs if requested. |
787 | ||
c052ead4 JD |
788 | 2011-12-03 Jan Djärv <jan.h.d@swipnet.se> |
789 | ||
790 | * widget.c (update_wm_hints): Return if wmshell is null. | |
791 | (widget_update_wm_size_hints): New function. | |
792 | ||
793 | * widget.h (widget_update_wm_size_hints): Declare. | |
794 | ||
795 | * xterm.c (x_wm_set_size_hint): If USE_X_TOOLKIT, call | |
796 | widget_update_wm_size_hints (Bug#10104). | |
797 | ||
9e49252b EZ |
798 | 2011-12-03 Eli Zaretskii <eliz@gnu.org> |
799 | ||
800 | * xdisp.c (handle_invisible_prop): If the invisible text ends just | |
801 | before a newline, prepare the bidi iterator for consuming the | |
802 | newline, and keep the current paragraph direction. (Bug#10183) | |
e9a49426 | 803 | (redisplay_window): Don't let `margin' become negative. (Bug#10192) |
9e49252b | 804 | |
02b16839 JL |
805 | 2011-12-02 Juri Linkov <juri@jurta.org> |
806 | ||
807 | * search.c (Fword_search_regexp): New Lisp function created from | |
808 | `wordify'. Change type of arg `lax' from `int' to `Lisp_Object'. | |
809 | (Fword_search_backward, Fword_search_forward) | |
810 | (Fword_search_backward_lax, Fword_search_forward_lax): | |
811 | Use `Fword_search_regexp' instead of `wordify'. Doc fix. | |
812 | (syms_of_search): Define `Sword_search_regexp'. (Bug#10145) | |
813 | ||
0068070e SM |
814 | 2011-12-01 Stefan Monnier <monnier@iro.umontreal.ca> |
815 | ||
816 | * fileio.c (Finsert_file_contents): Move after-change-function call | |
817 | to before the "handled:" label, since all "goto handled" appear in | |
818 | cases where the *-change-functions have already been properly called | |
819 | (bug#10117). | |
820 | ||
3360a3fc AS |
821 | 2011-12-01 Andreas Schwab <schwab@linux-m68k.org> |
822 | ||
823 | * keyboard.c (interrupt_signal): Don't call kill-emacs when | |
824 | waiting for input. (Bug#10169) | |
825 | ||
73d6c093 EZ |
826 | 2011-11-30 Eli Zaretskii <eliz@gnu.org> |
827 | ||
828 | * dispnew.c (adjust_glyph_matrix): Remove the assertion that | |
829 | verifies glyph row's hash code--we have just reallocated the | |
830 | glyphs, so their contents can be complete garbage. (Bug#10164) | |
831 | ||
febe6bea JB |
832 | 2011-11-30 Juanma Barranquero <lekktu@gmail.com> |
833 | ||
834 | * dispnew.c (adjust_glyph_matrix) [XASSERTS]: Add missing check. | |
835 | ||
801a4313 EZ |
836 | 2011-11-30 Eli Zaretskii <eliz@gnu.org> |
837 | ||
838 | * dispnew.c (adjust_glyph_matrix) [XASSERTS]: Ensure ROW's | |
839 | attributes are tested _before_ calling verify_row_hash, to protect | |
840 | against GCC re-ordering of the tests. (Bug#10164) | |
841 | ||
2b56b87e JD |
842 | 2011-11-29 Jan Djärv <jan.h.d@swipnet.se> |
843 | ||
844 | * xterm.h (struct x_output): net_wm_state_hidden_seen is new. | |
845 | ||
846 | * xterm.c (handle_one_xevent): Only set async_visible and friends | |
847 | if net_wm_state_hidden_seen is non-zero (Bug#10002) | |
7dbda6df | 848 | (get_current_wm_state): Set net_wm_state_hidden_seen to 1 if |
2b56b87e JD |
849 | _NET_WM_STATE_HIDDEN is in NET_WM_STATE. |
850 | ||
dbf31225 PE |
851 | 2011-11-28 Paul Eggert <eggert@cs.ucla.edu> |
852 | ||
853 | Remove GCPRO-related macros that exist only to avoid shadowing locals. | |
854 | * lisp.h (GCPRO1_VAR, GCPRO2_VAR, GCPRO3_VAR, GCPRO4_VAR, GCPRO5_VAR) | |
855 | (GCPRO6_VAR, UNGCPRO_VAR): Remove. See | |
856 | <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>. | |
857 | All uses changed to use GCPRO1 etc. | |
858 | (GCPRO1, GCPRO2, GCPRO3, GCPRO4, GCPRO5, GCPRO6, UNGCPRO): | |
859 | Revert to old implementation (i.e., before 2011-03-11). | |
860 | ||
1305621b YM |
861 | 2011-11-28 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
862 | ||
863 | * dispnew.c (scrolling_window): Truncate overlaps in copy destination | |
864 | of scroll runs so as to avoid assigning disabled bogus rows and | |
865 | unnecessary graphics copy operations. | |
866 | ||
8c9afb46 EZ |
867 | 2011-11-27 Eli Zaretskii <eliz@gnu.org> |
868 | ||
869 | * s/ms-w32.h (utimbuf) [_MSC_VER]: Don't define. | |
870 | (snprintf) [_MSC_VER]: Redirect to _snprintf. | |
871 | (strtoll) [_MSC_VER]: Redirect to _strtoi64. | |
872 | (malloc, free, realloc, calloc): Redirect to e_* only when | |
873 | compiling Emacs. | |
874 | ||
875 | * lisp.h (GCTYPEBITS): Move before first use. | |
876 | (ALIGN_GCTYPEBITS) [_MSC_VER]: Define. | |
877 | (DECL_ALIGN) [_MSC_VER]: Use it, as MSVC doesn't like bit ops in | |
878 | this macro definition. | |
879 | ||
880 | * s/ms-w32.h (tzname): Redirect to _tzname for all values of | |
881 | _MSC_VER. | |
882 | ||
54e9e3bf JD |
883 | 2011-11-27 Jan Djärv <jan.h.d@swipnet.se> |
884 | ||
6d5eb5b0 SM |
885 | * gtkutil.c (xg_create_frame_widgets): |
886 | Call gtk_window_set_has_resize_grip (FALSE) if that function is | |
54e9e3bf JD |
887 | present with Gtk+ 2.0. |
888 | ||
83aca1cb PE |
889 | 2011-11-26 Paul Eggert <eggert@cs.ucla.edu> |
890 | ||
891 | * fileio.c (Finsert_file_contents): Undo previous change; see | |
892 | <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>. | |
893 | ||
5b76caa4 PE |
894 | 2011-11-26 Paul Eggert <eggert@cs.ucla.edu> |
895 | ||
896 | Rename locals to avoid shadowing. | |
897 | * fileio.c (Finsert_file_contents): | |
898 | Rename inner 'gcpro1' to 'inner_gcpro1' to avoid shadowing. | |
899 | * process.c (wait_reading_process_output): | |
900 | Rename inner 'proc' to 'p' to avoid shadowing. | |
901 | Indent for consistency with usual Emacs style. | |
902 | ||
8c535114 EZ |
903 | 2011-11-25 Eli Zaretskii <eliz@gnu.org> |
904 | ||
905 | * xdisp.c (redisplay_window): If cursor row is not fully visible | |
906 | after recentering, and scroll-conservatively is set to a large | |
907 | number, scroll window by a few more lines to make the cursor fully | |
908 | visible and out of scroll-margin. (Bug#10105) | |
91b4a718 EZ |
909 | (start_display): Don't move to the next line if the display should |
910 | start at a newline that is part of a display vector or an overlay | |
911 | string. (Bug#10119) | |
8c535114 | 912 | |
fa4fdb5c JL |
913 | 2011-11-24 Juri Linkov <juri@jurta.org> |
914 | ||
915 | * image.c (imagemagick_load_image): Move `MagickSetResolution' down | |
916 | after the `MagickPingImage' call. (Bug#10112) | |
917 | ||
90ec88df CY |
918 | 2011-11-23 Chong Yidong <cyd@gnu.org> |
919 | ||
920 | * window.c (Fcoordinates_in_window_p): Accept only live windows. | |
921 | ||
56e2e794 MR |
922 | 2011-11-23 Martin Rudalics <rudalics@gmx.at> |
923 | ||
924 | * buffer.c (Fkill_buffer): Run replace_buffer_in_windows before | |
925 | making another buffer current. (Bug#10114) | |
926 | ||
b6e64c41 GM |
927 | 2011-11-23 Glenn Morris <rgm@gnu.org> |
928 | ||
929 | * font.c (font_find_for_lface) [HAVE_NS]: Ignore case. (Bug#2526) | |
930 | ||
6b21de18 CY |
931 | 2011-11-23 Chong Yidong <cyd@gnu.org> |
932 | ||
933 | * xdisp.c (compute_stop_pos): Check validity of end_charpos before | |
934 | using it (Bug#5984). | |
935 | ||
b12cd789 EZ |
936 | 2011-11-22 Eli Zaretskii <eliz@gnu.org> |
937 | ||
938 | * dispnew.c (adjust_glyph_matrix): Don't verify hash code of mode- | |
939 | and header-lines, as they don't have one computed for them. | |
940 | (Bug#10098) | |
941 | ||
942 | * .gdbinit (prow): Make displayed values more self-explaining. | |
943 | Add row's hash code. | |
944 | ||
261b6fd4 LMI |
945 | 2011-11-21 Lars Magne Ingebrigtsen <larsi@gnus.org> |
946 | ||
947 | * process.c (wait_reading_process_output): Fix asynchrounous | |
948 | GnuTLS socket handling on some versions of the GnuTLS library. | |
16c1ad08 | 949 | (wait_reading_process_output): Add comment and URL. |
261b6fd4 | 950 | |
e7cfd277 JD |
951 | 2011-11-21 Jan Djärv <jan.h.d@swipnet.se> |
952 | ||
953 | * xterm.c (x_clear_frame): Reinstate the XClearWindow call. | |
954 | ||
a9b9b7f5 CY |
955 | 2011-11-21 Chong Yidong <cyd@gnu.org> |
956 | ||
957 | * window.c (Fnext_window, Fprevious_window): Doc fix. | |
958 | ||
b0d15b4f SM |
959 | 2011-11-20 Stefan Monnier <monnier@iro.umontreal.ca> |
960 | ||
961 | * window.c (get_phys_cursor_glyph): Fix Lisp_Object/int mixup. | |
962 | ||
fe7a3057 JB |
963 | 2011-11-20 Juanma Barranquero <lekktu@gmail.com> |
964 | ||
965 | * nsfont.m (syms_of_nsfont) <ns-reg-to-script>: Fix typo. | |
966 | ||
d2999b1a MR |
967 | 2011-11-20 Martin Rudalics <rudalics@gmx.at> |
968 | ||
969 | * window.c (Fset_window_combination_limit): Rename argument | |
970 | STATUS to LIMIT. | |
971 | (Vwindow_combination_limit): Remove "status" from doc-string. | |
972 | ||
d5ff9cd0 AS |
973 | 2011-11-20 Andreas Schwab <schwab@linux-m68k.org> |
974 | ||
975 | * m/ibms390.h: Remove. | |
976 | * m/ibms390x.h: Don't include "ibms390.h". | |
977 | ||
a5bb9bd3 SM |
978 | 2011-11-20 Stefan Monnier <monnier@iro.umontreal.ca> |
979 | ||
980 | * fileio.c (Finsert_file_contents): Add missing gcpro1 variable. | |
981 | Suggested by Dmitry Antipov <dmantipov@yandex.ru>. | |
982 | ||
cd1181db JB |
983 | 2011-11-20 Juanma Barranquero <lekktu@gmail.com> |
984 | ||
985 | * casetab.c (Fset_case_table): | |
986 | * charset.c (Fcharset_after): Fix typos. | |
987 | ||
615a3b8d | 988 | 2011-11-20 Paul Eggert <eggert@cs.ucla.edu> |
6a0bf43d | 989 | |
17e845af PE |
990 | Standardize on VIRT_ADDR_VARIES behavior (Bug#10042). |
991 | Otherwise, valgrind does not work on some platforms. | |
992 | Problem reported by Andreas Schwab in | |
6a0bf43d PE |
993 | <http://lists.gnu.org/archive/html/emacs-devel/2011-11/msg00081.html>. |
994 | * puresize.h (pure, PURE_P): Always behave as if VIRT_ADDR_VARIES | |
995 | is set, removing the need for VIRT_ADDRESS_VARIES. | |
996 | (PURE_P): Use a more-efficient implementation that needs just one | |
997 | comparison, not two: on x86-64 with GCC 4.6.2, this cut down the | |
998 | number of instructions from 6 (xorl, cmpq, jge, xorl, cmpq, setge) | |
999 | to 4 (xorl, subq, cmpq, setbe). | |
1000 | * alloc.c (pure): Always extern now, since that's the | |
1001 | VIRT_ADDR_VARIES behavior. | |
1002 | (PURE_POINTER_P): Use a single comparison, not two, for | |
1003 | consistency with the new puresize.h. | |
1004 | * lisp.h (PNTR_COMPARISON_TYPE): Remove; no longer needed. | |
1005 | * m/ibms390.h, m/intel386.h, m/template.h, s/cygwin.h, s/hpux10-20.h: | |
1006 | Remove VIRT_ADDR_VARIES no longer needed. | |
1007 | ||
f8fe6f96 EZ |
1008 | 2011-11-19 Eli Zaretskii <eliz@gnu.org> |
1009 | ||
1010 | * xdisp.c (x_write_glyphs, draw_phys_cursor_glyph) | |
1011 | (erase_phys_cursor, update_window_cursor, show_mouse_face) | |
1012 | (cursor_in_mouse_face_p): If the cursor position is out of bounds, | |
1013 | behave as if the cursor position were at the window margin. | |
1014 | ||
1015 | * window.c (get_phys_cursor_glyph): If the window is hscrolled, | |
1016 | and the cursor position is out of bounds, behave as if the cursor | |
1017 | position were at the window margin. (Bug#10075) | |
1018 | ||
df05a53c CY |
1019 | 2011-11-18 Chong Yidong <cyd@gnu.org> |
1020 | ||
1021 | * window.c (Fwindow_combination_limit): Make first argument | |
1022 | non-optional, since it is meaningless for live windows like the | |
1023 | selected window. | |
1024 | ||
2071918e DA |
1025 | 2011-11-18 Dmitry Antipov <dmantipov@yandex.ru> |
1026 | ||
1027 | * keymap.c (Fwhere_is_internal): Add missing RETURN_UNGCPROs. | |
1028 | ||
b50a28de SM |
1029 | 2011-11-18 Stefan Monnier <monnier@iro.umontreal.ca> |
1030 | ||
1031 | * intervals.c: Fix grafting over the whole buffer (bug#10071). | |
1032 | (graft_intervals_into_buffer): Simplify. | |
1033 | ||
015137db EZ |
1034 | 2011-11-18 Eli Zaretskii <eliz@gnu.org> |
1035 | ||
1036 | * dispnew.c (swap_glyph_pointers): Swap the used[] arrays and the | |
1037 | hash values of the two rows. | |
1038 | (copy_row_except_pointers): Preserve the used[] arrays and the | |
1039 | hash values of the two rows. (Bug#10035) | |
68c95424 | 1040 | (add_row_entry): Add xassert to verify that ROW's hash code is valid. |
015137db EZ |
1041 | |
1042 | * xdisp.c (row_hash): New function, body extracted from | |
1043 | compute_line_metrics. | |
1044 | (compute_line_metrics): Call row_hash, instead of computing the | |
1045 | hash code inline. | |
1046 | ||
1047 | * dispnew.c (verify_row_hash): Call row_hash for computing the | |
1048 | hash code of a row, instead of duplicating code from xdisp.c. | |
1049 | ||
1050 | * dispextern.h (row_hash): Add prototype. | |
1051 | ||
a2addb04 TH |
1052 | 2011-11-18 Tassilo Horn <tassilo@member.fsf.org> |
1053 | ||
1054 | * frame.c (delete_frame): Don't delete the terminal when the last | |
1055 | X frame is closed if emacs is built with GTK toolkit. | |
1056 | ||
df85d315 JB |
1057 | 2011-11-17 Juanma Barranquero <lekktu@gmail.com> |
1058 | ||
1059 | * window.c (syms_of_window) <window-combination-resize>: Fix typo. | |
1060 | ||
a0c2d0ae MR |
1061 | 2011-11-17 Martin Rudalics <rudalics@gmx.at> |
1062 | ||
1063 | * window.c (Vwindow_splits): Rename to | |
1064 | Vwindow_combination_resize. Suggested by Juri Linkov. | |
1065 | (Fsplit_window_internal): Use Vwindow_combination_resize instead | |
1066 | of Vwindow_splits. | |
1067 | ||
58179cce JB |
1068 | 2011-11-16 Juanma Barranquero <lekktu@gmail.com> |
1069 | ||
7877f373 JB |
1070 | * nsfns.m (Fns_font_name): |
1071 | * window.c (syms_of_window) <window-combination-limit>: Fix typos. | |
58179cce | 1072 | |
b6f67890 MR |
1073 | 2011-11-16 Martin Rudalics <rudalics@gmx.at> |
1074 | ||
1075 | * window.h (window): Rename slot "nest" to "combination_limit". | |
1076 | * window.c (Fwindow_nest): Rename to Fwindow_combination_limit. | |
1077 | (Fset_window_nest): Rename to Fset_window_combination_limit. | |
1078 | (Vwindow_nest): Rename to Vwindow_combination_limit. | |
1079 | (recombine_windows, make_parent_window, make_window) | |
1080 | (Fsplit_window_internal, saved_window) | |
1081 | (Fset_window_configuration, save_window_save): Rename all | |
1082 | occurrences of window_nest to window_combination_limit. | |
1083 | ||
c7015153 JB |
1084 | 2011-11-15 Juanma Barranquero <lekktu@gmail.com> |
1085 | ||
1086 | * image.c (imagemagick_load_image): Fix typo. | |
1087 | ||
322ad6ec EZ |
1088 | 2011-11-14 Eli Zaretskii <eliz@gnu.org> |
1089 | ||
1090 | * xdisp.c (display_line): Move the call to | |
1091 | highlight_trailing_whitespace before the call to | |
1092 | compute_line_metrics, since the latter needs to see the final | |
6d5eb5b0 SM |
1093 | faces of all the glyphs to compute ROW's hash value. |
1094 | Fixes assertion violations in row_equal_p. (Bug#10035) | |
322ad6ec | 1095 | |
f067b8ec JB |
1096 | 2011-11-14 Juanma Barranquero <lekktu@gmail.com> |
1097 | ||
1098 | * w32proc.c (reader_thread): Don't check pending input if cp->fd < 0, | |
1099 | just return (bug#10044). | |
1100 | ||
1e5b2111 EZ |
1101 | 2011-11-12 Eli Zaretskii <eliz@gnu.org> |
1102 | ||
7ef3cbd5 EZ |
1103 | * makefile.w32-in (HEAPSIZE): New variable, allows to build temacs |
1104 | with user-defined heap size. Bump the default size of the temacs | |
1105 | heap to 27MB, to avoid memory warning when running temacs. | |
1106 | ($(TEMACS)): Use HEAPSIZE instead of a hardcoded value. | |
1107 | ||
1e5b2111 EZ |
1108 | * dispnew.c (scrolling_window): Fix incorrect indices in accessing |
1109 | current_matrix and desired_matrix. (Bug#9990) | |
7a7270dd EZ |
1110 | (verify_row_hash) [XASSERTS]: New function. |
1111 | (adjust_glyph_matrix, row_equal_p): Use it in xassert to verify | |
1112 | that the hash value of glyph rows is correct. | |
1e5b2111 | 1113 | |
89d61221 MR |
1114 | 2011-11-12 Martin Rudalics <rudalics@gmx.at> |
1115 | ||
1116 | * window.h (window): Remove splits slot. | |
1117 | * window.c (Fwindow_splits, Fset_window_splits): Remove. | |
1118 | (Fdelete_other_windows_internal, make_parent_window) | |
1119 | (make_window, Fsplit_window_internal, Fdelete_window_internal) | |
1120 | (Fset_window_configuration, save_window_save): Don't deal with | |
1121 | split status of windows. | |
1122 | (saved_window): Remove splits slot. | |
1123 | (Vwindow_splits): Rewrite doc-string. | |
1124 | ||
97f18cc8 JD |
1125 | 2011-11-11 Jan Djärv <jan.h.d@swipnet.se> |
1126 | ||
1127 | * xfns.c (unwind_create_frame): | |
1128 | * nsfns.m (unwind_create_frame): | |
1129 | * w32fns.c (unwind_create_frame): Use Fmemq to check if frame is in | |
1130 | Vframe_list (Bug#9999). | |
1131 | ||
22a648b4 DA |
1132 | 2011-11-11 Dmitry Antipov <dmantipov@yandex.ru> |
1133 | ||
0b381c7e | 1134 | * xdisp.c (syms_of_xdisp): Remove duplicated definition of Qtext. |
22a648b4 | 1135 | |
659afede KH |
1136 | 2011-11-11 Kenichi Handa <handa@m17n.org> |
1137 | ||
1138 | * callproc.c (Fcall_process): Set the member dst_multibyte of | |
1139 | process_coding. | |
1140 | ||
9ac0394b KH |
1141 | 2011-11-11 Johan Bockgård <bojohan@gnu.org> |
1142 | ||
1143 | * xdisp.c (fill_composite_glyph_string): Always set s->face, to | |
1144 | avoid a crash (bug#9496). | |
1145 | ||
2fbdc249 CY |
1146 | 2011-11-09 Chong Yidong <cyd@gnu.org> |
1147 | ||
1148 | * window.c (Fwindow_inside_edges, Fwindow_inside_pixel_edges) | |
1149 | (Fwindow_inside_absolute_pixel_edges): Only allow live windows. | |
1150 | ||
ac6b1f81 PE |
1151 | 2011-11-08 Paul Eggert <eggert@cs.ucla.edu> |
1152 | ||
1153 | * s/gnu.h (GC_MARK_STACK): Define to GC_MAKE_GCPROS_NOOPS (Bug#9926). | |
1154 | ||
09db192c PE |
1155 | 2011-11-08 Paul Eggert <eggert@cs.ucla.edu> |
1156 | ||
1157 | Avoid some portability problems by eschewing 'extern inline' functions. | |
1158 | The trivial performance wins aren't worth the portability hassles; see | |
1159 | <http://lists.gnu.org/archive/html/emacs-devel/2011-11/msg00084.html> | |
1160 | et seq. | |
1161 | * dispextern.h (window_box, window_box_height, window_text_bottom_y) | |
1162 | (window_box_width, window_box_left, window_box_left_offset) | |
1163 | (window_box_right, window_box_right_offset): Undo previous change, | |
1164 | by removing the "extern"s. | |
1165 | * intervals.c (adjust_intervals_for_insertion) | |
1166 | (adjust_intervals_for_deletion): Undo previous change, | |
1167 | making these static again. | |
1168 | (offset_intervals, temp_set_point_both, temp_set_point) | |
1169 | (copy_intervals_to_string): No longer inline. | |
1170 | * xdisp.c (window_text_bottom_y, window_box_width) | |
1171 | (window_box_height, window_box_left_offset) | |
1172 | (window_box_right_offset, window_box_left, window_box_right) | |
1173 | (window_box): No longer inline. | |
1174 | ||
105216ed CY |
1175 | 2011-11-08 Chong Yidong <cyd@gnu.org> |
1176 | ||
1177 | * window.c (Fwindow_left_column, Fwindow_top_line): Doc fix. | |
6d5eb5b0 SM |
1178 | (Fwindow_body_height, Fwindow_body_width): Move from Lisp. |
1179 | Signal an error if not a live window. | |
105216ed CY |
1180 | (Fwindow_total_width, Fwindow_total_height): Move from Lisp. |
1181 | (Fwindow_total_size, Fwindow_body_size): Move to Lisp. | |
1182 | ||
ae9e237f JB |
1183 | 2011-11-07 Juanma Barranquero <lekktu@gmail.com> |
1184 | ||
1185 | * lisp.h (syms_of_abbrev): Remove declaration. | |
1186 | Reported by CHENG Gao <chenggao@royau.me>. | |
1187 | ||
c7aa8333 EZ |
1188 | 2011-11-07 Eli Zaretskii <eliz@gnu.org> |
1189 | ||
1190 | * w32.c (check_windows_init_file): Don't look for term/w32-win.el | |
1191 | if Vpurify_flag is non-nil. Fixes a crash when running w32 build | |
1192 | of temacs in GUI mode. | |
1193 | ||
be7f5545 MR |
1194 | 2011-11-07 Martin Rudalics <rudalics@gmx.at> |
1195 | ||
1196 | * window.h: Declare delete_all_child_windows instead of | |
1197 | delete_all_subwindows. | |
1198 | * window.c (Fwindow_nest, Fset_window_nest) | |
1199 | (Fset_window_new_total, Fset_window_new_normal) | |
1200 | (Fwindow_resize_apply): Don't use term subwindow in doc-strings. | |
1201 | (delete_all_subwindows): Rename to delete_all_child_windows. | |
1202 | (Fdelete_other_windows_internal, Fset_window_configuration): | |
1203 | Call delete_all_child_windows instead of delete_all_subwindows. | |
1204 | * frame.c (delete_frame): Call delete_all_child_windows instead | |
1205 | of delete_all_subwindows. | |
1206 | ||
ca78dc43 PE |
1207 | 2011-11-07 Paul Eggert <eggert@cs.ucla.edu> |
1208 | ||
1209 | * alloc.c (DEADP): New macro, for porting to GNU/Hurd (Bug#9926). | |
1210 | This is also needed for porting to any host where GC_MARK_STACK is | |
1211 | not GC_MAKE_GCPROS_NOOPS. | |
1212 | (which_symbols): Use it. | |
1213 | ||
a0241d01 KH |
1214 | 2011-11-07 Kenichi Handa <handa@m17n.org> |
1215 | ||
1216 | * coding.c (coding_set_destination): Check coding->src_pos only | |
1217 | when coding->src_object is a buffer (bug#9910). | |
1218 | ||
1219 | * process.c (send_process): Set the member src_multibyte of coding | |
1220 | to 0 (bug#9911) when sending a unibyte text. | |
1221 | ||
1222 | * callproc.c (Fcall_process): Set the member src_multibyte of | |
1223 | process_coding to 0 (bug#9912). | |
1224 | ||
a64bfdfa | 1225 | 2011-11-06 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
ba24cea2 YM |
1226 | |
1227 | * xmenu.c (cleanup_widget_value_tree): New function. | |
1228 | (xmenu_show, xdialog_show): Use it in record_unwind_protect instead of | |
1229 | calling free_menubar_widget_value_tree directly (Bug#9830). | |
1230 | ||
cb41b32a PE |
1231 | 2011-11-06 Paul Eggert <eggert@cs.ucla.edu> |
1232 | ||
1233 | Fix some portability problems with 'inline'. | |
1234 | * dispextern.h (window_box, window_box_height, window_text_bottom_y) | |
1235 | (window_box_width, window_box_left, window_box_left_offset) | |
1236 | (window_box_right, window_box_right_offset): Declare extern. | |
1237 | Otherwise, these inline functions do not conform to C99 and | |
1238 | are miscompiled by Microsoft compilers. Reported by Eli Zaretskii in | |
1239 | <http://lists.gnu.org/archive/html/emacs-devel/2011-11/msg00084.html>. | |
1240 | * intervals.c (adjust_intervals_for_insertion) | |
1241 | (adjust_intervals_for_deletion): Now extern, because otherwise the | |
1242 | extern inline functions 'offset_intervals' couldn't refer to it. | |
1243 | (static_offset_intervals): Remove. | |
1244 | (offset_intervals): Rewrite using the old contents of | |
1245 | static_offset_intervals. The old version didn't conform to C99 | |
1246 | because an extern inline function contained a reference to an | |
1247 | identifier with static linkage. | |
1248 | ||
b7041366 AS |
1249 | 2011-11-06 Andreas Schwab <schwab@linux-m68k.org> |
1250 | ||
1251 | * keyboard.c (interrupt_signal): Don't call kill-emacs while in | |
1252 | GC. | |
1253 | ||
88a37c4d EZ |
1254 | 2011-11-06 Eli Zaretskii <eliz@gnu.org> |
1255 | ||
1256 | * xdisp.c (init_iterator, reseat_to_string): Don't set the | |
1257 | iterator's bidi_p flag if Vpurify_flag is non-nil. (Bug#9963) | |
1258 | (Fcurrent_bidi_paragraph_direction): If Vpurify_flag is non-nil, | |
1259 | return Qleft_to_right. | |
1260 | ||
49745b39 CY |
1261 | 2011-11-06 Chong Yidong <cyd@gnu.org> |
1262 | ||
1263 | * window.c (Fwindow_live_p, Fwindow_frame, Fframe_root_window) | |
1264 | (Fminibuffer_window, Fwindow_buffer, Fwindow_splits) | |
1265 | (Fset_window_splits, Fwindow_nest, Fset_window_nest) | |
1266 | (Fwindow_use_time, Fwindow_total_size, Fwindow_normal_size) | |
1267 | (Fwindow_new_normal, Fwindow_left_column, Fwindow_top_line) | |
1268 | (Fwindow_margins, Fwindow_fringes, Fwindow_scroll_bars) | |
1269 | (Fwindow_vscroll): Doc fix. | |
1270 | (Fwindow_top_child, Fwindow_left_child): Eliminate a nil default | |
1271 | argument, since it makes no sense to pass a live window and for | |
1272 | consistency with window-child. | |
1273 | ||
1f05cd82 CS |
1274 | 2011-11-05 Christoph Scholtes <cschol2112@googlemail.com> |
1275 | ||
1276 | * makefile.w32-in ($(TEMACS), (gl-stamp)): Use $(THISDIR) to | |
1277 | support MSVC. | |
1278 | ||
22610910 JR |
1279 | 2011-11-05 Jason Rumney <jasonr@gnu.org> |
1280 | ||
1281 | * w32font.c (font_matches_spec): Filter out non-Japanese kana fonts. | |
1282 | (add_font_entity_to_list): Filter out non-Japanese Shift-JIS | |
1283 | fonts (Bug#6029). | |
1284 | (add_font_entity_to_list): Fix logic errors in mixed boolean and | |
1285 | bitwise arithmetic preventing use of unicode-sip and non-truetype | |
1286 | opentype fonts. | |
1287 | ||
a06776b2 EZ |
1288 | 2011-11-05 Eli Zaretskii <eliz@gnu.org> |
1289 | ||
3ad924ba EZ |
1290 | * s/ms-w32.h (fstat, stat, utime): Move redirections to |
1291 | "emacs"-only part. | |
1292 | ||
a06776b2 EZ |
1293 | * w32fns.c (x_create_tip_frame, Fx_create_frame): Rearrange |
1294 | initialization code to keep similarity to xfns.c after changes | |
1295 | from 2011-11-05. | |
1296 | ||
c9e7db78 JD |
1297 | 2011-11-05 Jan Djärv <jan.h.d@swipnet.se> |
1298 | ||
a97f8f3f JD |
1299 | * nsfns.m: Declare image_cache_refcount if GLYPH_DEBUG. |
1300 | (unwind_create_frame): New function (Bug#9943). | |
1301 | (Fx_create_frame): Restructure code to be more similar to the one in | |
1302 | xfns.c. Call record_unwind_protect with unwind_create_frame (Bug#9943). | |
1303 | Initialize image_cache_refcount if GLYPH_DEBUG (Bug#9943). | |
1304 | Move terminal->reference_count++ just before making the frame official | |
1305 | (Bug#9943). | |
1306 | ||
1307 | * nsterm.m (x_free_frame_resources): New function. | |
1308 | (x_destroy_window): Move code to x_free_frame_resources. | |
1309 | ||
c9e7db78 | 1310 | * xfns.c (unwind_create_frame): Fix comment. |
6d5eb5b0 SM |
1311 | (Fx_create_frame, x_create_tip_frame): |
1312 | Move terminal->reference_count++ just before making the frame | |
c9e7db78 JD |
1313 | official. Move initialization of image_cache_refcount and |
1314 | dpyinfo_refcount before calling init_frame_faces (Bug#9943). | |
1315 | ||
a6fc3b5c EZ |
1316 | 2011-11-05 Eli Zaretskii <eliz@gnu.org> |
1317 | ||
1318 | Support MSVC build with newer versions of Visual Studio. | |
1319 | * makefile.w32-in (TAGS-gmake): Don't use $(patsubst ...), as | |
1320 | Nmake barfs on that. Use $(OBJ*_c) variables instead, defined on | |
1321 | nt/gmake.defs. | |
1322 | ||
1323 | * lisp.h (ENUM_BF): New macro, for enumerated types in bitfields, | |
1324 | which are not supported by MSVC. | |
1325 | (Lisp_Symbol, Lisp_Misc_Any, Lisp_Marker, Lisp_Misc_Overlay) | |
1326 | (Lisp_Save_Value, Lisp_Free): Use ENUM_BF for enumerated types in | |
1327 | bitfields. | |
1328 | (Lisp_Object) [USE_LISP_UNION_TYPE]: Use ENUM_BF for enumerated | |
1329 | types in bitfields. | |
1330 | (DEFUN) [_MSC_VER]: Define in a different way for MSVC. | |
1331 | ||
1332 | * w32fns.c [_MSC_VER]: DECLARE_HANDLE for any MSVC version. | |
1333 | ||
58179cce | 1334 | 2011-11-05 Fabrice Popineau <fabrice.popineau@supelec.fr> (tiny change) |
a6fc3b5c EZ |
1335 | |
1336 | Support MSVC build with newer versions of Visual Studio. | |
1337 | * w32.c: Don't include w32api.h for MSVC. | |
1338 | (init_environment) [_MSC_VER]: Call sys_access, not _access. | |
1339 | ||
1340 | * s/ms-w32.h <sigset_t, ssize_t> [_MSC_VER]: Typedefs for MSVC. | |
1341 | [_MSC_VER]: Include sys/timeb.h, sys/stat.h, and signal.h. | |
1342 | (fstat, stat, utime) [_MSC_VER]: Redirect to their sys_* cousins. | |
1343 | (malloc, free, realloc, calloc) [_MSC_VER]: Always redirect to the | |
1344 | e_* cousins. | |
1345 | (alloca) [_MSC_VER]: Define to _alloca. | |
1346 | ||
1347 | * lisp.h (DECL_ALIGN) [_MSC_VER]: Define for MSVC. | |
1348 | ||
1349 | * regex.c <re_char> [_MSC_VER]: A separate definition for MSVC. | |
1350 | ||
a58c13ed EZ |
1351 | 2011-11-04 Eli Zaretskii <eliz@gnu.org> |
1352 | ||
1353 | * xdisp.c (note_mouse_highlight): If either of | |
1354 | previous/next-single-property-change returns nil, treat that as | |
1355 | the beginning or the end of the buffer. (Bug#9955) | |
1356 | ||
fe0b6370 JD |
1357 | 2011-11-04 Jan Djärv <jan.h.d@swipnet.se> |
1358 | ||
a58c13ed | 1359 | * gtkutil.c (xg_make_tool_item): Add callbacks if one of wimage or |
fe0b6370 JD |
1360 | label is not null (Bug#9951). |
1361 | (xg_tool_item_stale_p): Handle the fact that wimage and/or wlbl | |
1362 | may be NULL. | |
1363 | ||
89bd5ee1 EZ |
1364 | 2011-11-04 Eli Zaretskii <eliz@gnu.org> |
1365 | ||
1366 | * window.c (Fwindow_body_size): Mention in the doc string that the | |
1367 | return value is in frame's canonical units. (Bug#9949) | |
1368 | ||
84c3edb9 EZ |
1369 | 2011-11-03 Eli Zaretskii <eliz@gnu.org> |
1370 | ||
4e2fb5c7 EZ |
1371 | * xdisp.c (note_mouse_highlight): Initialize `area'. (Bug#9947) |
1372 | ||
84c3edb9 | 1373 | * w32fns.c (unwind_create_frame): If needed, free the glyph |
3ab15fd6 | 1374 | matrices of the partially constructed frame. (Bug#9943) |
2a58bbc1 | 1375 | * xfns.c (unwind_create_frame): Likewise. |
84c3edb9 | 1376 | |
bc17a887 EZ |
1377 | 2011-11-01 Eli Zaretskii <eliz@gnu.org> |
1378 | ||
1379 | * xdisp.c (mouse_face_from_buffer_pos): Fix a typo in a comment. | |
1380 | Don't stop backward scan on the continuation glyph, even though | |
1381 | its CHARPOS is positive. | |
6d5eb5b0 SM |
1382 | (mouse_face_from_buffer_pos, note_mouse_highlight): |
1383 | Rename cover_string to disp_string. | |
bc17a887 | 1384 | |
4ee88440 MR |
1385 | 2011-11-01 Martin Rudalics <rudalics@gmx.at> |
1386 | ||
1387 | * window.c (temp_output_buffer_show): Don't use | |
1388 | Vtemp_buffer_show_specifiers. | |
1389 | (Vtemp_buffer_show_specifiers): Remove unused variable. | |
1390 | ||
c2ff3c02 EZ |
1391 | 2011-10-30 Eli Zaretskii <eliz@gnu.org> |
1392 | ||
1393 | * xdisp.c (try_cursor_movement): Make sure ROW isn't decremented | |
1394 | past the beginning of the current glyph matrix. | |
1395 | ||
58179cce | 1396 | 2011-10-30 Adam Sjøgren <asjo@koldfront.dk> (tiny change) |
6e56383b JD |
1397 | |
1398 | * xterm.c: Include X11/Xproto.h if HAVE_GTK3. | |
1399 | (x_error_handler): Ignore BadMatch for X_SetInputFocus for | |
1400 | HAVE_GTK3 (Bug#9869). | |
b77a6a7f | 1401 | |
3b574623 JD |
1402 | * gtkutil.c (xg_win_to_widget, xg_event_is_for_menubar): Initialize |
1403 | type to GDK_NOTHING so valgrind does not complain (Bug#9901). | |
1404 | ||
b77a6a7f JD |
1405 | * xterm.h (x_display_info): Add Xatom_net_wm_state_hidden (Bug#9893). |
1406 | ||
1407 | * xterm.c: Declare x_handle_net_wm_state to return int. | |
1408 | (handle_one_xevent): Check if we are iconified but don't have | |
1409 | _NET_WM_STATE_HIDDEN. If do, treat as deiconify (Bug#9893). | |
1410 | (get_current_wm_state): Return non-zero if not hidden, | |
1411 | check for _NET_WM_STATE_HIDDEN (Bug#9893). | |
1412 | (do_ewmh_fullscreen): Ignore return value from get_current_wm_state. | |
1413 | (x_handle_net_wm_state): Return what get_current_wm_state returns. | |
1414 | (x_term_init): Initialize dpyinfo->Xatom_net_wm_state_hidden. | |
1415 | ||
196e41e4 PE |
1416 | 2011-10-29 Paul Eggert <eggert@cs.ucla.edu> |
1417 | ||
1418 | * alloc.c (which_symbols): Declare EXTERNALLY_VISIBLE, | |
1419 | so that this new function doesn't get optimized away by a | |
1420 | whole-program optimizer. Make the 2nd arg EMACS_INT, not int. | |
1421 | ||
021f2e1a AS |
1422 | 2011-10-29 Andreas Schwab <schwab@linux-m68k.org> |
1423 | ||
1424 | * frame.h (MOUSE_HL_INFO): Remove excess parens. | |
1425 | ||
8b058d44 EZ |
1426 | 2011-10-29 Eli Zaretskii <eliz@gnu.org> |
1427 | ||
1428 | Fix the `xbytecode' command. | |
1429 | * .gdbinit (xprintbytestr): New command. | |
b50a28de | 1430 | (xwhichsymbols): Rename from `which'; all callers changed. |
8b058d44 EZ |
1431 | (xbytecode): Print the byte-code string as well. |
1432 | ||
4452fb80 EZ |
1433 | 2011-10-29 Kim Storm <storm@cua.dk> |
1434 | ||
8b058d44 EZ |
1435 | * alloc.c (which_symbols): New function. |
1436 | ||
21b72067 AS |
1437 | 2011-10-29 Andreas Schwab <schwab@linux-m68k.org> |
1438 | ||
1439 | * minibuf.c (read_minibuf_noninteractive): Allow reading empty | |
1440 | line. (Bug#9903) | |
1441 | ||
83ed7b5c GM |
1442 | 2011-10-29 Glenn Morris <rgm@gnu.org> |
1443 | ||
1444 | * process.c (wait_reading_process_output): Revert 2009-08-30 change. | |
1445 | Not clear what it was for, and it causes various bugs. (Bug#9839) | |
1446 | ||
5a7a728b EZ |
1447 | 2011-10-28 Eli Zaretskii <eliz@gnu.org> |
1448 | ||
1449 | * xdisp.c (note_mouse_highlight): Initialize `part', to avoid a | |
1450 | possible random value that matches one of those tested as | |
1451 | condition to clear the mouse face. | |
1452 | ||
d3d0842f CY |
1453 | 2011-10-28 Chong Yidong <cyd@gnu.org> |
1454 | ||
1455 | * xdisp.c (note_mouse_highlight): Fix use of uninitialized var. | |
1456 | ||
31b39d13 DN |
1457 | 2011-10-28 Dan Nicolaescu <dann@ics.uci.edu> |
1458 | ||
1459 | * window.c (make_window): Initialize phys_cursor_on_p. | |
1460 | ||
9aba6043 SM |
1461 | 2011-10-28 Stefan Monnier <monnier@iro.umontreal.ca> |
1462 | ||
1463 | * lisp.h (struct Lisp_Symbol): Update comments. | |
1464 | ||
c20992f4 JB |
1465 | 2011-10-28 Juanma Barranquero <lekktu@gmail.com> |
1466 | ||
1467 | * w32font.c (w32_load_unicows_or_gdi32): Add missing return. | |
1468 | ||
db4f02f2 EZ |
1469 | 2011-10-28 Eli Zaretskii <eliz@gnu.org> |
1470 | ||
1471 | Fix Emacs on Windows 9X (bug#8562). Thanks to oslsachem | |
1472 | <oslsachem@gmail.com> for helping to debug this. | |
1473 | ||
1474 | * w32font.c (g_b_init_is_w9x, g_b_init_get_outline_metrics_w) | |
1475 | (g_b_init_get_text_metrics_w, g_b_init_get_glyph_outline_w) | |
1476 | (g_b_init_get_glyph_outline_w): New static variables. | |
1477 | (GetOutlineTextMetricsW_Proc, GetTextMetricsW_Proc) | |
1478 | (GetGlyphOutlineW_Proc): New typedefs. | |
1479 | (w32_load_unicows_or_gdi32, get_outline_metrics_w) | |
9aba6043 SM |
1480 | (get_text_metrics_w, get_glyph_outline_w, globals_of_w32font): |
1481 | New functions. | |
1482 | (w32font_open_internal, compute_metrics): | |
1483 | Call get_outline_metrics_w, get_text_metrics_w, and get_glyph_outline_w | |
db4f02f2 EZ |
1484 | instead of calling the "wide" APIs directly. |
1485 | ||
1486 | * emacs.c (main) [HAVE_NTGUI]: Call globals_of_w32font. | |
1487 | ||
1488 | * w32.h (syms_of_w32font): Add prototype. | |
1489 | ||
87e68db4 JB |
1490 | 2011-10-27 Juanma Barranquero <lekktu@gmail.com> |
1491 | ||
1492 | * window.c (Fframe_root_window, Fframe_first_window, Fwindow_end) | |
1493 | (Fframe_selected_window, Ftemp_output_buffer_show, Fnext_window) | |
1494 | (Fdelete_window_internal, Fwindow_parameters): Fix typos in docstrings. | |
1495 | (Fmove_to_window_line): Doc fix. | |
1496 | ||
435c1d67 CY |
1497 | 2011-10-27 Chong Yidong <cyd@gnu.org> |
1498 | ||
1499 | * process.c (make_process): Set gnutls_state to NULL. | |
1500 | ||
1501 | * gnutls.c (emacs_gnutls_deinit): Deinit the gnutls_state if it is | |
1502 | non-NULL, regardless of GNUTLS_INITSTAGE. | |
1503 | (Fgnutls_boot): Cleanups. Call emacs_gnutls_deinit if we signal | |
1504 | an error. Set process slots as soon as we allocate them. | |
1505 | ||
1506 | * gnutls.h (GNUTLS_LOG, GNUTLS_LOG2): Fix macros. | |
1507 | ||
9c6c6f49 CY |
1508 | 2011-10-27 Chong Yidong <cyd@gnu.org> |
1509 | ||
9aba6043 SM |
1510 | * gnutls.c (emacs_gnutls_deinit): New function. |
1511 | Deallocate credentials structures as well as calling gnutls_deinit. | |
9c6c6f49 CY |
1512 | (Fgnutls_deinit, Fgnutls_boot): Use it. |
1513 | ||
1514 | * process.c (make_process): Initialize GnuTLS credentials to NULL. | |
1515 | (deactivate_process): Call emacs_gnutls_deinit. | |
1516 | ||
657d08d3 JB |
1517 | 2011-10-27 Juanma Barranquero <lekktu@gmail.com> |
1518 | ||
1519 | * image.c (x_create_x_image_and_pixmap): | |
1520 | * w32.c (sys_rename, w32_delayed_load): | |
1521 | * w32font.c (fill_in_logfont): | |
1522 | * w32reg.c (x_get_string_resource): Silence compiler warnings. | |
1523 | ||
5430d399 JB |
1524 | 2011-10-26 Juanma Barranquero <lekktu@gmail.com> |
1525 | ||
1526 | * w32fns.c (w32_default_color_map): New function, | |
1527 | extracted from Fw32_default_color_map. | |
a7ef684b | 1528 | (Fw32_default_color_map, Fx_open_connection): Use it. (Bug#9785) |
5430d399 | 1529 | |
fe0055fa PE |
1530 | 2011-10-25 Paul Eggert <eggert@cs.ucla.edu> |
1531 | ||
1532 | * dispextern.h (Fcontrolling_tty_p): New decl (Bug#6649 part 2). | |
1533 | ||
e6346438 SM |
1534 | 2011-10-25 Stefan Monnier <monnier@iro.umontreal.ca> |
1535 | ||
1536 | * keyboard.c (test_undefined): New function (bug#9751). | |
1537 | (read_key_sequence): Use it to detect when a key is bound to `undefined'. | |
1538 | ||
e112cc37 ET |
1539 | 2011-10-25 Enami Tsugutomo <tsugutomo.enami@jp.sony.com> |
1540 | ||
1541 | * sysdep.c (init_sys_modes): Fix the check for the controlling | |
1542 | terminal (Bug#6649). | |
1543 | ||
7b5d6677 EZ |
1544 | 2011-10-20 Eli Zaretskii <eliz@gnu.org> |
1545 | ||
1546 | * dispextern.h (struct bidi_it): New member next_en_type. | |
1547 | ||
1548 | * bidi.c (bidi_line_init): Initialize the next_en_type member. | |
1549 | (bidi_resolve_explicit_1): When next_en_pos is valid for the | |
1550 | current character, check also for next_en_type being WEAK_EN. | |
1551 | (bidi_resolve_weak): Don't enter the expensive loop if the current | |
1552 | position is before next_en_pos. Record the bidi type of the first | |
1553 | non-ET, non-BN character we find, in addition to its position. | |
1554 | (bidi_level_of_next_char): Invalidate next_en_type when | |
1555 | next_en_pos is over-stepped. | |
1556 | ||
7da0b018 PE |
1557 | 2011-10-20 Paul Eggert <eggert@cs.ucla.edu> |
1558 | ||
1559 | Time zone name fixes for non-ASCII locales (Bug#641, Bug#9794) | |
1560 | * editfns.c: Rewrite current-time-zone so that it invokes | |
1561 | the equivalent of (format-time-string "%Z") to get the time zone name. | |
1562 | This fixes a bug when the time zone name contains characters that | |
1563 | need converting from the system time locale to Emacs internal format. | |
1564 | This fixes a shortcoming that I introduced in my 1999-10-19 patch: | |
1565 | that patch fixed format-time-string to do the conversion, but | |
1566 | I forgot to fix current-time-zone. | |
1567 | (format_time_string): New function, containing most of | |
1568 | what Fformat_time_string used to contain. | |
1569 | (Fformat_time_string): Rewrite in terms of format_time_string. | |
1570 | This doesn't change this function's behavior. | |
1571 | (current-time-zone): Rewrite to use format_time_string. | |
1572 | This fixes the bug reported by Michael Schierl in | |
1573 | <http://lists.gnu.org/archive/html/emacs-devel/2007-06/msg00334.html>. | |
1574 | Jason Rumney's 2007-06-07 change worked around this bug, but | |
1575 | didn't fix it. | |
1576 | * systime.h (tzname, timezone): Remove no-longer-used declarations. | |
1577 | ||
8547b010 EZ |
1578 | 2011-10-19 Eli Zaretskii <eliz@gnu.org> |
1579 | ||
1580 | * xdisp.c (start_display): If the character at POS is displayed | |
1581 | via a display vector, reset IT->current.dpvec_index to zero. | |
12b32963 EZ |
1582 | (try_window_reusing_current_matrix): If a line ends in a display |
1583 | vector or the next line starts in a display vector, continue | |
1584 | redrawing the window even though the character position of | |
1585 | start_row was reached. | |
8547b010 EZ |
1586 | (Bug#9771, part 2) |
1587 | ||
4e948d15 CY |
1588 | 2011-10-18 Chong Yidong <cyd@gnu.org> |
1589 | ||
1590 | * xdisp.c (get_next_display_element): Handle U+2010 and U+2011 | |
1591 | with nobreak-char-display too. | |
1592 | ||
4787455f EZ |
1593 | 2011-10-18 Eli Zaretskii <eliz@gnu.org> |
1594 | ||
1595 | Fix part 3 of bug#9771. | |
1596 | * bidi.c (bidi_line_init): Initialize next_en_pos to zero, not -1. | |
1597 | (bidi_resolve_neutral): Don't enter the expensive loop looking for | |
1598 | non-neutral characters if the current character is a paragraph | |
1599 | separator (a.k.a. Newline). This avoids running the same | |
1600 | expensive loop twice, once when we consume the preceding newline | |
1601 | and the other time when the line actually needs to be displayed. | |
1602 | Avoid the loop when we see neutrals on the base embedding level | |
1603 | following a character whose directionality is the same as the | |
1604 | paragraph's. This avoids running the expensive loop when a line | |
1605 | ends in a long sequence of neutrals, like control characters. | |
1606 | Add assertion against STRONG_AL type. Slightly rearrange code | |
1607 | that determines the type of a neutral given the first non-neutral | |
1608 | that follows it. | |
1609 | (bidi_level_of_next_char): Set next_en_pos to zero when | |
1610 | invalidating its info. | |
1611 | ||
2c91f553 EZ |
1612 | 2011-10-17 Eli Zaretskii <eliz@gnu.org> |
1613 | ||
1614 | * xdisp.c (push_display_prop): Determine whether to record string | |
1615 | or buffer position by IT->string, not by IT->method. Allow | |
1616 | GET_FROM_DISPLAY_VECTOR as IT->method on entry. (Bug#9771, part 4) | |
f2ff9e88 EZ |
1617 | (move_it_vertically_backward): Don't look for character position |
1618 | immediately after the newline when in a continuation line. | |
1619 | (Bug#9771, part 1) | |
2c91f553 | 1620 | |
c7b08b0d MR |
1621 | 2011-10-15 Martin Rudalics <rudalics@gmx.at> |
1622 | ||
1623 | * window.c (coordinates_in_window): Rewrite and delabelize | |
1624 | vertical border check. (Bug#5357) (Bug#9618) | |
1625 | ||
6b02f655 SM |
1626 | 2011-10-14 Stefan Monnier <monnier@iro.umontreal.ca> |
1627 | ||
1628 | * xterm.c (frame_highlight, frame_unhighlight): Ignore unexplained | |
1629 | errors in XSetWindowBorder (bug#9310). | |
1630 | ||
81d40c92 DA |
1631 | 2011-10-13 Dmitry Antipov <dmantipov@yandex.ru> |
1632 | ||
1633 | * editfns.c (Fset_time_zone_rule): Replace free with xfree to | |
1634 | avoid crash when xmalloc overrun checking is enabled. | |
1635 | ||
d4172c3b EZ |
1636 | 2011-10-13 Eli Zaretskii <eliz@gnu.org> |
1637 | ||
1638 | * xdisp.c (Fcurrent_bidi_paragraph_direction): Initialize | |
1639 | itb.paragraph_dir to NEUTRAL_DIR. Fixes an occasional incorrect | |
1640 | cursor motion with <left> and <right> arrow keys. | |
1641 | ||
1642 | * bidi.c (bidi_init_it): Don't initialize paragraph_dir here, as | |
1643 | some callers set that themselves. | |
1644 | ||
b00eea75 EZ |
1645 | 2011-10-12 Eli Zaretskii <eliz@gnu.org> |
1646 | ||
1647 | * xdisp.c (find_row_edges): Handle the case where ROW comes from a | |
1648 | display string and the previous row comes from the same string and | |
1649 | is empty. (Bug#9739) (Bug#9738) | |
1650 | ||
8fe012c4 SM |
1651 | 2011-10-12 Stefan Monnier <monnier@iro.umontreal.ca> |
1652 | ||
1653 | * doc.c (get_doc_string): Encode file name (bug#9735). | |
1654 | ||
0074aef2 EZ |
1655 | 2011-10-12 Eli Zaretskii <eliz@gnu.org> |
1656 | ||
79beb178 EZ |
1657 | * bidi.c (bidi_level_of_next_char): |
1658 | * xdisp.c (get_visually_first_element): Remove old incorrect | |
1659 | comments regarding the Unicode Line Separator character. | |
1660 | ||
0074aef2 EZ |
1661 | * bidi.c (bidi_init_it): Initialize paragraph_dir to NEUTRAL_DIR. |
1662 | ||
6e4b3fbe DA |
1663 | 2011-10-12 Dmitry Antipov <dmantipov@yandex.ru> |
1664 | ||
1665 | * alloc.c (Fgc_status): Do not access beyond zombies array | |
1666 | boundary if nzombies > MAX_ZOMBIES. | |
1667 | * alloc.c (dump_zombies): Add missing format specifier. | |
1668 | ||
0324f3af PE |
1669 | 2011-10-12 Paul Eggert <eggert@cs.ucla.edu> |
1670 | ||
b5525cac PE |
1671 | * xdisp.c (set_cursor_from_row): Simplify conditionals, |
1672 | to pacify GCC 4.6.1 x86-64 with -O2 -Wstrict-overflow. | |
1673 | ||
0324f3af PE |
1674 | * lread.c (read_escape): Allow hex escapes as large as ?\xfffffff. |
1675 | Some packages use them to denote characters with modifiers. | |
1676 | ||
e9b5f888 AS |
1677 | 2011-10-11 Andreas Schwab <schwab@linux-m68k.org> |
1678 | ||
1679 | * lisp.h (GCPRO1_VAR, GCPRO2_VAR, GCPRO3_VAR, GCPRO4_VAR) | |
1680 | (GCPRO5_VAR, GCPRO6_VAR, UNGCPRO_VAR): Add whitespace to avoid | |
1681 | matching a pp-number. Rename parameter var to var1. | |
1682 | ||
127827c0 SM |
1683 | 2011-10-11 Stefan Monnier <monnier@iro.umontreal.ca> |
1684 | ||
1685 | * minibuf.c (Finternal_complete_buffer): Fix last change (bug#9709). | |
1686 | ||
c8fd3bd0 GM |
1687 | 2011-10-08 Glenn Morris <rgm@gnu.org> |
1688 | ||
1689 | * callint.c (Fcall_interactively): Give a more explicit error for the | |
1690 | 'c' case with a non-character input. (Bug#8479) | |
1691 | ||
352ec8ff EZ |
1692 | 2011-10-08 Eli Zaretskii <eliz@gnu.org> |
1693 | ||
03669ccb EZ |
1694 | * xdisp.c (hscroll_window_tree): Support hscroll in right-to-left |
1695 | lines. | |
7061c986 EZ |
1696 | (set_cursor_from_row): Fix cursor positioning in mixed L2R+R2L |
1697 | lines that are hscrolled on the left. | |
03669ccb | 1698 | |
352ec8ff EZ |
1699 | * dispnew.c (buffer_posn_from_coords): Account for a possible |
1700 | presence of header-line. (Bug#4426) | |
1701 | ||
a66cfb1c SM |
1702 | 2011-10-07 Stefan Monnier <monnier@iro.umontreal.ca> |
1703 | ||
6b02f655 SM |
1704 | * buffer.c (syms_of_buffer) <enable-multibyte-characters>: |
1705 | Don't advertise functionality which we discourage or doesn't work. | |
a66cfb1c | 1706 | |
7c5ee88e PE |
1707 | 2011-10-07 Paul Eggert <eggert@cs.ucla.edu> |
1708 | ||
1709 | * alloc.c (GC_LISP_OBJECT_ALIGNMENT): Use offsetof, not __alignof__ | |
1710 | or sizeof. __alignof__ gives the wrong answer on Fedora x86-64 | |
1711 | with GCC 4.6.1 when configured with CC='gcc -m32' --with-wide-int; | |
1712 | this makes Emacs dump core during garbage collection on rare | |
1713 | occasions. sizeof is obviously inferior to offsetof here, so | |
1714 | stick with offsetof. | |
1715 | (GC_POINTER_ALIGNMENT): New macro. | |
1716 | (mark_memory): Omit 3rd (offset) arg; caller changed. | |
1717 | Don't assume EMACS_INT alignment is the same as pointer alignment. | |
1718 | ||
df1bbe5b SM |
1719 | 2011-10-03 Stefan Monnier <monnier@iro.umontreal.ca> |
1720 | ||
1721 | * keyboard.c (read_key_sequence_remapped): New var. | |
1722 | (read_key_sequence): Compute remapping in the right buffer. | |
1723 | (command_loop_1): Use read_key_sequence's remapping directly. | |
1724 | ||
51553db6 SM |
1725 | 2011-10-02 Stefan Monnier <monnier@iro.umontreal.ca> |
1726 | ||
32c1fffd SM |
1727 | * dired.c (file_name_completion): Don't expand file name. |
1728 | (Ffile_name_completion, Ffile_name_all_completions): Expand file name | |
1729 | before checking file name handler. | |
1730 | ||
51553db6 SM |
1731 | * minibuf.c (Finternal_complete_buffer): Only show internal buffers if |
1732 | they've been requested explicitly (bug#9591). | |
1733 | ||
b6bd1599 | 1734 | 2011-10-01 Andreas Schwab <schwab@linux-m68k.org> |
fa2ec41f AS |
1735 | |
1736 | * keymap.c (Fsingle_key_description): Use make_specified_string | |
1737 | instead of build_string to build string from push_key_description. | |
1738 | (Bug#5193) | |
1739 | ||
f701dc2a PE |
1740 | 2011-09-30 Paul Eggert <eggert@cs.ucla.edu> |
1741 | ||
4222c55d PE |
1742 | * buffer.h (struct buffer): Use time_t, not int, for a time stamp. |
1743 | This fixes a Y2038 bug on 64-bit hosts. | |
1744 | * buffer.c (reset_buffer): | |
1745 | * fileio.c (Fdo_auto_save, Fset_buffer_auto_saved) | |
1746 | (Fclear_buffer_auto_save_failure): | |
1747 | Use 0, not -1, to represent an unset failure time, since time_t | |
1748 | might not be signed. | |
1749 | ||
f701dc2a PE |
1750 | Remove dependency on glibc malloc internals. |
1751 | * alloc.c (XMALLOC_OVERRUN_CHECK_OVERHEAD, XMALLOC_OVERRUN_CHECK_SIZE): | |
1752 | Move back here from lisp.h, but with their new implementations. | |
1753 | (XMALLOC_BASE_ALIGNMENT, COMMON_MULTIPLE, XMALLOC_HEADER_ALIGNMENT) | |
1754 | (XMALLOC_OVERRUN_SIZE_SIZE): Move these new lisp.h macros here. | |
1755 | * charset.c (charset_table_init): New static var. | |
1756 | (syms_of_charset): Use it instead of xmalloc. This removes a | |
1757 | dependency on glibc malloc internals. See Eli Zaretskii's comment in | |
1758 | <http://lists.gnu.org/archive/html/emacs-devel/2011-09/msg00815.html>. | |
1759 | * lisp.h (XMALLOC_OVERRUN_CHECK_OVERHEAD, XMALLOC_OVERRUN_CHECK_SIZE): | |
1760 | Move back to alloc.c. | |
1761 | (XMALLOC_BASE_ALIGNMENT, COMMON_MULTIPLE, XMALLOC_HEADER_ALIGNMENT) | |
1762 | (XMALLOC_OVERRUN_SIZE_SIZE): Move to alloc.c. | |
1763 | ||
9ceebf39 JD |
1764 | 2011-09-30 Jan Djärv <jan.h.d@swipnet.se> |
1765 | ||
1766 | * nsterm.m (windowDidResize): Call x_set_window_size only when | |
1767 | ns_in_resize is true. Otherwise set pixelwidth/height and | |
1768 | call change_frame_size (Bug#9628). | |
1769 | ||
cb993c58 PE |
1770 | 2011-09-30 Paul Eggert <eggert@cs.ucla.edu> |
1771 | ||
3930c88b PE |
1772 | Port --enable-checking=all to Fedora 14 x86-64. |
1773 | * charset.c (syms_of_charset): Also account for glibc malloc's | |
1774 | internal overhead when calculating the initial malloc maximum. | |
1775 | ||
cb993c58 PE |
1776 | Port --enable-checking=all to Fedora 14 x86. |
1777 | * alloc.c (XMALLOC_OVERRUN_CHECK_OVERHEAD, XMALLOC_OVERRUN_CHECK_SIZE): | |
1778 | Move to lisp.h. | |
1779 | (xmalloc_put_size, xmalloc_get_size, overrun_check_malloc) | |
1780 | (overrun_check_realloc, overrun_check_free): | |
1781 | Use XMALLOC_OVERRUN_SIZE_SIZE, not sizeof (size_t). | |
1782 | That way, xmalloc returns a properly-aligned pointer even if | |
1783 | XMALLOC_OVERRUN_CHECK is defined. The old debugging code happened | |
1784 | to align OK on typical 64-bit hosts, but not on Fedora 14 x86. | |
1785 | * charset.c (syms_of_charset): Take XMALLOC_OVERRUN_CHECK_OVERHEAD | |
1786 | into account when calculating the initial malloc maximum. | |
1787 | * lisp.h (XMALLOC_OVERRUN_CHECK_OVERHEAD, XMALLOC_OVERRUN_CHECK_SIZE): | |
1788 | Move here from alloc.c, so that charset.c can use it too. | |
1789 | Properly align; the old code wasn't right for common 32-bit hosts | |
1790 | when configured with --enable-checking=all. | |
1791 | (XMALLOC_BASE_ALIGNMENT, COMMON_MULTIPLE, XMALLOC_HEADER_ALIGNMENT) | |
1792 | (XMALLOC_OVERRUN_SIZE_SIZE): New macros. | |
1793 | ||
31bed486 EZ |
1794 | 2011-09-29 Eli Zaretskii <eliz@gnu.org> |
1795 | ||
04c70788 | 1796 | * sysdep.c (snprintf) [!EOVERFLOW]: If EOVERFLOW is not defined, |
31bed486 EZ |
1797 | use EDOM. |
1798 | ||
fbcaa2f3 EZ |
1799 | 2011-09-28 Eli Zaretskii <eliz@gnu.org> |
1800 | ||
1801 | * xdisp.c (compute_display_string_end): If there's no display | |
1802 | string at CHARPOS, return -1. | |
1803 | ||
1804 | * bidi.c (bidi_fetch_char): When compute_display_string_end | |
1805 | returns a negative value, treat the character as a normal | |
1806 | character not covered by a display string. (Bug#9624) | |
1807 | ||
a239d4e9 JB |
1808 | 2011-09-28 Juanma Barranquero <lekktu@gmail.com> |
1809 | ||
1810 | * lread.c (Fread_from_string): Fix typo in docstring. | |
1811 | ||
88652fd5 EZ |
1812 | 2011-09-27 Eli Zaretskii <eliz@gnu.org> |
1813 | ||
1814 | * xdisp.c (handle_invisible_prop): If invisible text ends on a | |
1815 | newline, reseat the iterator instead of bidi-iterating there one | |
1816 | character at a time. (Bug#9610) | |
32c1fffd SM |
1817 | (BUFFER_POS_REACHED_P, move_it_in_display_line_to): Bail when past |
1818 | TO_CHARPOS if the bidi iterator is at base embedding level. | |
88652fd5 | 1819 | |
ed497dd4 AS |
1820 | 2011-09-27 Andreas Schwab <schwab@linux-m68k.org> |
1821 | ||
1822 | * lread.c (readevalloop): Use correct code for NBSP. | |
1823 | (read1): Likewise. (Bug#9608) | |
1824 | ||
b2bf61aa MA |
1825 | 2011-09-25 Michael Albinus <michael.albinus@gmx.de> |
1826 | ||
1827 | * dbusbind.c (Fdbus_register_signal): When service is not | |
1828 | registered, use nil in Vdbus_registered_objects_table. (Bug#9581) | |
1829 | ||
32bbb17c GM |
1830 | 2011-09-25 Glenn Morris <rgm@gnu.org> |
1831 | ||
1832 | * buffer.c (truncate-lines): Doc fix. | |
1833 | ||
94e0933e CY |
1834 | 2011-09-24 Chong Yidong <cyd@stupidchicken.com> |
1835 | ||
1836 | * window.c (Fwindow_prev_buffers, Fset_window_prev_buffers) | |
1837 | (Fset_window_next_buffers): Doc fix. | |
1838 | ||
cddde921 GM |
1839 | 2011-09-24 Glenn Morris <rgm@gnu.org> |
1840 | ||
1841 | * minibuf.c (read_minibuf): Disable line truncation. (Bug#5715) | |
1842 | ||
1260aef1 PE |
1843 | 2011-09-24 Paul Eggert <eggert@cs.ucla.edu> |
1844 | ||
25b4bfa0 PE |
1845 | Fix minor problems found by static checking. |
1846 | * xdisp.c (string_from_display_spec): Don't assume vecsize fits in int. | |
1260aef1 PE |
1847 | * indent.c (Fvertical_motion): Fix == vs = typo. |
1848 | ||
e3cbd34b EZ |
1849 | 2011-09-24 Eli Zaretskii <eliz@gnu.org> |
1850 | ||
a66cfb1c SM |
1851 | * dispnew.c (syms_of_display) <redisplay-dont-pause>: |
1852 | Default value is now t. Doc fix. | |
6bf7006f | 1853 | |
e3cbd34b | 1854 | * indent.c (Fvertical_motion): Compute and apply the overshoot |
32c1fffd | 1855 | logic when moving up, not only when moving down. Fix the |
e3cbd34b | 1856 | confusing name and values of the it_overshoot_expected variable; |
32c1fffd | 1857 | logic changes accordingly. (Bug#9254) (Bug#9549) |
e3cbd34b EZ |
1858 | |
1859 | * xdisp.c (pos_visible_p): Produce correct pixel coordinates when | |
1860 | CHARPOS is covered by a display string which includes newlines. | |
1861 | (move_it_vertically_backward): Avoid inflooping when START_CHARPOS | |
1862 | is covered by a display string with embedded newlines. | |
1863 | ||
a3de0cbd MA |
1864 | 2011-09-24 Michael Albinus <michael.albinus@gmx.de> |
1865 | ||
1866 | * dbusbind.c (Fdbus_register_signal): Add match rule to | |
1867 | Vdbus_registered_objects_table. (Bug#9581) | |
a66cfb1c SM |
1868 | (Fdbus_register_method, Vdbus_registered_objects_table): |
1869 | Fix docstring. | |
a3de0cbd | 1870 | |
b260039d JM |
1871 | 2011-09-24 Jim Meyering <meyering@redhat.com> |
1872 | ||
32c1fffd | 1873 | do not ignore write error for any output size |
b260039d JM |
1874 | The previous change was incomplete. |
1875 | While it makes emacs --batch detect the vast majority of stdout | |
1876 | write failures, errors were still ignored whenever the output size is | |
1877 | k * (BUFSIZ+1) - 4. E.g., on a system with BUFSIZ of 4096, | |
1878 | $ emacs --batch --eval '(print (format "%4093d" 0))' > /dev/full \ | |
1879 | && echo FAIL: ignored write error | |
1880 | FAIL: ignored write error | |
1881 | $ emacs --batch --eval '(print (format "%20481d" 0))' > /dev/full \ | |
1882 | && echo FAIL: ignored write error | |
1883 | FAIL: ignored write error | |
1884 | * emacs.c (Fkill_emacs): Also test ferror. (Bug#9574) | |
1885 | ||
8eca8a7c AS |
1886 | 2011-09-23 Andreas Schwab <schwab@linux-m68k.org> |
1887 | ||
1888 | * emacs.c (Fkill_emacs): In noninteractive mode exit | |
1889 | non-successfully if a write error occurred on stdout. (Bug#9574) | |
1890 | ||
3341db62 EZ |
1891 | 2011-09-21 Eli Zaretskii <eliz@gnu.org> |
1892 | ||
1893 | * xdisp.c (pop_it): Allow it->object that is a cons cell to pass | |
1894 | the xassert test. | |
1895 | ||
1896 | * dispextern.h (struct it): Update the comment documenting what | |
1897 | can it->OBJECT be. | |
1898 | ||
8c203dbf EZ |
1899 | 2011-09-20 Eli Zaretskii <eliz@gnu.org> |
1900 | ||
1901 | * xdisp.c (set_cursor_from_row): If the row ends in a newline from | |
1902 | a display string, extend search for cursor position to end of row. | |
1903 | (find_row_edges): If the row ends in a newline from a display | |
1904 | string, increment its MATRIX_ROW_END_CHARPOS by one. (Bug#9549) | |
1905 | Handle the case of a display string with multiple newlines. | |
fd317ddf EZ |
1906 | (Fcurrent_bidi_paragraph_direction): Fix search for previous |
1907 | non-empty line. Fixes confusing cursor motion with arrow keys at | |
1908 | the beginning of a line that starts with whitespace. | |
8c203dbf | 1909 | |
a4824228 LMI |
1910 | 2011-09-19 Lars Magne Ingebrigtsen <larsi@gnus.org> |
1911 | ||
1912 | * lread.c (Fread_from_string): Document what FINAL-STRING-INDEX is | |
1913 | (bug#9493). | |
1914 | ||
33ed493b CY |
1915 | 2011-09-18 Chong Yidong <cyd@stupidchicken.com> |
1916 | ||
1917 | * xfns.c (Fx_create_frame): Handle the bitmapIcon resource as | |
1918 | boolean (Bug#9154). | |
1919 | ||
56cd55c8 EZ |
1920 | 2011-09-18 Eli Zaretskii <eliz@gnu.org> |
1921 | ||
1922 | * xdisp.c (display_line): Record maximum and minimum buffer | |
1923 | positions even if no glyphs were produced (e.g., by a zero-width | |
1924 | stretch). Fixes bug#9530 on a TTY. Under word-wrap, don't record | |
1925 | buffer positions that will be removed from the glyph row because | |
1926 | they don't fit. | |
c02dcedf EZ |
1927 | (produce_stretch_glyph): Fix a bug in :align-to on a TTY when the |
1928 | column is beyond frame width: don't subtract 1 "pixel" when | |
1929 | computing width of the stretch. | |
3e62b7e0 EZ |
1930 | (reseat_at_next_visible_line_start): Undo the change made on |
1931 | 2011-09-17 that saved paragraph information and restored it after | |
1932 | the call to `reseat'. (Bug#9545) | |
56cd55c8 | 1933 | |
5ed99d36 | 1934 | 2011-09-18 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
3390454c YM |
1935 | |
1936 | * xdisp.c (expose_window): Save original value of phys_cursor_on_p | |
1937 | and turn window cursor on if cleared (Bug#9415). | |
1938 | ||
5ed99d36 | 1939 | 2011-09-18 Andreas Schwab <schwab@linux-m68k.org> |
edb7b4dc AS |
1940 | |
1941 | * search.c (boyer_moore): Take unibyte characters from pattern | |
1942 | literally. (Bug#9458) | |
1943 | ||
9bade7b2 EZ |
1944 | 2011-09-18 Eli Zaretskii <eliz@gnu.org> |
1945 | ||
1946 | * xdisp.c (reseat_at_next_visible_line_start): Fix last change. | |
1947 | ||
e5e9d610 PE |
1948 | 2011-09-18 Paul Eggert <eggert@cs.ucla.edu> |
1949 | ||
87e4427a PE |
1950 | Fix minor problem found by static checking. |
1951 | * xdisp.c (reseat_at_next_visible_line_start): Mark locals as | |
1952 | initialized, to pacify gcc -Wuninitialized. | |
1953 | ||
e5e9d610 PE |
1954 | * fileio.c: Report proper errno when syscall falls. |
1955 | (Finsert_file_contents): Save and restore errno, | |
1956 | so that report_file_error outputs the correct diagnostic. | |
1957 | (Fwrite_region) [CLASH_DETECTION]: Likewise. | |
1958 | ||
a1674f0b EZ |
1959 | 2011-09-18 Eli Zaretskii <eliz@gnu.org> |
1960 | ||
1961 | * .gdbinit (pgx): Fix references to fields of `struct glyph'. | |
1962 | ||
fbfb6dd4 EZ |
1963 | 2011-09-17 Eli Zaretskii <eliz@gnu.org> |
1964 | ||
1965 | * xdisp.c (produce_stretch_glyph): Another fix for changes made on | |
1966 | 2011-08-30T17:32:44Z!eliz@gnu.org. (Bug#9530) | |
1967 | ||
bb187662 EZ |
1968 | 2011-09-17 Eli Zaretskii <eliz@gnu.org> |
1969 | ||
1137e8b8 | 1970 | * xdisp.c (reseat_at_next_visible_line_start): Keep information |
6b02f655 | 1971 | about the current paragraph and restore it after the call to reseat. |
1137e8b8 EZ |
1972 | |
1973 | * bidi.c (MAX_PARAGRAPH_SEARCH): New macro. | |
1974 | (bidi_find_paragraph_start): Search back for paragraph beginning | |
1975 | at most MAX_PARAGRAPH_SEARCH lines; if not found, return BEGV_BYTE. | |
1976 | (bidi_move_to_visually_next): Only trigger paragraph-related | |
1977 | computations when the last character is a newline or at EOB, not | |
1978 | just any NEUTRAL_B. (Bug#9470) | |
1979 | ||
bb187662 EZ |
1980 | * xdisp.c (set_cursor_from_row): Don't invoke special treatment of |
1981 | truncated lines if point is covered by a display string. (Bug#9524) | |
1982 | ||
2e621251 PE |
1983 | 2011-09-16 Paul Eggert <eggert@cs.ucla.edu> |
1984 | ||
1985 | * xselect.c: Relax test for outgoing X longs (Bug#9498). | |
1986 | (cons_to_x_long): New function. | |
1987 | (lisp_data_to_selection_data): Use it. Correct the test for | |
1988 | short-versus-long data; it was negated. Break out of vector | |
1989 | loop, for efficiency, when a long datum is discovered. | |
1990 | ||
91a15bc6 SM |
1991 | 2011-09-16 Stefan Monnier <monnier@iro.umontreal.ca> |
1992 | ||
1993 | * eval.c (Fquote): Document its non-consing behavior (bug#9482). | |
1994 | ||
b41c3a35 EZ |
1995 | 2011-09-16 Eli Zaretskii <eliz@gnu.org> |
1996 | ||
1997 | * image.c (tiff_handler): Work around a bug in MinGW GCC 3.x (see | |
1998 | GCC PR/17406) by declaring this function with external scope. | |
1999 | ||
7812ba2d PE |
2000 | 2011-09-15 Paul Eggert <eggert@cs.ucla.edu> |
2001 | ||
2002 | * editfns.c (Fformat): Fix bug in text-property fix (Bug#9514). | |
2003 | Don't mishandle (length (format "%%")) and (format "%4000s%%" ""). | |
2004 | ||
cf7edc2a AS |
2005 | 2011-09-15 Andreas Schwab <schwab@linux-m68k.org> |
2006 | ||
2007 | * editfns.c (Fformat): Correctly handle text properties on "%%". | |
2008 | ||
bd01620e EZ |
2009 | 2011-09-15 Eli Zaretskii <eliz@gnu.org> |
2010 | ||
2011 | * xterm.c (x_draw_composite_glyph_string_foreground): | |
2012 | * w32term.c (x_draw_composite_glyph_string_foreground): | |
2013 | * term.c (encode_terminal_code): | |
2014 | * composite.c (composition_update_it, get_composition_id): | |
2015 | * xdisp.c (get_next_display_element) | |
2016 | (fill_composite_glyph_string): Add comments about special meaning | |
2017 | of TAB characters in a composition. | |
2018 | ||
a02719a3 PE |
2019 | 2011-09-15 Paul Eggert <eggert@cs.ucla.edu> |
2020 | ||
2021 | * editfns.c (Fformat): Fix off-by-1 bug for "%%b" (Bug#9514). | |
4c122725 PE |
2022 | This occurs when processing a multibyte format. |
2023 | Problem reported by Wolfgang Jenker. | |
a02719a3 | 2024 | |
72589a3c JB |
2025 | 2011-09-15 Johan Bockgård <bojohan@gnu.org> |
2026 | ||
2027 | * xdisp.c (try_cursor_movement): Only check for exact match if | |
2028 | cursor hpos found by set_cursor_from_row is valid. (Bug#9495) | |
2029 | ||
1c14176c PE |
2030 | 2011-09-14 Paul Eggert <eggert@cs.ucla.edu> |
2031 | ||
2032 | Remove unused external symbols. | |
2033 | * dispextern.h (calc_pixel_width_or_height): Remove decl. | |
2034 | * xdisp.c (calc_pixel_width_or_height): Now static. | |
2035 | * doprnt.c (exprintf) [! (HAVE_X_WINDOWS && USE_X_TOOLKIT)]: Remove. | |
2036 | * indent.c (check_display_width): | |
2037 | * w32term.c: Fix comment to match code. | |
2038 | * xterm.c, xterm.h (x_catching_errors): Remove. | |
2039 | ||
d2eea5b5 PE |
2040 | 2011-09-14 Paul Eggert <eggert@cs.ucla.edu> |
2041 | ||
2042 | * xselect.c: Use signed conversions more consistently (Bug#9498). | |
2043 | (selection_data_to_lisp_data): Assume incoming selection data are | |
2044 | signed integers, not unsigned. This is to be consistent with | |
2045 | outgoing selection data, which was modified to use signed integers | |
2046 | in as part of the fix to Bug#9196 in response to Jan D.'s comment | |
2047 | in <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9196#32> that X11 | |
2048 | expects long, not unsigned long. | |
2049 | ||
46888499 EZ |
2050 | 2011-09-14 Eli Zaretskii <eliz@gnu.org> |
2051 | ||
2052 | * xdisp.c (try_window_reusing_current_matrix): Fix incorrect | |
2053 | computation of loop end. Reported by Johan Bockgård | |
2054 | <bojohan@gnu.org>. | |
2055 | ||
ef8ef9fb CY |
2056 | 2011-09-13 Chong Yidong <cyd@stupidchicken.com> |
2057 | ||
2058 | * frame.c (Fother_visible_frames_p): Function deleted. | |
2059 | ||
fa819fed EZ |
2060 | 2011-09-12 Eli Zaretskii <eliz@gnu.org> |
2061 | ||
2062 | * indent.c (compute_motion): Process display vector front to back | |
2063 | rather than the other way around. (Bug#2496) | |
2064 | ||
2ba8e008 SM |
2065 | 2011-09-12 Stefan Monnier <monnier@iro.umontreal.ca> |
2066 | ||
2067 | * fileio.c (Finsert_file_contents): Don't assume beg_offset is 0. | |
2068 | ||
20f53c69 CY |
2069 | 2011-09-11 Chong Yidong <cyd@stupidchicken.com> |
2070 | ||
2071 | * minibuf.c (Fread_from_minibuffer): Doc fix. | |
2072 | ||
d562d7a4 EZ |
2073 | 2011-09-11 Eli Zaretskii <eliz@gnu.org> |
2074 | ||
2075 | * xdisp.c (produce_stretch_glyph): Fix a typo made in changes from | |
2076 | 2011-08-30T17:32:44Z!eliz@gnu.org. (Bug#9475) | |
2077 | ||
1c4d7f3d LMI |
2078 | 2011-09-11 Lars Magne Ingebrigtsen <larsi@gnus.org> |
2079 | ||
2080 | * fileio.c (Fvisited_file_modtime): Document `(-1 65535)' as a | |
2081 | value for non-existent files. | |
2082 | ||
b885bf36 EZ |
2083 | 2011-09-11 Eli Zaretskii <eliz@gnu.org> |
2084 | ||
2085 | * fileio.c (Finsert_file_contents): If the file cannot be opened, | |
2086 | set its "size" to -1. This will set the modtime_size field of | |
2087 | the corresponding buffer to -1, which is what | |
2088 | verify-visited-file-modtime expects for files that do not exist. | |
2089 | (Bug#9139) | |
2090 | ||
6612f0bf PE |
2091 | 2011-09-11 Paul Eggert <eggert@cs.ucla.edu> |
2092 | ||
2093 | * keymap.h (KEY_DESCRIPTION_SIZE, push_key_description): Move decls | |
2094 | here ... | |
2095 | * lisp.h: ... from here. push_key_description is no longer | |
2096 | defined in keyboard.c, so its declaration should not be in | |
2097 | lisp.h's "Defined in keyboard.c" section, and KEY_DESCRIPTION_SIZE | |
2098 | logically belongs with push_key_description. | |
2099 | ||
dfb3f755 PE |
2100 | 2011-09-10 Paul Eggert <eggert@cs.ucla.edu> |
2101 | ||
2102 | * buffer.h: Include <sys/types.h> instead of <time.h>. | |
2103 | Otherwise, off_t wasn't defined on FreeBSD 9.0-BETA2 i386. | |
2104 | Problem reported by Herbert J. Skuhra. | |
2105 | ||
3134906c LMI |
2106 | 2011-09-10 Lars Magne Ingebrigtsen <larsi@gnus.org> |
2107 | ||
2108 | * xml.c (parse_region): Make the parsing work for | |
2109 | non-comment-starting XML files again (bug#9144). | |
2110 | ||
8d903f4e AS |
2111 | 2011-09-10 Andreas Schwab <schwab@linux-m68k.org> |
2112 | ||
2113 | * image.c (gif_load): Fix calculation of bottom and right corner. | |
2114 | (Bug#9468) | |
2115 | ||
80ad64f4 EZ |
2116 | 2011-09-10 Eli Zaretskii <eliz@gnu.org> |
2117 | ||
2118 | * xdisp.c (MAX_DISP_SCAN): Decrease to 250. Prevents sluggish | |
2119 | redisplay in small windows. | |
2120 | ||
208a048d EZ |
2121 | 2011-09-09 Eli Zaretskii <eliz@gnu.org> |
2122 | ||
2123 | * frame.c (x_report_frame_params): Cast to avoid compiler warnings. | |
2124 | ||
9b1c252e MR |
2125 | 2011-09-08 Martin Rudalics <rudalics@gmx.at> |
2126 | ||
2127 | * window.c (Fset_window_prev_buffers, Fset_window_next_buffers): | |
2128 | Operate on live windows only. | |
2129 | ||
2949f33b JB |
2130 | 2011-09-08 Juanma Barranquero <lekktu@gmail.com> |
2131 | ||
2132 | * emacs.c (my_heap_start): #ifdef to avoid warnings when unused. | |
2133 | ||
e08dcafd EZ |
2134 | 2011-09-07 Eli Zaretskii <eliz@gnu.org> |
2135 | ||
2136 | * xdisp.c (move_it_in_display_line_to): Call RESTORE_IT on ppos_it | |
2137 | only under bidi iteration. | |
2138 | ||
115b96bd JD |
2139 | 2011-09-07 Jan Djärv <jan.h.d@swipnet.se> |
2140 | ||
2141 | * gtkutil.c (xg_make_tool_item): Insert comment about eventbox. | |
2142 | ||
c8199d0f PE |
2143 | 2011-09-06 Paul Eggert <eggert@cs.ucla.edu> |
2144 | ||
2145 | isnan: Fix porting problem to Solaris 10 with bundled gcc. | |
2146 | Without this fix, the command to link temacs failed due to an | |
2147 | undefined symbol __builtin_isnan. This is because | |
2148 | /usr/include/iso/math_c99.h #defines isnan(x) to | |
2149 | __builtin_isnan(x), but the bundled gcc, which identifies itself | |
2150 | as gcc 3.4.3 (csl-sol210-3_4-branch+sol_rpath), does not have | |
2151 | a __builtin_isnan. | |
2152 | * floatfns.c (isnan): #undef, and then #define to a clone of | |
2153 | what's in data.c. | |
2154 | (Fisnan): Always define, since it's always available now. | |
2155 | (syms_of_floatfns): Always define isnan at the Lisp level. | |
2156 | ||
e39b275c | 2157 | 2011-09-06 Paul Eggert <eggert@cs.ucla.edu> |
1c262cae PE |
2158 | |
2159 | * Makefile.in (gl-stamp): move-if-change now in build-aux (Bug#9169). | |
2160 | ||
b2db44d9 | 2161 | 2011-09-06 Paul Eggert <eggert@cs.ucla.edu> |
728f8f0a | 2162 | |
f4af5137 | 2163 | * fileio.c: Fix bugs with large file offsets (Bug#9428). |
728f8f0a PE |
2164 | The previous code assumed that file offsets (off_t values) fit in |
2165 | EMACS_INT variables, which is not true on typical 32-bit hosts. | |
2166 | The code messed up by falsely reporting buffer overflow in cases | |
2167 | such as (insert-file-contents "big" nil 1 2) into an empty buffer | |
2168 | when "big" contains more than 2**29 bytes, even though this | |
2169 | inserts just one byte and does not overflow the buffer. | |
2170 | (Finsert_file_contents): Store file offsets as off_t | |
2171 | values, not as EMACS_INT values. Check for overflow when | |
2172 | converting between EMACS_INT and off_t. When checking for | |
2173 | buffer overflow or for overlap, take the offsets into account. | |
2174 | Don't use EMACS_INT for small values where int suffices. | |
2175 | When checking for overlap, fix a typo: ZV was used where | |
2176 | ZV_BYTE was intended. | |
2177 | (Fwrite_region): Don't assume off_t fits into 'long'. | |
2178 | * buffer.h (struct buffer.modtime_size): Now off_t, not EMACS_INT. | |
2179 | ||
ecfc0a49 MA |
2180 | 2011-09-05 Michael Albinus <michael.albinus@gmx.de> |
2181 | ||
2182 | * dbusbind.c (xd_signature_cat): Rename from signature_cat. | |
2183 | ||
6511acf2 | 2184 | 2011-09-04 Paul Eggert <eggert@cs.ucla.edu> |
61bfeeb7 | 2185 | |
0999621a | 2186 | sprintf-related integer and memory overflow issues (Bug#9412). |
62f19c19 PE |
2187 | |
2188 | * doprnt.c (doprnt): Support printing ptrdiff_t and intmax_t values. | |
8666506e | 2189 | (esprintf, exprintf, evxprintf): New functions. |
62f19c19 | 2190 | * keyboard.c (command_loop_level): Now EMACS_INT, not int. |
6b02f655 | 2191 | (cmd_error): Kbd macro iterations count is now EMACS_INT, not int. |
62f19c19 PE |
2192 | (modify_event_symbol): Do not assume that the length of |
2193 | name_alist_or_stem is safe to alloca and fits in int. | |
2194 | (Fexecute_extended_command): Likewise for function name and binding. | |
2195 | (Frecursion_depth): Wrap around reliably on integer overflow. | |
2196 | * keymap.c (push_key_description): First arg is now EMACS_INT, not int, | |
2197 | since some callers pass EMACS_INT values. | |
2198 | (Fsingle_key_description): Don't crash if symbol name contains more | |
2199 | than MAX_ALLOCA bytes. | |
2200 | * minibuf.c (minibuf_level): Now EMACS_INT, not int. | |
2201 | (get_minibuffer): Arg is now EMACS_INT, not int. | |
2202 | * lisp.h (get_minibuffer, push_key_description): Reflect API changes. | |
8666506e | 2203 | (esprintf, exprintf, evxprintf): New decls. |
62f19c19 PE |
2204 | * window.h (command_loop_level, minibuf_level): Reflect API changes. |
2205 | ||
2be7d702 PE |
2206 | * dbusbind.c (signature_cat): New function. |
2207 | (xd_signature, Fdbus_register_signal): | |
2ea16b89 PE |
2208 | Do not overrun buffer; instead, report string overflow. |
2209 | ||
9d1df220 PE |
2210 | * dispnew.c (add_window_display_history): Don't overrun buffer. |
2211 | Truncate instead; this is OK since it's just a log. | |
2212 | ||
33ef5c64 PE |
2213 | * editfns.c (Fcurrent_time_zone): Don't overrun buffer |
2214 | even if the time zone offset is outlandishly large. | |
2215 | Don't mishandle offset == INT_MIN. | |
2216 | ||
66c6fdd5 PE |
2217 | * emacs.c (main) [NS_IMPL_COCOA]: Don't overrun buffer |
2218 | when creating daemon; the previous buffer-overflow check was incorrect. | |
2219 | ||
d749b01b PE |
2220 | * eval.c (verror): Simplify by rewriting in terms of evxprintf, |
2221 | which has the guts of the old verror function. | |
2222 | ||
b5cd1905 PE |
2223 | * filelock.c (lock_file_1, lock_file): Don't blindly alloca long name; |
2224 | use SAFE_ALLOCA instead. Use esprintf to avoid int-overflow issues. | |
2225 | ||
6e1a67fb PE |
2226 | * font.c: Include <float.h>, for DBL_MAX_10_EXP. |
2227 | (font_unparse_xlfd): Don't blindly alloca long strings. | |
c21721cc | 2228 | Don't assume XINT result fits in int, or that XFLOAT_DATA * 10 |
8666506e | 2229 | fits in int, when using sprintf. Use single snprintf to count |
c21721cc PE |
2230 | length of string rather than counting it via multiple sprintfs; |
2231 | that's simpler and more reliable. | |
c21721cc PE |
2232 | (font_unparse_fcname): Use it to avoid sprintf buffer overrun. |
2233 | (generate_otf_features) [0 && HAVE_LIBOTF]: Use esprintf, not | |
2234 | sprintf, in case result does not fit in int. | |
2235 | ||
c57b67fc PE |
2236 | * fontset.c (num_auto_fontsets): Now printmax_t, not int. |
2237 | (fontset_from_font): Print it. | |
2238 | ||
8a401434 PE |
2239 | * frame.c (tty_frame_count): Now printmax_t, not int. |
2240 | (make_terminal_frame, set_term_frame_name): Print it. | |
2241 | (x_report_frame_params): In X, window IDs are unsigned long, | |
2242 | not signed long, so print them as unsigned. | |
2243 | (validate_x_resource_name): Check for implausibly long names, | |
2244 | and don't assume name length fits in 'int'. | |
2245 | (x_get_resource_string): Don't blindly alloca invocation name; | |
2246 | use SAFE_ALLOCA. Use esprintf, not sprintf, in case result does | |
2247 | not fit in int. | |
2248 | ||
6e1a67fb PE |
2249 | * gtkutil.c: Include <float.h>, for DBL_MAX_10_EXP. |
2250 | (xg_check_special_colors, xg_set_geometry): | |
84722b3d PE |
2251 | Make sprintf buffers a bit bigger, to avoid potential buffer overrun. |
2252 | ||
0df02bf3 PE |
2253 | * lread.c (dir_warning): Don't blindly alloca buffer; use SAFE_ALLOCA. |
2254 | Use esprintf, not sprintf, in case result does not fit in int. | |
2255 | ||
48e30793 PE |
2256 | * macros.c (executing_kbd_macro_iterations): Now EMACS_INT, not int. |
2257 | (Fend_kbd_macro): Don't mishandle MOST_NEGATIVE_FIXNUM by treating | |
2258 | it as a large positive number. | |
2259 | (Fexecute_kbd_macro): Don't assume repeat count fits in int. | |
2260 | * macros.h (executing_kbd_macro_iterations): Now EMACS_INT, not int. | |
2261 | ||
a66ff6d8 PE |
2262 | * nsterm.m ((NSSize)windowWillResize): Use esprintf, not sprintf, |
2263 | in case result does not fit in int. | |
2264 | ||
aca216ff PE |
2265 | * print.c (float_to_string): Detect width overflow more reliably. |
2266 | (print_object): Make sprintf buffer a bit bigger, to avoid potential | |
2267 | buffer overrun. Don't assume list length fits in 'int'. Treat | |
2268 | print length of 0 as 0, not as infinity; to be consistent with other | |
2269 | uses of print length in this function. Don't overflow print length | |
2270 | index. Don't assume hash table size fits in 'long', or that | |
2271 | vectorlike size fits in 'unsigned long'. | |
2272 | ||
31c286f7 PE |
2273 | * process.c (make_process): Use printmax_t, not int, to format |
2274 | process-name gensyms. | |
2275 | ||
55e5faa1 PE |
2276 | * sysdep.c (snprintf) [! HAVE_SNPRINTF]: New function. |
2277 | ||
80f2e268 PE |
2278 | * term.c (produce_glyphless_glyph): Make sprintf buffer a bit bigger |
2279 | to avoid potential buffer overrun. | |
2280 | ||
670741ab PE |
2281 | * xfaces.c (x_update_menu_appearance): Don't overrun buffer |
2282 | if X resource line is longer than 512 bytes. | |
2283 | ||
b7163a50 PE |
2284 | * xfns.c (x_window): Make sprintf buffer a bit bigger |
2285 | to avoid potential buffer overrun. | |
2286 | ||
ae58ff1f PE |
2287 | * xterm.c (x_io_error_quitter): Don't overrun sprintf buffer. |
2288 | ||
c43c8a6a PE |
2289 | * xterm.h (x_check_errors): Add ATTRIBUTE_FORMAT_PRINTF. |
2290 | ||
3f8236f4 PE |
2291 | 2011-09-04 Paul Eggert <eggert@cs.ucla.edu> |
2292 | ||
53e9fe90 | 2293 | Integer overflow fixes for scrolling, etc. |
6511acf2 PE |
2294 | Without these, Emacs silently mishandles large integers sometimes. |
2295 | For example, "C-u 4294967297 M-x recenter" was treated as if | |
53e9fe90 PE |
2296 | it were "C-u 1 M-x recenter" on a typical 64-bit host. |
2297 | ||
6511acf2 PE |
2298 | * xdisp.c (try_window_id): Check Emacs fixnum range before |
2299 | converting to 'int'. | |
806add1d | 2300 | |
6511acf2 | 2301 | * window.c (window_scroll_line_based, Frecenter): |
71f02bc5 PE |
2302 | Check that an Emacs fixnum is in range before assigning it to 'int'. |
2303 | (Frecenter, Fmove_to_window_line): Use EMACS_INT, not int, for | |
2304 | values converted from Emacs fixnums. | |
2305 | (Frecenter): Don't wrap around a line count if it is out of 'int' | |
2306 | range; instead, treat it as an extreme value. | |
2307 | (Fset_window_configuration, compare_window_configurations): | |
2308 | Use ptrdiff_t, not int, for index that might exceed 2 GiB. | |
2309 | ||
6511acf2 PE |
2310 | * search.c (Freplace_match): Use ptrdiff_t, not int, for indexes |
2311 | that can exceed INT_MAX. Check that EMACS_INT value is in range | |
2312 | before assigning it to the (possibly-narrower) index. | |
a0efffc8 PE |
2313 | (match_limit): Don't assume that a fixnum can fit in 'int'. |
2314 | ||
6511acf2 | 2315 | * print.c (print_object): Use ptrdiff_t, not int, for index that can |
29ebea3b PE |
2316 | exceed INT_MAX. |
2317 | ||
6511acf2 | 2318 | * indent.c (position_indentation): Now takes ptrdiff_t, not int. |
3f8236f4 PE |
2319 | (Fvertical_motion): Don't wrap around LINES values that don't fit |
2320 | in 'int'. Instead, treat them as extreme values. This is good | |
2321 | enough for windows, which can't have more than INT_MAX lines anyway. | |
2322 | ||
fcb901a7 LMI |
2323 | 2011-09-03 Lars Magne Ingebrigtsen <larsi@gnus.org> |
2324 | ||
0f2f6b6d LMI |
2325 | * Require libxml/parser.h to avoid compilation warning. |
2326 | ||
fcb901a7 LMI |
2327 | * emacs.c (shut_down_emacs): Call xmlCleanupParser on shutdown. |
2328 | ||
2329 | * xml.c (parse_region): Don't call xmlCleanupParser after parsing, | |
2330 | since this reportedly can destroy thread storage. | |
2331 | ||
6e20a0d4 CY |
2332 | 2011-08-30 Chong Yidong <cyd@stupidchicken.com> |
2333 | ||
2334 | * syntax.c (find_defun_start): Update all cache variables if | |
2335 | exiting early (Bug#9401). | |
2336 | ||
148ae00e EZ |
2337 | 2011-08-30 Eli Zaretskii <eliz@gnu.org> |
2338 | ||
f6cfbd8f EZ |
2339 | * image.c (x_bitmap_pixmap): Cast to int to avoid compiler warnings. |
2340 | ||
148ae00e EZ |
2341 | * xdisp.c (produce_stretch_glyph): No longer static, compiled also |
2342 | when HAVE_WINDOW_SYSTEM is not defined. Support both GUI and TTY | |
2343 | frames. Call tty_append_glyph in the TTY case. (Bug#9402) | |
2344 | ||
2345 | * term.c (tty_append_glyph): New function. | |
2346 | (produce_stretch_glyph): Static function and its prototype deleted. | |
2347 | ||
a66cfb1c SM |
2348 | * dispextern.h (produce_stretch_glyph, tty_append_glyph): |
2349 | Add prototypes. | |
148ae00e | 2350 | |
c4a07a4c PE |
2351 | 2011-08-29 Paul Eggert <eggert@cs.ucla.edu> |
2352 | ||
2353 | * image.c (parse_image_spec): Check for nonnegative, not for positive, | |
2354 | when checking :margin (Bug#9390). | |
2355 | (IMAGE_NON_NEGATIVE_INTEGER_VALUE_OR_PAIR): | |
a66cfb1c | 2356 | Rename from IMAGE_POSITIVE_INTEGER_VALUE_OR_PAIR, |
c4a07a4c PE |
2357 | so that the name doesn't mislead. All uses changed. |
2358 | ||
6bc8cd65 JB |
2359 | 2011-08-28 Johan Bockgård <bojohan@gnu.org> |
2360 | ||
2361 | * term.c (init_tty) [HAVE_GPM]: Move mouse settings after | |
2362 | set_tty_hooks. | |
2363 | ||
dca4927e EZ |
2364 | 2011-08-27 Eli Zaretskii <eliz@gnu.org> |
2365 | ||
2366 | * xdisp.c (move_it_to): Don't bail out early when reaching | |
2367 | position beyond to_charpos, if we are scanning backwards. | |
2368 | (move_it_vertically_backward): When DY == 0, make sure we get to | |
2369 | the first character in the line after the newline. | |
2370 | ||
f2cad773 PE |
2371 | 2011-08-27 Paul Eggert <eggert@cs.ucla.edu> |
2372 | ||
2373 | * ccl.c: Improve and simplify overflow checking (Bug#9196). | |
2374 | (ccl_driver): Do not generate an out-of-range pointer. | |
2375 | (Fccl_execute_on_string): Remove unnecessary check for | |
2376 | integer overflow, noted by Stefan Monnier in | |
2377 | <http://lists.gnu.org/archive/html/emacs-devel/2011-08/msg00979.html>. | |
2378 | Remove a FIXME that didn't need fixing. | |
2379 | Simplify the newly-introduced buffer reallocation code. | |
2380 | ||
0cae2cdb JB |
2381 | 2011-08-27 Juanma Barranquero <lekktu@gmail.com> |
2382 | ||
2383 | * makefile.w32-in ($(BLD)/alloc.$(O)): Depend on lib/verify.h. | |
2384 | ||
5fc295a4 | 2385 | 2011-08-26 Paul Eggert <eggert@cs.ucla.edu> |
ddff3151 | 2386 | |
70c60eb2 | 2387 | Integer and memory overflow issues (Bug#9196). |
726e0ab1 | 2388 | |
d31850da PE |
2389 | * doc.c (get_doc_string): Rework so that |
2390 | get_doc_string_buffer_size is the actual buffer size, rather than | |
2391 | being 1 less than the actual buffer size; this makes xpalloc more | |
2392 | convenient. | |
2393 | ||
a69fbedb PE |
2394 | * image.c (x_allocate_bitmap_record, cache_image): |
2395 | * xselect.c (Fx_register_dnd_atom): | |
2396 | Simplify previous changes by using xpalloc. | |
2397 | ||
fe5c5d37 PE |
2398 | * buffer.c (overlay_str_len): Now ptrdiff_t, not EMACS_INT, |
2399 | since either will do and ptrdiff_t is convenient with xpalloc. | |
2400 | ||
0065d054 PE |
2401 | * charset.c (charset_table_size) |
2402 | (struct charset_sort_data.priority): Now ptrdiff_t. | |
2403 | (charset_compare): Don't overflow if priorities differ greatly. | |
2404 | (Fsort_charsets): Don't assume list length fits in int. | |
2405 | Check for size-calculation overflow when allocating sort data. | |
2406 | (syms_of_charset): Allocate an initial charset table that is | |
2407 | just under 64 KiB, to avoid problems with glibc malloc and mmap. | |
2408 | ||
2409 | * cmds.c (internal_self_insert): Check for size-calculation overflow. | |
2410 | ||
2411 | * composite.h (struct composition.glyph_len): Now int, not unsigned. | |
2412 | The actual value is always <= INT_MAX, and leaving it unsigned made | |
2413 | overflow checking harder. | |
2414 | ||
2415 | * dispextern.h (struct glyph_matrix.rows_allocated) | |
2416 | (struct face_cache.size): Now ptrdiff_t, for convenience in use | |
2417 | with xpalloc. The values are still always <= INT_MAX. | |
2418 | ||
2419 | * indent.c (compute_motion): Adjust to region_cache_forward sig change. | |
2420 | ||
2421 | * lisp.h (xnmalloc, xnrealloc, xpalloc): New decls. | |
2422 | (SAFE_NALLOCA): New macro. | |
2423 | ||
2424 | * region-cache.c (struct boundary.pos, find_cache_boundary) | |
2425 | (move_cache_gap, insert_cache_boundary, delete_cache_boundaries) | |
2426 | (set_cache_region, invalidate_region_cache) | |
2427 | (revalidate_region_cache, know_region_cache, region_cache_forward) | |
2428 | (region_cache_backward, pp_cache): | |
2429 | Use ptrdiff_t, not EMACS_INT, since either will do. This is needed | |
2430 | so that ptrdiff_t * can be passed to xpalloc. | |
2431 | (struct region_cache): Similarly, for gap_start, gap_len, cache_len, | |
2432 | beg_unchanged, end_unchanged, buffer_beg, buffer_end members. | |
2433 | (pp_cache): Don't assume cache_len fits in int. | |
2434 | * region-cache.h: Adjust extern decls to match. | |
2435 | ||
2436 | * search.c (scan_buffer, Freplace_match): Use ptrdiff_t, not | |
2437 | EMACS_INT, since either will do, for xpalloc. | |
2438 | ||
2439 | * alloc.c: Include verify.h, and check that int fits in ptrdiff_t. | |
2440 | (xnmalloc, xnrealloc, xpalloc): New functions. | |
2441 | ||
726e0ab1 PE |
2442 | * bidi.c (bidi_shelve_header_size): New constant. |
2443 | (bidi_cache_ensure_space, bidi_shelve_cache): Use it. | |
2444 | (bidi_cache_ensure_space): Avoid integer overflow when allocating. | |
2445 | ||
51f30bc5 | 2446 | * bidi.c (bidi_cache_shrink): |
726e0ab1 PE |
2447 | * buffer.c (overlays_at, overlays_in, record_overlay_string) |
2448 | (overlay_strings): | |
2449 | Don't update size of array until after memory allocation succeeds, | |
2450 | because xmalloc/xrealloc may not return. | |
0065d054 PE |
2451 | (struct sortstrlist.bytes): Now ptrdiff_t, as EMACS_INT doesn't help |
2452 | now that we have proper integer overflow checking. | |
2453 | (record_overlay_string, overlay_strings): Catch overflows when | |
2454 | calculating size of overlay_str_buf. | |
726e0ab1 | 2455 | |
0065d054 PE |
2456 | * callproc.c (Fcall_process): Check for size overflow when |
2457 | calculating size of args2. | |
2458 | (child_setup): Avoid overflow by using size_t rather than ptrdiff_t. | |
2459 | Normally we prefer signed values, but sticking with ptrdiff_t would | |
2460 | require adding more-complicated checks. | |
726e0ab1 PE |
2461 | |
2462 | * ccl.c (Fccl_execute_on_string): Check for memory overflow. | |
2463 | Use ptrdiff_t rather than EMACS_INT where ptrdiff_t will do. | |
2464 | Redo buffer-overflow calculations to avoid integer overflow. | |
0065d054 | 2465 | Add a FIXME comment where memory seems to be over-allocated. |
726e0ab1 PE |
2466 | |
2467 | * character.c (Fstring): Check for size-calculation overflow. | |
2468 | ||
2469 | * coding.c (produce_chars): Redo buffer-overflow calculations to avoid | |
2470 | unnecessary integer overflow. Check for size overflow. | |
2471 | (encode_coding_object): Don't update size until xmalloc succeeds. | |
2472 | ||
2473 | * composite.c (get_composition_id): Check for overflow in glyph | |
2474 | length calculations. | |
2475 | ||
2476 | Integer and memory overflow fixes for display code. | |
2477 | * dispextern.h (struct glyph_pool.nglyphs): Now ptrdiff_t, not int. | |
2478 | * dispnew.c (adjust_glyph_matrix, realloc_glyph_pool) | |
2479 | (scrolling_window): Check for overflow in size calculations. | |
2480 | (line_draw_cost, realloc_glyph_pool, add_row_entry): | |
2481 | Don't assume glyph table len fits in int. | |
2482 | (struct row_entry.bucket, row_entry_pool_size, row_entry_idx) | |
2483 | (row_table_size): Now ptrdiff_t, not int. | |
2484 | (scrolling_window): Avoid overflow in size calculations. | |
2485 | Don't update size until allocation succeeds. | |
2486 | * fns.c (concat): Check for overflow in size calculations. | |
2487 | (next_almost_prime): Verify NEXT_ALMOST_PRIME_LIMIT. | |
2488 | * lisp.h (RANGED_INTEGERP, TYPE_RANGED_INTEGERP): New macros. | |
2489 | (NEXT_ALMOST_PRIME_LIMIT): New constant. | |
2490 | ||
2491 | * doc.c (get_doc_string_buffer_size): Now ptrdiff_t, not int. | |
2492 | (get_doc_string): Check for size calculation overflow. | |
2493 | Don't update size until allocation succeeds. | |
2494 | (get_doc_string, Fsubstitute_command_keys): Use ptrdiff_t, not | |
2495 | EMACS_INT, where ptrdiff_t will do. | |
2496 | (Fsubstitute_command_keys): Check for string overflow. | |
2497 | ||
2498 | * editfns.c (set_time_zone_rule): Don't assume environment length | |
2499 | fits in int. | |
2500 | (message_length): Now ptrdiff_t, not int. | |
2501 | (Fmessage_box): Don't update size until allocation succeeds. | |
2502 | Don't assume message length fits in int. | |
2503 | (Fformat): Use ptrdiff_t, not EMACS_INT, where ptrdiff_t will do. | |
2504 | ||
0065d054 PE |
2505 | * emacs.c (main): Do not reallocate argv, since there is a null at |
2506 | the end that can be overwritten, and this way there's no need to | |
2507 | worry about size-calculation overflow. | |
2508 | (sort_args): Check for size-calculation overflow. | |
726e0ab1 PE |
2509 | |
2510 | * eval.c (init_eval_once, grow_specpdl): Don't update size until | |
2511 | alloc succeeds. | |
2512 | (call_debugger, grow_specpdl): Redo calculations to avoid overflow. | |
2513 | ||
2514 | * frame.c (set_menu_bar_lines, x_set_frame_parameters) | |
2515 | (x_set_scroll_bar_width, x_figure_window_size): | |
2516 | Check for integer overflow. | |
2517 | (x_set_alpha): Do not assume XINT fits in int. | |
2518 | ||
2519 | * frame.h (struct frame): Use int, not EMACS_INT, where int works. | |
2520 | This is for the members text_lines, text_cols, total_lines, total_cols, | |
2521 | where the system imposes an 'int' limit. | |
2522 | ||
2523 | * fringe.c (Fdefine_fringe_bitmap): | |
2524 | Don't update size until alloc works. | |
2525 | ||
2526 | * ftfont.c (ftfont_get_open_type_spec, setup_otf_gstring) | |
2527 | (ftfont_shape_by_flt): Check for integer overflow in size calculations. | |
2528 | ||
2529 | * gtkutil.c (get_utf8_string, xg_store_widget_in_map): | |
2530 | Check for size-calculation overflow. | |
2531 | (get_utf8_string): Use ptrdiff_t, not size_t, where either will | |
2532 | do, as we prefer signed integers. | |
2533 | (id_to_widget.max_size, id_to_widget.used) | |
2534 | (xg_store_widget_in_map, xg_remove_widget_from_map) | |
2535 | (xg_get_widget_from_map, xg_get_scroll_id_for_window) | |
2536 | (xg_remove_scroll_bar, xg_update_scrollbar_pos): | |
2537 | Use and return ptrdiff_t, not int. | |
2538 | (xg_gtk_scroll_destroy): Don't assume ptrdiff_t fits in int. | |
2539 | * gtkutil.h: Change prototypes to match the above. | |
2540 | ||
2541 | * image.c (RANGED_INTEGERP, TYPE_RANGED_INTEGERP): Remove; these | |
2542 | are duplicate now that they've been promoted to lisp.h. | |
2543 | (x_allocate_bitmap_record, x_alloc_image_color) | |
2544 | (make_image_cache, cache_image, xpm_load): | |
2545 | Don't update size until alloc is done. | |
2546 | (xpm_load, lookup_rgb_color, lookup_pixel_color, x_to_xcolors) | |
2547 | (x_detect_edges): | |
3256efce | 2548 | Check for size calculation overflow. |
726e0ab1 PE |
2549 | (ct_colors_allocated_max): New constant. |
2550 | (x_to_xcolors, x_detect_edges): Reorder multiplicands to avoid | |
2551 | overflow. | |
3256efce | 2552 | |
726e0ab1 PE |
2553 | * keyboard.c (read_char, menu_bar_items, tool_bar_items) |
2554 | (read_char_x_menu_prompt, read_char_minibuf_menu_width) | |
2555 | (read_char_minibuf_menu_prompt, follow_key, read_key_sequence): | |
2556 | Use ptrdiff_t, not int, to count maps. | |
2557 | (read_char_minibuf_menu_prompt): Check for overflow in size | |
a66cfb1c SM |
2558 | calculations. Don't update size until allocation succeeds. |
2559 | Redo calculations to avoid overflow. | |
726e0ab1 PE |
2560 | * keyboard.h: Change prototypes to match the above. |
2561 | ||
2562 | * keymap.c (cmm_size, current_minor_maps): Use ptrdiff_t, not int, | |
2563 | to count maps. | |
2564 | (current_minor_maps): Check for size calculation overflow. | |
2565 | * keymap.h: Change prototypes to match the above. | |
2566 | ||
2567 | * lread.c (read1, init_obarray): Don't update size until alloc done. | |
2568 | ||
2569 | * macros.c (Fstart_kbd_macro): Don't update size until alloc done. | |
2570 | (store_kbd_macro_char): Reorder multiplicands to avoid overflow. | |
2571 | ||
726e0ab1 PE |
2572 | * nsterm.h (struct ns_color_table.size, struct ns_color_table.avail): |
2573 | Now ptrdiff_t, not int. | |
2574 | * nsterm.m (ns_index_color): Use ptrdiff_t, not int, for table indexes. | |
2575 | (ns_draw_fringe_bitmap): Rewrite to avoid overflow. | |
2576 | ||
2577 | * process.c (Fnetwork_interface_list): Check for overflow | |
2578 | in size calculation. | |
2579 | ||
2580 | * region-cache.c (move_cache_gap): Check for size calculation overflow. | |
2581 | ||
2582 | * scroll.c (do_line_insertion_deletion_costs): Check for size calc | |
2583 | overflow. Don't bother calling xmalloc when xrealloc will do. | |
2584 | ||
2585 | * search.c (Freplace_match): Check for size calculation overflow. | |
2586 | (Fset_match_data): Don't assume list lengths fit in 'int'. | |
2587 | ||
2588 | * sysdep.c (system_process_attributes): Use ptrdiff_t, not int, | |
2589 | for command line length. Do not attempt to address one before the | |
2590 | beginning of an array, as that's not portable. | |
2591 | ||
2592 | * term.c (max_frame_lines): Remove; unused. | |
2593 | (encode_terminal_src_size, encode_terminal_dst_size): Now ptrdiff_t, | |
2594 | not int. | |
2595 | (encode_terminal_code, calculate_costs): Check for size | |
2596 | calculation overflow. | |
2597 | (encode_terminal_code): Use ptrdiff_t, not int, to record glyph | |
2598 | table lengths and related sizes. Don't update size until alloc | |
2599 | done. Redo calculations to avoid overflow. | |
2600 | (calculate_costs): Don't bother calling xmalloc when xrealloc will do. | |
2601 | ||
2602 | * termcap.c (tgetent): Use ptrdiff_t, not int, to record results of | |
2603 | subtracting pointers. | |
2604 | (gobble_line): Check for overflow more carefully. Don't update size | |
2605 | until alloc done. | |
2606 | ||
2607 | * tparam.c (tparam1): Use ptrdiff_t, not int, for sizes. | |
2608 | Don't update size until alloc done. | |
2609 | Redo size calculations to avoid overflow. | |
2610 | Check for size calculation overflow. | |
0065d054 | 2611 | (main) [DEBUG]: Fix typo in invoking tparam1. |
726e0ab1 PE |
2612 | |
2613 | * xdisp.c (store_mode_line_noprop_char, x_consider_frame_title): | |
2614 | Use ptrdiff_t, not int, for sizes. | |
2615 | (store_mode_line_noprop_char): Don't update size until alloc done. | |
2616 | ||
0065d054 PE |
2617 | * xfaces.c (lface_id_to_name_size, Finternal_make_lisp_face): |
2618 | Use ptrdiff_t, not int, for sizes. | |
2619 | (Finternal_make_lisp_face, cache_face): | |
2620 | Check for size calculation overflow. | |
2621 | (cache_face): Treat size calculation overflows as if they were | |
2622 | memory exhaustion (the usual treatment), rather than aborting. | |
726e0ab1 PE |
2623 | |
2624 | * xfns.c (x_encode_text, x_set_name_internal) | |
2625 | (Fx_change_window_property): Use ptrdiff_t, not int, to count | |
2626 | sizes, since they can exceed INT_MAX in size. Check for size | |
2627 | calculation overflow. | |
2628 | ||
0065d054 PE |
2629 | * xgselect.c (gfds_size): Now ptrdiff_t, for convenience with xpalloc. |
2630 | (xg_select): Check for size calculation overflow. | |
726e0ab1 PE |
2631 | Don't update size until alloc done. |
2632 | ||
0065d054 | 2633 | * xrdb.c (get_environ_db): Don't assume path length fits in int, |
726e0ab1 | 2634 | as sprintf is limited to int lengths. |
1d526e2f | 2635 | |
252c5ee1 PE |
2636 | * xselect.c (X_LONG_SIZE, X_SHRT_MAX, X_SHRT_MIN, X_LONG_MAX) |
2637 | (X_LONG_MIN): New macros. | |
864d7ce7 PE |
2638 | Use them to make the following changes clearer. |
2639 | (MAX_SELECTION_QUANTUM): Make the other bounds on this value clearer. | |
2640 | This change doesn't affect the value now, but it may help remind | |
2641 | future maintainers not to raise the value too much later. | |
2642 | (SELECTION_QUANTUM): Remove, replacing with ... | |
2643 | (selection_quantum): ... new function, which avoids overflow. | |
2644 | All uses changed. | |
2645 | (struct selection_data.size): Now ptrdiff_t, not int, to avoid | |
2646 | assumption that selection length fits in 'int'. | |
2647 | (x_reply_selection_request, x_handle_selection_request) | |
2648 | (x_get_window_property, receive_incremental_selection) | |
2649 | (x_get_window_property_as_lisp_data, selection_data_to_lisp_data) | |
2650 | (lisp_data_to_selection_data, clean_local_selection_data): | |
2651 | Use ptrdiff_t, not int, to record length of selection. | |
2652 | (x_reply_selection_request, x_get_window_property) | |
2653 | (receive_incremental_selection, x_property_data_to_lisp): | |
2654 | Redo calculations to avoid overflow. | |
2655 | (x_reply_selection_request): When sending hint, ceiling it at | |
252c5ee1 | 2656 | X_LONG_MAX rather than relying on wraparound overflow to send |
864d7ce7 PE |
2657 | something. |
2658 | (x_get_window_property, receive_incremental_selection) | |
2659 | (lisp_data_to_selection_data, x_property_data_to_lisp): | |
2660 | Check for size-calculation overflow. | |
2661 | (x_get_window_property, receive_incremental_selection) | |
2662 | (lisp_data_to_selection_data, Fx_register_dnd_atom): | |
2663 | Don't store size until memory allocation succeeds. | |
2664 | (x_get_window_property): Plug memory leak on memory exhaustion. | |
2665 | Don't double-block input; malloc is safe here. Don't assume 2**34 | |
2666 | - 4 fits in unsigned long. Add an xassert to check | |
2667 | XGetWindowProperty overflow. Be more careful about overflow | |
2668 | calculations, and distinguish size from memory overflow better. | |
2669 | (receive_incremental_selection): When tracing, don't assume | |
2670 | unsigned int is less than INT_MAX. | |
2671 | (x_selection_data_to_lisp_data): Remove unnecessary (and in theory | |
2672 | harmful) conversions of unsigned short to int. | |
2673 | (lisp_data_to_selection_data): Don't assume that integers | |
2674 | in the range -65535 through -1 fit in an X unsigned short. | |
2675 | Don't assume that ULONG_MAX == X_ULONG_MAX. Don't store into | |
2676 | result parameters unless successful. Rely on cons_to_unsigned | |
2677 | to report problems with elements; the old code wasn't right anyway. | |
2678 | (x_check_property_data): Check for int overflow; we cannot use | |
2679 | a wider type due to X limits. | |
2680 | (x_handle_dnd_message): Use unsigned int, to avoid int overflow. | |
2681 | ||
726e0ab1 | 2682 | * xsmfns.c (smc_save_yourself_CB): Check for size calc overflow. |
34db673b | 2683 | |
0065d054 PE |
2684 | * xterm.c (x_color_cells, x_send_scrollbar_event, handle_one_xevent) |
2685 | (x_term_init): Check for size calculation overflow. | |
726e0ab1 PE |
2686 | (x_color_cells): Don't store size until memory allocation succeeds. |
2687 | (handle_one_xevent): Use ptrdiff_t, not int, for byte counts. | |
0065d054 | 2688 | Don't assume alloca size is less than MAX_ALLOCA. |
726e0ab1 PE |
2689 | (x_term_init): Don't assume length fits in int (sprintf is limited |
2690 | to int size). | |
bc18e09d | 2691 | |
ebfa62c0 PE |
2692 | Use ptrdiff_t for composition IDs. |
2693 | * character.c (lisp_string_width): | |
2694 | * composite.c (composition_table_size, n_compositions) | |
2695 | (get_composition_id, composition_gstring_from_id): | |
2696 | * dispextern.h (struct glyph_string.cmp_id, struct composition_it.id): | |
2697 | * xdisp.c (BUILD_COMPOSITE_GLYPH_STRING): | |
2698 | * window.c (Frecenter): | |
2699 | Use ptrdiff_t, not int, for composition IDs. | |
2700 | * composite.c (get_composition_id): Check for integer overflow. | |
2701 | * composite.h: Adjust prototypes to match the above changes. | |
2702 | ||
d3411f89 PE |
2703 | Use ptrdiff_t for hash table indexes. |
2704 | * category.c (hash_get_category_set): | |
2705 | * ccl.c (ccl_driver): | |
2706 | * charset.h (struct charset.hash_index, CHECK_CHARSET_GET_ID): | |
2707 | * coding.c (coding_system_charset_list, detect_coding_system): | |
2708 | * coding.h (struct coding_system.id): | |
2709 | * composite.c (get_composition_id, gstring_lookup_cache): | |
2710 | * fns.c (hash_lookup, hash_put, Fgethash, Fputhash): | |
2711 | * image.c (xpm_get_color_table_h): | |
2712 | * lisp.h (hash_lookup, hash_put): | |
2713 | * minibuf.c (Ftest_completion): | |
2714 | Use ptrdiff_t for hash table indexes, not int (which is too | |
2715 | narrow, on 64-bit hosts) or EMACS_INT (which is too wide, on | |
2716 | 32-bit --with-wide-int hosts). | |
2717 | ||
e097a6fa PE |
2718 | * charset.c (Fdefine_charset_internal): Check for integer overflow. |
2719 | Add a FIXME comment about memory leaks. | |
2720 | (syms_of_charset): Don't assume xmalloc returns. | |
2721 | ||
5637687f PE |
2722 | Don't assume that stated character widths fit in int. |
2723 | * character.c (Fchar_width, c_string_width, lisp_string_width): | |
2724 | * character.h (CHAR_WIDTH): | |
2725 | * indent.c (MULTIBYTE_BYTES_WIDTH): | |
2726 | Use sanitize_char_width to avoid undefined and/or bad behavior | |
2727 | with outlandish widths. | |
a66cfb1c | 2728 | * character.h (sanitize_tab_width): Rename from sanitize_width, |
5637687f PE |
2729 | now that we have two such functions. All uses changed. |
2730 | (sanitize_char_width): New inline function. | |
2731 | ||
a2271ba2 PE |
2732 | Don't assume that tab-width fits in int. |
2733 | * character.h (sanitize_width): New inline function. | |
2734 | (SANE_TAB_WIDTH): New macro. | |
2735 | (ASCII_CHAR_WIDTH): Use it. | |
2736 | * indent.c (sane_tab_width): Remove. All uses replaced by | |
2737 | SANE_TAB_WIDTH (current_buffer). | |
2738 | * xdisp.c (init_iterator): Use SANE_TAB_WIDTH. | |
2739 | ||
18c52557 PE |
2740 | * fileio.c: Integer overflow issues with file modes. |
2741 | (Fset_file_modes, auto_save_1): Don't assume EMACS_INT fits in int. | |
2742 | ||
caeeedc1 PE |
2743 | * charset.c (read_hex): New arg OVERFLOW. All uses changed. |
2744 | Remove unreachable code. | |
2745 | (read_hex, load_charset_map_from_file): Check for integer overflow. | |
2746 | ||
6df6ae42 | 2747 | * xterm.c: Don't go over XClientMessageEvent limit. |
50849c52 PE |
2748 | (scroll_bar_windows_size): Now ptrdiff_t, as we prefer signed. |
2749 | (x_send_scroll_bar_event): Likewise. Check that the size does not | |
2750 | exceed limits imposed by XClientMessageEvent, as well as the usual | |
2751 | ptrdiff_t and size_t limits. | |
2752 | ||
b13995db PE |
2753 | * keyboard.c: Overflow, signedness and related fixes. |
2754 | (make_lispy_movement): Use same integer type in forward decl | |
2755 | that is used in the definition. | |
2756 | (read_key_sequence, keyremap_step): | |
2757 | Change bufsize argument back to int, undoing my 2011-03-30 change. | |
2758 | We prefer signed types, and int is wide enough here. | |
2759 | (parse_tool_bar_item): Don't assume tool_bar_max_label_size is less | |
2760 | than TYPE_MAXIMUM (EMACS_INT) / 2. Don't let the label size grow | |
2761 | larger than STRING_BYTES_BOUND. Use ptrdiff_t for Emacs string | |
2762 | length, not size_t. Use ptrdiff_t for index, not int. | |
2763 | (keyremap_step, read_key_sequence): Redo bufsize check to avoid | |
2764 | possibility of integer overflow. | |
2765 | ||
13464394 PE |
2766 | Overflow, signedness and related fixes for images. |
2767 | ||
2768 | * dispextern.h (struct it.stack[0].u.image.image_id) | |
2769 | (struct_it.image_id, struct image.id, struct image_cache.size) | |
2770 | (struct image_cache.used, struct image_cache.ref_count): | |
2771 | * gtkutil.c (update_frame_tool_bar): | |
2772 | * image.c (x_reference_bitmap, Fimage_size, Fimage_mask_p) | |
2773 | (Fimage_metadata, free_image_cache, clear_image_cache, lookup_image) | |
2774 | (cache_image, mark_image_cache, x_kill_gs_process, Flookup_image): | |
2775 | * nsmenu.m (update_frame_tool_bar): | |
2776 | * xdisp.c (calc_pixel_width_or_height): | |
2777 | * xfns.c (image_cache_refcount): | |
2778 | Image IDs are now ptrdiff_t, not int, to avoid arbitrary limits | |
2779 | on typical 64-bit hosts. | |
2780 | ||
2781 | * image.c (RANGED_INTEGERP, TYPE_RANGED_INTEGERP): New macros. | |
2782 | (x_bitmap_pixmap, x_create_x_image_and_pixmap): | |
2783 | Omit unnecessary casts to int. | |
2784 | (parse_image_spec): Check that integers fall into 'int' range | |
2785 | when the callers expect that. | |
2786 | (image_ascent): Redo ascent calculation to avoid int overflow. | |
2787 | (clear_image_cache): Avoid overflow when sqrt (INT_MAX) < nimages. | |
2788 | (lookup_image): Remove unnecessary tests. | |
2789 | (xbm_image_p): Locals are now of int, not EMACS_INT, | |
2790 | since parse_image_check makes sure they fit into int. | |
2791 | (png_load, gif_load, svg_load_image): | |
2792 | Prefer int to unsigned where either will do. | |
2793 | (tiff_handler): New function, combining the cores of the | |
a66cfb1c SM |
2794 | old tiff_error_handler and tiff_warning_handler. |
2795 | This function is rewritten to use vsnprintf and thereby avoid | |
13464394 PE |
2796 | stack buffer overflows. It uses only the features of vsnprintf |
2797 | that are common to both POSIX and native Microsoft. | |
2798 | (tiff_error_handler, tiff_warning_handler): Use it. | |
2799 | (tiff_load, gif_load, imagemagick_load_image): | |
2800 | Don't assume :index value fits in 'int'. | |
2801 | (gif_load): Omit unnecessary cast to double, and avoid double-rounding. | |
2802 | (imagemagick_load_image): Check that crop parameters fit into | |
2803 | the integer types that MagickCropImage accepts. Don't assume | |
2804 | Vimagemagick_render_type has a nonnegative value. Don't assume | |
2805 | size_t fits in 'long'. | |
2806 | (gs_load): Use printmax_t to print the widest integers possible. | |
2807 | Check for integer overflow when computing image height and width. | |
2808 | ||
c11821d4 EZ |
2809 | 2011-08-26 Eli Zaretskii <eliz@gnu.org> |
2810 | ||
2811 | * xdisp.c (redisplay_window): Don't force window start if point | |
2812 | will be invisible in the resulting window. (Bug#9324) | |
2813 | ||
0c95fcf7 EZ |
2814 | 2011-08-25 Eli Zaretskii <eliz@gnu.org> |
2815 | ||
2816 | * xdisp.c (compute_display_string_pos): Return 2 in DISP_PROP when | |
2817 | the display spec is of the form `(space ...)'. | |
2818 | (handle_display_spec): Return the value returned by | |
2819 | handle_single_display_spec, not just 1 or zero. | |
2820 | (handle_single_display_spec): If the display spec is of the form | |
2821 | `(space ...)', and specifies display in the text area, return 2 | |
2822 | rather than 1. | |
fee65a97 | 2823 | (try_cursor_movement): Check for the need to scroll more |
a66cfb1c SM |
2824 | accurately, and prefer exact match for point under bidi. |
2825 | Don't advance `row' beyond the last row of the window. | |
0c95fcf7 EZ |
2826 | |
2827 | * dispextern.h (struct bidi_it): Rename the disp_prop_p member | |
2828 | into disp_prop; all users changed. | |
2829 | ||
2830 | * bidi.c (bidi_fetch_char): If compute_display_string_pos returns | |
2831 | DISP_PROP = 2, substitute the u+2029 PARAGRAPH SEPARATOR character | |
2832 | for the text covered by the display property. | |
2833 | ||
e4ed06f1 CY |
2834 | 2011-08-25 Chong Yidong <cyd@stupidchicken.com> |
2835 | ||
2836 | * buffer.c (Fbury_buffer_internal): Rename from Funrecord_buffer. | |
2837 | Change return value to nil. | |
2838 | (Frecord_buffer): Delete unused function. | |
2839 | ||
f67cdd7f EZ |
2840 | 2011-08-24 Eli Zaretskii <eliz@gnu.org> |
2841 | ||
5980d4c6 EZ |
2842 | * xdisp.c (Fcurrent_bidi_paragraph_direction): For unibyte |
2843 | buffers, return left-to-right. | |
8610fe8b EZ |
2844 | (set_cursor_from_row): Consider candidate row a win if its glyph |
2845 | represents a newline and point is on that newline. Fixes cursor | |
2846 | positioning on the newline at EOL of R2L text within L2R | |
2847 | paragraph, and vice versa. | |
2848 | (try_cursor_movement): Check continued rows, in addition to | |
2849 | continuation rows. Fixes unwarranted scroll when point enters a | |
2850 | continued line of R2L text within an L2R paragraph, or vice versa. | |
2851 | (cursor_row_p): Consider the case of point being equal to | |
2852 | MATRIX_ROW_END_CHARPOS. Prevents cursor being stuck when moving | |
2853 | from the end of a short line to the beginning of a continued line | |
2854 | of R2L text within L2R paragraph. | |
2855 | (RECORD_MAX_MIN_POS): For max_pos, use IT_CHARPOS even for | |
2856 | composed characters. | |
5980d4c6 | 2857 | |
f67cdd7f EZ |
2858 | * bidi.c (bidi_check_type): Use xassert. |
2859 | (bidi_cache_iterator_state): Update the disp_pos and disp_prop_p | |
2860 | members. | |
2861 | ||
bca633fb EZ |
2862 | 2011-08-23 Eli Zaretskii <eliz@gnu.org> |
2863 | ||
2864 | * bidi.c (bidi_get_type): Abort if we get zero as the bidi type of | |
2865 | a character. | |
2866 | ||
4a5885a7 CY |
2867 | 2011-08-23 Chong Yidong <cyd@stupidchicken.com> |
2868 | ||
2869 | * nsfont.m (ns_otf_to_script): Fix typo. | |
2870 | ||
0902a04e KH |
2871 | 2011-08-22 Kenichi Handa <handa@m17n.org> |
2872 | ||
2873 | * chartab.c (Fset_char_table_extra_slot): Do not inhibit setting a | |
2874 | extra slot even if the purpose is char-code-property-table. | |
2875 | ||
1a2e6670 EZ |
2876 | 2011-08-23 Eli Zaretskii <eliz@gnu.org> |
2877 | ||
8ddde651 EZ |
2878 | * xdisp.c (redisplay_window): When computing centering_position, |
2879 | account for the height of the header line. (Bug#8874) | |
2880 | ||
425cc014 EZ |
2881 | * dispnew.c (buffer_posn_from_coords): Use buf_charpos_to_bytepos |
2882 | instead of CHAR_TO_BYTE. Fixes a crash when a completion | |
2883 | candidate is selected by the mouse, and that candidate has a | |
2884 | composed character under the mouse. | |
2885 | ||
1a2e6670 EZ |
2886 | * xdisp.c (x_produce_glyphs): Set it->nglyphs to 1. Fixes pixel |
2887 | coordinates reported by pos-visible-in-window-p for a composed | |
2888 | character in column zero. | |
2889 | ||
8b76d6f8 SM |
2890 | 2011-08-23 Stefan Monnier <monnier@iro.umontreal.ca> |
2891 | ||
2892 | * cmds.c (Fself_insert_command): Mention post-self-insert-hook. | |
2893 | ||
dac347dd EZ |
2894 | 2011-08-22 Eli Zaretskii <eliz@gnu.org> |
2895 | ||
2896 | * xdisp.c (BUFFER_POS_REACHED_P): If this is a composition, | |
2897 | consider it a hit if to_charpos is anywhere in the range of the | |
2898 | composed buffer positions. | |
2899 | ||
e013fb34 CY |
2900 | 2011-08-22 Chong Yidong <cyd@stupidchicken.com> |
2901 | ||
2902 | * image.c (gif_load): Don't assume that each subimage has the same | |
2903 | dimensions as the base image. Handle disposal method that is | |
2904 | "undefined" by the gif spec (Bug#9335). | |
2905 | ||
bd1ba3e8 CY |
2906 | 2011-08-20 Chong Yidong <cyd@stupidchicken.com> |
2907 | ||
2908 | * eval.c (Fsignal): Handle `debug' symbol in error handler (Bug#9329). | |
024a2d76 | 2909 | (Fcondition_case): Document `debug' symbol in error handler. |
bd1ba3e8 | 2910 | |
54a1215b EZ |
2911 | 2011-08-19 Eli Zaretskii <eliz@gnu.org> |
2912 | ||
823564e5 EZ |
2913 | * xfaces.c (face_at_buffer_position): Avoid repeated evaluation of |
2914 | face ID by FACE_FROM_ID, and avoid a crash when mouse is moved | |
2915 | from an Org mode buffer to a Speedbar frame. | |
2916 | ||
54a1215b EZ |
2917 | * xdisp.c (RECORD_MAX_MIN_POS): If the display element comes from |
2918 | a composition, take its buffer position from IT->cmp_it.charpos. | |
2919 | Fixes cursor positioning at the beginning of a line that begins | |
2920 | with a composed character. | |
2921 | ||
9778ebcc EZ |
2922 | 2011-08-18 Eli Zaretskii <eliz@gnu.org> |
2923 | ||
0be6ee06 EZ |
2924 | * bidi.c (bidi_get_type): If bidi_type_table reports zero as the |
2925 | character bidirectional type, use STRONG_L instead. Fixes crashes | |
2926 | in a buffer produced by `describe-categories'. | |
2927 | ||
9778ebcc EZ |
2928 | * dispextern.h (struct bidi_it): Move disp_pos and disp_prop_p |
2929 | members before the level stack, so they would be saved and | |
2930 | restored when copying iterator state. Fixes incorrect reordering | |
2931 | around TABs covered by display properties. | |
2932 | ||
156bffbe AS |
2933 | 2011-08-18 Andreas Schwab <schwab@linux-m68k.org> |
2934 | ||
6b02f655 | 2935 | * process.c (Fnetwork_interface_list): Correctly determine buffer size. |
156bffbe | 2936 | |
72ad093b CY |
2937 | 2011-08-17 Chong Yidong <cyd@stupidchicken.com> |
2938 | ||
2939 | * eval.c (internal_condition_case, internal_condition_case_1) | |
8b76d6f8 SM |
2940 | (internal_condition_case_2, internal_condition_case_n): |
2941 | Remove unnecessary aborts (Bug#9081). | |
72ad093b | 2942 | |
35774242 EZ |
2943 | 2011-08-17 Eli Zaretskii <eliz@gnu.org> |
2944 | ||
2945 | * lread.c (Fload) [DOS_NT]: If `openp' returns -2, but the file | |
2946 | has no `load' handler, try opening the file locally. (Bug#9311) | |
2947 | ||
db76dd85 KB |
2948 | 2011-08-16 Ken Brown <kbrown@cornell.edu> |
2949 | ||
2950 | * gmalloc.c: Expand comment. | |
2951 | ||
b215eee5 EZ |
2952 | 2011-08-16 Eli Zaretskii <eliz@gnu.org> |
2953 | ||
2954 | * xdisp.c (set_cursor_from_row): Don't accept a previous candidate | |
2955 | if it fails the cursor_row_p test. Fixes cursor positioning at ZV. | |
2956 | ||
a4579d33 KB |
2957 | 2011-08-16 Ken Brown <kbrown@cornell.edu> |
2958 | ||
2959 | Fix memory allocation problems in Cygwin build (Bug#9273). | |
2960 | ||
2961 | * unexcw.c ( __malloc_initialized): Declare external variable. | |
2962 | (fixup_executable): Force the dumped emacs to reinitialize malloc. | |
2963 | ||
8b76d6f8 SM |
2964 | * gmalloc.c [CYGWIN] (bss_sbrk_heapbase, bss_sbrk_heapinfo): |
2965 | New variables. | |
a4579d33 KB |
2966 | (malloc_initialize_1) [CYGWIN]: Prepare for reinitializing the |
2967 | dumped emacs. | |
2968 | (_free_internal_nolock) [CYGWIN]: Ignore requests to free storage | |
2969 | in the static heap. | |
2970 | [CYGWIN] (special_realloc): New function. | |
2971 | (_realloc_internal_nolock) [CYGWIN]: Use the new function on | |
2972 | requests to realloc storage in the static heap. | |
2973 | ||
3ebec551 PE |
2974 | 2011-08-15 Paul Eggert <eggert@cs.ucla.edu> |
2975 | ||
2976 | * bidi.c (bidi_initialize): Remove unused local. | |
2977 | ||
9fd8be00 EZ |
2978 | 2011-08-15 Eli Zaretskii <eliz@gnu.org> |
2979 | ||
6b02f655 SM |
2980 | * bidimirror.h: |
2981 | * biditype.h: Remove file. | |
2982 | * makefile.w32-in ($(BLD)/bidi.$(O)): | |
2983 | * deps.mk (bidi.o): Remove biditype.h and bidimirror.h. | |
474a8465 EZ |
2984 | |
2985 | * dispextern.h: Fix a typo in the comment to bidi_type_t. | |
2986 | ||
2987 | * chartab.c: Improve commentary for the uniprop_table API. | |
2988 | ||
32413314 EZ |
2989 | * bidi.c (bidi_paragraph_init): Support zero value of |
2990 | bidi_ignore_explicit_marks_for_paragraph_level. | |
474a8465 EZ |
2991 | (bidi_initialize): Use uniprop_table instead of including |
2992 | biditype.h and bidimirror.h. | |
32413314 | 2993 | |
9fd8be00 EZ |
2994 | * xdisp.c (move_it_in_display_line_to): Don't reset pixel |
2995 | coordinates of the iterator when restoring from ppos_it. | |
2996 | (Bug#9296) | |
2997 | ||
5cf2b69b KH |
2998 | 2011-08-14 Kenichi Handa <handa@m17n.org> |
2999 | ||
3000 | * process.c (create_process): Call setup_process_coding_systems | |
72ad093b | 3001 | after the pid of the process is set to -1 (Bug#8162). |
5cf2b69b | 3002 | |
daf17d00 EZ |
3003 | 2011-08-14 Eli Zaretskii <eliz@gnu.org> |
3004 | ||
3005 | * xdisp.c (move_it_in_display_line_to): Don't invoke | |
3006 | IT_RESET_X_ASCENT_DESCENT when iterator position was restored from | |
3007 | ppos_it. Fixes vertical cursor motion when line beginning is | |
3008 | covered by an image. (Bug#9296) | |
3009 | ||
08e3161a JD |
3010 | 2011-08-14 Jan Djärv <jan.h.d@swipnet.se> |
3011 | ||
3012 | * nsterm.h (ns_run_ascript): Declare. | |
3013 | (NSAPP_DATA2_RUNASSCRIPT): Define. | |
3014 | ||
3015 | * nsfns.m (as_script, as_result, as_status): New static variables. | |
3016 | (ns_run_ascript): New function. | |
5e617bc2 | 3017 | (Fns_do_applescript): Set variables as_*. Make an NSApplicationDefined |
08e3161a JD |
3018 | event with data2 set to NSAPP_DATA2_RUNASSCRIPT, post it and then start |
3019 | the event loop. Get status from as_status (Bug#7276). | |
3020 | ||
3021 | * nsterm.m (sendEvent): If event is NSApplicationDefined and | |
3022 | data2 is NSAPP_DATA2_RUNASSCRIPT, call ns_run_ascript and then exit | |
3023 | the event loop (Bug#7276). | |
3024 | ||
a3720aa2 AS |
3025 | 2011-08-14 Andreas Schwab <schwab@linux-m68k.org> |
3026 | ||
3027 | * gnutls.c (QCgnutls_bootprop_priority) | |
3028 | (QCgnutls_bootprop_trustfiles, QCgnutls_bootprop_keylist) | |
3029 | (QCgnutls_bootprop_crlfiles, QCgnutls_bootprop_callbacks) | |
3030 | (QCgnutls_bootprop_loglevel, QCgnutls_bootprop_hostname) | |
3031 | (QCgnutls_bootprop_min_prime_bits, QCgnutls_bootprop_verify_flags) | |
3032 | (QCgnutls_bootprop_verify_hostname_error) | |
3033 | (QCgnutls_bootprop_callbacks_verify): Rename from | |
3034 | Qgnutls_bootprop_..., all uses changed. | |
3035 | ||
3036 | * xfaces.c (QCignore_defface): Rename from Qignore_defface, all | |
3037 | uses changed. | |
3038 | ||
0a0d27fb PE |
3039 | 2011-08-14 Paul Eggert <eggert@cs.ucla.edu> |
3040 | ||
19d5c50c PE |
3041 | * xfaces.c (Qframe_set_background_mode): Now static. |
3042 | * dispextern.h (Qframe_set_background_mode): Remove decl. | |
3043 | ||
0a0d27fb PE |
3044 | * process.c (Fnetwork_interface_info): Declare local only if needed. |
3045 | ||
377538cb JD |
3046 | 2011-08-13 Jan Djärv <jan.h.d@swipnet.se> |
3047 | ||
3048 | * process.c: Include ifaddrs.h and net/if_dl.h if available (Bug#8477). | |
3049 | (Fnetwork_interface_list): Allocate in increments of bytes instead | |
3050 | of sizeof (struct ifreq). Iterate over ifconf.ifc_req by counting | |
3051 | bytes (Bug#8477). Count bytes correctly when ifr_addr is a struct | |
3052 | sockaddr. | |
3053 | (struct ifflag_def): notrailers is smart on OSX. | |
3054 | (Fnetwork_interface_info): Handle case when ifr_flags is negative. | |
3055 | Get hardware address with getifaddrs if available. | |
3056 | ||
08fff70c EZ |
3057 | 2011-08-12 Eli Zaretskii <eliz@gnu.org> |
3058 | ||
3059 | * xdisp.c (iterate_out_of_display_property): xassert that | |
3060 | IT->position is set to within IT->object's boundaries. Break from | |
3061 | the loop as soon as EOB is reached; avoids infloops in redisplay | |
8b76d6f8 SM |
3062 | when IT->position is set up wrongly due to some bug. |
3063 | Set IT->current to match the bidi iterator unconditionally. | |
08fff70c EZ |
3064 | (push_display_prop): Allow GET_FROM_STRING as IT->method on |
3065 | entry. Force push_it to save on the stack the current | |
3066 | buffer/string position, to be restored by pop_it. Fix flags in | |
3067 | the iterator structure wrt the object coming from a display | |
3068 | property, as `line-prefix' and `wrap-prefix' are not ``replacing'' | |
3069 | properties. (Bug#9284) | |
3070 | ||
7be1c708 | 3071 | 2011-08-09 Andreas Schwab <schwab@linux-m68k.org> |
aac0c6e3 | 3072 | |
7be1c708 CY |
3073 | * fontset.c (fontset_get_font_group): Add proper type checks. |
3074 | (Bug#9172) | |
aac0c6e3 | 3075 | |
7be1c708 | 3076 | 2011-08-09 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
aac0c6e3 | 3077 | |
7be1c708 CY |
3078 | * unexmacosx.c (print_load_command_name): Add cases LC_FUNCTION_STARTS |
3079 | and LC_VERSION_MIN_MACOSX. | |
3080 | (copy_linkedit_data) [LC_FUNCTION_STARTS]: New function. | |
3081 | (dump_it) [LC_FUNCTION_STARTS]: Use it. | |
aac0c6e3 | 3082 | |
97bb72a6 EZ |
3083 | 2011-08-08 Eli Zaretskii <eliz@gnu.org> |
3084 | ||
3085 | * xdisp.c (forward_to_next_line_start): Allow to use the | |
8b76d6f8 SM |
3086 | no-display-properties-and-no-overlays under bidi display. |
3087 | Set disp_pos in the bidi iterator to avoid searches for display | |
757664a4 | 3088 | properties and overlays. |
97bb72a6 | 3089 | |
d5617611 CY |
3090 | 2011-08-08 Chong Yidong <cyd@stupidchicken.com> |
3091 | ||
37e11a63 CY |
3092 | * editfns.c (Fset_time_zone_rule): Document relationship with the |
3093 | setenv function. | |
3094 | ||
d5617611 CY |
3095 | * ftfont.c (ftfont_pattern_entity): Copy the extras argument to |
3096 | the font entity extracted from the cache (Bug#8109). | |
3097 | ||
58872834 CY |
3098 | 2011-08-07 Chong Yidong <cyd@stupidchicken.com> |
3099 | ||
3100 | * composite.c (autocmp_chars): Don't reset point. That is done by | |
3101 | restore_point_unwind (Bug#5984). | |
3102 | ||
75bfc667 JL |
3103 | 2011-08-07 Juri Linkov <juri@jurta.org> |
3104 | ||
3105 | * editfns.c (Fformat_time_string): Doc fix, add tag `usage:' | |
3106 | to show the arg `TIME' instead of `TIMEVAL'. | |
3107 | ||
d1410150 EZ |
3108 | 2011-08-06 Eli Zaretskii <eliz@gnu.org> |
3109 | ||
3110 | * xdisp.c (set_cursor_from_row): Fix cursor positioning when a | |
3111 | display property strides EOL and includes a newline, as in | |
3112 | longlines-mode. (Bug#9254) | |
75b771e4 EZ |
3113 | (move_it_in_display_line_to): Fix vertical-motion in a buffer with |
3114 | word-wrap under bidirectional display. (Bug#9224) | |
d1410150 EZ |
3115 | |
3116 | * bidi.c (bidi_unshelve_cache): Don't reset the cache if JUST_FREE | |
3117 | is non-zero, even if the data buffer is NULL. Fixes a crash in | |
3118 | vertical-motion with longlines-mode. (Bug#9254) | |
3119 | ||
35928349 EZ |
3120 | 2011-08-05 Eli Zaretskii <eliz@gnu.org> |
3121 | ||
ec7cc85b EZ |
3122 | * bidi.c <bidi_cache_total_alloc>: Now static. |
3123 | (bidi_initialize): Initialize bidi_cache_total_alloc. | |
3124 | ||
8b76d6f8 | 3125 | * xdisp.c (display_line): Release buffer allocated for shelved bidi |
35928349 EZ |
3126 | cache. (Bug#9221) |
3127 | ||
3128 | * bidi.c (bidi_shelve_cache, bidi_unshelve_cache): Track total | |
3129 | amount allocated this far in `bidi_cache_total_alloc'. | |
3130 | (bidi_unshelve_cache): Accept an additional argument JUST_FREE; if | |
3131 | non-zero, only free the data buffer without restoring the cache | |
3132 | contents. All callers changed. | |
3133 | ||
3134 | * dispextern.h (bidi_unshelve_cache): Update prototype. | |
3135 | ||
3136 | * xdisp.c (SAVE_IT, pos_visible_p, move_it_in_display_line_to) | |
3137 | (move_it_in_display_line, move_it_to) | |
3138 | (move_it_vertically_backward, move_it_by_lines): Replace the call | |
3139 | to xfree to an equivalent call to bidi_unshelve_cache. | |
3140 | (move_it_in_display_line_to): Fix logic of returning | |
412b6358 | 3141 | MOVE_POS_MATCH_OR_ZV in the bidi case. (Bug#9224) |
35928349 | 3142 | |
e2e2423b EZ |
3143 | 2011-08-05 Eli Zaretskii <eliz@gnu.org> |
3144 | ||
3145 | * xdisp.c (set_cursor_from_row): Prefer the candidate glyph that | |
3146 | came from a string character with a `cursor' property. (Bug#9229) | |
3147 | ||
ae9e757a JD |
3148 | 2011-08-04 Jan Djärv <jan.h.d@swipnet.se> |
3149 | ||
3150 | * Makefile.in (LIB_PTHREAD): New variable. | |
3151 | (LIBES): Add LIB_PTHREAD (Bug#9216). | |
3152 | ||
3153 | * alloc.c, emacs.c, gmalloc.c, gtkutil.c, keyboard.c, syssignal.h: | |
3154 | Rename HAVE_GTK_AND_PTHREAD to HAVE_PTHREAD (Bug#9216). | |
3155 | ||
213bd7f2 AS |
3156 | 2011-08-04 Andreas Schwab <schwab@linux-m68k.org> |
3157 | ||
6b02f655 | 3158 | * regex.c (re_iswctype): Remove some redundant boolean conversions. |
213bd7f2 | 3159 | |
99aaf75f JD |
3160 | 2011-08-04 Jan Djärv <jan.h.d@swipnet.se> |
3161 | ||
3162 | * xterm.c (x_find_topmost_parent): New function. | |
3163 | (x_set_frame_alpha): Find topmost parent window with | |
3164 | x_find_topmost_parent and set the property there also (bug#9181). | |
3165 | (handle_one_xevent): Call x_set_frame_alpha on ReparentNotify. | |
3166 | ||
c74e9d86 PE |
3167 | 2011-08-04 Paul Eggert <eggert@cs.ucla.edu> |
3168 | ||
3169 | * callproc.c (Fcall_process): Avoid vfork clobbering | |
3170 | the local vars buffer, coding_systems, current_dir. | |
3171 | ||
640c8776 SM |
3172 | 2011-08-03 Stefan Monnier <monnier@iro.umontreal.ca> |
3173 | ||
3174 | * keymap.c (Fmake_composed_keymap): Move to subr.el. | |
3175 | ||
f26d0e4c PE |
3176 | 2011-08-03 Paul Eggert <eggert@cs.ucla.edu> |
3177 | ||
8a10d76c PE |
3178 | * fontset.c (dump_fontset) [FONTSET_DEBUG]: Declare EXTERNALLY_VISIBLE |
3179 | so that it is not optimized away. | |
3180 | ||
f26d0e4c PE |
3181 | * xdisp.c (compute_display_string_pos): Remove unused local. |
3182 | ||
55439c61 EZ |
3183 | 2011-08-02 Eli Zaretskii <eliz@gnu.org> |
3184 | ||
3185 | Fix slow cursor motion and scrolling in large buffers with | |
3186 | selective display, like Org Mode buffers. (Bug#9218) | |
3187 | ||
3188 | * dispextern.h (struct bidi_it): New member disp_prop_p. | |
3189 | ||
3190 | * xdisp.c: Remove one-slot cache of display string positions. | |
3191 | (compute_display_string_pos): Accept an additional argument | |
5e617bc2 | 3192 | DISP_PROP_P; callers changed. Scan at most 5K characters forward |
55439c61 EZ |
3193 | for a display string or property. If found, set DISP_PROP_P |
3194 | non-zero. | |
3195 | ||
3196 | * bidi.c (bidi_fetch_char): Accept an additional argument | |
640c8776 SM |
3197 | DISP_PROP_P, and pass it to compute_display_string_pos. |
3198 | Only handle text covered by a display string if DISP_PROP_P is returned | |
55439c61 EZ |
3199 | non-zero. All callers of bidi_fetch_char changed. |
3200 | ||
fb33fa43 SM |
3201 | 2011-08-02 Stefan Monnier <monnier@iro.umontreal.ca> |
3202 | ||
3203 | * keymap.c (Fdefine_key): Fix Lisp_Object/int mixup; apply some CSE. | |
3204 | ||
b099e063 DM |
3205 | 2010-12-03 Don March <don@ohspite.net> |
3206 | ||
3207 | * keymap.c (Fdefine_key): Fix non-prefix key error message when | |
3208 | last character M-[char] is translated to ESC [char] (bug#7541). | |
3209 | ||
5cc7f7af KH |
3210 | 2011-08-02 Kenichi Handa <handa@m17n.org> |
3211 | ||
d0fffa3f | 3212 | * lisp.h (uniprop_table): Extern it. |
5cc7f7af KH |
3213 | |
3214 | * chartab.c (uniprop_table): Make it non-static. | |
3215 | ||
525d5e6e EZ |
3216 | 2011-08-01 Eli Zaretskii <eliz@gnu.org> |
3217 | ||
3218 | * xdisp.c (forward_to_next_line_start): Accept additional argument | |
3219 | BIDI_IT_PREV, and store into it the state of the bidi iterator had | |
3220 | on the newline. | |
3221 | (reseat_at_next_visible_line_start): Use the bidi iterator state | |
3222 | returned by forward_to_next_line_start to restore the state of | |
3223 | it->bidi_it after backing up to previous newline. (Bug#9212) | |
3224 | ||
31011111 AS |
3225 | 2011-07-30 Andreas Schwab <schwab@linux-m68k.org> |
3226 | ||
3227 | * regex.c (re_comp): Protoize. | |
3228 | (re_exec): Fix return type. | |
3229 | (regexec): Fix type of `ret'. (Bug#9203) | |
3230 | ||
476371c4 PE |
3231 | 2011-07-28 Paul Eggert <eggert@cs.ucla.edu> |
3232 | ||
e5d76069 PE |
3233 | * image.c (check_image_size): Use 1024x1024 if unknown frame (Bug#9189). |
3234 | This is needed if max-image-size is a floating-point number. | |
3235 | ||
9a79b20c AS |
3236 | 2011-07-28 Andreas Schwab <schwab@linux-m68k.org> |
3237 | ||
3238 | * print.c (print_object): Print empty symbol as ##. | |
3239 | ||
3240 | * lread.c (read1): Read ## as empty symbol. | |
3241 | ||
d8c2fa78 AA |
3242 | 2011-07-28 Alp Aker <alp.tekin.aker@gmail.com> |
3243 | ||
3244 | * nsfns.m (x_set_foreground_color): Set f->foreground_pixel when | |
3245 | setting frame foreground color (Bug#9175). | |
3246 | (x_set_background_color): Likewise. | |
3247 | ||
ffe57a7a AA |
3248 | * nsmenu.m (-setText): Size tooltip dimensions precisely to |
3249 | contents (Bug#9176). | |
3250 | (EmacsTooltip -init): Remove bezels and add shadows to | |
3251 | tooltip windows. | |
3252 | ||
bf3492a5 AA |
3253 | * nsterm.m (ns_dumpglyphs_stretch): Avoid overwriting left fringe |
3254 | or scroll bar (Bug#8470). | |
3255 | ||
d55e9c53 AA |
3256 | * nsfont.m (nsfont_open): Remove assignment to voffset and |
3257 | unnecessary vars hshink, expand, hd, full_height, min_height. | |
3258 | (nsfont_draw): Use s->ybase as baseline for glyph drawing (Bug#8913). | |
3259 | ||
3260 | * nsterm.h (nsfont_info): Remove voffset field. | |
3261 | ||
d8c2fa78 | 3262 | 2011-07-28 Alp Aker <alp.tekin.aker@gmail.com> |
4843aac3 AA |
3263 | |
3264 | Implement strike-through and overline on NextStep (Bug#8863). | |
3265 | ||
3266 | * nsfont.m (nsfont_open): Use underline position provided by font, | |
3267 | instead of hard-coded value of 2. | |
3268 | (nsfont_draw): Call ns_draw_text_decoration instead. | |
3269 | ||
3270 | * nsterm.h: Add declaration for ns_draw_text_decoration. | |
3271 | ||
3272 | * nsterm.m (ns_draw_text_decoration): New function for drawing | |
3273 | underline, overline, and strike-through. | |
3274 | (ns_dumpglyphs_image, ns_dumpglyphs_stretch): Add call to | |
3275 | ns_draw_text_decoration. Change treatment of cursor drawing to | |
8d5ed899 | 3276 | accommodate underlining, etc. |
4843aac3 | 3277 | |
4cc60b9b EZ |
3278 | 2011-07-28 Eli Zaretskii <eliz@gnu.org> |
3279 | ||
bc7ece87 EZ |
3280 | * buffer.c (init_buffer_once): Set bidi-display-reordering to t by |
3281 | default. | |
4cc60b9b | 3282 | |
476371c4 PE |
3283 | 2011-07-28 Paul Eggert <eggert@cs.ucla.edu> |
3284 | ||
66606eea PE |
3285 | * alloc.c (memory_full) [!SYNC_INPUT]: Fix signal-related race. |
3286 | Without this fix, if a signal arrives just after memory fills up, | |
3287 | 'malloc' might be invoked reentrantly. | |
3288 | ||
476371c4 PE |
3289 | * image.c (x_check_image_size) [!HAVE_X_WINDOWS]: Return 1. |
3290 | In other words, assume that every image size is allowed, on non-X | |
3291 | hosts. This assumption is probably wrong, but it lets Emacs compile. | |
3292 | ||
f3fcc40d AS |
3293 | 2011-07-28 Andreas Schwab <schwab@linux-m68k.org> |
3294 | ||
3295 | * regex.c (re_iswctype): Convert return values to boolean. | |
3296 | ||
350c992f EZ |
3297 | 2011-07-28 Eli Zaretskii <eliz@fencepost.gnu.org> |
3298 | ||
3299 | * xdisp.c (compute_display_string_pos): Don't use cached display | |
3300 | string position if the buffer had its restriction changed. | |
3301 | (Bug#9184) | |
3302 | ||
5266b4bb PE |
3303 | 2011-07-28 Paul Eggert <eggert@cs.ucla.edu> |
3304 | ||
3305 | * callproc.c (Fcall_process): Use 'volatile' to avoid vfork clobbering. | |
3306 | ||
2573a837 | 3307 | 2011-07-28 Paul Eggert <eggert@cs.ucla.edu> |
ca4aa935 | 3308 | |
41f55ccd | 3309 | Integer signedness and overflow and related fixes. (Bug#9079) |
cf950e6b | 3310 | |
39e378da PE |
3311 | * bidi.c: Integer size and overflow fixes. |
3312 | (bidi_cache_size, bidi_cache_idx, bidi_cache_last_idx) | |
3313 | (bidi_cache_start, bidi_cache_fetch_state, bidi_cache_search) | |
3314 | (bidi_cache_find_level_change, bidi_cache_ensure_space) | |
3315 | (bidi_cache_iterator_state, bidi_cache_find, bidi_cache_start_stack) | |
3316 | (bidi_find_other_level_edge): | |
3317 | Use ptrdiff_t instead of EMACS_INT where either will do. | |
3318 | This works better on 32-bit hosts configured --with-wide-int. | |
3319 | (bidi_cache_ensure_space): Check for size-calculation overflow. | |
3320 | Use % rather than repeated addition, for better worst-case speed. | |
3321 | Don't set bidi_cache_size until after xrealloc returns, because it | |
3322 | might not return. | |
3323 | (bidi_dump_cached_states): Use ptrdiff_t, not int, to avoid overflow. | |
f0eb61e9 PE |
3324 | (bidi_cache_ensure_space): Also check that the bidi cache size |
3325 | does not exceed that of the largest Lisp string or buffer. See Eli | |
3326 | Zaretskii in <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9079#29>. | |
39e378da | 3327 | |
5e927815 PE |
3328 | * alloc.c (__malloc_size_t): Remove. |
3329 | All uses replaced by size_t. See Andreas Schwab's note | |
3330 | <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9079#8>. | |
3331 | ||
ca4aa935 PE |
3332 | * image.c: Improve checking for integer overflow. |
3333 | (check_image_size): Assume that f is nonnull, since | |
3334 | it is always nonnull in practice. This is one less thing to | |
3335 | worry about when checking for integer overflow later. | |
3336 | (x_check_image_size): New function, which checks for integer | |
3337 | overflow issues inside X. | |
3338 | (x_create_x_image_and_pixmap, xbm_read_bitmap_data): Use it. | |
3339 | This removes the need for a memory_full check. | |
3340 | (xbm_image_p): Rewrite to avoid integer multiplication overflow. | |
3341 | (Create_Pixmap_From_Bitmap_Data, xbm_load): Use x_check_image_size. | |
3342 | (xbm_read_bitmap_data): Change locals back to 'int', since | |
3343 | their values must fit in 'int'. | |
3344 | (xpm_load_image, png_load, tiff_load): | |
3345 | Invoke x_create_x_image_and_pixmap earlier, | |
3346 | to avoid much needless work if the image is too large. | |
3347 | (tiff_load): Treat overly large images as if | |
3348 | x_create_x_image_and_pixmap failed, not as malloc failures. | |
3349 | (gs_load): Use x_check_image_size. | |
3350 | ||
5f8f9cc2 PE |
3351 | * gtkutil.c: Omit integer casts. |
3352 | (xg_get_pixbuf_from_pixmap): Remove unnecessary cast. | |
3353 | (xg_set_toolkit_scroll_bar_thumb): Rewrite to avoid need for cast. | |
3354 | ||
5adf60bc PE |
3355 | * image.c (png_load): Don't assume height * row_bytes fits in 'int'. |
3356 | ||
c8907a93 PE |
3357 | * xfaces.c (Fbitmap_spec_p): Fix integer overflow bug. |
3358 | Without this fix, (bitmap-spec-p '(34359738368 1 "x")) | |
3359 | would wrongly return t on a 64-bit host. | |
3360 | ||
e3c25c68 PE |
3361 | * dispnew.c (init_display): Use *_RANGE_OVERFLOW macros. |
3362 | The plain *_OVERFLOW macros run afoul of GCC bug 49705 | |
3363 | <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49705> | |
3364 | and therefore cause GCC to emit a bogus diagnostic in some cases. | |
3365 | ||
3f791afe PE |
3366 | * image.c: Integer signedness and overflow and related fixes. |
3367 | This is not an exhaustive set of fixes, but it's time to | |
3368 | record what I've got. | |
3369 | (lookup_pixel_color, check_image_size): Remove redundant decls. | |
3370 | (check_image_size): Don't assume that arbitrary EMACS_INT values | |
3371 | fit in 'int', or that arbitrary 'double' values fit in 'int'. | |
3372 | (x_alloc_image_color, x_create_x_image_and_pixmap, png_load) | |
3373 | (tiff_load, imagemagick_load_image): | |
3374 | Check for overflow in size calculations. | |
3375 | (x_create_x_image_and_pixmap): Remove unnecessary test for | |
3376 | xmalloc returning NULL; that can't happen. | |
3377 | (xbm_read_bitmap_data): Don't assume sizes fit into 'int'. | |
3378 | (xpm_color_bucket): Use better integer hashing function. | |
3379 | (xpm_cache_color): Don't possibly over-allocate memory. | |
3380 | (struct png_memory_storage, tiff_memory_source, tiff_seek_in_memory) | |
3381 | (gif_memory_source): | |
3382 | Use ptrdiff_t, not int or size_t, to record sizes. | |
3383 | (png_load): Don't assume values greater than 2**31 fit in 'int'. | |
3384 | (our_stdio_fill_input_buffer): Prefer ptrdiff_t to size_t when | |
3385 | either works, as we prefer signed integers. | |
3386 | (tiff_read_from_memory, tiff_write_from_memory): | |
3387 | Return tsize_t, not size_t, since that's what the TIFF API wants. | |
3388 | (tiff_read_from_memory): Don't fail simply because the read would | |
3389 | go past EOF; instead, return a short read. | |
3390 | (tiff_load): Omit no-longer-needed casts. | |
3391 | (Fimagemagick_types): Don't assume size fits into 'int'. | |
3392 | ||
3cc5a532 PE |
3393 | Improve hashing quality when configured --with-wide-int. |
3394 | * fns.c (hash_string): New function, taken from sxhash_string. | |
3395 | Do not discard information about ASCII character case; this | |
3396 | discarding is no longer needed. | |
3397 | (sxhash-string): Use it. Change sig to match it. Caller changed. | |
3398 | * lisp.h: Declare it. | |
3399 | * lread.c (hash_string): Remove, since we now use fns.c's version. | |
3400 | The fns.c version returns a wider integer if --with-wide-int is | |
3401 | specified, so this should help the quality of the hashing a bit. | |
3402 | ||
b312a492 PE |
3403 | * emacs.c: Integer overflow minor fix. |
3404 | (heap_bss_diff): Now uprintmax_t, not unsigned long. All used changed. | |
3405 | Define only if GNU_LINUX. | |
3406 | (main, Fdump_emacs): Set and use heap_bss_diff only if GNU_LINUX. | |
3407 | ||
dfd153ae PE |
3408 | * dispnew.c: Integer signedness and overflow fixes. |
3409 | Remove unnecessary forward decls, that were a maintenance hassle. | |
3410 | (history_tick): Now uprintmax_t, so it's more likely to avoid overflow. | |
3411 | All uses changed. | |
3412 | (adjust_glyph_matrix, realloc_glyph_pool, adjust_frame_message_buffer) | |
3413 | (scrolling_window): Use ptrdiff_t, not int, for byte count. | |
3414 | (prepare_desired_row, line_draw_cost): | |
3415 | Use int, not unsigned, where either works. | |
3416 | (save_current_matrix, restore_current_matrix): | |
3417 | Use ptrdiff_t, not size_t, where either works. | |
3418 | (init_display): Check for overflow more accurately, and without | |
3419 | relying on undefined behavior. | |
3420 | ||
a81d11a3 PE |
3421 | * editfns.c (pWIDE, pWIDElen, signed_wide, unsigned_wide): |
3422 | Remove, replacing with the new symbols in lisp.h. All uses changed. | |
3423 | * fileio.c (make_temp_name): | |
3424 | * filelock.c (lock_file_1, lock_file): | |
3425 | * xdisp.c (message_dolog): | |
3426 | Don't assume PRIdMAX etc. works; this isn't portable to pre-C99 hosts. | |
3427 | Use pMd etc. instead. | |
3428 | * lisp.h (printmax_t, uprintmax_t, pMd, pMu): New types and macros, | |
3429 | replacing the pWIDE etc. symbols removed from editfns.c. | |
3430 | ||
3300e6fd PE |
3431 | * keyboard.h (num_input_events): Now uintmax_t. |
3432 | This is (very slightly) less likely to mess up due to wraparound. | |
3433 | All uses changed. | |
3434 | ||
fd05c7e9 PE |
3435 | * buffer.c: Integer signedness fixes. |
3436 | (alloc_buffer_text, enlarge_buffer_text): | |
3437 | Use ptrdiff_t rather than size_t when either will do, as we prefer | |
3438 | signed integers. | |
3439 | ||
903fe15d PE |
3440 | * alloc.c: Integer signedness and overflow fixes. |
3441 | Do not impose an arbitrary 32-bit limit on malloc sizes when debugging. | |
3442 | (__malloc_size_t): Default to size_t, not to int. | |
3443 | (pure_size, pure_bytes_used_before_overflow, stack_copy_size) | |
3444 | (Fgarbage_collect, mark_object_loop_halt, mark_object): | |
3445 | Prefer ptrdiff_t to size_t when either would do, as we prefer | |
3446 | signed integers. | |
3447 | (XMALLOC_OVERRUN_CHECK_OVERHEAD): New macro. | |
3448 | (xmalloc_overrun_check_header, xmalloc_overrun_check_trailer): | |
3449 | Now const. Initialize with values that are in range even if char | |
3450 | is signed. | |
3451 | (XMALLOC_PUT_SIZE, XMALLOC_GET_SIZE): Remove, replacing with ... | |
3452 | (xmalloc_put_size, xmalloc_get_size): New functions. All uses changed. | |
3453 | These functions do the right thing with sizes > 2**32. | |
3454 | (check_depth): Now ptrdiff_t, not int. | |
3455 | (overrun_check_malloc, overrun_check_realloc, overrun_check_free): | |
3456 | Adjust to new way of storing sizes. Check for size overflow bugs | |
3457 | in rest of code. | |
3458 | (STRING_BYTES_MAX): Adjust to new overheads. The old code was | |
3459 | slightly wrong anyway, as it missed one instance of | |
3460 | XMALLOC_OVERRUN_CHECK_OVERHEAD. | |
3461 | (refill_memory_reserve): Omit needless cast to size_t. | |
3462 | (mark_object_loop_halt): Mark as externally visible. | |
3463 | ||
ac82cc6a PE |
3464 | * xselect.c: Integer signedness and overflow fixes. |
3465 | (Fx_register_dnd_atom, x_handle_dnd_message): | |
3466 | Use ptrdiff_t, not size_t, since we prefer signed. | |
3467 | (Fx_register_dnd_atom): Check for ptrdiff_t (and size_t) overflow. | |
3468 | * xterm.h (struct x_display_info): Use ptrdiff_t, not size_t, for | |
3469 | x_dnd_atoms_size and x_dnd_atoms_length. | |
3470 | ||
c2d1e36d PE |
3471 | * doprnt.c: Prefer signed to unsigned when either works. |
3472 | * eval.c (verror): | |
3473 | * doprnt.c (doprnt): | |
3474 | * lisp.h (doprnt): | |
3475 | * xdisp.c (vmessage): | |
3476 | Use ptrdiff_t, not size_t, when using or implementing doprnt, | |
3477 | since the sizes cannot exceed ptrdiff_t bounds anyway, and we | |
3478 | prefer signed arithmetic to avoid comparison confusion. | |
3479 | * doprnt.c (doprnt): Avoid a "+ 1" that can't overflow, | |
3480 | but is a bit tricky. | |
3481 | ||
0e926e56 PE |
3482 | Assume freestanding C89 headers, string.h, stdlib.h. |
3483 | * data.c, doprnt.c, floatfns.c, print.c: | |
3484 | Include float.h unconditionally. | |
3485 | * gmalloc.c: Assume C89-at-least behavior for preprocessor, | |
3486 | limits.h, stddef.h, string.h. Use memset instead of 'flood'. | |
3487 | * regex.c: Likewise for stddef.h, string.h. | |
3488 | (ISASCII): Remove; can assume it returns 1 now. All uses removed. | |
3489 | * s/aix4-2.h (HAVE_STRING_H): Remove obsolete undef. | |
3490 | * s/ms-w32.h (HAVE_LIMITS_H, HAVE_STRING_H, HAVE_STDLIB_H) | |
3491 | (STDC_HEADERS): Remove obsolete defines. | |
3492 | * sysdep.c: Include limits.h unconditionally. | |
3493 | ||
9cfdb3ec PE |
3494 | Assume support for memcmp, memcpy, memmove, memset. |
3495 | * lisp.h, sysdep.c (memcmp, memcpy, memmove, memset): | |
3496 | * regex.c (memcmp, memcpy): | |
3497 | Remove; we assume C89 now. | |
3498 | ||
3499 | * gmalloc.c (memcpy, memset, memmove): Remove; we assume C89 now. | |
3500 | (__malloc_safe_bcopy): Remove; no longer needed. | |
3501 | ||
cf950e6b | 3502 | * lisp.h (struct vectorlike_header, struct Lisp_Subr): Signed sizes. |
6089c567 PE |
3503 | Use EMACS_INT, not EMACS_UINT, for sizes. The code works equally |
3504 | well either way, and we prefer signed to unsigned. | |
3505 | ||
dbf38e02 LMI |
3506 | 2011-07-27 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3507 | ||
3508 | * gnutls.c (emacs_gnutls_read): Don't message anything if the peer | |
3509 | closes the connection while we're reading (bug#9182). | |
3510 | ||
d6f0886c | 3511 | 2011-07-25 Jan Djärv <jan.h.d@swipnet.se> |
24e0f6b1 | 3512 | |
d6f0886c JD |
3513 | * nsmenu.m (ns_popup_dialog): Add an "ok" button if no buttons |
3514 | are specified (Bug#9168). | |
24e0f6b1 | 3515 | |
2eb1f9e6 PE |
3516 | 2011-07-25 Paul Eggert <eggert@cs.ucla.edu> |
3517 | ||
3518 | * bidi.c (bidi_dump_cached_states): Fix printf format mismatch. | |
3519 | Found by GCC static checking and --with-wide-int on a 32-bit host. | |
3520 | ||
22381272 | 3521 | 2011-07-25 Eli Zaretskii <eliz@gnu.org> |
7daee910 EZ |
3522 | |
3523 | * xdisp.c (compute_display_string_pos): Fix logic of caching | |
3524 | previous display string position. Initialize cached_prev_pos to | |
3525 | -1. Fixes slow-down at the beginning of a buffer. | |
3526 | ||
f25e39b4 EZ |
3527 | 2011-07-24 Eli Zaretskii <eliz@gnu.org> |
3528 | ||
3529 | * xfaces.c (check_lface_attrs) [HAVE_WINDOW_SYSTEM]: Allow `nil' | |
3530 | for attrs[LFACE_FONTSET_INDEX]. | |
3531 | ||
04c4b52e PE |
3532 | 2011-07-23 Paul Eggert <eggert@cs.ucla.edu> |
3533 | ||
3534 | * xml.c (parse_region): Remove unused local | |
3535 | that was recently introduced. | |
3536 | ||
c1734fbd EZ |
3537 | 2011-07-23 Eli Zaretskii <eliz@gnu.org> |
3538 | ||
be18c5a5 EZ |
3539 | * xfns.c (unwind_create_frame) [GLYPH_DEBUG]: Adapt to changes in |
3540 | 2008-02-22T17:42:09Z!monnier@iro.umontreal.ca. | |
3541 | ||
c1734fbd EZ |
3542 | * xdisp.c (move_it_in_display_line_to): Record the best matching |
3543 | position for TO_CHARPOS while scanning the line, and restore it on | |
640c8776 SM |
3544 | exit if none of the characters scanned was an exact match. |
3545 | Fixes vertical-motion and pos-visible-in-window-p under bidi redisplay | |
a9269c18 EZ |
3546 | when exact match is impossible due to invisible text, and the |
3547 | lines are truncated. | |
3548 | ||
a258d627 JD |
3549 | 2011-07-23 Jan Djärv <jan.h.d@swipnet.se> |
3550 | ||
3551 | * nsterm.m (initFrameFromEmacs): Set NSTitledWindowMask in styleMask | |
3552 | for OSX >= 10.7. | |
3553 | ||
b6d5a689 EZ |
3554 | 2011-07-22 Eli Zaretskii <eliz@gnu.org> |
3555 | ||
0f74f785 EZ |
3556 | Fix a significant slow-down of cursor motion with C-n, C-p, |
3557 | C-f/C-b, and C-v/M-v that couldn't keep up with keyboard | |
3558 | auto-repeat under bidi redisplay in fontified buffers. | |
b6d5a689 | 3559 | * xdisp.c (compute_stop_pos_backwards): New function. |
b6d5a689 EZ |
3560 | (next_element_from_buffer): Call compute_stop_pos_backwards to |
3561 | find a suitable prev_stop when we find ourselves before | |
0f74f785 EZ |
3562 | base_level_stop. |
3563 | (reseat): Don't look for prev_stop, as that could mean a very long | |
3564 | run. | |
3565 | <cached_disp_pos, cached_disp_buffer, cached_disp_modiff> | |
3566 | <cached_disp_overlay_modiff>: Cache for last found display string | |
3567 | position. | |
551918c1 | 3568 | (compute_display_string_pos): Return the cached position if asked |
0f74f785 EZ |
3569 | about the same buffer in the same area of character positions, and |
3570 | the buffer wasn't changed since the time the display string | |
3571 | position was cached. | |
551918c1 | 3572 | |
b2d0c91a EZ |
3573 | 2011-07-22 Eli Zaretskii <eliz@gnu.org> |
3574 | ||
3575 | * xdisp.c (rows_from_pos_range): Don't ignore glyphs whose object | |
3576 | is an integer, which is important for empty lines. (Bug#9149) | |
3577 | ||
043604ee CY |
3578 | 2011-07-22 Chong Yidong <cyd@stupidchicken.com> |
3579 | ||
3580 | * frame.c (Fmodify_frame_parameters): In tty case, update the | |
3581 | default face if necessary (Bug#4238). | |
3582 | ||
da4adb04 CY |
3583 | 2011-07-21 Chong Yidong <cyd@stupidchicken.com> |
3584 | ||
3585 | * editfns.c (Fstring_to_char): No need to explain what a character | |
3586 | is in the docstring (Bug#6576). | |
3587 | ||
9abd0532 LMI |
3588 | 2011-07-20 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3589 | ||
3590 | * xml.c (parse_region): Make sure we always return a tree. | |
3591 | ||
36881d16 HK |
3592 | 2011-07-20 HAMANO Kiyoto <khiker.mail@gmail.com> |
3593 | ||
3594 | * xml.c (parse_region): If a document contains only comments, | |
3595 | return that, too. | |
3596 | ||
1e98674d LMI |
3597 | 2011-07-20 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3598 | ||
3599 | * xml.c (make_dom): Return comments, too. | |
3600 | ||
590bd467 PE |
3601 | 2011-07-19 Paul Eggert <eggert@cs.ucla.edu> |
3602 | ||
3603 | Port to OpenBSD. | |
3604 | See http://lists.gnu.org/archive/html/emacs-devel/2011-07/msg00688.html | |
3605 | and the surrounding thread. | |
3606 | * minibuf.c (read_minibuf_noninteractive): Rewrite to use getchar | |
3607 | rather than fgets, and retry after EINTR. Otherwise, 'emacs | |
3608 | --batch -f byte-compile-file' fails on OpenBSD if an inactivity | |
3609 | timer goes off. | |
3610 | * s/openbsd.h (BROKEN_SIGIO): Define. | |
3611 | * unexelf.c (unexec) [__OpenBSD__]: | |
3612 | Don't update the .mdebug section of the Alpha COFF symbol table. | |
3613 | ||
f41628b2 LMI |
3614 | 2011-07-19 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3615 | ||
3616 | * lread.c (syms_of_lread): Clarify when `lexical-binding' is used | |
3617 | (bug#8460). | |
3618 | ||
b59b67c5 PE |
3619 | 2011-07-18 Paul Eggert <eggert@cs.ucla.edu> |
3620 | ||
15e3a074 PE |
3621 | * fileio.c (Fcopy_file) [!MSDOS]: Tighten created file's mask. |
3622 | This fixes some race conditions on the permissions of any newly | |
3623 | created file. | |
3624 | ||
41bed37d PE |
3625 | * alloc.c (valid_pointer_p): Use pipe, not open. |
3626 | This fixes some permissions issues when debugging. | |
3627 | ||
b59b67c5 PE |
3628 | * fileio.c (Fcopy_file): Adjust mode if fchown fails. (Bug#9002) |
3629 | If fchown fails to set both uid and gid, try to set just gid, | |
3630 | as that is sometimes allowed. Adjust the file's mode to eliminate | |
3631 | setuid or setgid bits that are inappropriate if fchown fails. | |
3632 | ||
925a6be7 SM |
3633 | 2011-07-18 Stefan Monnier <monnier@iro.umontreal.ca> |
3634 | ||
3635 | * xdisp.c (next_element_from_string, next_element_from_buffer): Use EQ | |
3636 | to compare Lisp_Objects. | |
3637 | * gnutls.c (syms_of_gnutls): Rename Vgnutls_log_level to | |
3638 | global_gnutls_log_level, don't mistake it for a Lisp_Object. | |
3639 | (init_gnutls_functions, emacs_gnutls_handle_error): Fix up uses. | |
3640 | ||
52968808 AS |
3641 | 2011-07-17 Andreas Schwab <schwab@linux-m68k.org> |
3642 | ||
0a6a104b AS |
3643 | * lread.c (read_integer): Unread even EOF character. |
3644 | (read1): Likewise. Properly record start position of symbol. | |
3645 | ||
52968808 AS |
3646 | * lread.c (read1): Read `#:' as empty uninterned symbol if no |
3647 | symbol character follows. | |
3648 | ||
9e381cdd PE |
3649 | 2011-07-17 Paul Eggert <eggert@cs.ucla.edu> |
3650 | ||
3651 | * fileio.c (Fcopy_file): Pacify gcc re fchown. (Bug#9002) | |
3652 | This works around a problem with the previous change to Fcopy_file. | |
3653 | Recent glibc declares fchown with __attribute__((warn_unused_result)), | |
3654 | and without this change, GCC might complain about discarding | |
3655 | fchown's return value. | |
3656 | ||
b5641435 JB |
3657 | 2011-07-16 Juanma Barranquero <lekktu@gmail.com> |
3658 | ||
3659 | * makefile.w32-in (GLOBAL_SOURCES): Add gnutls.c (followup to bug#9059). | |
3660 | ||
a8031457 PE |
3661 | 2011-07-16 Paul Eggert <eggert@cs.ucla.edu> |
3662 | ||
3663 | * fileio.c (Fcopy_file): Don't diagnose fchown failures. (Bug#9002) | |
3664 | ||
dd889327 LMI |
3665 | 2011-07-16 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3666 | ||
750c33f7 LMI |
3667 | * gnutls.c (syms_of_gnutls): Define `gnutls-log-level' here, since |
3668 | it's used from the C level. | |
3669 | ||
dd889327 LMI |
3670 | * process.c: Use the same condition for POLL_FOR_INPUT in both |
3671 | keyboard.c and process.c (bug#1858). | |
3672 | ||
87e86684 LM |
3673 | 2011-07-09 Lawrence Mitchell <wence@gmx.li> |
3674 | ||
3675 | * gnutls.c (Qgnutls_bootprop_min_prime_bits): New variable. | |
3676 | (Fgnutls_boot): Use it. | |
3677 | ||
64348f40 AS |
3678 | 2011-07-15 Andreas Schwab <schwab@linux-m68k.org> |
3679 | ||
3680 | * doc.c (Fsubstitute_command_keys): Revert last change. | |
3681 | ||
1d698799 LMI |
3682 | 2011-07-15 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3683 | ||
f863868c LMI |
3684 | * doc.c (Fsubstitute_command_keys): Clarify that \= really only |
3685 | quotes the next character, and doesn't affect other longer | |
3686 | sequences (bug#8935). | |
3687 | ||
1d698799 LMI |
3688 | * lread.c (syms_of_lread): Clarify that is isn't only |
3689 | `eval-buffer' and `eval-defun' that's affected by | |
3690 | `lexical-binding' (bug#8460). | |
3691 | ||
aa4b6df6 EZ |
3692 | 2011-07-15 Eli Zaretskii <eliz@gnu.org> |
3693 | ||
3694 | * xdisp.c (move_it_in_display_line_to): Fix vertical motion with | |
6b02f655 | 3695 | bidi redisplay when a line includes both an image and is truncated. |
aa4b6df6 | 3696 | |
5d856da6 PE |
3697 | 2011-07-14 Paul Eggert <eggert@cs.ucla.edu> |
3698 | ||
ad6042bb PE |
3699 | Fix minor problems found by static checking. |
3700 | * bidi.c (bidi_cache_size): Now EMACS_INT, not size_t. | |
3701 | (elsz): Now a signed constant, not a size_t var. We prefer signed | |
3702 | types to unsigned, to avoid integer comparison confusion. Without | |
3703 | this change, GCC 4.6.1 with -Wunsafe-loop-optimizations complains | |
3704 | "cannot optimize loop, the loop counter may overflow", a symptom | |
3705 | of the confusion. | |
f00bbb22 | 3706 | * indent.c (Fvertical_motion): Mark locals as initialized. |
5d856da6 PE |
3707 | * xdisp.c (reseat_to_string): Fix pointer signedness issue. |
3708 | ||
6468f31c LMI |
3709 | 2011-07-14 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3710 | ||
49080b10 LMI |
3711 | * search.c (Fre_search_backward): Mention `case-fold-search' in |
3712 | all the re_search_* functions (bug#8138). | |
3713 | ||
6468f31c LMI |
3714 | * keyboard.c (Fopen_dribble_file): Document when the file is |
3715 | closed (bug#8056). | |
3716 | ||
c965adc5 EZ |
3717 | 2011-07-14 Eli Zaretskii <eliz@gnu.org> |
3718 | ||
df9733bf EZ |
3719 | * bidi.c (bidi_dump_cached_states): Fix format of displaying |
3720 | bidi_cache_idx. | |
3721 | ||
0bb23927 EZ |
3722 | Support bidi reordering of display and overlay strings. |
3723 | * xdisp.c (compute_display_string_pos) | |
3724 | (compute_display_string_end): Accept additional argument STRING. | |
3725 | (init_iterator, reseat_1): Initialize bidi_it->string.s to NULL. | |
3726 | (reseat_to_string): Initialize bidi_it->string.s and | |
3727 | bidi_it->string.schars. | |
3728 | (Fcurrent_bidi_paragraph_direction): Initialize itb.string.s to | |
640c8776 SM |
3729 | NULL (avoids a crash in bidi_paragraph_init). |
3730 | Initialize itb.string.lstring. | |
0bb23927 EZ |
3731 | (init_iterator): Call bidi_init_it only of a valid |
3732 | buffer position was specified. Initialize paragraph_embedding to | |
3733 | L2R. | |
3734 | (reseat_to_string): Initialize the bidi iterator. | |
3735 | (display_string): If we need to ignore text properties of | |
3736 | LISP_STRING, set IT->stop_charpos to IT->end_charpos. (The | |
3737 | original value of -1 will not work with bidi.) | |
3738 | (compute_display_string_pos): First arg is now struct | |
3739 | `text_pos *'; all callers changed. Support display properties on | |
3740 | Lisp strings. | |
3741 | (compute_display_string_end): Support display properties on Lisp | |
3742 | strings. | |
3743 | (init_iterator, reseat_1, reseat_to_string): Initialize the | |
3744 | string.bufpos member to 0 (zero, for compatibility with IT_CHARPOS | |
3745 | when iterating on a string not from display properties). | |
640c8776 SM |
3746 | (compute_display_string_pos, compute_display_string_end): |
3747 | Fix calculation of the object to scan. Fixes an error when using | |
0bb23927 EZ |
3748 | arrow keys. |
3749 | (next_element_from_buffer): Don't abort when IT_CHARPOS is before | |
640c8776 SM |
3750 | base_level_stop; instead, set base_level_stop to BEGV. |
3751 | Fixes crashes in vertical-motion. | |
0bb23927 EZ |
3752 | (next_element_from_buffer): Improve commentary for when |
3753 | the iterator is before prev_stop. | |
3754 | (init_iterator): Initialize bidi_p from the default value of | |
3755 | bidi-display-reordering, not from buffer-local value. Use the | |
3756 | buffer-local value only if initializing for buffer iteration. | |
3757 | (handle_invisible_prop): Support invisible properties on strings | |
3758 | that are being bidi-reordered. | |
3759 | (set_iterator_to_next): Support bidi reordering of C strings and | |
3760 | Lisp strings. | |
3761 | (next_element_from_string): Support bidi reordering of Lisp | |
3762 | strings. | |
3763 | (handle_stop_backwards): Support Lisp strings as well. | |
640c8776 SM |
3764 | (display_string): Support display of R2L glyph rows. |
3765 | Use IT_STRING_CHARPOS when displaying from a Lisp string. | |
0bb23927 EZ |
3766 | (init_iterator): Don't initialize it->bidi_p for strings |
3767 | here. | |
3768 | (reseat_to_string): Initialize it->bidi_p for strings here. | |
3769 | (next_element_from_string, next_element_from_c_string) | |
3770 | (next_element_from_buffer): Add xassert's for correspondence | |
3771 | between IT's object being iterated and it->bidi_it.string | |
3772 | structure. | |
3773 | (face_before_or_after_it_pos): Support bidi iteration. | |
3774 | (next_element_from_c_string): Handle the case of the first string | |
3775 | character that is not the first one in the visual order. | |
3776 | (get_visually_first_element): New function, refactored from common | |
3777 | parts of next_element_from_buffer, next_element_from_string, and | |
3778 | next_element_from_c_string. | |
3779 | (tool_bar_lines_needed, redisplay_tool_bar) | |
3780 | (display_menu_bar): Force left-to-right direction. Add a FIXME | |
3781 | comment for making that be controlled by a user option. | |
3782 | (push_it, pop_it): Save and restore the state of the | |
3783 | bidi iterator. Save and restore the bidi_p flag. | |
3784 | (pop_it): Iterate out of display property for string iteration as | |
3785 | well. | |
3786 | (iterate_out_of_display_property): Support iteration over strings. | |
3787 | (handle_single_display_spec): Set up it->bidi_it for iteration | |
3788 | over a display string, and call bidi_init_it. | |
3789 | (handle_single_display_spec, next_overlay_string) | |
3790 | (get_overlay_strings_1, push_display_prop): Set up the bidi | |
3791 | iterator for displaying display or overlay strings. | |
3792 | (forward_to_next_line_start): Don't use the shortcut if | |
3793 | bidi-iterating. | |
3794 | (back_to_previous_visible_line_start): If handle_display_prop | |
3795 | pushed the iterator stack, restore the internal state of the bidi | |
3796 | iterator by calling bidi_pop_it same number of times. | |
3797 | (reseat_at_next_visible_line_start): If ON_NEWLINE_P is non-zero, | |
3798 | and we are bidi-iterating, don't decrement the iterator position; | |
3799 | instead, set the first_elt flag in the bidi iterator, to produce | |
3800 | the same effect. | |
3801 | (reseat_1): Remove redundant setting of string_from_display_prop_p. | |
3802 | (push_display_prop): xassert that we are iterating a buffer. | |
3803 | (push_it, pop_it): Save and restore paragraph_embedding member. | |
3804 | (handle_single_display_spec, next_overlay_string) | |
3805 | (get_overlay_strings_1, reseat_1, reseat_to_string) | |
3806 | (push_display_prop): Set up the `unibyte' member of bidi_it.string | |
3807 | correctly. Don't assume unibyte strings are not bidi-reordered. | |
3808 | (compute_display_string_pos) | |
3809 | (compute_display_string_end): Fix handling the case of C string. | |
3810 | (push_it, pop_it): Save and restore from_disp_prop_p. | |
3811 | (handle_single_display_spec, push_display_prop): Set the | |
3812 | from_disp_prop_p flag. | |
3813 | (get_overlay_strings_1): Reset the from_disp_prop_p flag. | |
3814 | (pop_it): Call iterate_out_of_display_property only if we are | |
3815 | popping after iteration over a string that came from a display | |
3816 | property. Fix a typo in popping stretch info. Add an assertion | |
3817 | for verifying that the iterator position is in sync with the bidi | |
3818 | iterator. | |
3819 | (handle_single_display_spec, get_overlay_strings_1) | |
3820 | (push_display_prop): Fix initialization of paragraph direction for | |
3821 | string when that of the parent object is not yet determined. | |
3822 | (reseat_1): Call bidi_init_it to resync the bidi | |
3823 | iterator with IT's position. (Bug#7616) | |
3824 | (find_row_edges): If ROW->start.pos gives position | |
3825 | smaller than min_pos, use it as ROW->minpos. (Bug#7616) | |
3826 | (handle_stop, back_to_previous_visible_line_start, reseat_1): | |
3827 | Reset the from_disp_prop_p flag. | |
3828 | (SAVE_IT, RESTORE_IT): New macros. | |
3829 | (pos_visible_p, face_before_or_after_it_pos) | |
3830 | (back_to_previous_visible_line_start) | |
3831 | (move_it_in_display_line_to, move_it_in_display_line) | |
3832 | (move_it_to, move_it_vertically_backward, move_it_by_lines) | |
3833 | (try_scrolling, redisplay_window, display_line): Use them when | |
3834 | saving a temporary copy of the iterator and restoring it back. | |
3835 | (back_to_previous_visible_line_start, reseat_1) | |
3836 | (init_iterator): Empty the bidi cache "stack". | |
3837 | (move_it_in_display_line_to): If iterator ended up at | |
3838 | EOL, but we never saw any buffer positions smaller than | |
3839 | to_charpos, return MOVE_POS_MATCH_OR_ZV. Fixes vertical cursor | |
3840 | motion in bidi-reordered lines. | |
3841 | (move_it_in_display_line_to): Record prev_method and prev_pos | |
3842 | immediately before the call to set_iterator_to_next. Fixes cursor | |
3843 | motion in bidi-reordered lines with stretch glyphs and strings | |
3844 | displayed in margins. (Bug#8133) (Bug#8867) | |
3845 | Return MOVE_POS_MATCH_OR_ZV only if iterator position is past | |
3846 | TO_CHARPOS. | |
640c8776 SM |
3847 | (pos_visible_p): Support positions in bidi-reordered lines. |
3848 | Save and restore bidi cache. | |
0bb23927 EZ |
3849 | |
3850 | * bidi.c (bidi_level_of_next_char): clen should be EMACS_NT, not int. | |
3851 | (bidi_paragraph_info): Delete unused struct. | |
3852 | (bidi_cache_idx, bidi_cache_last_idx): Declare EMACS_INT. | |
3853 | (bidi_cache_start): New variable. | |
3854 | (bidi_cache_reset): Reset bidi_cache_idx to bidi_cache_start, not | |
3855 | to zero. | |
3856 | (bidi_cache_fetch_state, bidi_cache_search) | |
3857 | (bidi_cache_find_level_change, bidi_cache_iterator_state) | |
3858 | (bidi_cache_find, bidi_peek_at_next_level) | |
3859 | (bidi_level_of_next_char, bidi_find_other_level_edge) | |
3860 | (bidi_move_to_visually_next): Compare cache index with | |
3861 | bidi_cache_start rather than with zero. | |
3862 | (bidi_fetch_char): Accept new argument STRING; all callers | |
3863 | changed. Support iteration over a string. Support strings with | |
3864 | display properties. Support unibyte strings. Fix the type of | |
3865 | `len' according to what STRING_CHAR_AND_LENGTH expects. | |
3866 | (bidi_paragraph_init, bidi_resolve_explicit_1) | |
3867 | (bidi_resolve_explicit, bidi_resolve_weak) | |
640c8776 SM |
3868 | (bidi_level_of_next_char, bidi_move_to_visually_next): |
3869 | Support iteration over a string. | |
0bb23927 EZ |
3870 | (bidi_set_sor_type, bidi_resolve_explicit_1) |
3871 | (bidi_resolve_explicit, bidi_type_of_next_char): ignore_bn_limit | |
3872 | can now be zero (for strings); special values 0 and -1 were | |
3873 | changed to -1 and -2, respectively. | |
3874 | (bidi_char_at_pos): New function. | |
3875 | (bidi_paragraph_init, bidi_resolve_explicit, bidi_resolve_weak): | |
3876 | Call it instead of FETCH_MULTIBYTE_CHAR. | |
3877 | (bidi_move_to_visually_next): Abort if charpos or bytepos were not | |
3878 | initialized to valid values. | |
3879 | (bidi_init_it): Don't initialize charpos and bytepos with invalid | |
3880 | values. | |
3881 | (bidi_level_of_next_char): Allow the sentinel "position" to pass | |
3882 | the test for valid cached positions. Fix the logic for looking up | |
3883 | the sentinel state in the cache. GCPRO the Lisp string we are | |
3884 | iterating. | |
3885 | (bidi_push_it, bidi_pop_it): New functions. | |
3886 | (bidi_initialize): Initialize the bidi cache start stack pointer. | |
3887 | (bidi_cache_ensure_space): New function, refactored from part of | |
3888 | bidi_cache_iterator_state. Don't assume the required size is just | |
3889 | one BIDI_CACHE_CHUNK away. | |
3890 | (bidi_cache_start_stack, bidi_push_it): Use IT_STACK_SIZE. | |
3891 | (bidi_count_bytes, bidi_char_at_pos): New functions. | |
3892 | (bidi_cache_search): Don't assume bidi_cache_last_idx is | |
3893 | always valid if bidi_cache_idx is valid. | |
3894 | (bidi_cache_find_level_change): xassert that bidi_cache_last_idx | |
3895 | is valid if it's going to be used. | |
3896 | (bidi_shelve_cache, bidi_unshelve_cache): New functions. | |
3897 | (bidi_cache_fetch_state, bidi_cache_search) | |
c965adc5 EZ |
3898 | (bidi_cache_find_level_change, bidi_cache_ensure_space) |
3899 | (bidi_cache_iterator_state, bidi_cache_find) | |
640c8776 SM |
3900 | (bidi_find_other_level_edge, bidi_cache_start_stack): |
3901 | All variables related to cache indices are now EMACS_INT. | |
c965adc5 | 3902 | |
0bb23927 EZ |
3903 | * dispextern.h (struct bidi_string_data): New structure. |
3904 | (struct bidi_it): New member `string'. Make flag members be 1-bit | |
3905 | fields, and put them last in the struct. | |
640c8776 SM |
3906 | (compute_display_string_pos, compute_display_string_end): |
3907 | Update prototypes. | |
0bb23927 EZ |
3908 | (bidi_push_it, bidi_pop_it): Add prototypes. |
3909 | (struct iterator_stack_entry): New members bidi_p, | |
3910 | paragraph_embedding, and from_disp_prop_p. | |
3911 | (struct it): Member bidi_p is now a bit field 1 bit wide. | |
640c8776 SM |
3912 | (bidi_shelve_cache, bidi_unshelve_cache): |
3913 | Declare prototypes. | |
0bb23927 EZ |
3914 | |
3915 | * .gdbinit (xvectype, xvector, xcompiled, xchartable, xboolvector) | |
3916 | (xpr, xfont, xbacktrace): Use "header.size" when accessing vectors | |
3917 | and vector-like objects. | |
3918 | ||
3919 | * dispnew.c (buffer_posn_from_coords): Save and restore the bidi | |
3920 | cache around display iteration. | |
3921 | ||
3922 | * window.c (Fwindow_end, window_scroll_pixel_based) | |
3923 | (displayed_window_lines, Frecenter): Save and restore the bidi | |
3924 | cache around display iteration. | |
3925 | ||
3bbd2265 LMI |
3926 | 2011-07-14 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3927 | ||
3928 | * editfns.c (Fdelete_region): Clarify the use of the named | |
3929 | parameters (bug#6788). | |
3930 | ||
adc47434 MR |
3931 | 2011-07-14 Martin Rudalics <rudalics@gmx.at> |
3932 | ||
3933 | * indent.c (Fvertical_motion): Set and restore w->pointm when | |
3934 | saving and restoring the window's buffer (Bug#9006). | |
3935 | ||
837c31f8 LMI |
3936 | 2011-07-13 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3937 | ||
3938 | * editfns.c (Fstring_to_char): Clarify just what is returned | |
3939 | (bug#6576). Text by Eli Zaretskii. | |
3940 | ||
ac389d0c JB |
3941 | 2011-07-13 Juanma Barranquero <lekktu@gmail.com> |
3942 | ||
3943 | * gnutls.c (init_gnutls_functions): Honor gnutls_log_level (bug#9059). | |
3944 | ||
0be0ce47 EZ |
3945 | 2011-07-13 Eli Zaretskii <eliz@gnu.org> |
3946 | ||
3947 | * buffer.c (mmap_find): Fix a typo. | |
3948 | ||
cd18e7e3 JB |
3949 | 2011-07-13 Johan Bockgård <bojohan@gnu.org> |
3950 | ||
3951 | Fix execution of x selection hooks. | |
3952 | * xselect.c (Qx_lost_selection_functions) | |
3953 | (Qx_sent_selection_functions): New vars. | |
3954 | (syms_of_xselect): DEFSYM them. | |
3955 | (x_handle_selection_request): Pass Qx_sent_selection_functions | |
3956 | rather than Vx_sent_selection_functions to Frun_hook_with_args. | |
3957 | (x_handle_selection_clear,x_clear_frame_selections): | |
3958 | Pass Qx_lost_selection_functions rather than | |
3959 | Vx_lost_selection_functions to Frun_hook_with_args. | |
3960 | ||
47ea7f44 PE |
3961 | 2011-07-13 Paul Eggert <eggert@cs.ucla.edu> |
3962 | ||
ac389d0c | 3963 | * buffer.c (Fget_buffer_create): Initialize inhibit_shrinking. |
2941c447 PE |
3964 | The old code sometimes used this field without initializing it. |
3965 | ||
47ea7f44 PE |
3966 | * alloc.c (gc_sweep): Don't read past end of array. |
3967 | In theory, the old code could also have corrupted Emacs internals, | |
3968 | though it'd be very unlikely. | |
3969 | ||
bc985c87 AS |
3970 | 2011-07-12 Andreas Schwab <schwab@linux-m68k.org> |
3971 | ||
3972 | * character.c (Fcharacterp): Don't advertise optional ignored | |
ac389d0c | 3973 | argument. (Bug#4026) |
bc985c87 | 3974 | |
0cf34688 LMI |
3975 | 2011-07-12 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3976 | ||
b3dadd76 LMI |
3977 | * keymap.c (syms_of_keymap): Clarify that "modifier" is "modifier |
3978 | key" (bug#4257). | |
3979 | ||
0cf34688 LMI |
3980 | * window.c (Fset_window_start): Doc fix (bug#4199). |
3981 | (Fset_window_hscroll): Ditto. | |
3982 | ||
270768cd PE |
3983 | 2011-07-12 Paul Eggert <eggert@cs.ucla.edu> |
3984 | ||
077e3dda | 3985 | Fix minor new problems caught by GCC 4.6.1. |
270768cd | 3986 | * term.c (init_tty): Remove unused local. |
490011a6 | 3987 | * xsettings.c (store_monospaced_changed): Define this function only |
077e3dda | 3988 | if (defined HAVE_GSETTINGS || defined HAVE_GCONF), as it's |
490011a6 | 3989 | not used otherwise. |
270768cd | 3990 | |
b1f58454 CY |
3991 | 2011-07-12 Chong Yidong <cyd@stupidchicken.com> |
3992 | ||
3993 | * xdisp.c (Vresize_mini_windows): Minor doc fix (Bug#3300). | |
3994 | ||
22b9578d LMI |
3995 | 2011-07-11 Lars Magne Ingebrigtsen <larsi@gnus.org> |
3996 | ||
6e70ab07 LMI |
3997 | * xdisp.c (syms_of_xdisp): Make it explicit that the mini-windows |
3998 | are the mini-buffer and the echo area (bug#3320). | |
3999 | ||
22b9578d LMI |
4000 | * term.c (init_tty): Remove support for supdup, c10 and perq |
4001 | terminals, which are no longer supported (bug#1482). | |
4002 | ||
8974cc9f JB |
4003 | 2011-07-10 Johan Bockgård <bojohan@gnu.org> |
4004 | ||
4005 | * xdisp.c (Ftool_bar_lines_needed): Fix WINDOWP check. | |
4006 | ||
a560d974 JD |
4007 | 2011-07-10 Jan Djärv <jan.h.d@swipnet.se> |
4008 | ||
4009 | * xmenu.c (menu_highlight_callback): Only pass frame to show_help_event | |
4010 | for non-popups (Bug#3642). | |
4011 | ||
1dae0f0a AS |
4012 | 2011-07-10 Andreas Schwab <schwab@linux-m68k.org> |
4013 | ||
268c2c36 | 4014 | * alloc.c (reset_malloc_hooks): Protoize. |
1dae0f0a | 4015 | * buffer.c (mmap_init, mmap_find, mmap_free_1, mmap_enlarge) |
268c2c36 AS |
4016 | (mmap_set_vars, mmap_alloc, mmap_free, mmap_realloc): Likewise. |
4017 | * cm.c (losecursor): Likewise. | |
1dae0f0a AS |
4018 | * data.c (fmod): Likewise. |
4019 | * dispnew.c (swap_glyphs_in_rows): Likewise. | |
4020 | * emacs.c (memory_warning_signal): Likewise. | |
4021 | * floatfns.c (float_error): Likewise. | |
4022 | * font.c (check_gstring, check_otf_features, otf_tag_symbol) | |
4023 | (otf_open, font_otf_capability, generate_otf_features) | |
4024 | (font_otf_DeviceTable, font_otf_ValueRecord, font_otf_Anchor): | |
4025 | Likewise. | |
4026 | * image.c (pbm_read_file): Likewise. | |
4027 | * indent.c (string_display_width): Likewise. | |
4028 | * intervals.c (check_for_interval, search_for_interval) | |
4029 | (inc_interval_count, count_intervals, root_interval) | |
4030 | (adjust_intervals_for_insertion, make_new_interval): Likewise. | |
4031 | * lread.c (defalias): Likewise. | |
268c2c36 | 4032 | * ralloc.c (r_alloc_check): Likewise. |
1dae0f0a AS |
4033 | * regex.c (set_image_of_range_1, set_image_of_range) |
4034 | (regex_grow_registers): Likewise. | |
4035 | * sysdep.c (strerror): Likewise. | |
4036 | * termcap.c (valid_filename_p, tprint, main): Likewise. | |
4037 | * tparam.c (main): Likewise. | |
4038 | * unexhp9k800.c (run_time_remap, save_data_space) | |
4039 | (update_file_ptrs, read_header, write_header, calculate_checksum) | |
4040 | (copy_file, copy_rest, display_header): Likewise. | |
4041 | * widget.c (mark_shell_size_user_specified, create_frame_gcs): | |
4042 | Likewise. | |
4043 | * xdisp.c (check_it): Likewise. | |
4044 | * xfaces.c (register_color, unregister_color, unregister_colors): | |
4045 | Likewise. | |
4046 | * xfns.c (print_fontset_result): Likewise. | |
4047 | * xrdb.c (member, fatal, main): Likewise. | |
4048 | ||
99033785 PE |
4049 | 2011-07-10 Paul Eggert <eggert@cs.ucla.edu> |
4050 | ||
4051 | Fix minor problems found by static checking (Bug#9031). | |
4052 | * chartab.c (char_table_set_range, map_sub_char_table): | |
4053 | Remove unused locals. | |
4054 | (uniprop_table): Now static. | |
4055 | * composite.c (_work_char): Remove unused static var. | |
4056 | ||
9cb2ac56 JB |
4057 | 2011-07-09 Juanma Barranquero <lekktu@gmail.com> |
4058 | ||
4059 | * chartab.c (uniprop_table_uncompress): Remove unused local variable. | |
4060 | ||
f25661f0 JD |
4061 | 2011-07-09 Jan Djärv <jan.h.d@swipnet.se> |
4062 | ||
4063 | * gtkutil.c (qttip_cb): Remove code without function. | |
4064 | ||
8278c4fe EZ |
4065 | 2011-07-09 Eli Zaretskii <eliz@gnu.org> |
4066 | ||
4067 | * w32.c (pthread_sigmask): New stub. | |
4068 | ||
1692ae2d | 4069 | 2011-07-08 Paul Eggert <eggert@cs.ucla.edu> |
123403e4 | 4070 | |
8a6ebd58 | 4071 | Use pthread_sigmask, not sigprocmask (Bug#9010). |
123403e4 PE |
4072 | sigprocmask is portable only for single-threaded applications, and |
4073 | Emacs can be multi-threaded when it uses GTK. | |
1301ac26 PE |
4074 | * Makefile.in (LIB_PTHREAD_SIGMASK): New macro. |
4075 | (LIBES): Use it. | |
4076 | * callproc.c (Fcall_process): | |
4077 | * process.c (create_process): | |
4078 | * sysdep.c (sys_sigblock, sys_sigunblock, sys_sigsetmask): | |
4079 | Use pthread_sigmask, not sigprocmask. | |
123403e4 | 4080 | |
1b854618 JD |
4081 | 2011-07-08 Jan Djärv <jan.h.d@swipnet.se> |
4082 | ||
4083 | * gtkutil.c (qttip_cb): Set line wrap to FALSE for tooltip widget. | |
4084 | (xg_prepare_tooltip): Revert text in x->ttip_lbl, margins was | |
4085 | wrong (Bug#8591). | |
4086 | ||
3fe4b549 JD |
4087 | 2011-07-08 Jan Djärv <jan.h.d@swipnet.se> |
4088 | ||
0ce7e563 JD |
4089 | * gtkutil.c (xg_prepare_tooltip): Fix indentation and comment. |
4090 | Put text in x->ttip_lbl instead of gtk_tooltip_set_text (Bug#8591). | |
4091 | (xg_hide_tooltip): Fix comment. | |
4092 | ||
3fe4b549 JD |
4093 | * nsterm.m (initFrameFromEmacs): Don't use ns_return_types |
4094 | in registerServicesMenuSendTypes. | |
4095 | (validRequestorForSendType): Don't check ns_return_types. | |
4096 | ||
4097 | * nsfns.m (Fx_open_connection): Put NSStringPboardType into | |
4098 | ns_return_type. | |
4099 | ||
5df75e47 JR |
4100 | 2011-07-08 Jason Rumney <jasonr@gnu.org> |
4101 | ||
22610910 JR |
4102 | * w32term.c (x_make_frame_visible): Use SH_SHOWNORMAL rather than |
4103 | SH_SHOW for hidden windows (Bug#5482). | |
4104 | ||
5df75e47 JR |
4105 | * w32fns.c (w32_wnd_proc) [WM_TIMER, WM_SET_CURSOR]: Avoid using |
4106 | frame struct members of non-existent frames (Bug#6284). | |
4107 | ||
699c10bd JD |
4108 | 2011-07-08 Jan Djärv <jan.h.d@swipnet.se> |
4109 | ||
4393663b JD |
4110 | * nsterm.m (keyDown): Call to wantsToDelayTextChangeNotifications and |
4111 | variable firstTime not needed on OSX >= 10.6. | |
4112 | (setPosition): setFloatValue:knobProportion: is deprecated on OSX | |
4113 | >= 10.5. Use setKnobProportion, setDoubleValue. | |
4114 | ||
4115 | * nsterm.h (MAC_OS_X_VERSION_10_3, MAC_OS_X_VERSION_10_4) | |
4116 | (MAC_OS_X_VERSION_10_5): Define if not defined. | |
4117 | (EmacsView, EmacsTooltip): Implements NSWindowDelegate on OSX >= 10.6. | |
4118 | (EmacsMenu): Implements NSMenuDelegate on OSX >= 10.6. | |
4119 | (EmacsToolbar): Implements NSToolbarDelegate on OSX >= 10.6. | |
4120 | ||
4121 | * nsselect.m (ns_string_from_pasteboard): Don't use deprecated methods | |
4122 | cString and lossyCString on OSX >= 10.4 | |
4123 | ||
58179cce | 4124 | * nsmenu.m (fillWithWidgetValue): Don't use deprecated method |
4393663b JD |
4125 | sizeToFit on OSX >= 10.2. |
4126 | ||
4127 | * nsimage.m (allocInitFromFile): Don't use deprecated method | |
4128 | bestRepresentationForDevice on OSX >= 10.6. | |
4129 | ||
4130 | * nsfns.m (check_ns_display_info): Cast to long and use %ld in error | |
4131 | to avoid warning. | |
4132 | ||
4133 | * emacs.c: Declare unexec_init_emacs_zone. | |
4134 | ||
a63e0781 JD |
4135 | * nsgui.h: Fix compiler warning about gnulib redefining verify. |
4136 | ||
699c10bd JD |
4137 | * nsselect.m (ns_get_local_selection): Change to extern (Bug#8842). |
4138 | ||
4139 | * nsmenu.m (ns_update_menubar): Remove useless setDelegate call | |
4140 | on svcsMenu (Bug#8842). | |
4141 | ||
4142 | * nsfns.m (Fx_open_connection): Remove NSStringPboardType from | |
4143 | ns_return_types. | |
4144 | (Fns_list_services): Just return Qnil on 10.6, code not working there. | |
4145 | ||
4146 | * nsterm.m (QUTF8_STRING): Declare. | |
4147 | (initFrameFromEmacs): Call registerServicesMenuSendTypes. | |
4148 | (validRequestorForSendType): Return type is (id). | |
4149 | Change indexOfObjectIdenticalTo to indexOfObject. | |
4150 | Check if we have local selection before returning self (Bug#8842). | |
4151 | (writeSelectionToPasteboard): Put local selection into paste board | |
4152 | if we have a local selection (Bug#8842). | |
4153 | (syms_of_nsterm): DEFSYM QUTF8_STRING. | |
4154 | ||
4155 | * nsterm.h (MAC_OS_X_VERSION_10_6): Define here instead of nsterm.m. | |
4156 | (ns_get_local_selection): Declare. | |
4157 | ||
54e10184 LMI |
4158 | 2011-07-07 Lars Magne Ingebrigtsen <larsi@gnus.org> |
4159 | ||
9888ff71 LMI |
4160 | * keymap.c (describe_map_tree): Don't insert a double newline at |
4161 | the end of the buffer (bug#1169) and return whether we inserted | |
4162 | something. | |
4163 | ||
54e10184 LMI |
4164 | * callint.c (Fcall_interactively): Change "reading args" to |
4165 | "providing args" to try to clarify what it does (bug#1010). | |
4166 | ||
15fa4783 KH |
4167 | 2011-07-07 Kenichi Handa <handa@m17n.org> |
4168 | ||
4169 | * composite.c (composition_compute_stop_pos): Ignore a static | |
4170 | composition starting before CHARPOS (Bug#8915). | |
4171 | ||
4172 | * xdisp.c (handle_composition_prop): Likewise. | |
4173 | ||
a8815b00 EZ |
4174 | 2011-07-07 Eli Zaretskii <eliz@gnu.org> |
4175 | ||
4176 | * term.c (produce_glyphs) <xassert>: Allow IT_GLYPHLESS in it->what. | |
4177 | (Bug#9015) | |
4178 | ||
ef7b981d | 4179 | 2011-07-07 Kenichi Handa <handa@m17n.org> |
c805dec0 KH |
4180 | |
4181 | * character.h (unicode_category_t): New enum type. | |
4182 | ||
4183 | * chartab.c (uniprop_decoder_t, uniprop_encoder_t): New types. | |
4184 | (Qchar_code_property_table): New variable. | |
4185 | (UNIPROP_TABLE_P, UNIPROP_GET_DECODER) | |
4186 | (UNIPROP_COMPRESSED_FORM_P): New macros. | |
4187 | (char_table_ascii): Uncompress the compressed values. | |
4188 | (sub_char_table_ref): New arg is_uniprop. Callers changed. | |
4189 | Uncompress the compressed values. | |
ac389d0c | 4190 | (sub_char_table_ref_and_range): Likewise. |
c805dec0 KH |
4191 | (char_table_ref_and_range): Uncompress the compressed values. |
4192 | (sub_char_table_set): New arg is_uniprop. Callers changed. | |
4193 | Uncompress the compressed values. | |
4194 | (sub_char_table_set_range): Args changed. Callers changed. | |
4195 | (char_table_set_range): Adjuted for the above change. | |
4196 | (map_sub_char_table): Delete args default_val and parent. Add arg | |
4197 | top. Give decoded values to a Lisp function. | |
640c8776 | 4198 | (map_char_table): Adjust for the above change. Give decoded |
c805dec0 KH |
4199 | values to a Lisp function. Gcpro more variables. |
4200 | (uniprop_table_uncompress) | |
4201 | (uniprop_decode_value_run_length): New functions. | |
4202 | (uniprop_decoder, uniprop_decoder_count): New variables. | |
4203 | (uniprop_get_decoder, uniprop_encode_value_character) | |
4204 | (uniprop_encode_value_run_length, uniprop_encode_value_numeric): | |
4205 | New functions. | |
4206 | (uniprop_encoder, uniprop_encoder_count): New variables. | |
4207 | (uniprop_get_encoder, uniprop_table) | |
4208 | (Funicode_property_table_internal, Fget_unicode_property_internal) | |
4209 | (Fput_unicode_property_internal): New functions. | |
4210 | (syms_of_chartab): DEFSYM Qchar_code_property_table, defsubr | |
4211 | Sunicode_property_table_internal, Sget_unicode_property_internal, | |
5e617bc2 | 4212 | and Sput_unicode_property_internal. Defvar_lisp |
c805dec0 KH |
4213 | char-code-property-alist. |
4214 | ||
640c8776 | 4215 | * composite.c (CHAR_COMPOSABLE_P): Adjust for the change of |
c805dec0 KH |
4216 | Vunicode_category_table. |
4217 | ||
640c8776 | 4218 | * font.c (font_range): Adjust for the change of |
c805dec0 KH |
4219 | Vunicode_category_table. |
4220 | ||
76b397fb DN |
4221 | 2011-07-07 Dan Nicolaescu <dann@ics.uci.edu> |
4222 | ||
4223 | * m/iris4d.h: Remove file, move contents ... | |
4224 | * s/irix6-5.h: ... here. | |
4225 | ||
22b4128e PE |
4226 | 2011-07-06 Paul Eggert <eggert@cs.ucla.edu> |
4227 | ||
4228 | Remove unportable assumption about struct layout (Bug#8884). | |
8a5c77bb PE |
4229 | * alloc.c (mark_buffer): |
4230 | * buffer.c (reset_buffer_local_variables, Fbuffer_local_variables) | |
4231 | (clone_per_buffer_values): Don't assume that | |
22b4128e PE |
4232 | sizeof (struct buffer) is a multiple of sizeof (Lisp_Object). |
4233 | This isn't true in general, and it's particularly not true | |
4234 | if Emacs is configured with --with-wide-int. | |
4235 | * buffer.h (FIRST_FIELD_PER_BUFFER, LAST_FIELD_PER_BUFFER): | |
4236 | New macros, used in the buffer.c change. | |
4237 | ||
869795d6 JD |
4238 | 2011-07-05 Jan Djärv <jan.h.d@swipnet.se> |
4239 | ||
4240 | * xsettings.c: Use both GConf and GSettings if both are available. | |
4241 | (store_config_changed_event): Add comment. | |
4242 | (dpyinfo_valid, store_font_name_changed, map_tool_bar_style) | |
4243 | (store_tool_bar_style_changed): New functions. | |
5e617bc2 | 4244 | (store_monospaced_changed): Add comment. Call dpyinfo_valid. |
869795d6 JD |
4245 | (struct xsettings): Move font inside HAVE_XFT. |
4246 | (GSETTINGS_TOOL_BAR_STYLE, GSETTINGS_FONT_NAME): New defines. | |
640c8776 | 4247 | (GSETTINGS_MONO_FONT): Rename from SYSTEM_MONO_FONT. |
869795d6 | 4248 | Move inside HAVE_XFT. |
640c8776 | 4249 | (something_changed_gsettingsCB): Rename from something_changedCB. |
869795d6 JD |
4250 | Check for changes in GSETTINGS_TOOL_BAR_STYLE and GSETTINGS_FONT_NAME |
4251 | also. | |
4252 | (GCONF_TOOL_BAR_STYLE, GCONF_FONT_NAME): New defines. | |
5e617bc2 | 4253 | (GCONF_MONO_FONT): Rename from SYSTEM_MONO_FONT. Move inside HAVE_XFT. |
640c8776 | 4254 | (something_changed_gconfCB): Rename from something_changedCB. |
869795d6 JD |
4255 | Check for changes in GCONF_TOOL_BAR_STYLE and GCONF_FONT_NAME also. |
4256 | (parse_settings): Move check for font inside HAVE_XFT. | |
4257 | (read_settings, apply_xft_settings): Add comment. | |
4258 | (read_and_apply_settings): Add comment. Call map_tool_bar_style and | |
4259 | store_tool_bar_style_changed. Move check for font inside HAVE_XFT and | |
4260 | call store_font_name_changed. | |
4261 | (xft_settings_event): Add comment. | |
4262 | (init_gsettings): Add comment. Get values for GSETTINGS_TOOL_BAR_STYLE | |
4263 | and GSETTINGS_FONT_NAME. Move check for fonts within HAVE_XFT. | |
4264 | (init_gconf): Add comment. Get values for GCONF_TOOL_BAR_STYLE | |
4265 | and GCONF_FONT_NAME. Move check for fonts within HAVE_XFT. | |
4266 | (xsettings_initialize): Call init_gsettings last. | |
640c8776 SM |
4267 | (xsettings_get_system_font, xsettings_get_system_normal_font): |
4268 | Add comment. | |
869795d6 | 4269 | |
d8ed26bd PE |
4270 | 2011-07-05 Paul Eggert <eggert@cs.ucla.edu> |
4271 | ||
4272 | Random fixes. E.g., (random) never returned negative values. | |
4273 | * fns.c (Frandom): Use GET_EMACS_TIME for random seed, and add the | |
4274 | subseconds part to the entropy, as that's a bit more random. | |
4275 | Prefer signed to unsigned, since the signedness doesn't matter and | |
4276 | in general we prefer signed. When given a limit, use a | |
4277 | denominator equal to INTMASK + 1, not to VALMASK + 1, because the | |
4278 | latter isn't right if USE_2_TAGS_FOR_INTS. | |
4279 | * sysdep.c (get_random): Return a value in the range 0..INTMASK, | |
4280 | not 0..VALMASK. Don't discard "excess" bits that random () returns. | |
4281 | ||
cabf1cac SM |
4282 | 2011-07-04 Stefan Monnier <monnier@iro.umontreal.ca> |
4283 | ||
4284 | * textprop.c (text_property_stickiness): | |
4285 | Obey Vtext_property_default_nonsticky. | |
4286 | (syms_of_textprop): Add `display' to Vtext_property_default_nonsticky. | |
4287 | * w32fns.c (syms_of_w32fns): | |
4288 | * xfns.c (syms_of_xfns): Don't Add `display' since it's there by default. | |
4289 | ||
6e9b2be9 PE |
4290 | 2011-07-04 Paul Eggert <eggert@cs.ucla.edu> |
4291 | ||
4292 | * fileio.c (barf_or_query_if_file_exists): Use S_ISDIR. | |
4293 | This is more efficient than Ffile_directory_p and avoids a minor race. | |
4294 | ||
90186c68 LMI |
4295 | 2011-07-04 Lars Magne Ingebrigtsen <larsi@gnus.org> |
4296 | ||
7c301272 LMI |
4297 | * buffer.c (Foverlay_put): Say what the return value is |
4298 | (bug#7835). | |
4299 | ||
c4f2d8d4 LMI |
4300 | * fileio.c (barf_or_query_if_file_exists): Check first if the file |
4301 | is a directory before asking whether to use the file name | |
4302 | (bug#7564). | |
ad637907 LMI |
4303 | (barf_or_query_if_file_exists): Make the "File is a directory" |
4304 | error be more correct. | |
c4f2d8d4 | 4305 | |
90186c68 LMI |
4306 | * fns.c (Frequire): Remove the mention of the .gz files, since |
4307 | that's installation-specific, but keep the mention of | |
4308 | `get-load-suffixes'. | |
4309 | ||
da64016e PE |
4310 | 2011-07-04 Paul Eggert <eggert@cs.ucla.edu> |
4311 | ||
4312 | * editfns.c (Fformat_time_string): Don't assume strlen fits in int. | |
4313 | Report string overflow if the output is too long. | |
4314 | ||
7d47b580 JB |
4315 | 2011-07-04 Juanma Barranquero <lekktu@gmail.com> |
4316 | ||
a555cb87 JB |
4317 | * gnutls.c (Fgnutls_boot): Don't mention :verify-error. |
4318 | (syms_of_gnutls): Remove duplicate DEFSYM for | |
4319 | Qgnutls_bootprop_verify_hostname_error, an error for | |
4320 | Qgnutls_bootprop_verify_error (which is no longer used). | |
4321 | ||
7d47b580 JB |
4322 | * eval.c (find_handler_clause): Remove parameters `sig' and `data', |
4323 | unused since 2011-01-26T20:02:07Z!monnier@iro.umontreal.ca. All callers changed. | |
4324 | Also (re)move comments that are misplaced or no longer relevant. | |
4325 | ||
1e49bfab LMI |
4326 | 2011-07-03 Lars Magne Ingebrigtsen <larsi@gnus.org> |
4327 | ||
4328 | * callint.c (Finteractive): Clarify the meaning of "@" (bug#8813). | |
4329 | ||
1485f4c0 CY |
4330 | 2011-07-03 Chong Yidong <cyd@stupidchicken.com> |
4331 | ||
4332 | * xfaces.c (Finternal_merge_in_global_face): Modify the foreground | |
4333 | and background color parameters if they have been changed. | |
4334 | ||
a9ab721e LMI |
4335 | 2011-07-03 Lars Magne Ingebrigtsen <larsi@gnus.org> |
4336 | ||
4337 | * editfns.c (Fformat): Clarify the - and 0 flags (bug#6659). | |
4338 | ||
cf7cff57 PE |
4339 | 2011-07-03 Paul Eggert <eggert@cs.ucla.edu> |
4340 | ||
2e13213d PE |
4341 | * xsettings.c (SYSTEM_FONT): Define only when used. |
4342 | No need to define when HAVE_GSETTINGS || !HAVE_XFT. | |
4343 | ||
cf7cff57 PE |
4344 | * keymap.c (access_keymap_1): Now static. |
4345 | ||
7a8e04f7 CY |
4346 | 2011-07-02 Chong Yidong <cyd@stupidchicken.com> |
4347 | ||
4348 | * keyboard.c (command_loop_1): If a down-mouse event is unbound, | |
4349 | leave any prefix arg for the up event (Bug#1586). | |
4350 | ||
61352f62 LMI |
4351 | 2011-07-02 Lars Magne Ingebrigtsen <larsi@gnus.org> |
4352 | ||
69bb1ef7 LMI |
4353 | * lread.c (syms_of_lread): Mention single symbols defined by |
4354 | `defvar' or `defconst' (bug#7154). | |
4355 | ||
61352f62 | 4356 | * fns.c (Frequire): Mention .el.gz files (bug#7314). |
7b3747f9 | 4357 | (Frequire): Mention get-load-suffixes. |
61352f62 | 4358 | |
28545e04 MR |
4359 | 2011-07-02 Martin Rudalics <rudalics@gmx.at> |
4360 | ||
4361 | * window.h (window): Remove clone_number slot. | |
4362 | * window.c (Fwindow_clone_number, Fset_window_clone_number): | |
4363 | Remove. | |
4364 | (make_parent_window, make_window, saved_window) | |
4365 | (Fset_window_configuration, save_window_save): Don't deal with | |
4366 | clone numbers. | |
4367 | * buffer.c (Qclone_number): Remove declaration. | |
4368 | (sort_overlays, overlay_strings): Don't deal with clone numbers. | |
4369 | ||
3349e122 SM |
4370 | 2011-07-02 Stefan Monnier <monnier@iro.umontreal.ca> |
4371 | ||
4372 | Add multiple inheritance to keymaps. | |
4373 | * keymap.c (Fmake_composed_keymap): New function. | |
4374 | (Fset_keymap_parent): Simplify. | |
4375 | (fix_submap_inheritance): Remove. | |
4376 | (access_keymap_1): New function extracted from access_keymap to handle | |
4377 | embedded parents and handle lists of maps. | |
4378 | (access_keymap): Use it. | |
4379 | (Fkeymap_prompt, map_keymap_internal, map_keymap, store_in_keymap) | |
4380 | (Fcopy_keymap): Handle embedded parents. | |
4381 | (Fcommand_remapping, define_as_prefix): Simplify. | |
4382 | (Fkey_binding): Simplify. | |
4383 | (syms_of_keymap): Move minibuffer-local-completion-map, | |
4384 | minibuffer-local-filename-completion-map, | |
4385 | minibuffer-local-must-match-map, and | |
4386 | minibuffer-local-filename-must-match-map to Elisp. | |
4387 | (syms_of_keymap): Defsubr make-composed-keymap. | |
4388 | * keyboard.c (menu_bar_items): Use map_keymap_canonical. | |
4389 | (parse_menu_item): Trivial simplification. | |
4390 | ||
3279eb87 GM |
4391 | 2011-07-01 Glenn Morris <rgm@gnu.org> |
4392 | ||
4393 | * Makefile.in (SETTINGS_LIBS): Fix typo. | |
4394 | ||
4550efdf KI |
4395 | 2011-07-01 Kazuhiro Ito <kzhr@d1.dion.ne.jp> (tiny patch) |
4396 | ||
4397 | * coding.c (Fencode_coding_string): Record the last coding system | |
4398 | used, as the function doc string says (bug#8738). | |
4399 | ||
0949d2b6 JD |
4400 | 2011-07-01 Jan Djärv <jan.h.d@swipnet.se> |
4401 | ||
4402 | * xsettings.c (store_monospaced_changed): Take new font as arg and | |
4403 | check for change against current_mono_font. | |
4404 | (EMACS_TYPE_SETTINGS): Remove this and related defines. | |
4405 | (emacs_settings_constructor, emacs_settings_get_property) | |
4406 | (emacs_settings_set_property, emacs_settings_class_init) | |
4407 | (emacs_settings_init, gsettings_obj): Remove. | |
4408 | (something_changedCB): New function for HAVE_GSETTINGS. | |
4409 | (something_changedCB): HAVE_GCONF: Call store_monospaced_changed | |
4410 | with value as argument. | |
4411 | (init_gsettings): Check that GSETTINGS_SCHEMA exists before calling | |
4412 | g_settings_new (Bug#8967). Do not create gsettings_obj. | |
9173deec | 4413 | Remove calls to g_settings_bind. Connect something_changedCB to |
0949d2b6 JD |
4414 | "changed". |
4415 | ||
4416 | * xgselect.c: Add defined (HAVE_GSETTINGS). | |
4417 | (xgselect_initialize): Ditto. | |
4418 | ||
4419 | * process.c: Add defined (HAVE_GSETTINGS) for xgselect.h | |
4420 | (wait_reading_process_output): Add defined (HAVE_GSETTINGS) for | |
4421 | xg_select. | |
4422 | ||
bbc6b304 PE |
4423 | 2011-07-01 Paul Eggert <eggert@cs.ucla.edu> |
4424 | ||
4425 | * eval.c (struct backtrace): Simplify and port the data structure. | |
4426 | Do not assume that "int nargs : BITS_PER_INT - 2;" produces a | |
4427 | signed bit field, as this assumption is not portable and it makes | |
4428 | Emacs crash when compiled with Sun C 5.8 on sparc. Do not use | |
4429 | "char debug_on_exit : 1" as this is not portable either; instead, | |
4430 | use the portable "unsigned int debug_on_exit : 1". Remove unused | |
4431 | member evalargs. Remove obsolete comments about cc bombing out. | |
4432 | ||
9851bfc5 JD |
4433 | 2011-06-30 Jan Djärv <jan.h.d@swipnet.se> |
4434 | ||
51bb811f | 4435 | * xsettings.c: Include glib-object.h, gio/gio.h if HAVE_GSETTINGS. |
9851bfc5 JD |
4436 | Let HAVE_GSETTINGS override HAVE_GCONF. |
4437 | (store_monospaced_changed): New function. | |
4438 | (EMACS_SETTINGS): A new type derived from GObject to handle | |
4439 | GSettings notifications. | |
4440 | (emacs_settings_constructor, emacs_settings_get_property) | |
4441 | (emacs_settings_set_property, emacs_settings_class_init): | |
4442 | New functions. | |
4443 | (gsettings_client, gsettings_obj): New variables. | |
4444 | (GSETTINGS_SCHEMA): New define. | |
4445 | (something_changedCB): Call store_monospaced_changed. | |
4446 | (init_gsettings): New function. | |
4447 | (xsettings_initialize): Call init_gsettings. | |
4448 | (syms_of_xsettings): Initialize gsettings_client, gsettings_obj | |
4449 | to NULL. | |
4450 | ||
640c8776 | 4451 | * Makefile.in (SETTINGS_CFLAGS, SETTINGS_LIBS): Rename from |
9851bfc5 JD |
4452 | GCONF_CFLAGS/LIBS. |
4453 | ||
5386012d MR |
4454 | 2011-06-29 Martin Rudalics <rudalics@gmx.at> |
4455 | ||
4456 | * window.c (resize_root_window, grow_mini_window) | |
4457 | (shrink_mini_window): Rename Qresize_root_window to | |
4458 | Qwindow_resize_root_window and Qresize_root_window_vertically to | |
4459 | Qwindow_resize_root_window_vertically. | |
4460 | ||
f13e0b08 PE |
4461 | 2011-06-28 Paul Eggert <eggert@cs.ucla.edu> |
4462 | ||
4463 | * gnutls.c (Qgnutls_bootprop_verify_error): Remove unused var. | |
4464 | ||
94515237 JB |
4465 | 2011-06-27 Juanma Barranquero <lekktu@gmail.com> |
4466 | ||
4467 | * makefile.w32-in: Redesign dependencies so they reflect more | |
4468 | clearly which files are directly included by each source file, | |
4469 | and not through other includes. | |
4470 | ||
e43b6e43 MR |
4471 | 2011-06-27 Martin Rudalics <rudalics@gmx.at> |
4472 | ||
4473 | * buffer.c (Qclone_number): Declare static and DEFSYM it. | |
4474 | (sort_overlays, overlay_strings): When an overlay's clone number | |
4475 | matches the window's clone number process the overlay even if | |
4476 | the overlay's window property doesn't match the current window. | |
4477 | ||
d68443dc MR |
4478 | * window.c (Fwindow_vchild): Rename to Fwindow_top_child. |
4479 | (Fwindow_hchild): Rename to Fwindow_left_child. | |
4480 | (Fwindow_next): Rename to Fwindow_next_sibling. | |
4481 | (Fwindow_prev): Rename to Fwindow_prev_sibling. | |
d615d6d2 MR |
4482 | (resize_window_check): Rename to window_resize_check. |
4483 | (resize_window_apply): Rename to window_resize_apply. | |
4484 | (Fresize_window_apply): Rename to Fwindow_resize_apply. | |
4485 | (Fdelete_other_windows_internal, resize_frame_windows) | |
4486 | (Fsplit_window_internal, Fdelete_window_internal) | |
4487 | (grow_mini_window, shrink_mini_window) | |
4488 | (Fresize_mini_window_internal): Fix callers accordingly. | |
d68443dc | 4489 | |
c7e73be5 JD |
4490 | 2011-06-26 Jan Djärv <jan.h.d@swipnet.se> |
4491 | ||
4492 | * emacsgtkfixed.h: State that this is only used with Gtk+3. | |
4493 | (emacs_fixed_set_min_size): Remove. | |
4494 | (emacs_fixed_new): Take frame as argument. | |
4495 | ||
4496 | * emacsgtkfixed.c: State that this is only used with Gtk+3. | |
4497 | (_EmacsFixedPrivate): Remove minwidth/height. | |
4498 | Add struct frame *f. | |
4499 | (emacs_fixed_init): Initialize priv->f. | |
4500 | (get_parent_class, emacs_fixed_set_min_size): Remove. | |
4501 | (emacs_fixed_new): Set priv->f to argument. | |
4502 | (emacs_fixed_get_preferred_width) | |
4503 | (emacs_fixed_get_preferred_height): Use min_width/height from | |
4504 | frames size_hint to set minimum and natural (Bug#8919). | |
4505 | (XSetWMSizeHints, XSetWMNormalHints): Override these functions | |
4506 | and use min_width/height from frames size_hint to set | |
4507 | min_width/height (Bug#8919). | |
4508 | ||
4509 | * gtkutil.c (xg_create_frame_widgets): Pass f to emacs_fixed_new. | |
9173deec JB |
4510 | (x_wm_set_size_hint): Remove call to emacs_fixed_set_min_size. |
4511 | Fix indentation. | |
c7e73be5 | 4512 | |
cf99dcf8 EZ |
4513 | 2011-06-26 Eli Zaretskii <eliz@gnu.org> |
4514 | ||
4515 | * bidi.c (bidi_paragraph_init): Test for ZV_BYTE before calling | |
4516 | bidi_at_paragraph_end, since fast_looking_at doesn't like to be | |
4517 | called at ZV. | |
4518 | ||
029529ac CY |
4519 | 2011-06-26 Chong Yidong <cyd@stupidchicken.com> |
4520 | ||
4521 | * process.c (wait_reading_process_output): Bypass select if | |
4522 | waiting for a cell while ignoring keyboard input, and input is | |
4523 | pending. Suggested by Jan Djärv (Bug#8869). | |
4524 | ||
7a7ef429 PE |
4525 | 2011-06-25 Paul Eggert <eggert@cs.ucla.edu> |
4526 | ||
4527 | Use gnulib's dup2 module instead of rolling our own. | |
4528 | * sysdep.c (dup2) [!HAVE_DUP2]: Remove; gnulib now does this. | |
4529 | ||
11fdef7d | 4530 | 2011-06-25 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
989b42d2 YM |
4531 | |
4532 | * dispnew.c (scrolling_window): Before scrolling, turn off a | |
4533 | mouse-highlight in the window being scrolled. | |
4534 | ||
cd3520a4 JB |
4535 | 2011-06-24 Juanma Barranquero <lekktu@gmail.com> |
4536 | ||
4537 | Move DEFSYM to lisp.h and use everywhere. | |
4538 | ||
4539 | * character.h (DEFSYM): Move declaration... | |
4540 | * lisp.h (DEFSYM): ...here. | |
4541 | ||
4542 | * gnutls.c: | |
4543 | * minibuf.c: | |
4544 | * w32menu.c: | |
4545 | * w32proc.c: | |
4546 | * w32select.c: Don't include character.h. | |
4547 | ||
4548 | * alloc.c (syms_of_alloc): | |
4549 | * buffer.c (syms_of_buffer): | |
4550 | * bytecode.c (syms_of_bytecode): | |
4551 | * callint.c (syms_of_callint): | |
4552 | * casefiddle.c (syms_of_casefiddle): | |
4553 | * casetab.c (init_casetab_once): | |
4554 | * category.c (init_category_once, syms_of_category): | |
4555 | * ccl.c (syms_of_ccl): | |
4556 | * cmds.c (syms_of_cmds): | |
4557 | * composite.c (syms_of_composite): | |
4558 | * dbusbind.c (syms_of_dbusbind): | |
4559 | * dired.c (syms_of_dired): | |
4560 | * dispnew.c (syms_of_display): | |
4561 | * doc.c (syms_of_doc): | |
4562 | * editfns.c (syms_of_editfns): | |
4563 | * emacs.c (syms_of_emacs): | |
4564 | * eval.c (syms_of_eval): | |
4565 | * fileio.c (syms_of_fileio): | |
4566 | * fns.c (syms_of_fns): | |
4567 | * frame.c (syms_of_frame): | |
4568 | * fringe.c (syms_of_fringe): | |
4569 | * insdel.c (syms_of_insdel): | |
4570 | * keymap.c (syms_of_keymap): | |
4571 | * lread.c (init_obarray, syms_of_lread): | |
4572 | * macros.c (syms_of_macros): | |
4573 | * msdos.c (syms_of_msdos): | |
4574 | * print.c (syms_of_print): | |
4575 | * process.c (syms_of_process): | |
4576 | * search.c (syms_of_search): | |
4577 | * sound.c (syms_of_sound): | |
4578 | * syntax.c (init_syntax_once, syms_of_syntax): | |
4579 | * terminal.c (syms_of_terminal): | |
4580 | * textprop.c (syms_of_textprop): | |
4581 | * undo.c (syms_of_undo): | |
4582 | * w32.c (globals_of_w32): | |
4583 | * window.c (syms_of_window): | |
4584 | * xdisp.c (syms_of_xdisp): | |
4585 | * xfaces.c (syms_of_xfaces): | |
4586 | * xfns.c (syms_of_xfns): | |
4587 | * xmenu.c (syms_of_xmenu): | |
4588 | * xsettings.c (syms_of_xsettings): | |
4589 | * xterm.c (syms_of_xterm): Use DEFSYM. | |
4590 | ||
4228cf16 TZ |
4591 | 2011-06-24 Teodor Zlatanov <tzz@lifelogs.com> |
4592 | ||
cd3520a4 | 4593 | * gnutls.c (syms_of_gnutls): Use the DEFSYM macro from character.h. |
4228cf16 | 4594 | |
7fcccf1e PE |
4595 | 2011-06-23 Paul Eggert <eggert@cs.ucla.edu> |
4596 | ||
7efb4e0e PE |
4597 | Integer and buffer overflow fixes (Bug#8873). |
4598 | ||
ff5844ad PE |
4599 | * print.c (printchar, strout): Check for string overflow. |
4600 | (PRINTPREPARE, printchar, strout): | |
4601 | Don't set size unless allocation succeeds. | |
4602 | ||
90532f02 PE |
4603 | * minibuf.c (read_minibuf_noninteractive): Use ptrdiff_t, not int, |
4604 | for sizes. Check for string overflow more accurately. | |
4605 | Simplify newline removal at end; this suppresses a GCC 4.6.0 warning. | |
4606 | ||
6d84508d PE |
4607 | * macros.c: Integer and buffer overflow fixes. |
4608 | * keyboard.h (struct keyboard.kbd_macro_bufsize): | |
4609 | * macros.c (Fstart_kbd_macro, store_kbd_macro_char): | |
4610 | Use ptrdiff_t, not int, for sizes. | |
4611 | Don't increment bufsize until after realloc succeeds. | |
4612 | Check for size-calculation overflow. | |
4613 | (Fstart_kbd_macro): Use EMACS_INT, not int, for XINT result. | |
4614 | ||
437b2cb4 PE |
4615 | * lisp.h (DEFVAR_KBOARD): Use offsetof instead of char * finagling. |
4616 | ||
8b9ac8b4 PE |
4617 | * lread.c: Integer overflow fixes. |
4618 | (read_integer): Radix is now EMACS_INT, not int, | |
4619 | to improve quality of diagnostics for out-of-range radices. | |
4620 | Calculate buffer size correctly for out-of-range radices. | |
4621 | (read1): Check for integer overflow in radices, and in | |
4622 | read-circle numbers. | |
82cb60d3 PE |
4623 | (read_escape): Avoid int overflow. |
4624 | (Fload, openp, read_buffer_size, read1) | |
4625 | (substitute_object_recurse, read_vector, read_list, map_obarray): | |
4626 | Use ptrdiff_t, not int, for sizes. | |
4627 | (read1): Use EMACS_INT, not int, for sizes. | |
20270765 | 4628 | Check for size overflow. |
8b9ac8b4 | 4629 | |
7fcccf1e PE |
4630 | * image.c (cache_image): Check for size arithmetic overflow. |
4631 | ||
bfbbd7e7 PE |
4632 | * lread.c: Integer overflow issues. |
4633 | (saved_doc_string_size, saved_doc_string_length) | |
4634 | (prev_saved_doc_string_size, prev_saved_doc_string_length): | |
4635 | Now ptrdiff_t, not int. | |
4636 | (read1): Don't assume doc string length fits in int. Check for | |
4637 | out-of-range doc string lengths. | |
4638 | (read_list): Don't assume file position fits in int. | |
39019e54 | 4639 | (read_escape): Check for hex character overflow. |
bfbbd7e7 | 4640 | |
4e323265 LL |
4641 | 2011-06-22 Leo Liu <sdl.web@gmail.com> |
4642 | ||
4643 | * minibuf.c (Fcompleting_read_default, Vcompleting_read_function): | |
4644 | Move to minibuffer.el. | |
4645 | ||
85fece3e PE |
4646 | 2011-06-22 Paul Eggert <eggert@cs.ucla.edu> |
4647 | ||
20b84ce9 | 4648 | Fixes for GLYPH_DEBUG found by GCC 4.6.0 static checking. |
85fece3e PE |
4649 | The following patches are for when GLYPH_DEBUG && !XASSERT. |
4650 | * dispextern.h (trace_redisplay_p, dump_glyph_string): | |
4651 | * dispnew.c (flush_stdout): | |
4652 | * xdisp.c (dump_glyph_row, dump_glyph_matrix, dump_glyph): | |
4653 | Mark as externally visible. | |
4654 | * dispnew.c (check_window_matrix_pointers): Now static. | |
4655 | * dispnew.c (window_to_frame_vpos): | |
4656 | * xfns.c (unwind_create_frame): | |
4657 | * xterm.c (x_check_font): Remove unused local. | |
4658 | * scroll.c (CHECK_BOUNDS): | |
4659 | * xfaces.c (cache_fache): Rename local to avoid shadowing. | |
4660 | * xfns.c, w32fns.c (image_cache_refcount, dpyinfo_refcount): Now static. | |
4661 | * xdisp.c (check_window_end): Now a no-op if !XASSERTS. | |
4662 | (debug_first_unchanged_at_end_vpos, debug_last_unchanged_at_beg_vpos) | |
4663 | (debug_dvpos, debug_dy, debug_delta, debug_delta_bytes, debug_end_vpos): | |
4664 | Now static. | |
4665 | (debug_method_add): Use va_list and vsprintf rather than relying | |
4666 | on undefined behavior with wrong number of arguments. | |
4667 | (dump_glyph, dump_glyph_row, Fdump_glyph_matrix): | |
4668 | Don't assume ptrdiff_t and EMACS_INT are the same width as int. | |
4669 | In this code, it's OK to assume C99 behavior for ptrdiff_t formats | |
4670 | since we're not interested in debugging glyphs with old libraries. | |
4671 | * xfaces.c (cache_face): Move debugging code earlier; this pacifies | |
4672 | GCC 4.6.0's static checking. | |
4673 | ||
0766b489 PE |
4674 | 2011-06-22 Paul Eggert <eggert@cs.ucla.edu> |
4675 | ||
31fd4b32 PE |
4676 | Integer overflow and signedness fixes (Bug#8873). |
4677 | A few related buffer overrun fixes, too. | |
4678 | ||
b79e8648 PE |
4679 | * font.c (font_score): Use EMACS_INT, not int, to store XINT value. |
4680 | ||
0766b489 PE |
4681 | * dispextern.h (struct face.stipple): |
4682 | * image.c (x_bitmap_height, x_bitmap_width, x_bitmap_pixmap) | |
4683 | (x_bitmap_mask, x_allocate_bitmap_record) | |
4684 | (x_create_bitmap_from_data, x_create_bitmap_from_file) | |
4685 | (x_destroy_bitmap, x_destroy_all_bitmaps, x_create_bitmap_mask) | |
4686 | (x_create_bitmap_from_xpm_data): | |
4687 | * nsterm.h (struct ns_display_info.bitmaps_size, .bitmaps_last): | |
4688 | * w32term.h (struct w32_display_info.icon_bitmap_id, .bitmaps_size) | |
4689 | (.bitmaps_last): | |
4690 | * xfaces.c (load_pixmap): | |
4691 | * xterm.c (x_bitmap_icon, x_wm_set_icon_pixmap): | |
4692 | * xterm.h (struct x_display_info.icon_bitmap_id, .bitmaps_size) | |
4693 | (.bitmaps_last, struct x_output.icon_bitmap): | |
4694 | Use ptrdiff_t, not int, for bitmap indexes. | |
4695 | (x_allocate_bitmap_record): Check for size overflow. | |
4696 | * dispextern.h, lisp.h: Adjust to API changes elsewhere. | |
4697 | ||
b081724f PE |
4698 | Use ptrdiff_t, not int, for overlay counts. |
4699 | * buffer.h (overlays_at, sort_overlays, GET_OVERLAYS_AT): | |
4700 | * editfns.c (overlays_around, get_pos_property): | |
4701 | * textprop.c (get_char_property_and_overlay): | |
4702 | * xdisp.c (next_overlay_change, note_mouse_highlight): | |
4703 | * xfaces.c (face_at_buffer_position): | |
21514da7 PE |
4704 | * buffer.c (OVERLAY_COUNT_MAX): New macro. |
4705 | (overlays_at, overlays_in, sort_overlays, Foverlays_at) | |
4706 | (Fnext_overlay_change, Fprevious_overlay_change) | |
4707 | (mouse_face_overlay_overlaps, Foverlays_in): | |
b081724f | 4708 | Use ptrdiff_t, not int, for sizes. |
21514da7 | 4709 | (overlays_at, overlays_in): Check for size-calculation overflow. |
b081724f | 4710 | |
3de73e5e PE |
4711 | * xterm.c (xim_initialize, same_x_server): Strlen may not fit in int. |
4712 | ||
2606c57b PE |
4713 | * xsmfns.c (smc_save_yourself_CB, x_session_initialize): Avoid strlen. |
4714 | (x_session_initialize): Do not assume string length fits in int. | |
4715 | ||
aaafe47a PE |
4716 | * xsettings.c (apply_xft_settings): Fix potential buffer overrun. |
4717 | This is unlikely, but can occur if DPI is outlandish. | |
4718 | ||
2674ddc8 | 4719 | * xsettings.c (Ffont_get_system_normal_font, Ffont_get_system_font): |
3a5077c5 PE |
4720 | * xselect.c (Fx_get_atom_name): Avoid need for strlen. |
4721 | ||
28154962 PE |
4722 | * xrdb.c: Don't assume strlen fits in int; avoid some strlens. |
4723 | * xrdb.c (magic_file_p, search_magic_path): | |
4724 | Omit last arg SUFFIX; it was always 0. All callers changed. | |
4725 | (magic_file_p): Use ptrdiff_t, not int. Check for size overflow. | |
4726 | ||
7de51af5 PE |
4727 | * xfont.c (xfont_match): Avoid need for strlen. |
4728 | ||
25ed6cc3 PE |
4729 | * xfns.c: Don't assume strlen fits in int. |
4730 | (xic_create_fontsetname, x_window): Use ptrdiff_t, not int. | |
4731 | ||
4eab31dd PE |
4732 | * xdisp.c (message_log_check_duplicate): Return intmax_t, |
4733 | not unsigned long, as we prefer signed integers. All callers changed. | |
4734 | Detect integer overflow in repeat count. | |
4735 | (message_dolog): Don't assume print length fits in 39 bytes. | |
df1f27af | 4736 | (display_mode_element): Don't assume strlen fits in int. |
4eab31dd | 4737 | |
171e2a58 PE |
4738 | * termcap.c: Don't assume sizes fit in int and never overflow. |
4739 | (struct termcap_buffer, tgetent): Use ptrdiff_t, not int, for sizes. | |
4740 | (gobble_line): Check for size-calculation overflow. | |
4741 | ||
ad39faca | 4742 | * minibuf.c (Fread_buffer): |
6e5bb2dc | 4743 | * lread.c (intern, intern_c_string): |
74ca2eb3 PE |
4744 | * image.c (xpm_scan) [HAVE_NS && !HAVE_XPM]: |
4745 | Don't assume string length fits in int. | |
4746 | ||
52c61c22 | 4747 | * keyboard.c (parse_tool_bar_item): |
9bda3520 PE |
4748 | * gtkutil.c (style_changed_cb): Avoid need for strlen. |
4749 | ||
b5b8c9e5 PE |
4750 | * font.c: Don't assume string length fits in int. |
4751 | (font_parse_xlfd, font_parse_fcname, font_unparse_fcname): | |
4752 | Use ptrdiff_t, not int. | |
ccd6111c PE |
4753 | (font_intern_prop): Don't assume string length fits in int. |
4754 | Don't assume integer property fits in fixnum. | |
4755 | * font.h (font_intern_prop): 2nd arg is now ptrdiff_t, not int. | |
b5b8c9e5 | 4756 | |
882f0d81 | 4757 | * filelock.c: Fix some buffer overrun and integer overflow issues. |
51cab52b | 4758 | (get_boot_time): Don't assume gzip command string fits in 100 bytes. |
882f0d81 PE |
4759 | Reformulate so as not to need the command string. |
4760 | Invoke gzip -cd rather than gunzip, as it's more portable. | |
4761 | (lock_info_type, lock_file_1, lock_file): | |
4762 | Don't assume pid_t and time_t fit in unsigned long. | |
4763 | (LOCK_PID_MAX): Remove; we now use more-reliable bounds. | |
4764 | (current_lock_owner): Prefer signed type for sizes. | |
4765 | Use memcpy, not strncpy, where memcpy is what is really wanted. | |
4766 | Don't assume (via atoi) that time_t and pid_t fit in int. | |
4767 | Check for time_t and/or pid_t out of range, e.g., via a network share. | |
4768 | Don't alloca where an auto var works fine. | |
4769 | ||
93f4cf88 PE |
4770 | * fileio.c: Fix some integer overflow issues. |
4771 | (file_name_as_directory, Fexpand_file_name, Fsubstitute_in_file_name): | |
4772 | Don't assume string length fits in int. | |
4773 | (directory_file_name): Don't assume string length fits in long. | |
4774 | (make_temp_name): Don't assume pid fits in int, or that its print | |
4775 | length is less than 20. | |
4776 | ||
f3e92b69 PE |
4777 | * data.c (Fsubr_name): Rewrite to avoid a strlen call. |
4778 | ||
1bfdaf10 PE |
4779 | * coding.c (make_subsidiaries): Don't assume string length fits in int. |
4780 | ||
35016e9a PE |
4781 | * callproc.c (child_setup): Rewrite to avoid two strlen calls. |
4782 | ||
3d1e65a1 PE |
4783 | * process.c (Fformat_network_address): Use EMACS_INT, not EMACS_UINT. |
4784 | We prefer signed integers, even for size calculations. | |
4785 | ||
0b963a93 PE |
4786 | * emacs.c: Don't assume string length fits in 'int'. |
4787 | (DEFINE_DUMMY_FUNCTION, sort_args): Use ptrdiff_t, not int. | |
4788 | (main): Don't invoke strlen when not needed. | |
4789 | ||
573f4b54 PE |
4790 | * dbusbind.c (XD_ERROR): Don't arbitrarily truncate string. |
4791 | (XD_DEBUG_MESSAGE): Don't waste a byte. | |
4792 | ||
989f33ba PE |
4793 | * callproc.c (getenv_internal_1, getenv_internal) |
4794 | (Fgetenv_internal): | |
965d34eb PE |
4795 | * buffer.c (init_buffer): Don't assume string length fits in 'int'. |
4796 | ||
e4d29b33 PE |
4797 | * lread.c (invalid_syntax): Omit length argument. |
4798 | All uses changed. This doesn't fix a bug, but it simplifies the | |
4799 | code away from its former Hollerith-constant appearance, and it's | |
4800 | one less 'int' to worry about when looking at integer-overflow issues. | |
51cab52b | 4801 | (string_to_number): Simplify 2011-04-26 change by invoking xsignal1. |
e4d29b33 | 4802 | |
eb49b136 PE |
4803 | * lisp.h (DEFUN): Remove bogus use of sizeof (struct Lisp_Subr). |
4804 | This didn't break anything, but it didn't help either. | |
4805 | It's confusing to put a bogus integer in a place where the actual | |
4806 | value does not matter. | |
9f62aeb1 | 4807 | (LIST_END_P): Remove unused macro and its bogus comment. |
cbeff735 | 4808 | (make_fixnum_or_float): Remove unnecessary cast to EMACS_INT. |
eb49b136 | 4809 | |
15375a22 PE |
4810 | * lisp.h (union Lisp_Object.i): EMACS_INT, not EMACS_UINT. |
4811 | This is for consistency with the ordinary, non-USE_LISP_UNION_TYPE, | |
4812 | implementation. | |
b61cc01c PE |
4813 | (struct Lisp_Bool_Vector.size): EMACS_INT, not EMACS_UINT. |
4814 | We prefer signed types, and the value cannot exceed the EMACS_INT | |
4815 | range anyway (because otherwise the length would not be representable). | |
9a8e8d9b PE |
4816 | (XSET) [USE_LISP_UNION_TYPE]: Use uintptr_t and intptr_t, |
4817 | not EMACS_UINT and EMACS_INT, when converting pointer to integer. | |
4818 | This avoids a GCC warning when WIDE_EMACS_INT. | |
15375a22 | 4819 | |
53b2623d PE |
4820 | * indent.c (sane_tab_width): New function. |
4821 | (current_column, scan_for_column, Findent_to, position_indentation) | |
4822 | (compute_motion): Use it. This is just for clarity. | |
8fcaf9cc | 4823 | (Fcompute_motion): Don't assume hscroll and tab offset fit in int. |
53b2623d | 4824 | |
51cab52b | 4825 | * image.c (xbm_image_p): Don't assume stated width, height fit in int. |
45aebb64 | 4826 | |
f2ed8a70 PE |
4827 | * lisp.h (lint_assume): New macro. |
4828 | * composite.c (composition_gstring_put_cache): | |
4829 | * ftfont.c (ftfont_shape_by_flt): Use it to pacify GCC 4.6.0. | |
4830 | ||
abe80cc6 PE |
4831 | * editfns.c, insdel.c: |
4832 | Omit unnecessary forward decls, to simplify future changes. | |
a9e860e1 | 4833 | |
b02c740e PE |
4834 | * ftfont.c (ftfont_shape_by_flt): Use signed integers for lengths. |
4835 | ||
ebc96716 PE |
4836 | * font.c (Ffont_shape_gstring): Don't assume glyph len fits in 'int'. |
4837 | ||
b4e50fa0 | 4838 | * fns.c (Ffillarray): Don't assume bool vector size fits in 'int'. |
f03dc6ef | 4839 | Use much-faster test for byte-length change. |
311d5d7c | 4840 | Don't assume string byte-length fits in 'int'. |
a4cf38e4 | 4841 | Check that character arg fits in 'int'. |
85461888 | 4842 | (mapcar1): Declare byte as byte, for clarity. |
b4e50fa0 | 4843 | |
c0c1ee9f PE |
4844 | * alloc.c (Fmake_bool_vector): Avoid unnecessary multiplication. |
4845 | ||
a498d7f4 PE |
4846 | * fns.c (concat): Catch string overflow earlier. |
4847 | Do not rely on integer wraparound. | |
4848 | ||
51cab52b PE |
4849 | * dispextern.h (struct it.overlay_strings_charpos) |
4850 | (struct it.selective): Now EMACS_INT, not int. | |
87830974 PE |
4851 | * xdisp.c (forward_to_next_line_start) |
4852 | (back_to_previous_visible_line_start) | |
4853 | (reseat_at_next_visible_line_start, next_element_from_buffer): | |
4854 | Don't arbitrarily truncate the value of 'selective' to int. | |
4855 | ||
76031fad PE |
4856 | * xdisp.c (init_iterator): Use XINT, not XFASTINT; it might be < 0. |
4857 | ||
5eb55db9 PE |
4858 | * composite.c: Don't truncate sizes to 'int'. |
4859 | (composition_gstring_p, composition_reseat_it) | |
4860 | (composition_adjust_point): Use EMACS_INT, not int. | |
7d100a81 PE |
4861 | (get_composition_id, composition_gstring_put_cache): Use EMACS_INT, |
4862 | not EMACS_UINT, for indexes. | |
5eb55db9 | 4863 | |
0703a717 PE |
4864 | * category.h (CATEGORY_SET_P): Remove unnecessary cast to EMACS_INT. |
4865 | ||
d6202519 PE |
4866 | * buffer.c: Include <verify.h>. |
4867 | (struct sortvec.priority, struct sortstr.priority): | |
8961a454 | 4868 | Now EMACS_INT, not int. |
c20998a7 | 4869 | (compare_overlays, cmp_for_strings): Avoid subtraction overflow. |
67c36fce PE |
4870 | (struct sortstr.size, record_overlay_string) |
4871 | (struct sortstrlist.size, struct sortlist.used): | |
4872 | Don't truncate size to int. | |
4873 | (record_overlay_string): Check for size-calculation overflow. | |
d6202519 | 4874 | (init_buffer_once): Check at compile-time, not run-time. |
fadf4e30 | 4875 | |
d5a19415 JM |
4876 | 2011-06-22 Jim Meyering <meyering@redhat.com> |
4877 | ||
029529ac | 4878 | Don't leak an XBM-image-sized buffer |
d5a19415 JM |
4879 | * image.c (xbm_load): Free the image buffer after using it. |
4880 | ||
a9041e6c PE |
4881 | 2011-06-21 Paul Eggert <eggert@cs.ucla.edu> |
4882 | ||
4883 | Port to Sun C. | |
4884 | * composite.c (find_automatic_composition): Omit needless 'return 0;' | |
4885 | that Sun C diagnosed. | |
4886 | * fns.c (secure_hash): Fix pointer signedness issue. | |
4887 | * intervals.c (static_offset_intervals): New function. | |
4888 | (offset_intervals): Use it. | |
4889 | ||
7f3f739f LL |
4890 | 2011-06-21 Leo Liu <sdl.web@gmail.com> |
4891 | ||
4892 | * deps.mk (fns.o): | |
4893 | * makefile.w32-in ($(BLD)/fns.$(O)): Include sha256.h and | |
4894 | sha512.h. | |
4895 | ||
4896 | * fns.c (secure_hash): Rename from crypto_hash_function and change | |
4897 | the first arg to accept symbols. | |
5b66d427 | 4898 | (Fsecure_hash): New primitive. |
7f3f739f LL |
4899 | (syms_of_fns): New symbols. |
4900 | ||
76147d94 DD |
4901 | 2011-06-20 Deniz Dogan <deniz@dogan.se> |
4902 | ||
4903 | * process.c (Fset_process_buffer): Clarify return value in | |
4904 | docstring. | |
4905 | ||
7d7d0045 CY |
4906 | 2011-06-18 Chong Yidong <cyd@stupidchicken.com> |
4907 | ||
4908 | * dispnew.c (add_window_display_history): Use BVAR. | |
4909 | ||
4910 | * xdisp.c (debug_method_add): Use BVAR. | |
4911 | (check_window_end, dump_glyph_matrix, dump_glyph) | |
4912 | (dump_glyph_row, dump_glyph_string): Convert arglist to ANSI C. | |
4913 | ||
4914 | * xfaces.c (check_lface_attrs, check_lface, dump_realized_face): | |
4915 | Likewise. | |
4916 | ||
4917 | * xfns.c (Fx_create_frame, x_create_tip_frame): Delay image cache | |
4918 | check till after the cache is created in init_frame_faces. | |
4919 | ||
ff2bc410 SM |
4920 | 2011-06-17 Stefan Monnier <monnier@iro.umontreal.ca> |
4921 | ||
4922 | * fns.c (Fsafe_length): Yet another int/Lisp_Object mixup. | |
4923 | ||
28177add PE |
4924 | 2011-06-16 Paul Eggert <eggert@cs.ucla.edu> |
4925 | ||
dd3482fe PE |
4926 | * lisp.h: Include <limits.h>, for INT_MAX, LONG_MAX, LLONG_MAX. |
4927 | Without this, prin1 mishandles Lisp_Misc_Save_Value printing on | |
4928 | hosts with pre-C99 libraries, because pD is wrongly defined to "t". | |
4929 | ||
393d71f3 | 4930 | Improve buffer-overflow checking (Bug#8873). |
1c8e352f PE |
4931 | * fileio.c (Finsert_file_contents): |
4932 | * insdel.c (insert_from_buffer_1, replace_range, replace_range_2): | |
4933 | Remove the old (too-loose) buffer overflow checks. | |
4934 | They weren't needed, since make_gap checks for buffer overflow. | |
4935 | * insdel.c (make_gap_larger): Catch buffer overflows that were missed. | |
4936 | The old code merely checked for Emacs fixnum overflow, and relied | |
4937 | on undefined (wraparound) behavior. The new code avoids undefined | |
4938 | behavior, and also checks for ptrdiff_t and/or size_t overflow. | |
4939 | ||
2e6813b0 | 4940 | * editfns.c (Finsert_char): Don't dump core with very negative counts. |
21d890a4 PE |
4941 | Tune. Don't use wider integers than needed. Don't use alloca. |
4942 | Use a bigger 'string' buffer. Rewrite to avoid 'n > 0' test. | |
2e6813b0 | 4943 | |
599a9e4f PE |
4944 | * insdel.c (replace_range): Fix buf overflow when insbytes < outgoing. |
4945 | ||
99561444 PE |
4946 | * insdel.c, lisp.h (buffer_overflow): New function. |
4947 | (insert_from_buffer_1, replace_range, replace_range_2): | |
4948 | * insdel.c (make_gap_larger): | |
4949 | * editfns.c (Finsert_char): | |
4950 | * fileio.c (Finsert_file_contents): Use it, to normalize wording. | |
4951 | ||
28177add PE |
4952 | * buffer.h (BUF_BYTES_MAX): Cast to ptrdiff_t so that it's signed. |
4953 | ||
e69dafad PE |
4954 | 2011-06-15 Paul Eggert <eggert@cs.ucla.edu> |
4955 | ||
4baa020d | 4956 | Integer overflow and signedness fixes (Bug#8873, Bug#8828). |
ff672d2c | 4957 | |
b1c46f02 PE |
4958 | * ccl.c (ASCENDING_ORDER): New macro, to work around GCC bug 43772. |
4959 | (GET_CCL_RANGE, IN_INT_RANGE): Use it. | |
4960 | ||
e69dafad PE |
4961 | * fileio.c: Don't assume EMACS_INT fits in off_t. |
4962 | (emacs_lseek): New static function. | |
4963 | (Finsert_file_contents, Fwrite_region): Use it. | |
4964 | Use SEEK_SET, SEEK_CUR, SEEK_END as appropriate. | |
4965 | ||
566684ea PE |
4966 | * fns.c (Fload_average): Don't assume 100 * load average fits in int. |
4967 | ||
e6966cd6 PE |
4968 | * fns.c: Don't overflow int when computing a list length. |
4969 | * fns.c (QUIT_COUNT_HEURISTIC): New constant. | |
4970 | (Flength, Fsafe_length): Use EMACS_INT, not int, to avoid unwanted | |
4971 | truncation on 64-bit hosts. Check for QUIT every | |
4972 | QUIT_COUNT_HEURISTIC entries rather than every other entry; that's | |
4973 | faster and is responsive enough. | |
4974 | (Flength): Report an error instead of overflowing an integer. | |
4975 | (Fsafe_length): Return a float if the value is not representable | |
4976 | as a fixnum. This shouldn't happen except in contrived situations. | |
6346d301 | 4977 | (Fnthcdr, Fsort): Don't assume list length fits in int. |
de41a810 | 4978 | (Fcopy_sequence): Don't assume vector length fits in int. |
00c604f2 | 4979 | |
dd0b0efb PE |
4980 | * alloc.c: Check that resized vectors' lengths fit in fixnums. |
4981 | (header_size, word_size): New constants. | |
4982 | (allocate_vectorlike): Don't check size overflow here. | |
4983 | (allocate_vector): Check it here instead, since this is the only | |
4984 | caller of allocate_vectorlike that could cause overflow. | |
4985 | Check that the new vector's length is representable as a fixnum. | |
4986 | ||
86fe5cfe PE |
4987 | * fns.c (next_almost_prime): Don't return a multiple of 3 or 5. |
4988 | The previous code was bogus. For example, next_almost_prime (32) | |
4989 | returned 39, which is undesirable as it is a multiple of 3; and | |
4990 | next_almost_prime (24) returned 25, which is a multiple of 5 so | |
4991 | why was the code bothering to check for multiples of 7? | |
4992 | ||
80e88859 PE |
4993 | * bytecode.c (exec_byte_code): Use ptrdiff_t, not int, for vector length. |
4994 | ||
4a2f0ad6 PE |
4995 | * eval.c, doprnt.c (SIZE_MAX): Remove; inttypes.h defines this now. |
4996 | ||
f66c7cf8 PE |
4997 | Variadic C functions now count arguments with ptrdiff_t. |
4998 | This partly undoes my 2011-03-30 change, which replaced int with size_t. | |
4999 | Back then I didn't know that the Emacs coding style prefers signed int. | |
5000 | Also, in the meantime I found a few more instances where arguments | |
4a2f0ad6 PE |
5001 | were being counted with int, which may truncate counts on 64-bit |
5002 | machines, or EMACS_INT, which may be unnecessarily wide. | |
f66c7cf8 PE |
5003 | * lisp.h (struct Lisp_Subr.function.aMANY) |
5004 | (DEFUN_ARGS_MANY, internal_condition_case_n, safe_call): | |
5005 | Arg counts are now ptrdiff_t, not size_t. | |
5006 | All variadic functions and their callers changed accordingly. | |
5007 | (struct gcpro.nvars): Now size_t, not size_t. All uses changed. | |
5008 | * bytecode.c (exec_byte_code): Check maxdepth for overflow, | |
5009 | to avoid potential buffer overrun. Don't assume arg counts fit in 'int'. | |
5010 | * callint.c (Fcall_interactively): Check arg count for overflow, | |
5011 | to avoid potential buffer overrun. Use signed char, not 'int', | |
5012 | for 'varies' array, so that we needn't bother to check its size | |
5013 | calculation for overflow. | |
5014 | * editfns.c (Fformat): Use ptrdiff_t, not EMACS_INT, to count args. | |
5015 | * eval.c (apply_lambda): | |
5016 | * fns.c (Fmapconcat): Use XFASTINT, not XINT, to get args length. | |
5017 | (struct textprop_rec.argnum): Now ptrdiff_t, not int. All uses changed. | |
5018 | (mapconcat): Use ptrdiff_t, not int and EMACS_INT, to count args. | |
5019 | ||
a1759b76 PE |
5020 | * callint.c (Fcall_interactively): Don't use index var as event count. |
5021 | ||
d96be9fc PE |
5022 | * vm-limit.c (check_memory_limits): Fix incorrect extern function decls. |
5023 | * mem-limits.h (SIZE): Remove; no longer used. | |
5024 | ||
a690a978 | 5025 | * xterm.c (x_alloc_nearest_color_1): Prefer int to long when int works. |
5efd304b | 5026 | |
578c21e6 PE |
5027 | Remove unnecessary casts. |
5028 | * xterm.c (x_term_init): | |
5029 | * xfns.c (x_set_border_pixel): | |
5030 | * widget.c (create_frame_gcs): Remove casts to unsigned long etc. | |
5031 | These aren't needed now that we assume ANSI C. | |
5032 | ||
96f53c6c PE |
5033 | * sound.c (Fplay_sound_internal): Remove cast to unsigned long. |
5034 | It's more likely to cause problems (due to unsigned overflow) | |
5035 | than to cure them. | |
5036 | ||
83c77d31 PE |
5037 | * dired.c (Ffile_attributes): Don't use 32-bit hack on 64-bit hosts. |
5038 | ||
ee2079f1 PE |
5039 | * unexelf.c (unexec): Don't assume BSS addr fits in unsigned. |
5040 | ||
6da65536 PE |
5041 | * xterm.c (handle_one_xevent): Omit unnecessary casts to unsigned. |
5042 | ||
7147c4a4 PE |
5043 | * keyboard.c (modify_event_symbol): Don't limit alist len to UINT_MAX. |
5044 | ||
193e32d9 PE |
5045 | * lisp.h (CHAR_TABLE_SET): Omit now-redundant test. |
5046 | ||
e5533da6 PE |
5047 | * lread.c (Fload): Don't compare a possibly-garbage time_t value. |
5048 | ||
9910e595 PE |
5049 | GLYPH_CODE_FACE returns EMACS_INT, not int. |
5050 | * dispextern.h (merge_faces): | |
5051 | * xfaces.c (merge_faces): | |
01103c44 PE |
5052 | * xdisp.c (get_next_display_element, next_element_from_display_vector): |
5053 | Don't assume EMACS_INT fits in int. | |
9910e595 | 5054 | |
2638320e PE |
5055 | * character.h (CHAR_VALID_P): Remove unused parameter. |
5056 | * fontset.c, lisp.h, xdisp.c: All uses changed. | |
5057 | ||
045eb8d9 PE |
5058 | * editfns.c (Ftranslate_region_internal): Omit redundant test. |
5059 | ||
c1f134b5 PE |
5060 | * fns.c (concat): Minor tuning based on overflow analysis. |
5061 | This doesn't fix any bugs. Use int to hold character, instead | |
5062 | of constantly refetching from Emacs object. Use XFASTINT, not | |
5063 | XINT, for value known to be a character. Don't bother comparing | |
5064 | a single byte to 0400, as it's always less. | |
5065 | ||
395fcb93 | 5066 | * floatfns.c (Fexpt): |
327eeec8 PE |
5067 | * fileio.c (make_temp_name): Omit unnecessary cast to unsigned. |
5068 | ||
abbd3d23 PE |
5069 | * editfns.c (Ftranslate_region_internal): Use int, not EMACS_INT |
5070 | for characters. | |
5071 | ||
684a03ef PE |
5072 | * doc.c (get_doc_string): Omit (unsigned)c that mishandled negatives. |
5073 | ||
0fed43f3 PE |
5074 | * data.c (Faset): If ARRAY is a string, check that NEWELT is a char. |
5075 | Without this fix, on a 64-bit host (aset S 0 4294967386) would | |
5076 | incorrectly succeed when S was a string, because 4294967386 was | |
5077 | truncated before it was used. | |
5078 | ||
8fd02eb7 PE |
5079 | * chartab.c (Fchar_table_range): Use CHARACTERP to check range. |
5080 | Otherwise, an out-of-range integer could cause undefined behavior | |
5081 | on a 64-bit host. | |
5082 | ||
f8c86b69 PE |
5083 | * composite.c: Use int, not EMACS_INT, for characters. |
5084 | (fill_gstring_body, composition_compute_stop_pos): Use int, not | |
5085 | EMACS_INT, for values that are known to be in character range. | |
5086 | This doesn't fix any bugs but is the usual style inside Emacs and | |
5087 | may generate better code on 32-bit machines. | |
5088 | ||
34206dd2 PE |
5089 | Make sure a 64-bit char is never passed to ENCODE_CHAR. |
5090 | This is for reasons similar to the recent CHAR_STRING fix. | |
5091 | * charset.c (Fencode_char): Check that character arg is actually | |
5092 | a character. Pass an int to ENCODE_CHAR. | |
5093 | * charset.h (ENCODE_CHAR): Verify that the character argument is no | |
5094 | wider than 'int', as a compile-time check to prevent future regressions | |
5095 | in this area. | |
5096 | ||
c5958d4c | 5097 | * character.c (char_string): Remove unnecessary casts. |
13bdea59 PE |
5098 | |
5099 | Make sure a 64-bit char is never passed to CHAR_STRING. | |
5100 | Otherwise, CHAR_STRING would do the wrong thing on a 64-bit platform, | |
5101 | by silently ignoring the top 32 bits, allowing some values | |
5102 | that were far too large to be valid characters. | |
5103 | * character.h: Include <verify.h>. | |
5104 | (CHAR_STRING, CHAR_STRING_ADVANCE): Verify that the character | |
5105 | arguments are no wider than unsigned, as a compile-time check | |
5106 | to prevent future regressions in this area. | |
5107 | * data.c (Faset): | |
01103c44 | 5108 | * editfns.c (Fchar_to_string, general_insert_function, Finsert_char) |
13bdea59 PE |
5109 | (Fsubst_char_in_region): |
5110 | * fns.c (concat): | |
5111 | * xdisp.c (decode_mode_spec_coding): | |
5112 | Adjust to CHAR_STRING's new requirement. | |
5113 | * editfns.c (Finsert_char, Fsubst_char_in_region): | |
5114 | * fns.c (concat): Check that character args are actually | |
5115 | characters. Without this test, these functions did the wrong | |
5116 | thing with wildly out-of-range values on 64-bit hosts. | |
5117 | ||
d37ca623 PE |
5118 | Remove incorrect casts to 'unsigned' that lose info on 64-bit hosts. |
5119 | These casts should not be needed on 32-bit hosts, either. | |
5120 | * keyboard.c (read_char): | |
5121 | * lread.c (Fload): Remove casts to unsigned. | |
5122 | ||
ea204efb PE |
5123 | * lisp.h (UNSIGNED_CMP): New macro. |
5124 | This fixes comparison bugs on 64-bit hosts. | |
5125 | (ASCII_CHAR_P): Use it. | |
5126 | * casefiddle.c (casify_object): | |
01103c44 | 5127 | * character.h (ASCII_BYTE_P, CHAR_VALID_P) |
ea204efb PE |
5128 | (SINGLE_BYTE_CHAR_P, CHAR_STRING): |
5129 | * composite.h (COMPOSITION_ENCODE_RULE_VALID): | |
5130 | * dispextern.h (FACE_FROM_ID): | |
5131 | * keyboard.c (read_char): Use UNSIGNED_CMP. | |
5132 | ||
41cb286c PE |
5133 | * xmenu.c (dialog_selection_callback) [!USE_GTK]: Cast to intptr_t, |
5134 | not to EMACS_INT, to avoid GCC warning. | |
5135 | ||
4a1b9832 PE |
5136 | * xfns.c (x_set_scroll_bar_default_width): Remove unused 'int' locals. |
5137 | ||
55daad71 PE |
5138 | * buffer.h (PTR_BYTE_POS, BUF_PTR_BYTE_POS): Remove harmful cast. |
5139 | The cast incorrectly truncated 64-bit byte offsets to 32 bits, and | |
5140 | isn't needed on 32-bit machines. | |
8f95c75c | 5141 | |
01103c44 PE |
5142 | * buffer.c (Fgenerate_new_buffer_name): |
5143 | Use EMACS_INT for count, not int. | |
0ceccced | 5144 | (advance_to_char_boundary): Return EMACS_INT, not int. |
e762cafe PE |
5145 | |
5146 | * data.c (Qcompiled_function): Now static. | |
5147 | ||
c6f072e7 PE |
5148 | * window.c (window_body_lines): Now static. |
5149 | ||
20ce5912 PE |
5150 | * image.c (gif_load): Rename local to avoid shadowing. |
5151 | ||
9c4c5f81 PE |
5152 | * lisp.h (SAFE_ALLOCA_LISP): Check for integer overflow. |
5153 | (struct Lisp_Save_Value): Use ptrdiff_t, not int, for 'integer' member. | |
5154 | * alloc.c (make_save_value): Integer argument is now of type | |
5155 | ptrdiff_t, not int. | |
5156 | (mark_object): Use ptrdiff_t, not int. | |
5157 | * lisp.h (pD): New macro. | |
5158 | * print.c (print_object): Use it. | |
5159 | ||
c0c5c8ae PE |
5160 | * alloc.c: Use EMACS_INT, not int, to count objects. |
5161 | (total_conses, total_markers, total_symbols, total_vector_size) | |
5162 | (total_free_conses, total_free_markers, total_free_symbols) | |
01103c44 PE |
5163 | (total_free_floats, total_floats, total_free_intervals) |
5164 | (total_intervals, total_strings, total_free_strings): | |
c0c5c8ae PE |
5165 | Now EMACS_INT, not int. All uses changed. |
5166 | (Fgarbage_collect): Compute overall total using a double, so that | |
5167 | integer overflow is less likely to be a problem. Check for overflow | |
5168 | when converting back to an integer. | |
5a25e253 PE |
5169 | (n_interval_blocks, n_string_blocks, n_float_blocks, n_cons_blocks) |
5170 | (n_vectors, n_symbol_blocks, n_marker_blocks): Remove. | |
5171 | These were 'int' variables that could overflow on 64-bit hosts; | |
5172 | they were never used, so remove them instead of repairing them. | |
211a0b2a | 5173 | (nzombies, ngcs, max_live, max_zombies): Now EMACS_INT, not 'int'. |
6349ae4d PE |
5174 | (inhibit_garbage_collection): Set gc_cons_threshold to max value. |
5175 | Previously, this ceilinged at INT_MAX, but that doesn't work on | |
5176 | 64-bit machines. | |
e46bb31a | 5177 | (allocate_pseudovector): Don't use EMACS_INT when int would do. |
c0c5c8ae | 5178 | |
c78baabf | 5179 | * alloc.c (Fmake_bool_vector): Don't assume vector size fits in int. |
86f61a15 | 5180 | (allocate_vectorlike): Check for ptrdiff_t overflow. |
b6439961 PE |
5181 | (mark_vectorlike, mark_char_table, mark_object): Avoid EMACS_UINT |
5182 | when a (possibly-narrower) signed value would do just as well. | |
5183 | We prefer using signed arithmetic, to avoid comparison confusion. | |
c78baabf | 5184 | |
c9d624c6 PE |
5185 | * alloc.c: Catch some string size overflows that we were missing. |
5186 | (XMALLOC_OVERRUN_CHECK_SIZE) [!XMALLOC_OVERRUN_CHECK]: Define to 0, | |
5187 | for convenience in STRING_BYTES_MAX. | |
5188 | (STRING_BYTES_MAX): New macro, superseding the old one in lisp.h. | |
5189 | The definition here is exact; the one in lisp.h was approximate. | |
5190 | (allocate_string_data): Check for string overflow. This catches | |
5191 | some instances we weren't catching before. Also, it catches | |
5192 | size_t overflow on (unusual) hosts where SIZE_MAX <= min | |
5193 | (PTRDIFF_MAX, MOST_POSITIVE_FIXNUM), e.g., when size_t is 32 bits | |
5194 | and ptrdiff_t and EMACS_INT are both 64 bits. | |
c78baabf | 5195 | |
c9d624c6 PE |
5196 | * character.c, coding.c, doprnt.c, editfns.c, eval.c: |
5197 | All uses of STRING_BYTES_MAX replaced by STRING_BYTES_BOUND. | |
640c8776 | 5198 | * lisp.h (STRING_BYTES_BOUND): Rename from STRING_BYTES_MAX. |
c9d624c6 | 5199 | |
353032ce PE |
5200 | * character.c (string_escape_byte8): Fix nbytes/nchars typo. |
5201 | ||
2bccce07 PE |
5202 | * alloc.c (Fmake_string): Check for out-of-range init. |
5203 | ||
0ac30604 SM |
5204 | 2011-06-15 Stefan Monnier <monnier@iro.umontreal.ca> |
5205 | ||
5206 | * eval.c (Fdefvaralias): Also mark the target as variable-special-p. | |
5207 | ||
c195f2de JD |
5208 | 2011-06-14 Jan Djärv <jan.h.d@swipnet.se> |
5209 | ||
5210 | * xfns.c (x_set_scroll_bar_default_width): Remove argument to | |
5211 | xg_get_default_scrollbar_width. | |
5212 | ||
5213 | * gtkutil.c: Include emacsgtkfixed.h if HAVE_GTK3. | |
5214 | (int_gtk_range_get_value): Move to the scroll bar part of the file. | |
5215 | (style_changed_cb): Call update_theme_scrollbar_width and call | |
5216 | x_set_scroll_bar_default_width and xg_frame_set_char_size for | |
5217 | all frames (Bug#8505). | |
5218 | (xg_create_frame_widgets): Call emacs_fixed_new if HAVE_GTK3 (Bug#8505). | |
5219 | Call gtk_window_set_resizable if HAVE_GTK3. | |
5220 | (x_wm_set_size_hint): Call emacs_fixed_set_min_size with min width | |
5221 | and height if HAVE_GTK3 (Bug#8505). | |
5222 | (scroll_bar_width_for_theme): New variable. | |
5223 | (update_theme_scrollbar_width): New function. | |
5224 | (xg_get_default_scrollbar_width): Move code to | |
5225 | update_theme_scrollbar_width, just return scroll_bar_width_for_theme. | |
5226 | (xg_initialize): Call update_theme_scrollbar_width. | |
5227 | ||
5228 | * gtkutil.h (xg_get_default_scrollbar_width): Remove argument. | |
5229 | ||
5230 | * emacsgtkfixed.c, emacsgtkfixed.h: New files. | |
5231 | ||
e10ac9f1 MR |
5232 | 2011-06-12 Martin Rudalics <rudalics@gmx.at> |
5233 | ||
5234 | * frame.c (make_frame): Call other_buffer_safely instead of | |
5235 | other_buffer. | |
5236 | ||
5237 | * window.c (temp_output_buffer_show): Call display_buffer with | |
5238 | second argument Vtemp_buffer_show_specifiers and reset latter | |
5239 | immediately after the call. | |
5240 | (Vtemp_buffer_show_specifiers): New variable. | |
5241 | (auto_window_vscroll_p, next_screen_context_lines) | |
5242 | (Vscroll_preserve_screen_position): Remove leading asterisks from | |
5243 | doc-strings. | |
5244 | ||
2d3c217e | 5245 | 2011-06-12 Paul Eggert <eggert@cs.ucla.edu> |
4475bec4 | 5246 | |
7b7f97e8 | 5247 | Fix minor problems found by GCC 4.6.0 static checking. |
4475bec4 PE |
5248 | * buffer.c (Qclone_number): Remove for now, as it's unused. |
5249 | (record_buffer, Funrecord_buffer): Rename local to avoid shadowing. | |
5250 | (record_buffer): Remove unused local. | |
5251 | * frame.c (other_visible_frames, frame_buffer_list): Now static. | |
5252 | (set_frame_buffer_list): Remove; unused. | |
5253 | * frame.h (other_visible_frames): Remove decl. | |
5254 | * keyboard.h (menu_items_inuse): Declare only if USE_GTK || USE_MOTIF. | |
5255 | * lisp.h (frame_buffer_list, set_frame_buffer_list): Remove decls. | |
5256 | (add_gpm_wait_descriptor, delete_gpm_wait_descriptor): Declare only | |
5257 | if HAVE_GPM. | |
5258 | * menu.c (menu_items_inuse): Now static unless USE_GTK || USE_MOTIF. | |
5259 | * process.c (add_gpm_wait_descriptor, delete_gpm_wait_descriptor): | |
5260 | Define only if HAVE_GPM. | |
5261 | * widget.c (EmacsFrameResize, emacsFrameClassRec): Now static. | |
5262 | (update_hints_inhibit): Remove; never set. All uses removed. | |
5263 | * widgetprv.h (emacsFrameClassRec): Remove decl. | |
5264 | * window.c (delete_deletable_window): Now returns void, since it | |
5265 | wasn't returning anything. | |
5266 | (compare_window_configurations): Remove unused locals. | |
5267 | * xfns.c (x_set_scroll_bar_default_width): Remove unused locals. | |
5268 | * xmenu.c (x_menu_set_in_use): Define only if USE_GTK || USE_MOTIF. | |
4475bec4 PE |
5269 | (dialog_selection_callback) [!USE_GTK]: Prefer intptr_t for integers |
5270 | the same widths as pointers. This follows up on the 2011-05-06 patch. | |
5271 | * xterm.c (x_alloc_lighter_color_for_widget): Define only if USE_LUCID. | |
5272 | * xterm.h: Likewise. | |
5273 | (x_menu_set_in_use): Declare only if USE_GTK || USE_MOTIF. | |
5274 | ||
1384b89e JB |
5275 | 2011-06-12 Juanma Barranquero <lekktu@gmail.com> |
5276 | ||
5277 | * makefile.w32-in: Update dependencies. | |
5278 | (LISP_H): Add lib/intprops.h. | |
5279 | ||
1100a63c CY |
5280 | 2011-06-11 Chong Yidong <cyd@stupidchicken.com> |
5281 | ||
5282 | * image.c (gif_load): Add animation frame delay to the metadata. | |
5283 | (syms_of_image): Use DEFSYM. New symbol `delay'. | |
5284 | ||
6198ccd0 MR |
5285 | 2011-06-11 Martin Rudalics <rudalics@gmx.at> |
5286 | ||
5287 | * window.c (delete_deletable_window): Re-add. | |
5288 | (Fset_window_configuration): Rewrite to handle dead buffers and | |
5289 | consequently deletable windows. | |
5290 | (window_tree, Fwindow_tree): Remove. Supply functionality in | |
5291 | window.el. | |
5292 | (compare_window_configurations): Simplify code. | |
5293 | ||
b6e3633c AS |
5294 | 2011-06-11 Andreas Schwab <schwab@linux-m68k.org> |
5295 | ||
1ab0dee5 AS |
5296 | * image.c (imagemagick_load_image): Fix type mismatch. |
5297 | (Fimagemagick_types): Likewise. | |
5298 | ||
b6e3633c AS |
5299 | * window.h (replace_buffer_in_windows): Declare. |
5300 | ||
9397e56f MR |
5301 | 2011-06-11 Martin Rudalics <rudalics@gmx.at> |
5302 | ||
5303 | * buffer.c: New Lisp objects Qbuffer_list_update_hook and | |
5304 | Qclone_number. Remove external declaration of Qdelete_window. | |
5305 | (Fbuffer_list): Rewrite doc-string. Minor restructuring of | |
5306 | code. | |
640c8776 SM |
5307 | (Fget_buffer_create, Fmake_indirect_buffer, Frename_buffer): |
5308 | Run Qbuffer_list_update_hook if allowed. | |
9397e56f MR |
5309 | (Fother_buffer): Rewrite doc-string. Major rewrite for new |
5310 | buffer list implementation. | |
5311 | (other_buffer_safely): New function. | |
5312 | (Fkill_buffer): Replace call to replace_buffer_in_all_windows by | |
5313 | calls to replace_buffer_in_windows and | |
5314 | replace_buffer_in_windows_safely. Run Qbuffer_list_update_hook | |
5315 | if allowed. | |
5316 | (record_buffer): Inhibit quitting and rewrite using quittable | |
5317 | functions. Run Qbuffer_list_update_hook if allowed. | |
5318 | (Frecord_buffer, Funrecord_buffer): New functions. | |
640c8776 SM |
5319 | (switch_to_buffer_1, Fswitch_to_buffer): Remove. |
5320 | Move switch-to-buffer to window.el. | |
9397e56f MR |
5321 | (bury-buffer): Move to window.el. |
5322 | (Vbuffer_list_update_hook): New variable. | |
5323 | ||
5324 | * lisp.h (other_buffer_safely): Add prototype in buffer.c | |
5325 | section. | |
5326 | ||
5327 | * window.h (resize_frame_windows): Move up in code. | |
5328 | (Fwindow_frame): Remove EXFUN. | |
5329 | (replace_buffer_in_all_windows): Remove prototype. | |
5330 | (replace_buffer_in_windows_safely): Add prototype. | |
5331 | ||
5332 | * window.c: Declare Qdelete_window static again. Move down | |
5333 | declaration of select_count. | |
5334 | (Fnext_window, Fprevious_window): Rewrite doc-strings. | |
5335 | (Fother_window): Move to window.el. | |
5336 | (window_loop): Remove DELETE_BUFFER_WINDOWS and UNSHOW_BUFFER | |
5337 | cases. Add REPLACE_BUFFER_IN_WINDOWS_SAFELY case. | |
5338 | (Fdelete_windows_on, Freplace_buffer_in_windows): Move to | |
5339 | window.el. | |
5340 | (replace_buffer_in_windows): Implement by calling | |
5341 | Qreplace_buffer_in_windows. | |
5342 | (replace_buffer_in_all_windows): Remove with some functionality | |
5343 | moved into replace_buffer_in_windows_safely. | |
5344 | (replace_buffer_in_windows_safely): New function. | |
5345 | (select_window_norecord, select_frame_norecord): Move in front | |
5346 | of run_window_configuration_change_hook. Remove now obsolete | |
5347 | declarations. | |
640c8776 SM |
5348 | (Fset_window_buffer): Rewrite doc-string. |
5349 | Call Qrecord_window_buffer. | |
9397e56f MR |
5350 | (keys_of_window): Move binding for other-window to window.el. |
5351 | ||
b50691aa CY |
5352 | 2011-06-11 Chong Yidong <cyd@stupidchicken.com> |
5353 | ||
5354 | * dispextern.h (struct image): Replace data member, whose int_val | |
5355 | and ptr_val fields were not used by anything, with a single | |
5356 | lisp_val object. | |
5357 | ||
5358 | * image.c (Fimage_metadata, make_image, mark_image, tiff_load) | |
5359 | (gif_clear_image, gif_load, imagemagick_load_image) | |
5360 | (gs_clear_image, gs_load): Callers changed. | |
5361 | ||
3f754b86 PE |
5362 | 2011-06-10 Paul Eggert <eggert@cs.ucla.edu> |
5363 | ||
cca69397 PE |
5364 | * buffer.h: Include <time.h>, for time_t. |
5365 | Needed to build on FreeBSD 8.2. Problem reported by Herbert J. Skuhra. | |
5366 | ||
109e28d0 PE |
5367 | Fix minor problems found by static checking. |
5368 | ||
60737f02 PE |
5369 | * image.c (PixelGetMagickColor): Declare if ImageMagick headers don't. |
5370 | ||
4b66faf3 PE |
5371 | Make identifiers static if they are not used in other modules. |
5372 | * data.c (Qcompiled_function, Qframe, Qvector): | |
5373 | * image.c (QimageMagick, Qsvg): | |
5374 | * minibuf.c (Qmetadata): | |
5375 | * window.c (resize_window_check, resize_root_window): Now static. | |
5376 | * window.h (resize_window_check, resize_root_window): Remove decls. | |
5377 | ||
109e28d0 PE |
5378 | * window.c (window_deletion_count, delete_deletable_window): |
5379 | Remove; unused. | |
46a4ce9e PE |
5380 | (window_body_lines): Now static. |
5381 | (Fdelete_other_windows_internal): Mark vars as initialized. | |
5382 | Make sure 'resize_failed' is initialized. | |
5383 | (run_window_configuration_change_hook): Rename local to avoid shadowing. | |
5384 | (resize_window_apply): Remove unused local. | |
5385 | * window.h (delete_deletable_window): Remove decl. | |
5386 | ||
109e28d0 | 5387 | * image.c (gif_load, svg_load_image): Rename locals to avoid shadowing. |
33290528 PE |
5388 | (imagemagick_load_image): Fix pointer signedness problem by changing |
5389 | last arg from unsigned char * to char *. All uses changed. | |
5390 | Also, fix a local for similar reasons. | |
5391 | Remove unused locals. Remove locals to avoid shadowing. | |
5392 | (fn_rsvg_handle_free): Remove; unused. | |
5393 | (svg_load, svg_load_image): Fix pointer signedness problem. | |
f7e13da3 | 5394 | (imagemagick_load_image): Don't use garbage pointer image_wand. |
33290528 | 5395 | |
3f754b86 PE |
5396 | * ftfont.c (ftfont_get_metrics, ftfont_drive_otf): Remove unused locals. |
5397 | ||
2547adb1 CY |
5398 | 2011-06-10 Chong Yidong <cyd@stupidchicken.com> |
5399 | ||
5400 | * image.c (gif_load): Fix omitted cast error introduced by | |
5401 | 2011-06-06 change. | |
5402 | ||
2c8e37d4 MR |
5403 | 2011-06-10 Martin Rudalics <rudalics@gmx.at> |
5404 | ||
5405 | * window.h (resize_proportionally, orig_total_lines) | |
5406 | (orig_top_line): Remove from window structure. | |
5407 | (set_window_height, set_window_width, change_window_heights) | |
5408 | (Fdelete_window): Remove prototypes. | |
5409 | (resize_frame_windows): Remove duplicate declaration. | |
5410 | ||
440a42e3 EZ |
5411 | 2011-06-10 Eli Zaretskii <eliz@gnu.org> |
5412 | ||
5413 | * window.h (resize_frame_windows, resize_window_check) | |
5414 | (delete_deletable_window, resize_root_window) | |
5415 | (resize_frame_windows): Declare prototypes. | |
5416 | ||
5417 | * window.c (resize_window_apply): Make definition be "static" to | |
5418 | match the prototype. | |
5419 | ||
562dd5e9 MR |
5420 | 2011-06-10 Martin Rudalics <rudalics@gmx.at> |
5421 | ||
5422 | * window.c: Remove declarations of Qwindow_size_fixed, | |
5423 | window_min_size_1, window_min_size_2, window_min_size, | |
5424 | size_window, window_fixed_size_p, enlarge_window, delete_window. | |
5425 | Remove static from declaration of Qdelete_window, it's | |
5426 | temporarily needed by Fbury_buffer. | |
5427 | (replace_window): Don't assign orig_top_line and | |
5428 | orig_total_lines. | |
5429 | (Fdelete_window, delete_window): Remove. Window deletion is | |
5430 | handled by window.el. | |
640c8776 SM |
5431 | (window_loop): Remove DELETE_OTHER_WINDOWS case. |
5432 | Replace Fdelete_window calls with calls to Qdelete_window. | |
562dd5e9 MR |
5433 | (Fdelete_other_windows): Remove. Deleting other windows is |
5434 | handled by window.el. | |
5435 | (window_fixed_size_p): Remove. Fixed-sizeness of windows is | |
5436 | handled in window.el. | |
5437 | (window_min_size_2, window_min_size_1, window_min_size): Remove. | |
5438 | Window minimum sizes are handled in window.el. | |
5439 | (shrink_windows, size_window, set_window_height) | |
5440 | (set_window_width, change_window_heights, window_height) | |
5441 | (window_width, CURBEG, CURSIZE, enlarge_window) | |
5442 | (adjust_window_trailing_edge, Fadjust_window_trailing_edge) | |
5443 | (Fenlarge_window, Fshrink_window): Remove. Window resizing is | |
5444 | handled in window.el. | |
5445 | (make_dummy_parent): Rename to make_parent_window and give it a | |
5446 | second argument horflag. | |
5447 | (make_window): Don't set resize_proportionally any more. | |
5448 | (Fsplit_window): Remove. Windows are split in window.el. | |
5449 | (save_restore_action, save_restore_orig_size) | |
5450 | (shrink_window_lowest_first, save_restore_orig_size): Remove. | |
5451 | Resize mini windows in window.el. | |
5452 | (grow_mini_window, shrink_mini_window): Implement by calling | |
5453 | Qresize_root_window_vertically, resize_window_check and | |
5454 | resize_window_apply. | |
640c8776 SM |
5455 | (saved_window, Fset_window_configuration, save_window_save): |
5456 | Do not handle orig_top_line, orig_total_lines, and | |
562dd5e9 MR |
5457 | resize_proportionally. |
5458 | (window_min_height, window_min_width): Move to window.el. | |
5459 | (keys_of_window): Move bindings for delete-other-windows, | |
5460 | split-window, delete-window and enlarge-window to window.el. | |
5461 | ||
5462 | * buffer.c: Temporarily extern Qdelete_window. | |
5463 | (Fbury_buffer): Temporarily call Qdelete_window instead of | |
5464 | Fdelete_window (Fbury_buffer will move to window.el soon). | |
5465 | ||
5466 | * frame.c (set_menu_bar_lines_1): Remove code handling | |
5467 | orig_top_line and orig_total_lines. | |
5468 | ||
5469 | * dispnew.c (adjust_frame_glyphs_initially): Don't use | |
5470 | set_window_height but set heights directly. | |
5471 | (change_frame_size_1): Use resize_frame_windows. | |
5472 | ||
5473 | * xdisp.c (init_xdisp): Don't use set_window_height but set | |
5474 | heights directly. | |
5475 | ||
640c8776 SM |
5476 | * xfns.c (x_set_menu_bar_lines, x_set_tool_bar_lines): |
5477 | Use resize_frame_windows instead of change_window_heights and run | |
562dd5e9 MR |
5478 | run_window_configuration_change_hook. |
5479 | ||
5480 | * w32fns.c (x_set_tool_bar_lines): Use resize_frame_windows | |
5481 | instead of change_window_heights and run | |
5482 | run_window_configuration_change_hook. | |
5483 | ||
1a13852e MR |
5484 | 2011-06-09 Martin Rudalics <rudalics@gmx.at> |
5485 | ||
5486 | * window.c (replace_window): Rename second argument REPLACEMENT to | |
5487 | NEW. New third argument SETFLAG. Rewrite. | |
5488 | (delete_window, make_dummy_parent): Call replace_window with | |
5489 | third argument 1. | |
5490 | (window_list_1): Move down in code. | |
5491 | (run_window_configuration_change_hook): Move set_buffer part | |
5492 | before select_frame_norecord part in order to unwind correctly. | |
5493 | Rename count1 to count. | |
5494 | (recombine_windows, delete_deletable_window, resize_root_window) | |
5495 | (Fdelete_other_windows_internal) | |
5496 | (Frun_window_configuration_change_hook, make_parent_window) | |
5497 | (resize_window_check, resize_window_apply, Fresize_window_apply) | |
5498 | (resize_frame_windows, Fsplit_window_internal) | |
640c8776 SM |
5499 | (Fdelete_window_internal, Fresize_mini_window_internal): |
5500 | New functions. | |
1a13852e MR |
5501 | (syms_of_window): New variables Vwindow_splits and Vwindow_nest. |
5502 | ||
f3d1777e MR |
5503 | 2011-06-08 Martin Rudalics <rudalics@gmx.at> |
5504 | ||
496e208e MR |
5505 | * window.h (window): Add some new members to window structure - |
5506 | normal_lines, normal_cols, new_total, new_normal, clone_number, | |
5507 | splits, nest, prev_buffers, next_buffers. | |
5508 | (WINDOW_TOTAL_SIZE): Move here from window.c. | |
b9e809c2 | 5509 | (MIN_SAFE_WINDOW_WIDTH, MIN_SAFE_WINDOW_HEIGHT): Define here. |
496e208e | 5510 | |
f3d1777e MR |
5511 | * window.c (Fwindow_height, Fwindow_width, Fwindow_full_width_p): |
5512 | Remove. | |
496e208e MR |
5513 | (make_dummy_parent): Set new members of windows structure. |
5514 | (make_window): Move down in code. Handle new members of window | |
5515 | structure. | |
5516 | (Fwindow_clone_number, Fwindow_splits, Fset_window_splits) | |
5517 | (Fwindow_nest, Fset_window_nest, Fwindow_new_total) | |
5518 | (Fwindow_normal_size, Fwindow_new_normal, Fwindow_prev_buffers) | |
5519 | (Fset_window_prev_buffers, Fwindow_next_buffers) | |
640c8776 SM |
5520 | (Fset_window_next_buffers, Fset_window_clone_number): |
5521 | New functions. | |
496e208e MR |
5522 | (Fwindow_hscroll, Fwindow_at, Fwindow_point, Fwindow_start) |
5523 | (Fwindow_end, Fwindow_line_height, Fset_window_dedicated_p): | |
5524 | Doc-string fixes. | |
5525 | (Fwindow_parameters, Fwindow_parameter, Fset_window_parameter): | |
5526 | Argument WINDOW can be now internal window too. | |
5527 | (Fwindow_use_time): Move up in code. | |
5528 | (Fget_buffer_window): Rename argument FRAME to ALL-FRAMES. | |
5529 | Rewrite doc-string. | |
5530 | (Fset_window_configuration, saved_window) | |
5531 | (Fcurrent_window_configuration, save_window_save): Handle new | |
5532 | members of window structure. | |
b9e809c2 MR |
5533 | (WINDOW_TOTAL_SIZE, MIN_SAFE_WINDOW_WIDTH) |
5534 | (MIN_SAFE_WINDOW_HEIGHT): Move to window.h. | |
5535 | (syms_of_window): New Lisp objects Qrecord_window_buffer, | |
5536 | Qwindow_deletable_p, Qdelete_window, Qreplace_buffer_in_windows, | |
5537 | Qget_mru_window, Qresize_root_window, | |
5538 | Qresize_root_window_vertically, Qsafe, Qabove, Qbelow, | |
5539 | Qauto_buffer_name; staticpro them. | |
f3d1777e | 5540 | |
abde8f8c MR |
5541 | 2011-06-07 Martin Rudalics <rudalics@gmx.at> |
5542 | ||
5543 | * window.c (Fwindow_total_size, Fwindow_left_column) | |
5544 | (Fwindow_top_line, window_body_lines, Fwindow_body_size) | |
5545 | (Fwindow_list_1): New functions. | |
5546 | (window_box_text_cols): Replace with window_body_cols. | |
640c8776 SM |
5547 | (Fwindow_width, Fscroll_left, Fscroll_right): |
5548 | Use window_body_cols instead of window_box_text_cols. | |
5549 | (delete_window, Fset_window_configuration): | |
5550 | Call delete_all_subwindows with window as argument. | |
fa8a67e6 MR |
5551 | (delete_all_subwindows): Take a window as argument and not a |
5552 | structure. Rewrite. | |
190b47e6 MR |
5553 | (window_loop): Remove handling of GET_LRU_WINDOW and |
5554 | GET_LARGEST_WINDOW. | |
5555 | (Fget_lru_window, Fget_largest_window): Move to window.el. | |
abde8f8c MR |
5556 | |
5557 | * window.h: Extern window_body_cols instead of | |
fa8a67e6 MR |
5558 | window_box_text_cols. delete_all_subwindows now takes a |
5559 | Lisp_Object as argument. | |
abde8f8c | 5560 | |
640c8776 SM |
5561 | * indent.c (compute_motion, Fcompute_motion): |
5562 | Use window_body_cols instead of window_box_text_cols. | |
abde8f8c | 5563 | |
fa8a67e6 MR |
5564 | * frame.c (delete_frame): Call delete_all_subwindows with root |
5565 | window as argument. | |
5566 | ||
a54e3482 DC |
5567 | 2011-06-07 Daniel Colascione <dan.colascione@gmail.com> |
5568 | ||
5569 | * fns.c (Fputhash): Document return value. | |
5570 | ||
60002bf5 CY |
5571 | 2011-06-06 Chong Yidong <cyd@stupidchicken.com> |
5572 | ||
5573 | * image.c (gif_load): Implement gif89a spec "no disposal" method. | |
5574 | ||
0c671da6 | 5575 | 2011-06-06 Paul Eggert <eggert@cs.ucla.edu> |
ccd9a01a | 5576 | |
b862a52a | 5577 | Cons<->int and similar integer overflow fixes (Bug#8794). |
77984278 | 5578 | |
be44ca6c PE |
5579 | Check for overflow when converting integer to cons and back. |
5580 | * charset.c (Fdefine_charset_internal, Fdecode_char): | |
5581 | Use cons_to_unsigned to catch overflow. | |
5582 | (Fencode_char): Use INTEGER_TO_CONS. | |
5583 | * composite.h (LGLYPH_CODE): Use cons_to_unsigned. | |
5584 | (LGLYPH_SET_CODE): Use INTEGER_TO_CONS. | |
5585 | * data.c (long_to_cons, cons_to_long): Remove. | |
5586 | (cons_to_unsigned, cons_to_signed): New functions. | |
5587 | These signal an error for invalid or out-of-range values. | |
5588 | * dired.c (Ffile_attributes): Use INTEGER_TO_CONS. | |
5589 | * fileio.c (Fset_visited_file_modtime): Use CONS_TO_INTEGER. | |
5590 | * font.c (Ffont_variation_glyphs): | |
5591 | * fontset.c (Finternal_char_font): Use INTEGER_TO_CONS. | |
5592 | * lisp.h: Include <intprops.h>. | |
5593 | (INTEGER_TO_CONS, CONS_TO_INTEGER): New macros. | |
5594 | (cons_to_signed, cons_to_unsigned): New decls. | |
5595 | (long_to_cons, cons_to_long): Remove decls. | |
5596 | * undo.c (record_first_change): Use INTEGER_TO_CONS. | |
5597 | (Fprimitive_undo): Use CONS_TO_INTEGER. | |
5598 | * xfns.c (Fx_window_property): Likewise. | |
5599 | * xselect.c: Include <limits.h>. | |
5600 | (x_own_selection, selection_data_to_lisp_data): | |
5601 | Use INTEGER_TO_CONS. | |
5602 | (x_handle_selection_request, x_handle_selection_clear) | |
5603 | (x_get_foreign_selection, Fx_disown_selection_internal) | |
5604 | (Fx_get_atom_name, x_send_client_event): Use CONS_TO_INTEGER. | |
5605 | (lisp_data_to_selection_data): Use cons_to_unsigned. | |
5606 | (x_fill_property_data): Use cons_to_signed. | |
5607 | Report values out of range. | |
5608 | ||
d1f3d2af PE |
5609 | Check for buffer and string overflow more precisely. |
5610 | * buffer.h (BUF_BYTES_MAX): New macro. | |
5611 | * lisp.h (STRING_BYTES_MAX): New macro. | |
5612 | * alloc.c (Fmake_string): | |
5613 | * character.c (string_escape_byte8): | |
5614 | * coding.c (coding_alloc_by_realloc): | |
5615 | * doprnt.c (doprnt): | |
5616 | * editfns.c (Fformat): | |
5617 | * eval.c (verror): | |
5618 | Use STRING_BYTES_MAX, not MOST_POSITIVE_FIXNUM, | |
5619 | since they may not be the same number. | |
5620 | * editfns.c (Finsert_char): | |
5621 | * fileio.c (Finsert_file_contents): | |
5622 | Likewise for BUF_BYTES_MAX. | |
5623 | ||
dd52fcea PE |
5624 | * image.c: Use ptrdiff_t, not int, for sizes. |
5625 | (slurp_file): Switch from int to ptrdiff_t. | |
5626 | All uses changed. | |
5627 | (slurp_file): Check that file size fits in both size_t (for | |
5628 | malloc) and ptrdiff_t (for sanity and safety). | |
5629 | ||
7f9bbdbb PE |
5630 | * fileio.c (Fverify_visited_file_modtime): Avoid time overflow |
5631 | if b->modtime has its maximal value. | |
5632 | ||
dfe18f82 PE |
5633 | * dired.c (Ffile_attributes): Don't assume EMACS_INT has >32 bits. |
5634 | ||
84acfcf0 PE |
5635 | Don't assume time_t can fit into int. |
5636 | * buffer.h (struct buffer.modtime): Now time_t, not int. | |
5637 | * fileio.c (Fvisited_file_modtime): No need for time_t cast now. | |
5638 | * undo.c (Fprimitive_undo): Use time_t, not int, for time_t value. | |
5639 | ||
ccd9a01a PE |
5640 | Minor fixes for signed vs unsigned integers. |
5641 | * character.h (MAYBE_UNIFY_CHAR): | |
5642 | * charset.c (maybe_unify_char): | |
5643 | * keyboard.c (read_char, reorder_modifiers): | |
5644 | XINT -> XFASTINT, since the integer must be nonnegative. | |
5645 | * ftfont.c (ftfont_spec_pattern): | |
5646 | * keymap.c (access_keymap, silly_event_symbol_error): | |
5647 | XUINT -> XFASTINT, since the integer must be nonnegative. | |
5648 | (Fsingle_key_description, preferred_sequence_p): XUINT -> XINT, | |
5649 | since it makes no difference and we prefer signed. | |
5650 | * keyboard.c (record_char): Use XUINT when all the neighbors do. | |
5651 | (access_keymap): NATNUMP -> INTEGERP, since the integer must be | |
5652 | nonnegative. | |
5653 | ||
d6d100dd SM |
5654 | 2011-06-06 Stefan Monnier <monnier@iro.umontreal.ca> |
5655 | ||
5656 | * window.h (Fwindow_frame): Declare. | |
5657 | ||
2b6148e4 PE |
5658 | 2011-06-06 Paul Eggert <eggert@cs.ucla.edu> |
5659 | ||
5660 | * alloc.c: Simplify handling of large-request failures (Bug#8800). | |
5661 | (SPARE_MEMORY): Always define. | |
5662 | (LARGE_REQUEST): Remove. | |
5663 | (memory_full): Use SPARE_MEMORY rather than LARGE_REQUEST. | |
5664 | ||
f230ecc9 MR |
5665 | 2011-06-06 Martin Rudalics <rudalics@gmx.at> |
5666 | ||
727e958e MR |
5667 | * lisp.h: Move EXFUNS for Fframe_root_window, |
5668 | Fframe_first_window and Fset_frame_selected_window to window.h. | |
5669 | ||
5670 | * window.h: Move EXFUNS for Fframe_root_window, | |
5671 | Fframe_first_window and Fset_frame_selected_window here from | |
5672 | lisp.h. | |
5673 | ||
5674 | * frame.c (Fwindow_frame, Fframe_first_window) | |
5675 | (Fframe_root_window, Fframe_selected_window) | |
5676 | (Fset_frame_selected_window): Move to window.c. | |
5677 | (Factive_minibuffer_window): Move to minibuf.c. | |
5678 | (Fother_visible_frames_p): New function. | |
5679 | ||
5680 | * minibuf.c (Factive_minibuffer_window): Move here from frame.c. | |
5681 | ||
f230ecc9 MR |
5682 | * window.c (decode_window, decode_any_window): Move up in code. |
5683 | (Fwindowp, Fwindow_live_p): Rewrite doc-strings. | |
5684 | (inhibit_frame_unsplittable): Remove unused variable. | |
bf60a96b MR |
5685 | (Fwindow_buffer): Move up and rewrite doc-string. |
5686 | (Fwindow_parent, Fwindow_vchild, Fwindow_hchild, Fwindow_next) | |
5687 | (Fwindow_prev): New functions. | |
727e958e MR |
5688 | (Fwindow_frame): Move here from frame.c. Accept any window as |
5689 | argument. | |
5690 | (Fframe_root_window, Fframe_first_window) | |
5691 | (Fframe_selected_window): Move here from frame.c. Accept frame | |
5692 | or arbitrary window as argument. Update doc-strings. | |
5693 | (Fminibuffer_window): Move up in code. | |
5694 | (Fwindow_minibuffer_p): Move up in code and simplify. | |
d6d100dd SM |
5695 | (Fset_frame_selected_window): Move here from frame.c. |
5696 | Marginal rewrite. | |
727e958e MR |
5697 | (Fselected_window, select_window, Fselect_window): Move up in |
5698 | code. Minor doc-string fixes. | |
f230ecc9 | 5699 | |
4d09bcf6 PE |
5700 | 2011-06-06 Paul Eggert <eggert@cs.ucla.edu> |
5701 | ||
5702 | * alloc.c (memory_full) [SYSTEM_MALLOC]: Port to MacOS (Bug#8800). | |
5703 | Do not assume that spare memory exists; that assumption is valid | |
5704 | only if SYSTEM_MALLOC. | |
5705 | (LARGE_REQUEST): New macro, so that the issue of large requests | |
5706 | is separated from the issue of spare memory. | |
5707 | ||
810928a2 AS |
5708 | 2011-06-05 Andreas Schwab <schwab@linux-m68k.org> |
5709 | ||
172418ad AS |
5710 | * editfns.c (Fformat): Correctly handle zero flag with hexadecimal |
5711 | format. (Bug#8806) | |
5712 | ||
43f862f7 AS |
5713 | * gtkutil.c (xg_get_default_scrollbar_width): Avoid warning. |
5714 | ||
810928a2 AS |
5715 | * xfns.c (x_set_scroll_bar_default_width): Move declarations |
5716 | before statements. | |
5717 | ||
a059fe24 JD |
5718 | 2011-06-05 Jan Djärv <jan.h.d@swipnet.se> |
5719 | ||
5720 | * gtkutil.c (xg_get_default_scrollbar_width): New function. | |
5721 | ||
5722 | * gtkutil.h: Declare xg_get_default_scrollbar_width. | |
5723 | ||
5724 | * xfns.c (x_set_scroll_bar_default_width): If USE_GTK, get | |
5725 | min width by calling x_set_scroll_bar_default_width (Bug#8505). | |
5726 | ||
989bf368 JB |
5727 | 2011-06-05 Juanma Barranquero <lekktu@gmail.com> |
5728 | ||
5729 | * xdisp.c (single_display_spec_intangible_p): Remove declaration. | |
5730 | ||
4b80f674 CY |
5731 | 2011-06-04 Chong Yidong <cyd@stupidchicken.com> |
5732 | ||
5733 | * xselect.c (x_clipboard_manager_save): Remove redundant arg. | |
5734 | (x_clipboard_manager_save): Add return value. | |
d6d100dd SM |
5735 | (x_clipboard_manager_error_1, x_clipboard_manager_error_2): |
5736 | New error handlers. | |
4b80f674 CY |
5737 | (x_clipboard_manager_save_frame, x_clipboard_manager_save_all): |
5738 | Obey Vx_select_enable_clipboard_manager. Catch errors in | |
5739 | x_clipboard_manager_save (Bug#8779). | |
5740 | (Vx_select_enable_clipboard_manager): New variable. | |
de65b42c | 5741 | (x_get_foreign_selection): Reduce scope of x_catch_errors (Bug#8790). |
4b80f674 | 5742 | |
99a33b77 | 5743 | 2011-06-04 Dan Nicolaescu <dann@ics.uci.edu> |
8b3115e7 DN |
5744 | |
5745 | * emacs.c (main): Warn when starting a GTK emacs in daemon mode. | |
5746 | ||
99a33b77 | 5747 | 2011-06-04 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
14eca62f YM |
5748 | |
5749 | * fringe.c (update_window_fringes): Don't update overlay arrow bitmap | |
5750 | in the current matrix if keep_current_p is non-zero. | |
5751 | ||
8264569d EZ |
5752 | 2011-06-04 Eli Zaretskii <eliz@gnu.org> |
5753 | ||
5754 | * bidi.c (bidi_level_of_next_char): Fix last change. | |
5755 | ||
57f97249 EZ |
5756 | 2011-06-03 Eli Zaretskii <eliz@gnu.org> |
5757 | ||
fec2107c | 5758 | Support bidi reordering of text covered by display properties. |
57f97249 | 5759 | |
fec2107c EZ |
5760 | * bidi.c (bidi_copy_it): Use offsetof instead of emulating it. |
5761 | (bidi_fetch_char, bidi_fetch_char_advance): New functions. | |
5762 | (bidi_cache_search, bidi_cache_iterator_state) | |
5763 | (bidi_paragraph_init, bidi_resolve_explicit, bidi_resolve_weak) | |
d6d100dd SM |
5764 | (bidi_level_of_next_char, bidi_move_to_visually_next): |
5765 | Support character positions inside a run of characters covered by a | |
fec2107c EZ |
5766 | display string. |
5767 | (bidi_paragraph_init, bidi_resolve_explicit_1) | |
5768 | (bidi_level_of_next_char): Call bidi_fetch_char and | |
5769 | bidi_fetch_char_advance instead of FETCH_CHAR and | |
5770 | FETCH_CHAR_ADVANCE. | |
5771 | (bidi_init_it): Initialize new members. | |
5772 | (LRE_CHAR, RLE_CHAR, PDF_CHAR, LRO_CHAR, RLO_CHAR): Remove macro | |
5773 | definitions. | |
5774 | (bidi_explicit_dir_char): Lookup character type in bidi_type_table, | |
5775 | instead of using explicit *_CHAR codes. | |
d6d100dd SM |
5776 | (bidi_resolve_explicit, bidi_resolve_weak): |
5777 | Use FETCH_MULTIBYTE_CHAR instead of FETCH_CHAR, as reordering of | |
fec2107c EZ |
5778 | bidirectional text is supported only in multibyte buffers. |
5779 | (bidi_init_it): Accept additional argument FRAME_WINDOW_P and use | |
5780 | it to initialize the frame_window_p member of struct bidi_it. | |
5781 | (bidi_cache_iterator_state, bidi_resolve_explicit_1) | |
5782 | (bidi_resolve_explicit, bidi_resolve_weak) | |
5783 | (bidi_level_of_next_char, bidi_move_to_visually_next): Abort if | |
5784 | bidi_it->nchars is non-positive. | |
5785 | (bidi_level_of_next_char): Don't try to lookup the cache for the | |
5786 | next/previous character if nothing is cached there yet, or if we | |
5787 | were just reseat()'ed to a new position. | |
c40e2fb2 | 5788 | |
0e14fe90 EZ |
5789 | * xdisp.c (set_cursor_from_row): Set start and stop points |
5790 | according to the row's direction when priming the loop that looks | |
5791 | for the glyph on which to display cursor. | |
5792 | (single_display_spec_intangible_p): Function deleted. | |
5793 | (display_prop_intangible_p): Reimplement to call | |
5794 | handle_display_spec instead of single_display_spec_intangible_p. | |
d6d100dd SM |
5795 | Accept 3 additional arguments needed by handle_display_spec. |
5796 | This fixes incorrect cursor motion across display property with complex | |
0e14fe90 EZ |
5797 | values: lists, `(when COND...)' forms, etc. |
5798 | (single_display_spec_string_p): Support property values that are | |
5799 | lists with the argument STRING its top-level element. | |
5800 | (display_prop_string_p): Fix the condition for processing a | |
5801 | property that is a list to be consistent with handle_display_spec. | |
fec2107c | 5802 | (handle_display_spec): New function, refactored from the |
fc6f18ce EZ |
5803 | last portion of handle_display_prop. |
5804 | (compute_display_string_pos): Accept additional argument | |
5805 | FRAME_WINDOW_P. Call handle_display_spec to determine whether the | |
5806 | value of a `display' property is a "replacing spec". | |
5807 | (handle_single_display_spec): Accept 2 additional arguments BUFPOS | |
5808 | and FRAME_WINDOW_P. If IT is NULL, don't set up the iterator from | |
5809 | the display property, but just return a value indicating whether | |
5810 | the display property will replace the characters it covers. | |
5811 | (Fcurrent_bidi_paragraph_direction): Initialize the nchars and | |
5812 | frame_window_p members of struct bidi_it. | |
d6d100dd SM |
5813 | (compute_display_string_pos, compute_display_string_end): |
5814 | New functions. | |
fec2107c EZ |
5815 | (push_it): Accept second argument POSITION, where pop_it should |
5816 | jump to continue iteration. | |
5817 | (reseat_1): Initialize bidi_it.disp_pos. | |
fc6f18ce | 5818 | |
fec2107c EZ |
5819 | * keyboard.c (adjust_point_for_property): Adjust the call to |
5820 | display_prop_intangible_p to its new signature. | |
fc6f18ce EZ |
5821 | |
5822 | * dispextern.h (struct bidi_it): New member frame_window_p. | |
fec2107c EZ |
5823 | (bidi_init_it): Update prototypes. |
5824 | (display_prop_intangible_p): Update prototype. | |
d6d100dd SM |
5825 | (compute_display_string_pos, compute_display_string_end): |
5826 | Declare prototypes. | |
fec2107c EZ |
5827 | (struct bidi_it): New members nchars and disp_pos. ch_len is now |
5828 | EMACS_INT. | |
fc6f18ce | 5829 | |
40087514 | 5830 | 2011-06-02 Paul Eggert <eggert@cs.ucla.edu> |
0de4bb68 | 5831 | |
57f53182 PE |
5832 | Malloc failure behavior now depends on size of allocation. |
5833 | * alloc.c (buffer_memory_full, memory_full): New arg NBYTES. | |
5834 | * lisp.h: Change signatures accordingly. | |
5835 | * alloc.c, buffer.c, editfns.c, menu.c, minibuf.c, xterm.c: | |
5836 | All callers changed. (Bug#8762) | |
5837 | ||
5838 | * gnutls.c: Use Emacs's memory allocators. | |
5839 | Without this change, the gnutls library would invoke malloc etc. | |
5840 | directly, which causes problems on non-SYNC_INPUT hosts, and which | |
5841 | runs afoul of improving memory_full behavior. (Bug#8761) | |
5842 | (fn_gnutls_global_set_mem_functions): New macro or function pointer. | |
5843 | (emacs_gnutls_global_init): Use it to specify xmalloc, xrealloc, | |
5844 | xfree instead of the default malloc, realloc, free. | |
5845 | (Fgnutls_boot): No need to check for memory allocation failure, | |
5846 | since xmalloc does that for us. | |
5847 | ||
ac32cd99 | 5848 | Remove arbitrary limit of 2**31 entries in hash tables. (Bug#8771) |
3870d916 PE |
5849 | * category.c (hash_get_category_set): |
5850 | * ccl.c (ccl_driver): | |
5851 | * charset.c (Fdefine_charset_internal): | |
5852 | * charset.h (struct charset.hash_index): | |
5853 | * composite.c (get_composition_id, gstring_lookup_cache) | |
5854 | (composition_gstring_put_cache): | |
5855 | * composite.h (struct composition.hash_index): | |
5856 | * dispextern.h (struct image.hash): | |
5857 | * fns.c (next_almost_prime, larger_vector, cmpfn_eql) | |
5858 | (cmpfn_equal, cmpfn_user_defined, hashfn_eq, hashfn_eql) | |
5859 | (hashfn_equal, hashfn_user_defined, make_hash_table) | |
5860 | (maybe_resize_hash_table, hash_lookup, hash_put) | |
5861 | (hash_remove_from_table, hash_clear, sweep_weak_table, SXHASH_COMBINE) | |
5862 | (sxhash_string, sxhash_list, sxhash_vector, sxhash_bool_vector) | |
5863 | (Fsxhash, Fgethash, Fputhash, Fmaphash): | |
5864 | * image.c (make_image, search_image_cache, lookup_image) | |
5865 | (xpm_put_color_table_h): | |
5866 | * lisp.h (struct Lisp_Hash_Table): | |
0de4bb68 | 5867 | * minibuf.c (Ftry_completion, Fall_completions, Ftest_completion): |
ac389d0c | 5868 | * print.c (print): Use 'EMACS_UINT' and 'EMACS_INT' |
3870d916 | 5869 | for hashes and hash indexes, instead of 'unsigned' and 'int'. |
40087514 PE |
5870 | * alloc.c (allocate_vectorlike): |
5871 | Check for overflow in vector size calculations. | |
5872 | * ccl.c (ccl_driver): | |
5873 | Check for overflow when converting EMACS_INT to int. | |
0de4bb68 PE |
5874 | * fns.c, image.c: Remove unnecessary static decls that would otherwise |
5875 | need to be updated by these changes. | |
40087514 PE |
5876 | * fns.c (make_hash_table, maybe_resize_hash_table): |
5877 | Check for integer overflow with large hash tables. | |
0de4bb68 PE |
5878 | (make_hash_table, maybe_resize_hash_table, Fmake_hash_table): |
5879 | Prefer the faster XFLOAT_DATA to XFLOATINT where either will do. | |
5880 | (SXHASH_REDUCE): New macro. | |
5881 | (sxhash_string, sxhash_list, sxhash_vector, sxhash_bool_vector): | |
5882 | Use it instead of discarding useful hash info with large hash values. | |
5883 | (sxhash_float): New function. | |
5884 | (sxhash): Use it. No more need for "& INTMASK" due to above changes. | |
5885 | * lisp.h (FIXNUM_BITS): New macro, useful for SXHASH_REDUCE etc. | |
40087514 PE |
5886 | (MOST_NEGATIVE_FIXNUM, MOST_POSITIVE_FIXNUM, INTMASK): |
5887 | Rewrite to use FIXNUM_BITS, as this simplifies things. | |
0de4bb68 PE |
5888 | (next_almost_prime, larger_vector, sxhash, hash_lookup, hash_put): |
5889 | Adjust signatures to match updated version of code. | |
5890 | (consing_since_gc): Now EMACS_INT, since a single hash table can | |
5891 | use more than INT_MAX bytes. | |
5892 | ||
698d32e2 DN |
5893 | 2011-06-01 Dan Nicolaescu <dann@ics.uci.edu> |
5894 | ||
5895 | Make it possible to build with GCC-4.6+ -O2 -flto. | |
5896 | ||
5897 | * emacs.c (__malloc_initialize_hook): Mark as EXTERNALLY_VISIBLE. | |
5898 | ||
fd6fa53f SM |
5899 | 2011-06-01 Stefan Monnier <monnier@iro.umontreal.ca> |
5900 | ||
5901 | * minibuf.c (get_minibuffer, read_minibuf_unwind): | |
5902 | Call minibuffer-inactive-mode. | |
5903 | ||
864db017 JB |
5904 | 2011-05-31 Juanma Barranquero <lekktu@gmail.com> |
5905 | ||
5906 | * makefile.w32-in ($(BLD)/data.$(O), $(BLD)/editfns.$(O)): | |
5907 | Update dependencies. | |
5908 | ||
2ad0baf4 DN |
5909 | 2011-05-31 Dan Nicolaescu <dann@ics.uci.edu> |
5910 | ||
5911 | * data.c (init_data): Remove code for UTS, this system is not | |
5912 | supported anymore. | |
5913 | ||
4fcc2638 DN |
5914 | 2011-05-31 Dan Nicolaescu <dann@ics.uci.edu> |
5915 | ||
5916 | Don't force ./temacs to start in terminal mode. | |
5917 | ||
5918 | * frame.c (make_initial_frame): Initialize faces in all cases, not | |
5919 | only when CANNOT_DUMP is defined. | |
5920 | * dispnew.c (init_display): Remove CANNOT_DUMP condition. | |
5921 | ||
c56e0fd5 DN |
5922 | 2011-05-31 Dan Nicolaescu <dann@ics.uci.edu> |
5923 | ||
5924 | * dispnew.c (add_window_display_history): Use const for the string | |
5925 | pointer. Remove declaration, not needed. | |
5926 | ||
333d54da | 5927 | 2011-05-31 Paul Eggert <eggert@cs.ucla.edu> |
9cf9f756 | 5928 | |
55d4c1b2 | 5929 | Use 'inline', not 'INLINE'. |
333d54da | 5930 | <http://lists.gnu.org/archive/html/emacs-devel/2011-05/msg00914.html> |
55d4c1b2 PE |
5931 | * alloc.c, fontset.c (INLINE): Remove. |
5932 | * alloc.c, bidi.c, charset.c, coding.c, dispnew.c, fns.c, image.c: | |
5933 | * intervals.c, keyboard.c, process.c, syntax.c, textprop.c, w32term.c: | |
5934 | * xdisp.c, xfaces.c, xterm.c: Replace all uses of INLINE with inline. | |
5935 | * gmalloc.c (register_heapinfo): Use inline unconditionally. | |
5936 | * lisp.h (LISP_MAKE_RVALUE): Use inline, not __inline__. | |
5937 | ||
738db178 DN |
5938 | 2011-05-31 Dan Nicolaescu <dann@ics.uci.edu> |
5939 | ||
5940 | Make it possible to run ./temacs. | |
5941 | ||
5942 | * callproc.c (set_initial_environment): Remove CANNOT_DUMP code, | |
5943 | syms_of_callproc does the same thing. Remove test for | |
5944 | "initialized", do it in the caller. | |
5945 | * emacs.c (main): Avoid calling set_initial_environment when dumping. | |
5946 | ||
620c53a6 SM |
5947 | 2011-05-31 Stefan Monnier <monnier@iro.umontreal.ca> |
5948 | ||
5949 | * minibuf.c (Finternal_complete_buffer): Return `category' metadata. | |
5950 | (read_minibuf): Use get_minibuffer. | |
5951 | (syms_of_minibuf): Use DEFSYM. | |
5952 | (Qmetadata): New var. | |
5953 | * data.c (Qbuffer): Don't make it static. | |
5954 | (syms_of_data): Use DEFSYM. | |
5955 | ||
e003a292 PE |
5956 | 2011-05-31 Paul Eggert <eggert@cs.ucla.edu> |
5957 | ||
5958 | * ccl.c (CCL_CODE_RANGE): Allow negative numbers. (Bug#8751) | |
5959 | (CCL_CODE_MIN): New macro. | |
5960 | ||
ed008a6d PE |
5961 | 2011-05-30 Paul Eggert <eggert@cs.ucla.edu> |
5962 | ||
3687c2ef PE |
5963 | * alloc.c (lisp_align_malloc): Omit unnecessary val==NULL tests. |
5964 | ||
ed008a6d PE |
5965 | * eval.c (Qdebug): Now static. |
5966 | * lisp.h (Qdebug): Remove decl. This reverts a part of the | |
5967 | 2011-04-26T11:26:05Z!dan.colascione@gmail.com that inadvertently undid part of | |
5968 | 2011-04-14T06:48:41Z!eggert@cs.ucla.edu. | |
5969 | ||
d66c4c7c CY |
5970 | 2011-05-29 Chong Yidong <cyd@stupidchicken.com> |
5971 | ||
5972 | * image.c: Various fixes to ImageMagick code comments. | |
5973 | (Fimagemagick_types): Doc fix. | |
5974 | ||
5fbc2025 PE |
5975 | 2011-05-29 Paul Eggert <eggert@cs.ucla.edu> |
5976 | ||
0196f88a PE |
5977 | Minor fixes prompted by GCC 4.6.0 warnings. |
5978 | ||
5979 | * xselect.c (converted_selections, conversion_fail_tag): Now static. | |
5980 | ||
5fbc2025 PE |
5981 | * emacs.c [HAVE_X_WINDOWS]: Include "xterm.h". |
5982 | (x_clipboard_manager_save_all): Move extern decl to ... | |
5983 | * xterm.h: ... here, so that it can be checked for consistency. | |
5984 | ||
1dd3c2d9 CY |
5985 | 2011-05-29 Chong Yidong <cyd@stupidchicken.com> |
5986 | ||
5987 | * xselect.c (x_clipboard_manager_save_frame) | |
5988 | (x_clipboard_manager_save_all): New functions. | |
5989 | (Fx_clipboard_manager_save): Lisp function deleted. | |
5990 | ||
5991 | * emacs.c (Fkill_emacs): Call x_clipboard_manager_save_all. | |
5992 | * frame.c (delete_frame): Call x_clipboard_manager_save_frame. | |
5993 | ||
5994 | * xterm.h: Update prototype. | |
5995 | ||
5ba6571d WX |
5996 | 2011-05-28 William Xu <william.xwl@gmail.com> |
5997 | ||
5998 | * nsterm.m (ns_term_shutdown): Synchronize user defaults before | |
5999 | exiting (Bug#8239). | |
6000 | ||
3eaff834 JM |
6001 | 2011-05-28 Jim Meyering <meyering@redhat.com> |
6002 | ||
e1900994 | 6003 | Avoid a sign-extension bug in crypto_hash_function. |
3eaff834 JM |
6004 | * fns.c (to_uchar): Define. |
6005 | (crypto_hash_function): Use it to convert some newly-signed | |
6006 | variables to unsigned, to avoid sign-extension bugs. For example, | |
6007 | without this change, (md5 "truc") would evaluate to | |
6008 | 45723a2aff78ff4fff7fff1114760e62 rather than the expected | |
6009 | 45723a2af3788c4ff17f8d1114760e62. Reported by Antoine Levitt in | |
e1900994 | 6010 | https://lists.gnu.org/archive/html/emacs-devel/2011-05/msg00883.html. |
3eaff834 | 6011 | |
0f6990a7 PE |
6012 | 2011-05-27 Paul Eggert <eggert@cs.ucla.edu> |
6013 | ||
6014 | Integer overflow fixes. | |
c8a9ca5a | 6015 | |
08686060 PE |
6016 | * dbusbind.c: Serial number integer overflow fixes. |
6017 | (CHECK_DBUS_SERIAL_GET_SERIAL): New macro. | |
08686060 PE |
6018 | (Fdbus_call_method_asynchronously, xd_read_message_1): Use a float |
6019 | to hold a serial number that is too large for a fixnum. | |
6020 | (Fdbus_method_return_internal, Fdbus_method_error_internal): | |
6021 | Check for serial numbers out of range. Decode any serial number | |
59568bf0 | 6022 | that was so large that it became a float. (Bug#8722) |
08686060 | 6023 | |
2d1fc3c7 PE |
6024 | * dbusbind.c: Use XFASTINT rather than XUINT, and check for nonneg. |
6025 | (Fdbus_call_method, Fdbus_call_method_asynchronously): | |
6026 | Use XFASTINT rather than XUINT when numbers are nonnegative. | |
6027 | (xd_append_arg, Fdbus_method_return_internal): | |
6028 | (Fdbus_method_error_internal): Likewise. Also, for unsigned | |
6029 | arguments, check that Lisp number is nonnegative, rather than | |
59568bf0 | 6030 | silently wrapping negative numbers around. (Bug#8722) |
30217ff0 | 6031 | (xd_read_message_1): Don't assume dbus_uint32_t can fit in int. |
59568bf0 | 6032 | (Bug#8722) |
2d1fc3c7 | 6033 | |
c8a9ca5a PE |
6034 | * data.c (arith_driver, Flsh): Avoid unnecessary casts to EMACS_UINT. |
6035 | ||
519e1d69 PE |
6036 | * ccl.c (ccl_driver): Redo slightly to avoid the need for 'unsigned'. |
6037 | ||
6df6ae42 | 6038 | ccl: Add integer overflow checks. |
30569699 PE |
6039 | * ccl.c (CCL_CODE_MAX, GET_CCL_RANGE, GET_CCL_CODE, GET_CCL_INT): |
6040 | (IN_INT_RANGE): New macros. | |
6041 | (ccl_driver): Use them to check for integer overflow when | |
6042 | decoding a CCL program. Many of the new checks are whether XINT (x) | |
6043 | fits in int; it doesn't always, on 64-bit hosts. The new version | |
6044 | doesn't catch all possible integer overflows, but it's an | |
847044ea | 6045 | improvement. (Bug#8719) |
30569699 | 6046 | |
c11285dc PE |
6047 | * alloc.c (make_event_array): Use XINT, not XUINT. |
6048 | There's no need for unsigned here. | |
6049 | ||
fdccd48e PE |
6050 | * mem-limits.h (EXCEEDS_LISP_PTR) [!USE_LSB_TAG]: EMACS_UINT -> uintptr_t |
6051 | This follows up to the 2011-05-06 change that substituted uintptr_t | |
6052 | for EMACS_INT. This case wasn't caught back then. | |
6053 | ||
37910ab2 PE |
6054 | Rework Fformat to avoid integer overflow issues. |
6055 | * editfns.c: Include <float.h> unconditionally, as it's everywhere | |
6056 | now (part of C89). Include <verify.h>. | |
6057 | (MAX_10_EXP, CONVERTED_BYTE_SIZE): Remove; no longer needed. | |
6058 | (pWIDE, pWIDElen, signed_wide, unsigned_wide): New defns. | |
6059 | (Fformat): Avoid the prepass trying to compute sizes; it was only | |
6060 | approximate and thus did not catch overflow reliably. Instead, walk | |
6061 | through the format just once, formatting and computing sizes as we go, | |
6062 | checking for integer overflow at every step, and allocating a larger | |
6063 | buffer as needed. Keep track separately whether the format is | |
6064 | multibyte. Keep only the most-recently calculated precision, rather | |
6065 | than them all. Record whether each argument has been converted to | |
6066 | string. Use EMACS_INT, not int, for byte and char and arg counts. | |
6067 | Support field widths and precisions larger than INT_MAX. Avoid | |
6068 | sprintf's undefined behavior with conversion specifications such as %#d | |
6069 | and %.0c. Fix bug with strchr succeeding on '\0' when looking for | |
6070 | flags. Fix bug with (format "%c" 256.0). Avoid integer overflow when | |
6071 | formatting out-of-range floating point numbers with int | |
9173deec | 6072 | formats. (Bug#8668) |
37910ab2 | 6073 | |
2e6578fb PE |
6074 | * lisp.h (FIXNUM_OVERFLOW_P): Work even if arg is a NaN. |
6075 | ||
0ae6bdee PE |
6076 | * data.c: Avoid integer truncation in expressions involving floats. |
6077 | * data.c: Include <intprops.h>. | |
6078 | (arith_driver): When there's an integer overflow in an expression | |
6079 | involving floating point, convert the integers to floating point | |
6080 | so that the resulting value does not suffer from catastrophic | |
6081 | integer truncation. For example, on a 64-bit host (* 4 | |
6082 | most-negative-fixnum 0.5) should yield about -4.6e+18, not zero. | |
6083 | Do not rely on undefined behavior after integer overflow. | |
6084 | ||
de883a70 PE |
6085 | merge count_size_as_multibyte, parse_str_to_multibyte |
6086 | * character.c, character.h (count_size_as_multibyte): | |
fd6fa53f | 6087 | Rename from parse_str_to_multibyte; all uses changed. |
de883a70 PE |
6088 | Check for integer overflow. |
6089 | * insdel.c, lisp.h (count_size_as_multibyte): Remove, | |
6090 | since it's now a duplicate of the other. This is more of | |
6091 | a character than a buffer op, so better that it's in character.c. | |
6092 | * fns.c, print.c: Adjust to above changes. | |
6093 | ||
2ff916cb PE |
6094 | 2011-05-27 Stefan Monnier <monnier@iro.umontreal.ca> |
6095 | ||
6096 | * xselect.c (x_convert_selection): Yet another int/Lisp_Object mixup. | |
6097 | ||
f1b54466 PE |
6098 | 2011-05-27 Paul Eggert <eggert@cs.ucla.edu> |
6099 | ||
fb1ac845 PE |
6100 | * xselect.c: Fix minor problems prompted by GCC 4.6.0 warnings. |
6101 | (x_handle_selection_request, frame_for_x_selection): Remove unused vars. | |
6102 | (x_clipboard_manager_save): Now static. | |
6103 | (Fx_clipboard_manager_save): Rename local to avoid shadowing. | |
6104 | ||
f1b54466 PE |
6105 | * fns.c: Fix minor problems prompted by GCC 4.6.0 warnings. |
6106 | (crypto_hash_function): Now static. | |
6107 | Fix pointer signedness problems. Avoid unnecessary initializations. | |
6108 | ||
a9f737ee CY |
6109 | 2011-05-27 Chong Yidong <cyd@stupidchicken.com> |
6110 | ||
6111 | * termhooks.h (Vselection_alist): Make it terminal-local. | |
6112 | ||
6113 | * terminal.c (create_terminal): Initialize it. | |
6114 | ||
6115 | * xselect.c: Support for clipboard managers. | |
6116 | (Vselection_alist): Move to termhooks.h as terminal-local var. | |
6117 | (LOCAL_SELECTION): New macro. | |
6118 | (x_atom_to_symbol): Handle x_display_info_for_display fail case. | |
6119 | (symbol_to_x_atom): Remove gratuitous arg. | |
6120 | (x_handle_selection_request, lisp_data_to_selection_data) | |
6121 | (x_get_foreign_selection, Fx_register_dnd_atom): Callers changed. | |
620c53a6 SM |
6122 | (x_own_selection, x_get_local_selection, x_convert_selection): |
6123 | New arg, specifying work frame. Use terminal-local Vselection_alist. | |
a9f737ee CY |
6124 | (some_frame_on_display): Delete unused function. |
6125 | (Fx_own_selection_internal, Fx_get_selection_internal) | |
6126 | (Fx_disown_selection_internal, Fx_selection_owner_p) | |
6127 | (Fx_selection_exists_p): New optional frame arg. | |
6128 | (frame_for_x_selection, Fx_clipboard_manager_save): New functions. | |
6129 | (x_handle_selection_clear): Don't treat other terminals with the | |
6130 | same keyboard specially. Use the terminal-local Vselection_alist. | |
6131 | (x_clear_frame_selections): Use Frun_hook_with_args. | |
6132 | ||
6133 | * xterm.c (x_term_init): Intern ATOM and CLIPBOARD_MANAGER atoms. | |
6134 | ||
6135 | * xterm.h: Add support for those atoms. | |
6136 | ||
e067f0c1 CY |
6137 | 2011-05-26 Chong Yidong <cyd@stupidchicken.com> |
6138 | ||
6139 | * xselect.c: ICCCM-compliant handling of MULTIPLE targets. | |
6140 | (converted_selections, conversion_fail_tag): New global variables. | |
6141 | (x_selection_request_lisp_error): Free the above. | |
6142 | (x_get_local_selection): Remove unnecessary code. | |
6143 | (x_reply_selection_request): Args changed; handle arbitrary array | |
620c53a6 SM |
6144 | of converted selections stored in converted_selections. |
6145 | Separate the XChangeProperty and SelectionNotify steps. | |
e067f0c1 CY |
6146 | (x_handle_selection_request): Rewrite to handle MULTIPLE target. |
6147 | (x_convert_selection): New function. | |
6148 | (x_handle_selection_event): Simplify. | |
6149 | (x_get_foreign_selection): Don't ignore incoming requests while | |
6150 | waiting for an answer; this will fail when we implement | |
6151 | SAVE_TARGETS, and seems unnecessary anyway. | |
6152 | (selection_data_to_lisp_data): Recognize ATOM_PAIR type. | |
6153 | (Vx_sent_selection_functions): Doc fix. | |
6154 | ||
0f4aebc0 LL |
6155 | 2011-05-26 Leo Liu <sdl.web@gmail.com> |
6156 | ||
6157 | * editfns.c (Ftranspose_regions): Allow empty regions. (Bug#8699) | |
6158 | ||
e61124cd YM |
6159 | 2011-05-25 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
6160 | ||
6161 | * dispextern.h (struct glyph_row): New member fringe_bitmap_periodic_p. | |
6162 | ||
6163 | * dispnew.c (shift_glyph_matrix, scrolling_window): Mark scrolled row | |
6164 | for fringe update if it has periodic bitmap. | |
ac389d0c | 6165 | (row_equal_p): Also compare left_fringe_offset, right_fringe_offset, |
e61124cd YM |
6166 | and fringe_bitmap_periodic_p. |
6167 | ||
6168 | * fringe.c (get_fringe_bitmap_data): New function. | |
6169 | (draw_fringe_bitmap_1, update_window_fringes): Use it. | |
6170 | (update_window_fringes): Record periodicity of fringe bitmap in glyph | |
6171 | row. Mark glyph row for fringe update if periodicity changed. | |
6172 | ||
6173 | * xdisp.c (try_window_reusing_current_matrix): Don't mark scrolled row | |
6174 | for fringe update unless it has periodic bitmap. | |
6175 | ||
f16d9837 KH |
6176 | 2011-05-25 Kenichi Handa <handa@m17n.org> |
6177 | ||
6178 | * xdisp.c (get_next_display_element): Set correct it->face_id for | |
6179 | a static composition. | |
6180 | ||
e1b90ef6 LL |
6181 | 2011-05-24 Leo Liu <sdl.web@gmail.com> |
6182 | ||
6183 | * deps.mk (fns.o): | |
6184 | * makefile.w32-in ($(BLD)/fns.$(O)): Include sha1.h. | |
6185 | ||
6186 | * fns.c (crypto_hash_function, Fsha1): New function. | |
6187 | (Fmd5): Use crypto_hash_function. | |
6188 | (syms_of_fns): Add Ssha1. | |
6189 | ||
7400048f PE |
6190 | 2011-05-22 Paul Eggert <eggert@cs.ucla.edu> |
6191 | ||
6192 | * gnutls.c: Remove unused macros. | |
6193 | (fn_gnutls_transport_set_lowat, fn_gnutls_transport_set_pull_function): | |
6194 | (fn_gnutls_transport_set_push_function) [!WINDOWSNT]: | |
6195 | Remove macros that are defined and never used. | |
6196 | Caught by gcc -Wunused-macros (GCC 4.6.0, Fedora 14). | |
6197 | ||
abb71cf4 CY |
6198 | 2011-05-22 Chong Yidong <cyd@stupidchicken.com> |
6199 | ||
6200 | * xselect.c (syms_of_xselect): Remove unused symbol SAVE_TARGETS. | |
6201 | (Fx_get_selection_internal): Minor cleanup. | |
6202 | (Fx_own_selection_internal): Rename arguments for consistency with | |
6203 | select.el. | |
6204 | ||
6307db39 PE |
6205 | 2011-05-22 Paul Eggert <eggert@cs.ucla.edu> |
6206 | ||
6207 | * xselect.c (QSAVE_TARGETS): New static var, to fix build failure. | |
6208 | ||
f3d4e0a4 CY |
6209 | 2011-05-22 Chong Yidong <cyd@stupidchicken.com> |
6210 | ||
6211 | * xselect.c (syms_of_xselect): Include character.h; use DEFSYM. | |
6212 | ||
4d8ade89 YM |
6213 | 2011-05-21 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
6214 | ||
6215 | * dispnew.c (scrolling_window): Don't exclude the case that the | |
6216 | last enabled row in the desired matrix touches the bottom boundary. | |
6217 | ||
32078c8d GM |
6218 | 2011-05-21 Glenn Morris <rgm@gnu.org> |
6219 | ||
6220 | * Makefile.in ($(etc)/DOC): Make second command line even shorter. | |
33cf345f GM |
6221 | (SOME_MACHINE_OBJECTS): Replace FONT_OBJ by its maximal expansion, |
6222 | and add some more files. | |
32078c8d | 6223 | |
7285dc67 EZ |
6224 | 2011-05-20 Eli Zaretskii <eliz@gnu.org> |
6225 | ||
6226 | * callproc.c (Fcall_process) [MSDOS]: Fix arguments to | |
6227 | report_file_error introduced by the change from 2011-05-07. | |
6228 | ||
89d1bd22 PE |
6229 | 2011-05-20 Paul Eggert <eggert@cs.ucla.edu> |
6230 | ||
6231 | * systime.h (Time): Define only if emacs is defined. | |
6232 | This is to allow ../lib-src/profile.c to be compiled on FreeBSD, | |
6233 | where the include path doesn't have X11/X.h by default. See | |
6234 | <http://lists.gnu.org/archive/html/emacs-devel/2011-05/msg00561.html>. | |
6235 | ||
cd394be1 | 6236 | 2011-05-20 Kenichi Handa <handa@m17n.org> |
31bfc35c KH |
6237 | |
6238 | * composite.c (find_automatic_composition): Fix previous change. | |
6239 | ||
b9704ad9 GM |
6240 | 2011-05-20 Glenn Morris <rgm@gnu.org> |
6241 | ||
6242 | * lisp.mk: New file, split from Makefile.in. | |
6243 | * Makefile.in (lisp): Move to separate file, inserted by @lisp_frag@. | |
6244 | (shortlisp): Remove. | |
6245 | ($(etc)/DOC): Edit lisp.mk rather than using $shortlisp. | |
6246 | ||
4a720484 GM |
6247 | 2011-05-19 Glenn Morris <rgm@gnu.org> |
6248 | ||
6249 | * Makefile.in (MSDOS_SUPPORT_REAL, MSDOS_SUPPORT, NS_SUPPORT) | |
6250 | (REAL_MOUSE_SUPPORT, GPM_MOUSE_SUPPORT, MOUSE_SUPPORT, TOOLTIP_SUPPORT) | |
6251 | (BASE_WINDOW_SUPPORT, X_WINDOW_SUPPORT, WINDOW_SUPPORT): Remove. | |
6252 | (lisp): Set the order to that of loadup.el. | |
6253 | (shortlisp): Make it a copy of $lisp. | |
6254 | (SOME_MACHINE_LISP): Remove. | |
6255 | ($(etc)/DOC): Depend just on $lisp, not $SOME_MACHINE_LISP too. | |
6256 | Use just $shortlisp, not $SOME_MACHINE_LISP too. | |
6257 | ||
a28d4396 KH |
6258 | 2011-05-18 Kenichi Handa <handa@m17n.org> |
6259 | ||
6260 | * composite.c (CHAR_COMPOSABLE_P): Add more check for efficiency. | |
6261 | (BACKWARD_CHAR): Wrap the arg STOP by parenthesis. | |
6262 | (find_automatic_composition): Mostly rewrite for efficiency. | |
6263 | ||
a2b1fa8e JB |
6264 | 2011-05-18 Juanma Barranquero <lekktu@gmail.com> |
6265 | ||
6266 | * makefile.w32-in: Update dependencies. | |
6267 | ||
8e1f5610 CS |
6268 | 2011-05-18 Christoph Scholtes <cschol2112@googlemail.com> |
6269 | ||
6270 | * menu.c: Include limits.h (fixes the MS-Windows build broken by | |
7d7d0045 | 6271 | 2011-06-18T18:49:19Z!cyd@stupidchicken.com). |
8e1f5610 | 6272 | |
7025ee00 | 6273 | 2011-05-18 Paul Eggert <eggert@cs.ucla.edu> |
cb93f9be | 6274 | |
cdfa6eab PE |
6275 | Fix some integer overflow issues, such as string length overflow. |
6276 | ||
06d6db33 PE |
6277 | * insdel.c (count_size_as_multibyte): Check for string overflow. |
6278 | ||
2b4560a8 PE |
6279 | * character.c (lisp_string_width): Check for string overflow. |
6280 | Use EMACS_INT, not int, for string indexes and lengths; in | |
6281 | particular, 2nd arg is now EMACS_INT, not int. Do not crash if | |
6282 | the resulting string length overflows an EMACS_INT; instead, | |
6283 | report a string overflow if no precision given. When checking for | |
6284 | precision exhaustion, use a check that cannot possibly have | |
6285 | integer overflow. (Bug#8675) | |
6286 | * character.h (lisp_string_width): Adjust to new signature. | |
6287 | ||
cb93f9be PE |
6288 | * alloc.c (string_overflow): New function. |
6289 | (Fmake_string): Use it. This doesn't change behavior, but saves | |
6290 | a few bytes and will simplify future changes. | |
6291 | * character.c (string_escape_byte8): Likewise. | |
6292 | * lisp.h (string_overflow): New decl. | |
6293 | ||
1a1f3366 PE |
6294 | Fixups, following up to the user-interface timestamp change. |
6295 | * nsterm.m (last_mouse_movement_time, ns_mouse_position): Use Time | |
6296 | for UI timestamps, instead of unsigned long. | |
9fbd6841 PE |
6297 | * msdos.c (mouse_get_pos): Likewise. |
6298 | * w32inevt.c (movement_time, w32_console_mouse_position): Likewise. | |
1a1f3366 PE |
6299 | * w32gui.h (Time): Define by including "systime.h" rather than by |
6300 | declaring it ourselves. (Bug#8664) | |
6301 | ||
d4e3e4d3 PE |
6302 | * dispextern.h (struct image): Don't assume time_t <= unsigned long. |
6303 | * image.c (clear_image_cache): Likewise. | |
6304 | ||
f6a24d19 PE |
6305 | * term.c (term_mouse_position): Don't assume time_t wraparound. |
6306 | ||
08dc5ae6 PE |
6307 | Be more systematic about user-interface timestamps. |
6308 | Before, the code sometimes used 'Time', sometimes 'unsigned long', | |
620c53a6 SM |
6309 | and sometimes 'EMACS_UINT', to represent these timestamps. |
6310 | This change causes it to use 'Time' uniformly, as that's what X uses. | |
08dc5ae6 PE |
6311 | This makes the code easier to follow, and makes it easier to catch |
6312 | integer overflow bugs such as Bug#8664. | |
6313 | * frame.c (Fmouse_position, Fmouse_pixel_position): | |
6314 | Use Time, not unsigned long, for user-interface timestamps. | |
6315 | * keyboard.c (last_event_timestamp, kbd_buffer_get_event): Likewise. | |
6316 | (button_down_time, make_lispy_position, make_lispy_movement): Likewise. | |
6317 | * keyboard.h (last_event_timestamp): Likewise. | |
6318 | * menu.c (Fx_popup_menu) [!HAVE_X_WINDOWS]: Likewise. | |
6319 | * menu.h (xmenu_show): Likewise. | |
6320 | * term.c (term_mouse_position): Likewise. | |
6321 | * termhooks.h (struct input_event.timestamp): Likewise. | |
6322 | (struct terminal.mouse_position_hook): Likewise. | |
6323 | * xmenu.c (create_and_show_popup_menu, xmenu_show): Likewise. | |
6324 | * xterm.c (XTmouse_position, x_scroll_bar_report_motion): Likewise. | |
6325 | * systime.h (Time): New decl. Pull it in from <X11/X.h> if | |
6326 | HAVE_X_WINDOWS, otherwise define it as unsigned long, which is | |
6327 | what it was before. | |
6328 | * menu.h, termhooks.h: Include "systime.h", for Time. | |
6329 | ||
8e55734a PE |
6330 | * keyboard.c (make_lispy_event): Fix problem in integer overflow. |
6331 | Don't assume that the difference between two unsigned long values | |
6332 | can fit into an integer. At this point, we know button_down_time | |
6333 | <= event->timestamp, so the difference must be nonnegative, so | |
6334 | there's no need to cast the result if double-click-time is | |
6335 | nonnegative, as it should be; check that it's nonnegative, just in | |
6336 | case. This bug is triggered when events are more than 2**31 ms | |
86db42d2 | 6337 | apart (about 25 days). (Bug#8664) |
8e55734a | 6338 | |
841f1b75 | 6339 | * xselect.c (last_event_timestamp): Remove duplicate decl. |
6434756c | 6340 | (x_own_selection): Remove needless cast to unsigned long. |
841f1b75 | 6341 | |
3e26f69c PE |
6342 | * xmenu.c (set_frame_menubar): Use int, not EMACS_UINT, for indexes |
6343 | that always fit in int. Use a sentinel instead of a counter, to | |
6344 | avoid a temp and to allay GCC's concerns about possible int overflow. | |
d230cb74 PE |
6345 | * frame.h (struct frame): Use int for menu_bar_items_used |
6346 | instead of EMACS_INT, since it always fits in int. | |
3e26f69c | 6347 | |
5cc152c0 PE |
6348 | * menu.c (grow_menu_items): Check for int overflow. |
6349 | ||
d89eb65e PE |
6350 | * xmenu.c (set_frame_menubar): Don't mishandle vectors with no nils. |
6351 | ||
5235bd3e PE |
6352 | * xterm.c: Use EMACS_INT for Emacs modifiers, and int for X modifiers. |
6353 | Before, the code was not consistent. These values cannot exceed | |
6354 | 2**31 - 1 so there's no need to make them unsigned. | |
6355 | (x_x_to_emacs_modifiers): Accept int and return EMACS_INT. | |
6356 | (x_emacs_to_x_modifiers): Accept EMACS_INT and return int. | |
6357 | (x_x_to_emacs_modifiers, x_emacs_to_x_modifiers): Reject non-integers | |
6358 | as modifiers. | |
6359 | * xterm.h (x_x_to_emacs_modifiers): Adjust to signature change. | |
6360 | ||
bc827e23 PE |
6361 | * lisp.h (XINT) [USE_LISP_UNION_TYPE]: Cast to EMACS_INT. |
6362 | (XUINT) [USE_LISP_UNION_TYPE]: Cast to EMACS_UINT. | |
6363 | Otherwise, GCC 4.6.0 warns about printf (pI, XINT (...)), | |
6364 | presumably because the widths might not match. | |
6365 | ||
78eb494e PE |
6366 | * window.c (size_window): Avoid needless test at loop start. |
6367 | ||
04f2d78b CB |
6368 | 2011-05-18 Courtney Bane <emacs-bugs-7626@cbane.org> (tiny change) |
6369 | ||
6370 | * term.c (Fresume_tty): Restore hooks before reinitializing (bug#8687). | |
6371 | ||
d2fc7e3d | 6372 | 2011-05-12 Drew Adams <drew.adams@oracle.com> |
e531bdff DA |
6373 | |
6374 | * textprop.c (Fprevious_single_char_property_change): Doc fix (bug#8655). | |
6375 | ||
d2fc7e3d | 6376 | 2011-05-12 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
7db47798 YM |
6377 | |
6378 | * w32term.c (w32_draw_fringe_bitmap): Rename local vars `left' and | |
6379 | `width' to `bar_area_x' and `bar_area_width', respectively. | |
6380 | (x_scroll_run): Take account of fringe background extension. | |
6381 | ||
04f2d78b CB |
6382 | * xterm.c (x_draw_fringe_bitmap) [USE_TOOLKIT_SCROLL_BARS]: |
6383 | Rename local vars `left' and `width' to `bar_area_x' and | |
7db47798 YM |
6384 | `bar_area_width', respectively. |
6385 | (x_scroll_run) [USE_TOOLKIT_SCROLL_BARS]: Take account of fringe | |
6386 | background extension. | |
6387 | ||
79b70037 GM |
6388 | 2011-05-10 Jim Meyering <meyering@redhat.com> |
6389 | ||
6390 | * xdisp.c (x_intersect_rectangles): Fix typo "the the -> the". | |
6391 | ||
2f142cc5 JB |
6392 | 2011-05-10 Juanma Barranquero <lekktu@gmail.com> |
6393 | ||
6394 | * image.c (Finit_image_library): Return t for built-in image types, | |
6395 | like pbm and xbm. (Bug#8640) | |
6396 | ||
57679c86 AS |
6397 | 2011-05-09 Andreas Schwab <schwab@linux-m68k.org> |
6398 | ||
6399 | * w32menu.c (set_frame_menubar): Fix submenu allocation. | |
6400 | ||
888c9e86 EZ |
6401 | 2011-05-07 Eli Zaretskii <eliz@gnu.org> |
6402 | ||
b0512a1d EZ |
6403 | * w32console.c (Fset_screen_color): Doc fix. |
6404 | (Fget_screen_color): New function. | |
6405 | (syms_of_ntterm): Defsubr it. | |
6406 | ||
7285dc67 EZ |
6407 | * callproc.c (call_process_cleanup) [MSDOS]: Don't close and |
6408 | unlink the temporary file if Fcall_process didn't create it in the | |
6409 | first place. | |
6410 | (Fcall_process) [MSDOS]: Don't create tempfile if stdout of the | |
6411 | child process will be redirected to a file specified with `:file'. | |
888c9e86 EZ |
6412 | Don't try to re-open tempfile in that case, and set fd[0] to -1 as |
6413 | cue to call_process_cleanup not to close that handle. | |
6414 | ||
4d3fcc8e BK |
6415 | 2011-05-07 Ben Key <bkey76@gmail.com> |
6416 | ||
6417 | * makefile.w32-in: The bootstrap-temacs rule now makes use of | |
6418 | one of two shell specific rules, either bootstrap-temacs-CMD or | |
6419 | bootstrap-temacs-SH. The bootstrap-temacs-SH rule is identical | |
6420 | to the previous implementation of the bootstrap-temacs rule. | |
6421 | The bootstrap-temacs-CMD rule is similar to the previous | |
6422 | implementation of the bootstrap-temacs rule except that it | |
6423 | makes use of the ESC_CFLAGS variable instead of the CFLAGS | |
6424 | variable. | |
6425 | ||
6426 | These changes, along with some changes to nt/configure.bat, | |
6427 | nt/gmake.defs, and nt/nmake.defs, are required to extend my | |
6428 | earlier fix to add support for --cflags and --ldflags options | |
6429 | that include quotes so that it works whether make uses cmd or | |
6430 | sh as the shell. | |
6431 | ||
b4289b64 MA |
6432 | 2011-05-06 Michael Albinus <michael.albinus@gmx.de> |
6433 | ||
6434 | * dbusbind.c (QCdbus_type_unix_fd): Declare static. | |
6435 | (xd_remove_watch): Don't check QCdbus_type_unix_fd for SYMBOLP, it | |
6436 | is a constant. | |
6437 | (Fdbus_init_bus, xd_read_queued_messages): Bus can be a symbol or | |
6438 | a string. Handle both cases. | |
6439 | (Fdbus_call_method_asynchronously, Fdbus_register_signal) | |
6440 | (Fdbus_register_method): Use Qinvalid_function. | |
6441 | ||
af4c0e28 JB |
6442 | 2011-05-06 Juanma Barranquero <lekktu@gmail.com> |
6443 | ||
6444 | * makefile.w32-in: Update dependencies. | |
6445 | (LISP_H): Add inttypes.h and stdin.h. | |
6446 | (PROCESS_H): Add unistd.h. | |
6447 | ||
c51453d9 EZ |
6448 | 2011-05-06 Eli Zaretskii <eliz@gnu.org> |
6449 | ||
6450 | * lread.c: Include limits.h (fixes the MS-Windows build broken by | |
6451 | 2011-05-06T07:13:19Z!eggert@cs.ucla.edu). | |
6452 | ||
8ff0ac3c | 6453 | 2011-05-06 Paul Eggert <eggert@cs.ucla.edu> |
c032b5f8 | 6454 | |
4c4b566b PE |
6455 | * image.c (Finit_image_library) [!HAVE_NTGUI]: Omit unused local. |
6456 | ||
aab2b9b5 PE |
6457 | * term.c (vfatal): Remove stray call to va_end. |
6458 | It's not needed and the C Standard doesn't allow it here anyway. | |
6459 | ||
c378da0b PE |
6460 | Use C99's va_copy to avoid undefined behavior on x86-64 GNU/Linux. |
6461 | * eval.c (verror): doprnt a copy of ap, not the original. (Bug#8545) | |
6462 | ||
288b08c7 PE |
6463 | * eval.c (verror): OK to create a string of up to MOST_POSITIVE_FIXNUM |
6464 | bytes. | |
6465 | ||
e3601888 PE |
6466 | * term.c: Don't include <stdarg.h>, as <lisp.h> does that. |
6467 | ||
db6c0e74 PE |
6468 | * callproc.c (Fcall_process): Use 'volatile' to avoid vfork clobbering. |
6469 | ||
dd5963ea PE |
6470 | * process.c (Fformat_network_address): Fix typo: args2 -> *args2. |
6471 | ||
88c9450f PE |
6472 | * xmenu.c (set_frame_menubar): Fix typo: int * -> int (3 times). |
6473 | ||
2f9442b8 PE |
6474 | * coding.c (detect_coding_charset): Fix typo: * 2 -> *4 (Bug#8601). |
6475 | ||
c032b5f8 PE |
6476 | * charset.h (struct charset.code_space): Now has 15 elements, not 16. |
6477 | * charset.c (Fdefine_charset_internal): Don't initialize | |
6478 | charset.code_space[15]. The value was garbage, on hosts with | |
2d38271b | 6479 | 32-bit int (Bug#8600). |
a108c10b PE |
6480 | |
6481 | * lread.c (read_integer): Be more consistent with string-to-number. | |
6482 | Use string_to_number to do the actual conversion; this avoids | |
6483 | rounding errors and fixes some other screwups. Without this fix, | |
6484 | for example, #x1fffffffffffffff was misread as -2305843009213693952. | |
6485 | (digit_to_number): Move earlier, for benefit of read_integer. | |
6486 | Return -1 if the digit is out of range for the base, -2 if it is | |
48e400f0 | 6487 | not a digit in any supported base. (Bug#8602) |
a108c10b | 6488 | |
ad5f9eea PE |
6489 | * doprnt.c (doprnt): Support arbitrary pI values, such as "I64". |
6490 | ||
aec1708a PE |
6491 | * dispnew.c (scrolling_window): Return 1 if we scrolled, |
6492 | to match comment at start of function. This also removes a | |
6493 | GCC warning about overflow in a 32+64-bit port. | |
6494 | ||
47be4ab5 PE |
6495 | * lisp.h (EMACS_INT, EMACS_UINT, BITS_PER_EMACS_INT, pI): Simplify. |
6496 | ||
371cac43 PE |
6497 | * dbusbind.c: Do not use XPNTR on a value that may be an integer. |
6498 | Reported by Stefan Monnier in | |
6499 | <http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00919.html>. | |
04f2d78b CB |
6500 | (xd_remove_watch, Fdbus_init_bus, xd_read_queued_messages): |
6501 | Use SYMBOLP-guarded XSYMBOL, not XPNTR. | |
371cac43 | 6502 | |
d01a7826 PE |
6503 | * lisp.h (EMACS_INTPTR): Remove. All uses changed to intptr_t. |
6504 | (EMACS_UINTPTR): Likewise, with uintptr_t. | |
6505 | ||
7fd47d5c PE |
6506 | * lisp.h: Prefer 64-bit EMACS_INT if available. |
6507 | (EMACS_INT, EMACS_UINT, BITS_PER_EMACS_INT, pI): Define to 64-bit | |
6508 | on 32-bit hosts that have 64-bit int, so that they can access | |
6509 | large files. | |
122b0c86 PE |
6510 | However, temporarily disable this change unless the temporary |
6511 | symbol WIDE_EMACS_INT is defined. | |
7fd47d5c | 6512 | |
8727937b PE |
6513 | * lread.c, process.c: Do not include <inttypes.h>; lisp.h does it now. |
6514 | ||
8ac068ac PE |
6515 | Prefer intptr_t/uintptr_t for integers the same widths as pointers. |
6516 | This removes an assumption that EMACS_INT and long are the same | |
6517 | width as pointers. The assumption is true for Emacs porting targets | |
6518 | now, but we want to make other targets possible. | |
6519 | * lisp.h: Include <inttypes.h>, for INTPTR_MAX, UINTPTR_MAX. | |
6520 | (EMACS_INTPTR, EMACS_UINTPTR): New macros. | |
6521 | In the rest of the code, change types of integers that hold casted | |
6522 | pointers to EMACS_INTPTR and EMACS_UINTPTR, systematically | |
6523 | replacing EMACS_INT, long, EMACS_UINT, and unsigned long. | |
6524 | (XTYPE): Don't cast arg to EMACS_UINT; normally is not needed. | |
6525 | (XSET): Cast type of XTYPE arg to EMACS_INTPTR; it is needed here. | |
6526 | No need to cast type when ORing. | |
6527 | (XPNTR): Return a value of type EMACS_INTPTR or EMACS_UINTPTR. | |
6528 | * alloc.c (lisp_align_malloc): Remove a no-longer-needed cast. | |
6529 | * doc.c (store_function_docstring): Use EMACS_INTPTR, so as not to | |
6530 | assume EMACS_INT is the same width as char *. | |
6531 | * gtkutil.c (xg_gtk_scroll_destroy, xg_tool_bar_button_cb): | |
6532 | (xg_tool_bar_callback, xg_tool_bar_help_callback, xg_make_tool_item): | |
6533 | Remove no-longer-needed casts. | |
6534 | (xg_create_scroll_bar, xg_tool_bar_button_cb, xg_tool_bar_callback): | |
6535 | (xg_tool_bar_help_callback, xg_make_tool_item): | |
6536 | Use EMACS_INTPTR to hold an integer | |
6537 | that will be cast to void *; this can avoid a GCC warning | |
6538 | if EMACS_INT is not the same width as void *. | |
6539 | * menu.c (find_and_call_menu_selection): Remove no-longer-needed cast. | |
6540 | * xdisp.c (display_echo_area_1, resize_mini_window_1): | |
6541 | (current_message_1, set_message_1): | |
6542 | Use a local to convert to proper width without a cast. | |
6543 | * xmenu.c (dialog_selection_callback): Likewise. | |
6544 | ||
ede49d71 PE |
6545 | * sysdep.c (get_random): Don't assume EMACS_INT is no wider than long. |
6546 | Also, don't assume VALBITS / RAND_BITS is less than 5, | |
6547 | and don't rely on undefined behavior when shifting a 1 left into | |
6548 | the sign bit. | |
6549 | * lisp.h (get_random): Change signature to match. | |
6550 | ||
2f30ecd0 PE |
6551 | * lread.c (hash_string): Use size_t, not int, for hash computation. |
6552 | Normally we prefer signed values; but hashing is special, because | |
6553 | it's better to use unsigned division on hash table sizes so that | |
6554 | the remainder is nonnegative. Also, size_t is the natural width | |
6555 | for hashing into memory. The previous code used 'int', which doesn't | |
6556 | retain enough info to hash well into very large tables. | |
6557 | (oblookup, oblookup_last_bucket_number, Funintern): Likewise. | |
6558 | ||
2a866e7b PE |
6559 | * dbusbind.c: Don't possibly lose pointer info when converting. |
6560 | (xd_remove_watch, Fdbus_init_bus, xd_read_queued_messages): | |
6561 | Use XPNTR rather than XHASH, so that the high-order bits of | |
6562 | the pointer aren't lost when converting through void *. | |
6563 | ||
51639eac PE |
6564 | * eval.c (Fautoload): Don't double-shift a pointer. |
6565 | ||
92394119 PE |
6566 | * fns.c (Frandom): Let EMACS_UINT be wider than unsigned long. |
6567 | ||
dbdb9a7c JB |
6568 | 2011-05-06 Juanma Barranquero <lekktu@gmail.com> |
6569 | ||
6570 | * gnutls.c (DEF_GNUTLS_FN): | |
6571 | * image.c (DEF_IMGLIB_FN): Make function pointers static. | |
6572 | ||
db7a0b4f AS |
6573 | 2011-05-05 Andreas Schwab <schwab@linux-m68k.org> |
6574 | ||
6575 | * lread.c (lisp_file_lexically_bound_p): Stop scanning at end | |
6576 | marker. (Bug#8610) | |
6577 | ||
cd394be1 | 6578 | 2011-05-05 Eli Zaretskii <eliz@gnu.org> |
fab624aa EZ |
6579 | |
6580 | * w32heap.c (allocate_heap) [USE_LISP_UNION_TYPE || USE_LSB_TAG]: | |
6581 | New version that can reserve upto 2GB of heap space. | |
6582 | ||
f7ff1b0f | 6583 | 2011-05-05 Chong Yidong <cyd@stupidchicken.com> |
45cb8994 CY |
6584 | |
6585 | * nsfns.m (Fns_read_file_name): Doc fix (Bug#8534). | |
6586 | ||
639c109b TZ |
6587 | 2011-05-05 Teodor Zlatanov <tzz@lifelogs.com> |
6588 | ||
6589 | * gnutls.c (fn_gnutls_certificate_set_x509_key_file): Add alias to | |
6590 | `gnutls_certificate_set_x509_key_file'. | |
6591 | ||
d2127135 JB |
6592 | 2011-05-05 Juanma Barranquero <lekktu@gmail.com> |
6593 | ||
6594 | * makefile.w32-in ($(BLD)/image.$(O), $(BLD)/process.$(O)): | |
6595 | Update dependencies. | |
6596 | ||
e968f4f3 JB |
6597 | 2011-05-04 Juanma Barranquero <lekktu@gmail.com> |
6598 | ||
6599 | * gnutls.h (emacs_gnutls_write, emacs_gnutls_read): | |
6600 | * gnutls.c (emacs_gnutls_write, emacs_gnutls_read): | |
6601 | Remove unused parameter `fildes'. | |
6602 | * process.c (read_process_output, send_process): Don't pass it. | |
6603 | ||
84d358f0 JB |
6604 | 2011-05-04 Juanma Barranquero <lekktu@gmail.com> |
6605 | ||
6606 | Fix previous change: the library cache is defined in w32.c. | |
6607 | * image.c (CACHE_IMAGE_TYPE) [!HAVE_NTGUI]: Define to noop. | |
6608 | (Finit_image_library): Wrap Vlibrary_cache on "#ifdef HAVE_NTGUI". | |
6609 | ||
0898ca10 JB |
6610 | 2011-05-04 Juanma Barranquero <lekktu@gmail.com> |
6611 | ||
6612 | Implement dynamic loading of GnuTLS on Windows. | |
6613 | ||
6614 | * gnutls.h (GNUTLS_EMACS_ERROR_NOT_LOADED): New macro. | |
6615 | (emacs_gnutls_write, emacs_gnutls_read): Mark as extern. | |
6616 | (emacs_gnutls_record_check_pending, emacs_gnutls_transport_set_errno): | |
6617 | Declare. | |
6618 | ||
6619 | * gnutls.c (Qgnutls_dll): Define. | |
6620 | (DEF_GNUTLS_FN, LOAD_GNUTLS_FN): New macros. | |
6621 | (gnutls_*): Declare function pointers. | |
6622 | (init_gnutls_functions): New function to initialize function pointers. | |
6623 | (emacs_gnutls_handshake, Fgnutls_error_string, Fgnutls_deinit) | |
6624 | (emacs_gnutls_global_init, Fgnutls_bye): Use function pointers. | |
6625 | (emacs_gnutls_record_check_pending, emacs_gnutls_transport_set_errno): | |
6626 | Wrappers for gnutls_record_check_pending and gnutls_transport_set_errno. | |
6627 | (emacs_gnutls_write, emacs_gnutls_read) | |
6628 | (emacs_gnutls_handle_error, Fgnutls_error_fatalp) | |
6629 | (Fgnutls_available_p): New function. | |
6630 | (Fgnutls_boot): Call Fgnutls_available_p. Use function pointers. | |
6631 | (syms_of_gnutls) <Qgnutls_dll>: Initialize and staticpro it. | |
6632 | (syms_of_gnutls) <Sgnutls_available_p>: defsubr it. | |
6633 | ||
6634 | * image.c: Include w32.h. | |
6635 | (Vimage_type_cache): Delete. | |
6636 | (syms_of_image) <Vimage_type_cache>: Don't initialize and staticpro it. | |
6637 | (CACHE_IMAGE_TYPE, Finit_image_library): Use Vlibrary_cache instead. | |
6638 | (w32_delayed_load): Move to w32.c. | |
6639 | ||
6640 | * w32.h (VlibraryCache, QCloaded_from, w32_delayed_load): Declare. | |
6641 | ||
6642 | * w32.c (QCloaded_from, Vlibrary_cache): Define. | |
6643 | (w32_delayed_load): Move from image.c. When loading a library, record | |
6644 | its filename in the :loaded-from property of the library id. | |
6645 | (globals_of_w32) <QCloaded_from, Vlibrary_cache>: | |
6646 | Initialize and staticpro them. | |
6647 | (emacs_gnutls_pull, emacs_gnutls_push): Call emacs_gnutls_* functions. | |
6648 | ||
6649 | * process.c: Include lisp.h before w32.h, not after. | |
6650 | (wait_reading_process_output): Call emacs_gnutls_record_check_pending | |
6651 | instead of gnutls_record_check_pending. | |
6652 | ||
6653 | * callproc.c, emacs.c: Include lisp.h before w32.h, not after. | |
6654 | ||
ff4de4aa TZ |
6655 | 2011-05-04 Teodor Zlatanov <tzz@lifelogs.com> |
6656 | ||
6657 | * gnutls.c (Fgnutls_boot): Support :keylist and :crlfiles options | |
6658 | instead of :keyfiles. Give GnuTLS the keylist and the CRL lists | |
6659 | as passed in. | |
6660 | ||
abe95abb JD |
6661 | 2011-05-03 Jan Djärv <jan.h.d@swipnet.se> |
6662 | ||
6663 | * xterm.c (x_set_frame_alpha): Do not set property on anything | |
6664 | else than FRAME_X_OUTER_WINDOW (Bug#8608). | |
6665 | ||
e16e55d4 JB |
6666 | 2011-05-02 Juanma Barranquero <lekktu@gmail.com> |
6667 | ||
6668 | * sysdep.c (get_tty_size) [WINDOWSNT]: Implement. (Bug#8596) | |
6669 | ||
bafcf6a5 JB |
6670 | 2011-05-02 Juanma Barranquero <lekktu@gmail.com> |
6671 | ||
6672 | * gnutls.c (Qgnutls_log_level, Qgnutls_code, Qgnutls_anon) | |
6673 | (Qgnutls_x509pki, Qgnutls_e_interrupted, Qgnutls_e_again) | |
6674 | (Qgnutls_e_invalid_session, Qgnutls_e_not_ready_for_handshake) | |
6675 | (gnutls_global_initialized, Qgnutls_bootprop_priority) | |
6676 | (Qgnutls_bootprop_trustfiles, Qgnutls_bootprop_keyfiles) | |
6677 | (Qgnutls_bootprop_callbacks, Qgnutls_bootprop_loglevel) | |
6678 | (Qgnutls_bootprop_hostname, Qgnutls_bootprop_verify_flags) | |
6679 | (Qgnutls_bootprop_verify_error, Qgnutls_bootprop_verify_hostname_error) | |
6680 | (Qgnutls_bootprop_callbacks_verify): Make static. | |
6681 | ||
e7a6747f AS |
6682 | 2011-05-01 Andreas Schwab <schwab@linux-m68k.org> |
6683 | ||
19ed11ba AS |
6684 | * callproc.c: Indentation fixup. |
6685 | ||
e7a6747f | 6686 | * sysdep.c (wait_for_termination_1): Make static. |
04f2d78b CB |
6687 | (wait_for_termination, interruptible_wait_for_termination): |
6688 | Move after wait_for_termination_1. | |
e7a6747f | 6689 | |
1ef14cb4 LMI |
6690 | 2011-05-01 Lars Magne Ingebrigtsen <larsi@gnus.org> |
6691 | ||
6692 | * sysdep.c (interruptible_wait_for_termination): New function | |
6693 | which is like wait_for_termination, but allows keyboard | |
6694 | interruptions. | |
6695 | ||
6696 | * callproc.c (Fcall_process): Add (:file "file") as an option for | |
6697 | the STDOUT buffer. | |
6698 | (Fcall_process_region): Ditto. | |
6699 | ||
330d880c EZ |
6700 | 2011-04-30 Eli Zaretskii <eliz@gnu.org> |
6701 | ||
8db90b73 EZ |
6702 | * dosfns.c (Fint86, Fdos_memget, Fdos_memput): Use `ASIZE (FOO)' |
6703 | rather than `XVECTOR (FOO)->size'. | |
6704 | ||
330d880c EZ |
6705 | * process.c: Remove HAVE_INTTYPES_H condition from inclusion of |
6706 | inttypes.h, as a gnulib replacement is used if it not available in | |
6707 | system headers. | |
6708 | ||
15cbd324 EZ |
6709 | 2011-04-21 Eli Zaretskii <eliz@gnu.org> |
6710 | ||
6711 | Lift the MOST_POSITIVE_FIXNUM/4 limitation on visited files. | |
6712 | * fileio.c (Finsert_file_contents): Don't limit file size to 1/4 | |
6713 | of MOST_POSITIVE_FIXNUM. (Bug#8528) | |
6714 | ||
6715 | * coding.c (coding_alloc_by_realloc): Error out if destination | |
6716 | will grow beyond MOST_POSITIVE_FIXNUM. | |
6717 | (decode_coding_emacs_mule): Abort if there isn't enough place in | |
6718 | charbuf for the composition carryover bytes. Reserve an extra | |
6719 | space for up to 2 characters produced in a loop. | |
6720 | (decode_coding_iso_2022): Abort if there isn't enough place in | |
6721 | charbuf for the composition carryover bytes. | |
6722 | ||
6723 | 2011-04-21 Eli Zaretskii <eliz@gnu.org> | |
afda1437 | 6724 | |
ae940cca EZ |
6725 | * doprnt.c (doprnt) [!HAVE_LONG_LONG_INT]: Error out instead of |
6726 | aborting when %lld or %lll format is passed. | |
6727 | [!HAVE_UNSIGNED_LONG_LONG_INT]: Error out instead of aborting when | |
6728 | %llo or %llx format is passed. (Bug#8545) | |
6729 | ||
03ab8921 EZ |
6730 | * window.c (window_scroll_line_based): Use a marker instead of |
6731 | simple variables to record original value of point. (Bug#7952) | |
6732 | ||
afda1437 EZ |
6733 | * doprnt.c (doprnt): Fix the case where a multibyte sequence |
6734 | produced by %s or %c overflows available buffer space. (Bug#8545) | |
6735 | ||
f76dee0c PE |
6736 | 2011-04-28 Paul Eggert <eggert@cs.ucla.edu> |
6737 | ||
6738 | * doprnt.c (doprnt): Omit useless test; int overflow check (Bug#8545). | |
283cdbef | 6739 | (SIZE_MAX): Move defn after all includes, as they might #define it. |
f76dee0c | 6740 | |
fdc5744d JB |
6741 | 2011-04-28 Juanma Barranquero <lekktu@gmail.com> |
6742 | ||
6743 | * w32.c (init_environment): Warn about defaulting HOME to C:\. | |
6744 | ||
638f053a JB |
6745 | 2011-04-28 Juanma Barranquero <lekktu@gmail.com> |
6746 | ||
6747 | * keyboard.c (Qdelayed_warnings_hook): Define. | |
6748 | (command_loop_1): Run `delayed-warnings-hook' | |
6749 | if Vdelayed_warnings_list is non-nil. | |
6750 | (syms_of_keyboard) <delayed-warnings-hook>: DEFSYM it. | |
6751 | (syms_of_keyboard) <delayed-warnings-list>: DEFVAR_LISP it. | |
6752 | ||
d178f871 EZ |
6753 | 2011-04-28 Eli Zaretskii <eliz@gnu.org> |
6754 | ||
6755 | * doprnt.c (doprnt): Don't return value smaller than the buffer | |
6756 | size if the message was truncated. (Bug#8545). | |
6757 | ||
b124fd93 JB |
6758 | 2011-04-28 Juanma Barranquero <lekktu@gmail.com> |
6759 | ||
6760 | * w32fns.c (Fx_change_window_property, Fx_delete_window_property) | |
6761 | (Fx_window_property): #if-0 the whole functions, not just the bodies. | |
6762 | ||
e810457d PE |
6763 | 2011-04-27 Paul Eggert <eggert@cs.ucla.edu> |
6764 | ||
6765 | * doprnt.c (doprnt): Support "ll" length modifier, for long long. | |
6766 | ||
ea51cceb JB |
6767 | 2011-04-27 Juanma Barranquero <lekktu@gmail.com> |
6768 | ||
6769 | * makefile.w32-in: Update dependencies. | |
6770 | ||
94dcfacf EZ |
6771 | 2011-04-27 Eli Zaretskii <eliz@gnu.org> |
6772 | ||
6773 | Improve `doprnt' and its usage. (Bug#8545) | |
6774 | * doprnt.c (doprnt): Make sure `format' is never accessed beyond | |
6775 | `format_end'. Remove support for %l as a conversion specifier. | |
6776 | Don't use xrealloc. Improve diagnostics when the %l size modifier | |
6777 | is used. Update the commentary. | |
6778 | ||
6779 | * eval.c (verror): Simplify calculation of size_t. | |
6780 | ||
6781 | * coding.c (Ffind_operation_coding_system): Fix diagnostic error | |
6782 | messages. | |
6783 | ||
f61f41d7 PE |
6784 | 2011-04-27 Yoshiaki Kasahara <kasahara@nc.kyushu-u.ac.jp> (tiny change) |
6785 | ||
6786 | * buffer.c (init_buffer) [USE_MMAP_FOR_BUFFERS]: Adjust to aliasing | |
6787 | change. | |
6788 | ||
96fb4434 PE |
6789 | 2011-04-27 Paul Eggert <eggert@cs.ucla.edu> |
6790 | ||
6791 | * nsmenu.m: Replace all uses of XVECTOR with ASIZE and AREF. | |
6792 | This makes this file independent of the recent pseudovector change. | |
6793 | ||
671875da | 6794 | 2011-04-26 Paul Eggert <eggert@cs.ucla.edu> |
eab3844f | 6795 | |
69e9b5a3 PE |
6796 | * keyboard.c (handle_user_signal): Fix pointer signedness problem. |
6797 | ||
b5f869a7 | 6798 | * gnutls.c (emacs_gnutls_handle_error): Remove unused local. |
7754e151 | 6799 | (Fgnutls_boot): gnutls_certificate_verify_peers2 wants unsigned *. |
8d4c3955 | 6800 | Remove unused local. |
c8926152 | 6801 | (emacs_gnutls_write): Don't use uninitialized rtnval if nbyte <= 0. |
080e5a8d | 6802 | |
841a1577 | 6803 | * lisp.h: Fix a problem with aliasing and vector headers. (Bug#8546) |
04f2d78b CB |
6804 | GCC 4.6.0 optimizes based on type-based alias analysis. |
6805 | For example, if b is of type struct buffer * and v of type struct | |
eab3844f PE |
6806 | Lisp_Vector *, then gcc -O2 was incorrectly assuming that &b->size |
6807 | != &v->size, and therefore "v->size = 1; b->size = 2; return | |
6808 | v->size;" must therefore return 1. This assumption is incorrect | |
6809 | for Emacs, since it type-puns struct Lisp_Vector * with many other | |
6810 | types. To fix this problem, this patch adds a new type struct | |
f904488f | 6811 | vectorlike_header that documents the constraints on layout of vectors |
eab3844f PE |
6812 | and pseudovectors, and helps optimizing compilers not get fooled |
6813 | by Emacs's type punning. It also adds the macros XSETTYPED_PVECTYPE | |
6814 | XSETTYPED_PSEUDOVECTOR, TYPED_PSEUDOVECTORP, for similar reasons. | |
f904488f PE |
6815 | * lisp.h (XSETTYPED_PVECTYPE): New macro, specifying the name of |
6816 | the size member. | |
eab3844f PE |
6817 | (XSETPVECTYPE): Rewrite in terms of new macro. |
6818 | (XSETPVECTYPESIZE): New macro, specifying both type and size. | |
6819 | This is a bit clearer, and further avoids the possibility of | |
6820 | undesirable aliasing. | |
6821 | (XSETTYPED_PSEUDOVECTOR): New macro, specifying the size. | |
f904488f | 6822 | (XSETPSEUDOVECTOR): Rewrite in terms of XSETTYPED_PSEUDOVECTOR. |
eab3844f PE |
6823 | (XSETSUBR): Rewrite in terms of XSETTYPED_PSEUDOVECTOR and XSIZE, |
6824 | since Lisp_Subr is a special case (no "next" field). | |
04f2d78b CB |
6825 | (ASIZE): Now uses header.size rather than size. |
6826 | All previous uses of XVECTOR (foo)->size replaced to use this macro, | |
f904488f PE |
6827 | to avoid the hassle of writing XVECTOR (foo)->header.size. |
6828 | (struct vectorlike_header): New type. | |
eab3844f PE |
6829 | (TYPED_PSEUDOVECTORP): New macro, also specifying the C type of the |
6830 | object, to help avoid aliasing. | |
6831 | (PSEUDOVECTORP): Rewrite in terms of TYPED_PSEUDOVECTORP. | |
6832 | (SUBRP): Likewise, since Lisp_Subr is a special case. | |
6833 | * lisp.h (struct Lisp_Vector, struct Lisp_Char_Table): | |
6834 | (struct Lisp_Sub_Char_Table, struct Lisp_Bool_Vector): | |
6835 | (struct Lisp_Hash_Table): Combine first two members into a single | |
f904488f | 6836 | struct vectorlike_header member. All uses of "size" and "next" members |
eab3844f PE |
6837 | changed to be "header.size" and "header.next". |
6838 | * buffer.h (struct buffer): Likewise. | |
6839 | * font.h (struct font_spec, struct font_entity, struct font): Likewise. | |
6840 | * frame.h (struct frame): Likewise. | |
6841 | * process.h (struct Lisp_Process): Likewise. | |
6842 | * termhooks.h (struct terminal): Likewise. | |
6843 | * window.c (struct save_window_data, struct saved_window): Likewise. | |
6844 | * window.h (struct window): Likewise. | |
6845 | * alloc.c (allocate_buffer, Fmake_bool_vector, allocate_pseudovector): | |
6846 | Use XSETPVECTYPESIZE, not XSETPVECTYPE, to avoid aliasing problems. | |
6847 | * buffer.c (init_buffer_once): Likewise. | |
6848 | * lread.c (defsubr): Use XSETTYPED_PVECTYPE, since Lisp_Subr is a | |
6849 | special case. | |
6850 | * process.c (Fformat_network_address): Use local var for size, | |
6851 | for brevity. | |
6852 | ||
0df1eac5 PE |
6853 | * bytecode.c (exec_byte_code): Don't use XVECTOR before CHECK_VECTOR. |
6854 | ||
847ab9d1 | 6855 | Make the Lisp reader and string-to-float more consistent (Bug#8525) |
452f4150 PE |
6856 | * data.c (atof): Remove decl; no longer used or needed. |
6857 | (digit_to_number): Move to lread.c. | |
6858 | (Fstring_to_number): Use new string_to_number function, to be | |
6859 | consistent with how the Lisp reader treats infinities and NaNs. | |
6860 | Do not assume that floating-point numbers represent EMACS_INT | |
6861 | without losing information; this is not true on most 64-bit hosts. | |
6862 | Avoid double-rounding errors, by insisting on integers when | |
6863 | parsing non-base-10 numbers, as the documentation specifies. | |
6864 | * lisp.h (string_to_number): New decl, replacing ... | |
6865 | (isfloat_string): Remove. | |
bc0a5c13 | 6866 | * lread.c: Include <inttypes.h>, for uintmax_t and strtoumax. |
d78050d6 | 6867 | (read1): Do not accept +. and -. as integers; this |
452f4150 PE |
6868 | appears to have been a coding error. Similarly, do not accept |
6869 | strings like +-1e0 as floating point numbers. Do not report | |
6870 | overflow for integer overflows unless the base is not 10 which | |
6871 | means we have no simple and reliable way to continue. | |
6872 | Break out the floating-point parsing into a new | |
6873 | function string_to_number, so that Fstring_to_number parses | |
6874 | floating point numbers consistently with the Lisp reader. | |
04f2d78b | 6875 | (digit_to_number): Move here from data.c. Make it static inline. |
452f4150 PE |
6876 | (E_CHAR, EXP_INT): Remove, replacing with ... |
6877 | (E_EXP): New macro, to solve the "1.0e+" problem mentioned below. | |
6878 | (string_to_number): New function, replacing isfloat_string. | |
6879 | This function checks for valid syntax and produces the resulting | |
6880 | Lisp float number too. Rework it so that string-to-number | |
bc0a5c13 | 6881 | no longer mishandles examples like "1.0e+". Use strtoumax, |
d78050d6 PE |
6882 | so that overflow for non-base-10 numbers is reported only when |
6883 | there's no portable and simple way to convert to floating point. | |
452f4150 | 6884 | |
67769ffc PE |
6885 | * textprop.c (set_text_properties_1): Rewrite for clarity, |
6886 | and to avoid GCC warning about integer overflow. | |
6887 | ||
c20db43f PE |
6888 | * intervals.h (struct interval): Use EMACS_INT for members |
6889 | where EMACS_UINT might cause problems. See | |
6890 | <http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00514.html>. | |
6891 | (CHECK_TOTAL_LENGTH): Remove cast to EMACS_INT; no longer needed. | |
6892 | * intervals.c (interval_deletion_adjustment): Now returns EMACS_INT. | |
6893 | All uses changed. | |
37aa2f85 PE |
6894 | (offset_intervals): Tell GCC not to worry about length overflow |
6895 | when negating a negative length. | |
c20db43f | 6896 | |
2538aa2f PE |
6897 | * alloc.c (overrun_check_malloc, overrun_check_realloc): Now static. |
6898 | (overrun_check_free): Likewise. | |
6899 | ||
f2d3008d PE |
6900 | * alloc.c (SDATA_SIZE) [!GC_CHECK_STRING_BYTES]: Avoid runtime check |
6901 | in the common case where SDATA_DATA_OFFSET is a multiple of Emacs | |
6902 | word size. | |
6903 | ||
ec8df744 PE |
6904 | * gnutls.c: Fix problems found by GCC 4.6.0 on Ubuntu 10.10. |
6905 | (gnutls_make_error): Rename local to avoid shadowing. | |
6906 | (gnutls_emacs_global_deinit): ifdef out; not used. | |
6907 | (Fgnutls_boot): Use const for pointer to readonly storage. | |
6908 | Comment out unused local. Fix pointer signedness problems. | |
6909 | ||
640ee02d PE |
6910 | * lread.c (openp): Don't stuff size_t into an 'int'. |
6911 | Use <= on length, not < on length + 1, to avoid GCC 4.6.0 warning | |
6912 | about possible signed overflow. | |
6913 | ||
6048fb2a PE |
6914 | * gtkutil.c: Fix problems found by GCC 4.6.0 on Ubuntu 10.10. |
6915 | (GDK_KEY_g): Don't define if already defined. | |
6916 | (xg_prepare_tooltip): Avoid pointer signedness problem. | |
6917 | (xg_set_toolkit_scroll_bar_thumb): Redo to avoid two casts. | |
6918 | ||
fa3c87e1 PE |
6919 | * process.c (Fnetwork_interface_info): Avoid left-shift undefined |
6920 | behavior with 1 << 31. GCC 4.6.0 warns about this on 32-bit hosts. | |
6921 | ||
2172544b PE |
6922 | * xfns.c (Fx_window_property): Simplify a bit, |
6923 | to make a bit faster and to avoid GCC 4.6.0 warning. | |
6924 | * xselect.c (x_get_window_property, x_handle_dnd_message): Likewise. | |
6925 | ||
9b821a21 PE |
6926 | * fns.c (internal_equal): Don't assume size_t fits in int. |
6927 | ||
3c616cfa PE |
6928 | * alloc.c (compact_small_strings): Tighten assertion a little. |
6929 | ||
c2982e87 PE |
6930 | Replace pEd with more-general pI, and fix some printf arg casts. |
6931 | * lisp.h (pI): New macro, generalizing old pEd macro to other | |
6932 | conversion specifiers. For example, use "...%"pI"d..." rather | |
6933 | than "...%"pEd"...". | |
6934 | (pEd): Remove. All uses replaced with similar uses of pI. | |
61bdb816 | 6935 | * m/amdx86-64.h, m/ia64.h, m/ibms390x.h: Likewise. |
c2982e87 PE |
6936 | * alloc.c (check_pure_size): Don't overflow by converting size to int. |
6937 | * bidi.c (bidi_dump_cached_states): Use pI to avoid cast. | |
6938 | * data.c (Fnumber_to_string): Use pI instead of if-then-else-abort. | |
6939 | * dbusbind.c (xd_append_arg): Use pI to avoid cast. | |
6940 | (Fdbus_method_return_internal, Fdbus_method_error_internal): Likewise. | |
6941 | * font.c (font_unparse_xlfd): Avoid potential buffer overrun on | |
6942 | 64-bit hosts. | |
6943 | (font_unparse_xlfd, font_unparse_fcname): Use pI to avoid casts. | |
6944 | * keyboard.c (record_char, modify_event_symbol): Use pI to avoid casts. | |
6945 | * print.c (safe_debug_print, print_object): Likewise. | |
6946 | (print_object): Don't overflow by converting EMACS_INT or EMACS_UINT | |
6947 | to int. | |
6f04d126 PE |
6948 | Use pI instead of if-then-else-abort. Use %p to avoid casts, |
6949 | avoiding the 0 flag, which is not portable. | |
c2982e87 PE |
6950 | * process.c (Fmake_network_process): Use pI to avoid cast. |
6951 | * region-cache.c (pp_cache): Likewise. | |
6952 | * xdisp.c (decode_mode_spec): Likewise. | |
6953 | * xrdb.c (x_load_resources) [USE_MOTIF]: Use pI to avoid undefined | |
6954 | behavior on 64-bit hosts with printf arg. | |
6f04d126 | 6955 | * xselect.c (x_queue_event): Use %p to avoid casts, avoiding 0 flag. |
c2982e87 PE |
6956 | (x_stop_queuing_selection_requests): Likewise. |
6957 | (x_get_window_property): Don't truncate byte count to an 'int' | |
6958 | when tracing. | |
0b432f21 | 6959 | |
5e073ec7 PE |
6960 | * frame.c (frame_name_fnn_p): Get rid of strtol, which isn't right |
6961 | here, since it parses constructs like leading '-' and spaces, | |
6962 | which are not wanted; and it overflows with large numbers. | |
6963 | Instead, simply match F[0-9]+, which is what is wanted anyway. | |
6964 | ||
36372bf9 PE |
6965 | * alloc.c: Remove unportable assumptions about struct layout. |
6966 | (SDATA_SELECTOR, SDATA_DATA_OFFSET): New macros. | |
6967 | (SDATA_OF_STRING, SDATA_SIZE, allocate_string_data): | |
6968 | (allocate_vectorlike, make_pure_vector): Use the new macros, | |
6969 | plus offsetof, to remove unportable assumptions about struct layout. | |
6970 | These assumptions hold on all porting targets that I know of, but | |
6971 | they are not guaranteed, they're easy to remove, and removing them | |
6972 | makes further changes easier. | |
6973 | ||
0b432f21 PE |
6974 | * alloc.c (BLOCK BYTES): Fix typo by changing "ablock" to "ablocks". |
6975 | This doesn't fix a bug but makes the code clearer. | |
bfd1c781 PE |
6976 | (string_overrun_cookie): Now const. Use initializers that |
6977 | don't formally overflow signed char, to avoid warnings. | |
000098c1 PE |
6978 | (allocate_string_data) [GC_CHECK_STRING_OVERRUN]: Fix typo that |
6979 | can cause Emacs to crash when string overrun checking is enabled. | |
c7bda33c PE |
6980 | (allocate_buffer): Don't assume sizeof (struct buffer) is a |
6981 | multiple of sizeof (EMACS_INT); it need not be, if | |
6982 | alignof(EMACS_INT) < sizeof (EMACS_INT). | |
d0f4e1f5 | 6983 | (check_sblock, check_string_bytes, check_string_free_list): Protoize. |
0b432f21 | 6984 | |
895009e1 JB |
6985 | 2011-04-26 Juanma Barranquero <lekktu@gmail.com> |
6986 | ||
6987 | * keyboard.c (QCrtl): Rename from Qrtl. All uses changed. | |
6988 | ||
6a7a1b0b TZ |
6989 | 2011-04-26 Teodor Zlatanov <tzz@lifelogs.com> |
6990 | ||
6991 | * gnutls.c (emacs_gnutls_handshake): Return an error if we're not | |
b5f869a7 | 6992 | supposed to be handshaking. (Bug#8556) |
6a7a1b0b TZ |
6993 | Reported by Paul Eggert <eggert@cs.ucla.edu>. |
6994 | ||
841a1577 | 6995 | 2011-04-26 Daniel Colascione <dan.colascione@gmail.com> |
0438ce91 DC |
6996 | |
6997 | * lisp.h (Qdebug): List symbol. | |
895009e1 | 6998 | * eval.c (Qdebug): Restore global linkage. |
0438ce91 DC |
6999 | * keyboard.c (debug-on-event): New variable. |
7000 | (handle_user_signal): Break into debugger when debug-on-event | |
7001 | matches the current signal symbol. | |
7002 | ||
f2d3ba6f DN |
7003 | 2011-04-25 Dan Nicolaescu <dann@ics.uci.edu> |
7004 | ||
7005 | * alloc.c (check_sblock, check_string_bytes) | |
7006 | (check_string_free_list): Convert to standard C. | |
7007 | ||
42ce4c63 TZ |
7008 | 2011-04-25 Teodor Zlatanov <tzz@lifelogs.com> |
7009 | ||
7010 | * w32.c (emacs_gnutls_push): Fix typo. | |
7011 | ||
825cd63c EZ |
7012 | 2011-04-25 Eli Zaretskii <eliz@gnu.org> |
7013 | ||
fb11d64d EZ |
7014 | * gnutls.c (emacs_gnutls_handshake): Avoid compiler warnings about |
7015 | "cast to pointer from integer of different size". | |
7016 | ||
825cd63c EZ |
7017 | Improve doprnt and its use in verror. (Bug#8545) |
7018 | * doprnt.c (doprnt): Document the set of format control sequences | |
7019 | supported by the function. Use SAFE_ALLOCA instead of always | |
7020 | using `alloca'. | |
7021 | ||
7022 | * eval.c (verror): Don't limit the buffer size at size_max-1, that | |
7023 | is one byte too soon. Don't use xrealloc; instead xfree and | |
7024 | xmalloc anew. | |
7025 | ||
e061a11b TZ |
7026 | 2011-04-24 Teodor Zlatanov <tzz@lifelogs.com> |
7027 | ||
7028 | * gnutls.h: Add GNUTLS_STAGE_CALLBACKS enum to denote we're in the | |
7029 | callbacks stage. | |
7030 | ||
7031 | * gnutls.c: Renamed global_initialized to | |
7032 | gnutls_global_initialized. Added internals for the | |
7033 | :verify-hostname-error, :verify-error, and :verify-flags | |
7034 | parameters of `gnutls-boot' and documented those parameters in the | |
7035 | docstring. Start callback support. | |
9173deec JB |
7036 | (emacs_gnutls_handshake): Add Woe32 support. Retry handshake |
7037 | unless a fatal error occurred. Call gnutls_alert_send_appropriate | |
7038 | on error. Return error code. | |
e061a11b TZ |
7039 | (emacs_gnutls_write): Call emacs_gnutls_handle_error. |
7040 | (emacs_gnutls_read): Likewise. | |
7041 | (Fgnutls_boot): Return handshake error code. | |
7042 | (emacs_gnutls_handle_error): New function. | |
7043 | (wsaerror_to_errno): Likewise. | |
7044 | ||
7045 | * w32.h (emacs_gnutls_pull): Add prototype. | |
7046 | (emacs_gnutls_push): Likewise. | |
7047 | ||
7048 | * w32.c (emacs_gnutls_pull): New function for GnuTLS on Woe32. | |
7049 | (emacs_gnutls_push): Likewise. | |
7050 | ||
7051 | 2011-04-24 Claudio Bley <claudio.bley@gmail.com> (tiny change) | |
7052 | ||
7053 | * process.c (wait_reading_process_output): Check if GnuTLS | |
7054 | buffered some data internally if no FDs are set for TLS | |
7055 | connections. | |
7056 | ||
7057 | * makefile.w32-in (OBJ2): Add gnutls.$(O). | |
7058 | (LIBS): Link to USER_LIBS. | |
7059 | ($(BLD)/gnutls.$(0)): New target. | |
7060 | ||
fa6996bc EZ |
7061 | 2011-04-24 Eli Zaretskii <eliz@gnu.org> |
7062 | ||
eb35682e EZ |
7063 | * xdisp.c (handle_single_display_spec): Rename the |
7064 | display_replaced_before_p argument into display_replaced_p, to | |
7065 | make it consistent with the commentary. Fix typos in the | |
7066 | commentary. | |
7067 | ||
e2ad650c EZ |
7068 | * textprop.c (syms_of_textprop): Remove dead code. |
7069 | (copy_text_properties): Delete obsolete commentary about an | |
7070 | interface that was deleted long ago. Fix typos in the description | |
7071 | of arguments. | |
7072 | ||
1b2de274 EZ |
7073 | * msdos.c (XMenuActivate, XMenuAddSelection): Adjust argument list |
7074 | to changes in oldXMenu/XMenu.h from 2011-04-16. | |
7075 | <menu_help_message, prev_menu_help_message>: Constify. | |
7076 | (IT_menu_make_room): menu->help_text is now `const char **'; | |
7077 | adjust. | |
7078 | ||
7079 | * msdos.h (XMenuActivate, XMenuAddSelection): Adjust prototypes | |
7080 | to changes in oldXMenu/XMenu.h from 2011-04-16. | |
7081 | (struct XMenu): Declare `help_text' `const char **'. | |
7082 | ||
7083 | * xfaces.c <Qunspecified>: Make extern again. | |
7084 | ||
7085 | * syntax.c: Include sys/types.h before including regex.h, as | |
7086 | required by Posix. | |
7087 | ||
762b15be EZ |
7088 | * doc.c (get_doc_string): Improve the format passed to `error'. |
7089 | ||
7090 | * doprnt.c (doprnt): Improve commentary. | |
7091 | ||
7092 | * term.c (init_tty) [MSDOS]: Fix 1st argument to maybe_fatal. | |
7093 | ||
7094 | * Makefile.in (TAGS): Depend on $(M_FILE) and $(S_FILE), and scan | |
7095 | them with etags. | |
7096 | ||
f1052e5d EZ |
7097 | * makefile.w32-in (globals.h): Add a dummy recipe, to make any |
7098 | changes in globals.h immediately force recompilation. | |
762b15be EZ |
7099 | (TAGS): Depend on $(CURDIR)/m/intel386.h and |
7100 | $(CURDIR)/s/ms-w32.h. | |
7101 | (TAGS-gmake): Scan $(CURDIR)/m/intel386.h and $(CURDIR)/s/ms-w32.h. | |
f1052e5d | 7102 | |
fa6996bc EZ |
7103 | * character.c (Fchar_direction): Function deleted. |
7104 | (syms_of_character): Don't defsubr it. | |
7105 | <char-direction-table>: Deleted. | |
7106 | ||
e6c3da20 EZ |
7107 | 2011-04-23 Eli Zaretskii <eliz@gnu.org> |
7108 | ||
7109 | Fix doprnt so it could be used again safely in `verror'. (Bug#8435) | |
7110 | * doprnt.c: Include limits.h. | |
7111 | (SIZE_MAX): New macro. | |
04f2d78b CB |
7112 | (doprnt): Return a size_t value. 2nd arg is now size_t. |
7113 | Many local variables are now size_t instead of int or unsigned. | |
e6c3da20 EZ |
7114 | Improve overflow protection. Support `l' modifier for integer |
7115 | conversions. Support %l conversion. Don't assume an EMACS_INT | |
7116 | argument for integer conversions and for %c. | |
7117 | ||
7118 | * lisp.h (doprnt): Restore prototype. | |
7119 | ||
7120 | * makefile.w32-in ($(BLD)/callint.$(O)): Depend on | |
7121 | $(SRC)/character.h. | |
7122 | ||
7123 | * Makefile.in (base_obj): Add back doprnt.o. | |
7124 | ||
7125 | * deps.mk (doprnt.o): Add back prerequisites. | |
7126 | (callint.o): Depend on character.h. | |
7127 | ||
7128 | * eval.c (internal_lisp_condition_case): Include the handler | |
7129 | representation in the error message. | |
7130 | (verror): Call doprnt instead of vsnprintf. Fix an off-by-one bug | |
7131 | when breaking from the loop. | |
7132 | ||
7133 | * xdisp.c (vmessage): Call doprnt instead of vsnprintf. | |
7134 | ||
7135 | * callint.c (Fcall_interactively): When displaying error message | |
7136 | about invalid control letter, pass the character's codepoint, not | |
7137 | a pointer to its multibyte form. Improve display of the character | |
7138 | in octal and display also its hex code. | |
7139 | ||
7140 | * character.c (char_string): Use %x to display the (unsigned) | |
7141 | codepoint of an invalid character, to avoid displaying a bogus | |
7142 | negative value. | |
7143 | ||
7144 | * font.c (check_otf_features): Pass SDATA of SYMBOL_NAME to | |
7145 | `error', not SYMBOL_NAME itself. | |
7146 | ||
7147 | * coding.c (Fencode_sjis_char, Fencode_big5_char): Use %c for | |
7148 | character arguments to `error'. | |
7149 | ||
7150 | * charset.c (check_iso_charset_parameter): Fix incorrect argument | |
7151 | to `error' in error message about FINAL_CHAR argument. Make sure | |
7152 | FINAL_CHAR is a character, and use %c when it is passed as | |
7153 | argument to `error'. | |
7154 | ||
4ffd0d6b | 7155 | 2011-04-23 Eli Zaretskii <eliz@gnu.org> |
97a93095 EZ |
7156 | |
7157 | * s/ms-w32.h (localtime): Redirect to sys_localtime. | |
7158 | ||
7159 | * w32.c: Include <time.h>. | |
7160 | (sys_localtime): New function. | |
7161 | ||
4ffd0d6b | 7162 | 2011-04-23 Chong Yidong <cyd@stupidchicken.com> |
c17819f4 CY |
7163 | |
7164 | * xdisp.c (init_xdisp): Initialize echo_area_window (Bug#6451). | |
7165 | ||
4ffd0d6b | 7166 | * buffer.c (syms_of_buffer): Doc fix (Bug#6902). |
aac0c6e3 | 7167 | |
4ffd0d6b | 7168 | 2011-04-23 Samuel Thibault <sthibault@debian.org> (tiny change) |
aac0c6e3 | 7169 | |
4ffd0d6b GM |
7170 | * sysdep.c (wait_for_termination): On GNU Hurd, kill returns -1 on |
7171 | zombies (Bug#8467). | |
aac0c6e3 | 7172 | |
04c56954 EZ |
7173 | 2011-04-19 Eli Zaretskii <eliz@gnu.org> |
7174 | ||
7175 | * syntax.h (SETUP_SYNTAX_TABLE_FOR_OBJECT): Fix setting of | |
7176 | gl_state.e_property when gl_state.object is Qt. | |
7177 | ||
7178 | * insdel.c (make_gap_larger): Remove limitation of buffer size | |
7179 | to <= INT_MAX. | |
7180 | ||
16a43933 CY |
7181 | 2011-04-18 Chong Yidong <cyd@stupidchicken.com> |
7182 | ||
7183 | * xdisp.c (lookup_glyphless_char_display) | |
7184 | (produce_glyphless_glyph): Handle cons cell entry in | |
7185 | glyphless-char-display. | |
7186 | (Vglyphless_char_display): Document it. | |
7187 | ||
7188 | * term.c (produce_glyphless_glyph): Handle cons cell entry in | |
7189 | glyphless-char-display. | |
7190 | ||
4581706e CY |
7191 | 2011-04-17 Chong Yidong <cyd@stupidchicken.com> |
7192 | ||
7193 | * xdisp.c (get_next_display_element): Remove unnecessary ifdefs. | |
7194 | ||
7195 | * termhooks.h (FRAME_WINDOW_P): Remove duplicated definitions. | |
7196 | ||
7197 | * dispextern.h (FACE_SUITABLE_FOR_ASCII_CHAR_P): Add missing | |
7198 | definition for no-X builds. | |
7199 | ||
4887c6e2 | 7200 | 2011-04-16 Paul Eggert <eggert@cs.ucla.edu> |
764430a3 | 7201 | |
fd35b6f9 PE |
7202 | Static checks with GCC 4.6.0 and non-default toolkits. |
7203 | ||
5c1ccb01 PE |
7204 | * s/sol2-6.h, s/unixware.h (PTY_TTY_NAME_SPRINTF): Protoize decl. |
7205 | ||
006c5daa PE |
7206 | * process.c (keyboard_bit_set): Define only if SIGIO. |
7207 | (send_process_trap): Mark it with NO_RETURN if it doesn't return. | |
7208 | (send_process): Repair possible setjmp clobbering. | |
7209 | ||
efc736d3 PE |
7210 | * s/usg5-4-common.h (SETUP_SLAVE_PTY): Don't pass extra arg to 'fatal'. |
7211 | ||
4e2fe2e6 PE |
7212 | * eval.c: Include <stdio.h>, for vsnprintf on non-GNU/Linux hosts. |
7213 | ||
f97334a2 PE |
7214 | * data.c (arith_error): Mark with NO_RETURN if it doesn't return. |
7215 | ||
4e75f29d PE |
7216 | * alloc.c (bytes_used_when_full, SPARE_MEMORY, BYTES_USED): |
7217 | Define only if needed. | |
7218 | ||
90efadd1 PE |
7219 | * sysdep.c (_FILE_OFFSET_BITS): Make this hack even uglier |
7220 | by pacifying GCC about it. Maybe it's time to retire it? | |
875975e9 | 7221 | * xfaces.c (USG, __TIMEVAL__): Likewise. |
90efadd1 | 7222 | |
3c647824 PE |
7223 | * dispextern.h (struct redisplay_interface): Rename param |
7224 | to avoid shadowing. | |
e264f262 | 7225 | * termhooks.h (struct terminal): Likewise. |
761383f4 | 7226 | * xterm.c (xembed_send_message): Likewise. |
3c647824 | 7227 | |
b58c5c4a PE |
7228 | * insdel.c (make_gap_smaller): Define only if |
7229 | USE_MMAP_FOR_BUFFERS || REL_ALLOC || DOUG_LEA_MALLOC. | |
7230 | ||
cad59032 PE |
7231 | * keyboard.c (read_char): Make a var volatile so longjmp won't clobber |
7232 | it. | |
7233 | ||
c339dc2e PE |
7234 | * emacs.c (MAX_HEAP_BSS_DIFF, my_edata): Move to where they're used, |
7235 | so that we aren't warned about unused symbols. | |
7236 | ||
91a3e27b PE |
7237 | * xfns.c (Fx_file_dialog): Rename local to avoid shadowing. |
7238 | ||
399c71d3 | 7239 | * xdisp.c (x_produce_glyphs): Mark var as initialized (Bug#8512). |
7a3fb125 | 7240 | |
8ffc96f5 PE |
7241 | * xfns.c (x_real_positions): Mark locals as initialized. |
7242 | ||
eef9bc79 PE |
7243 | * xmenu.c (xmenu_show): Don't use uninitialized vars. |
7244 | ||
098db9dd PE |
7245 | * xterm.c: Fix problems found by static analysis with other toolkits. |
7246 | (toolkit_scroll_bar_interaction): Define and use only if USE_X_TOOLKIT. | |
dda3aedd PE |
7247 | (x_dispatch_event): Declare static if USE_GTK, and |
7248 | define if USE_GTK || USE_X_TOOLKIT. | |
098db9dd | 7249 | (SET_SAVED_BUTTON_EVENT): Define only if USE_X_TOOLKIT || USE_GTK. |
dda3aedd | 7250 | * xterm.h (x_dispatch_event): Extern only if USE_X_TOOLKIT. |
841a1577 JB |
7251 | * xterm.c, xterm.h (x_mouse_leave): Bring this function back, but only |
7252 | if defined HAVE_MENUS && !defined USE_X_TOOLKIT && !defined USE_GTK. | |
098db9dd | 7253 | |
eb18f6cc PE |
7254 | * xmenu.c (menu_help_callback): Pointer type fixes. |
7255 | Use const pointers when pointing at readonly data. Avoid pointer | |
7256 | signedness clashes. | |
7257 | (FALSE): Remove unused macro. | |
7258 | (update_frame_menubar): Remove unused decl. | |
7259 | ||
1fe72bf8 PE |
7260 | * xfns.c (Fx_hide_tip): Move locals to avoid shadowing. |
7261 | ||
60d9e1db PE |
7262 | * menu.c (push_submenu_start, push_submenu_end): Do not define unless |
7263 | USE_X_TOOLKIT || USE_GTK || HAVE_NS || defined HAVE_NTGUI. | |
7264 | (single_menu_item): Rename local to avoid shadowing. | |
7265 | ||
39261c26 PE |
7266 | * keyboard.c (make_lispy_event): Remove unused local var. |
7267 | ||
018c5e19 PE |
7268 | * frame.c, frame.h (x_get_resource_string): Bring this back, but |
7269 | only if HAVE_X_WINDOWS && !USE_X_TOOLKIT. | |
7270 | ||
63d2b86e PE |
7271 | * bitmaps: Change bitmaps from unsigned char back to the X11 |
7272 | compatible char. Avoid the old compiler warnings about | |
7273 | out-of-range initializers by using, for example, '\xab' rather | |
7274 | than 0xab. | |
7275 | ||
aefd87e1 PE |
7276 | * xgselect.c (xgselect_initialize): Check vs interface |
7277 | even if ! (defined (USE_GTK) || defined (HAVE_GCONF)). | |
7278 | ||
bf501fb9 PE |
7279 | * xmenu.c (xmenu_show): Rename parm to avoid shadowing. |
7280 | ||
e9829fdf PE |
7281 | * xterm.c (x_create_toolkit_scroll_bar): Use const * for pointers |
7282 | to read-only memory. | |
7283 | ||
1086c095 PE |
7284 | * fns.c (vector): Remove; this old hack is no longer needed. |
7285 | ||
2baccd04 | 7286 | * xsmfns.c (create_client_leader_window): Rename shadowing arg. |
401f10cb | 7287 | Remove unused var. |
dde42981 | 7288 | (gdk_x11_set_sm_client_id) [!USE_GTK]: Don't define. |
2baccd04 | 7289 | |
72391843 | 7290 | * xrdb.c (x_load_resources): Omit unused local. |
3565b346 | 7291 | |
436c16df | 7292 | * xfns.c (free_frame_menubar, atof): Remove duplicate decls. |
8a94ea33 | 7293 | (x_window): Rename locals to avoid shadowing. |
dc5ddd85 | 7294 | (USG): Use the kludged USG macro, to pacify gcc. |
436c16df | 7295 | |
92bb796d | 7296 | * xterm.c (x_alloc_nearest_color_for_widget): Remove; unused. |
bbbef9e1 | 7297 | (x_term_init): Remove local to avoid shadowing. |
92bb796d | 7298 | |
764430a3 | 7299 | * xfns.c, xterm.c (_XEditResCheckMessages): Protoize decl. |
4887c6e2 PE |
7300 | |
7301 | * xdisp.c, dispextern.h (set_vertical_scroll_bar): Now extern if | |
7302 | USE_TOOLKIT_SCROLL_BARS && !USE_GTK, as xterm.c needs it then. | |
7303 | ||
d1dfb56c EZ |
7304 | 2011-04-16 Eli Zaretskii <eliz@gnu.org> |
7305 | ||
c4354cb4 EZ |
7306 | * gnutls.c (Fgnutls_boot): Don't pass Lisp_Object to `error'. |
7307 | ||
d1dfb56c EZ |
7308 | Fix regex.c, syntax.c and friends for buffers > 2GB. |
7309 | * syntax.h (struct gl_state_s): Declare character position members | |
7310 | EMACS_INT. | |
7311 | ||
7312 | * syntax.c (update_syntax_table): Declare 2nd argument EMACS_INT. | |
7313 | ||
04f2d78b CB |
7314 | * textprop.c (verify_interval_modification, interval_of): |
7315 | Declare arguments EMACS_INT. | |
d1dfb56c EZ |
7316 | |
7317 | * intervals.c (adjust_intervals_for_insertion): Declare arguments | |
7318 | EMACS_INT. | |
7319 | ||
7320 | * intervals.h (CHECK_TOTAL_LENGTH): Cast to EMACS_INT, not `int'. | |
7321 | ||
7322 | * indent.c (Fvertical_motion): Local variable it_start is now | |
7323 | EMACS_INT. | |
7324 | ||
7325 | * regex.c (re_match, re_match_2, re_match_2_internal) | |
7326 | (bcmp_translate, regcomp, regexec, print_double_string) | |
7327 | (group_in_compile_stack, re_search, re_search_2, regex_compile) | |
7328 | (re_compile_pattern, re_exec): Declare arguments and local | |
7329 | variables `size_t' and `ssize_t' and return values `regoff_t', as | |
7330 | appropriate. | |
7331 | (POP_FAILURE_REG_OR_COUNT) <pfreg>: Declare `long'. | |
7332 | (CHECK_INFINITE_LOOP) <failure>: Declare `ssize_t'. | |
7333 | <compile_stack_type>: `size' and `avail' are now `size_t'. | |
7334 | ||
7335 | * regex.h <regoff_t>: Use ssize_t, not int. | |
7336 | (re_search, re_search_2, re_match, re_match_2): Arguments that | |
7337 | specify buffer/string position and length are now ssize_t and | |
7338 | size_t. Return type is regoff_t. | |
7339 | ||
613052cd BK |
7340 | 2011-04-16 Ben Key <bkey76@gmail.com> |
7341 | ||
7342 | * nsfont.m: Fixed bugs in ns_get_family and | |
7343 | ns_descriptor_to_entity that were caused by using free to | |
7344 | deallocate memory blocks that were allocated by xmalloc (via | |
7345 | xstrdup). This caused Emacs to crash when compiled with | |
7346 | XMALLOC_OVERRUN_CHECK defined (when Emacs was configured with | |
7347 | --enable-checking=xmallocoverrun). xfree is now used to | |
7348 | deallocate these memory blocks. | |
7349 | ||
4170f62f | 7350 | 2011-04-15 Paul Eggert <eggert@cs.ucla.edu> |
3e047f51 | 7351 | |
71b41406 PE |
7352 | * sysdep.c (emacs_read): Remove unnecessary check vs MAX_RW_COUNT. |
7353 | ||
9587a89d PE |
7354 | emacs_write: Accept and return EMACS_INT for sizes. |
7355 | See http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00514.html | |
7356 | et seq. | |
7357 | * gnutls.c, gnutls.h (emacs_gnutls_read, emacs_gnutls_write): | |
7358 | Accept and return EMACS_INT. | |
7359 | (emacs_gnutls_write): Return the number of bytes written on | |
7360 | partial writes. | |
7361 | * sysdep.c, lisp.h (emacs_read, emacs_write): Likewise. | |
273a5f82 PE |
7362 | (emacs_read, emacs_write): Remove check for negative size, as the |
7363 | Emacs source code has been audited now. | |
9587a89d PE |
7364 | * sysdep.c (MAX_RW_COUNT): New macro, to work around kernel bugs. |
7365 | (emacs_read, emacs_write): Use it. | |
273a5f82 PE |
7366 | * process.c (send_process): Adjust to the new signatures of |
7367 | emacs_write and emacs_gnutls_write. Do not attempt to store | |
7368 | a byte offset into an 'int'; it might overflow. | |
9587a89d | 7369 | See http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00483.html |
273a5f82 | 7370 | |
3e047f51 PE |
7371 | * sound.c: Don't assume sizes fit in 'int'. |
7372 | (struct sound_device.period_size, alsa_period_size): | |
9c3c56a7 | 7373 | Return EMACS_INT, not int. |
3e047f51 | 7374 | (struct sound_device.write, vox_write, alsa_write): |
9c3c56a7 PE |
7375 | Accept EMACS_INT, not int. |
7376 | (wav_play, au_play): Use EMACS_INT to store sizes and to | |
3e047f51 PE |
7377 | record read return values. |
7378 | ||
cc39a9db BK |
7379 | 2011-04-15 Ben Key <bkey76@gmail.com> |
7380 | ||
c9d0ec6d JB |
7381 | * keyboard.c (Qundefined): Don't declare static since it is used |
7382 | in nsfns.m. | |
7383 | * xfaces.c (Qbold, Qexpanded, Qitalic, Qcondensed): Don't declare | |
7384 | static since they are used in nsfont.m. | |
cc39a9db | 7385 | |
6c60eb9f SM |
7386 | 2011-04-15 Stefan Monnier <monnier@iro.umontreal.ca> |
7387 | ||
7388 | * process.c (Qprocessp): Don't declare static. | |
7389 | * lisp.h (Qprocessp): Declare again. | |
7390 | ||
7990b61a JB |
7391 | 2011-04-15 Juanma Barranquero <lekktu@gmail.com> |
7392 | ||
7393 | * font.c (Qopentype): Don't make static (used from w32uniscribe.c). | |
7394 | ||
5d4cb038 PE |
7395 | 2011-04-14 Paul Eggert <eggert@cs.ucla.edu> |
7396 | ||
8bd7b830 | 7397 | Improve C-level modularity by making more things 'static'. |
cd64ea1d | 7398 | |
e3b27b31 PE |
7399 | Don't publish debugger-only interfaces to other modules. |
7400 | * lisp.h (safe_debug_print, debug_output_compilation_hack): | |
7401 | (verify_bytepos, count_markers): Move decls to the only modules | |
7402 | that need them. | |
7403 | * region-cache.h (pp_cache): Likewise. | |
7404 | * window.h (check_all_windows): Likewise. | |
7405 | * marker.c, print.c, region-cache.c, window.c: Decls moved here. | |
7406 | ||
5d4cb038 PE |
7407 | * sysdep.c (croak): Now static, if |
7408 | defined TIOCNOTTY || defined USG5 || defined CYGWIN. | |
7409 | * syssignal.h (croak): Declare only if not static. | |
69003fd8 PE |
7410 | |
7411 | * alloc.c (refill_memory_reserve): Now static if | |
7412 | !defined REL_ALLOC || defined SYSTEM_MALLOC. | |
7413 | * lisp.h (refill_memory_reserve): Declare only if not static. | |
93ea6e8f | 7414 | |
e87b6180 PE |
7415 | * xsettings.c, xsettings.h (xsettings_get_system_normal_font): |
7416 | Define only if USE_LUCID. | |
7417 | ||
ac64929e PE |
7418 | * xrdb.c (x_customization_string, x_rm_string): Now static. |
7419 | ||
6f37259d PE |
7420 | * xmenu.c (x_menu_wait_for_event): Export only if USE_MOTIF. |
7421 | * xterm.h (x_menu_wait_for_event): Declare only if USE_MOTIF. | |
7422 | ||
1683e3ab PE |
7423 | * xdisp.c (draw_row_with_mouse_face): Now static. |
7424 | * dispextern.h (draw_row_with_mouse_fave): Remove decl. | |
7425 | ||
de9c2632 PE |
7426 | * window.h (check_all_windows): Mark externally visible. |
7427 | ||
2b96acb7 PE |
7428 | * window.c (window_deletion_count): Now static. |
7429 | ||
7430 | * undo.c: Make symbols static if they're not exported. | |
7431 | (last_undo_buffer, last_boundary_position, pending_boundary): | |
7432 | Now static. | |
7433 | ||
50436f33 PE |
7434 | * textprop.c (interval_insert_behind_hooks): Now static. |
7435 | (interval_insert_in_front_hooks): Likewise. | |
7436 | ||
64520e5c PE |
7437 | * term.c: Make symbols static if they're not exported. |
7438 | (tty_turn_off_highlight, get_tty_terminal, max_frame_cols): | |
7439 | (max_frame_lines, tty_set_terminal_modes): | |
7440 | (tty_reset_terminal_modes, tty_turn_off_highlight): | |
7441 | (get_tty_terminal): Now static. | |
7442 | (term_mouse_moveto): Do not define if HAVE_WINDOW_SYSTEM. | |
7443 | * termhooks.h (term_mouse_moveto): Do not declare if | |
8bd7b830 | 7444 | HAVE_WINDOW_SYSTEM. |
64520e5c PE |
7445 | * dispextern.h (tty_set_terminal_modes, tty_reset_terminal_modes): |
7446 | (tty_turn_off_highlight, get_tty_terminal): Remove decls. | |
7447 | ||
1fa53021 PE |
7448 | * sysdep.c: Make symbols static if they're not exported. |
7449 | (emacs_get_tty, emacs_set_tty, old_fcntl_flags, old_fcntl_owner): | |
7450 | Now static. | |
7451 | (sigprocmask_set, full_mask): Remove; unused. | |
7452 | (wait_debugging): Mark as visible. | |
7453 | * syssignal.h (SIGFULLMASK, full_mask): Remove decls. | |
7454 | * systty.h (emacs_get_tty, emacs_set_tty): Remove decls. | |
7455 | ||
d4b43b22 PE |
7456 | * syntax.c (syntax_temp): Define only if !__GNUC__. |
7457 | ||
b7c513d0 PE |
7458 | * sound.c (current_sound_device, current_sound): Now static. |
7459 | ||
989b29ad PE |
7460 | * search.c (searchbufs, searchbuf_head): Now static. |
7461 | ||
13a55a78 PE |
7462 | * scroll.c (scroll_cost): Remove; unused. |
7463 | * dispextern.h (scroll_cost): Remove decl. | |
7464 | ||
de68a1fc PE |
7465 | * region-cache.h (pp_cache): Mark as externally visible. |
7466 | ||
40ccffa6 PE |
7467 | * process.c: Make symbols static if they're not exported. |
7468 | (process_tick, update_tick, create_process, chan_process): | |
7469 | (Vprocess_alist, proc_buffered_char, datagram_access): | |
7470 | (fd_callback_data, send_process_frame, process_sent_to): Now static. | |
7471 | (deactivate_process): Mark defn as static, as well as decl. | |
7472 | * lisp.h (create_process): Remove decl. | |
7473 | * process.h (chan_process, Vprocess_alist): Remove decls. | |
7474 | ||
ad64fc97 PE |
7475 | * print.c: Make symbols static if they're not exported. |
7476 | (print_depth, new_backquote_output, being_printed, print_buffer): | |
7477 | (print_buffer_size, print_buffer_pos, print_buffer_pos_byte): | |
7478 | (print_interval, print_number_index, initial_stderr_stream): | |
7479 | Now static. | |
7480 | * lisp.h (Fprinc): Remove decl. | |
7481 | (debug_output_compilation_hack): Mark as externally visible. | |
7482 | ||
adddb265 PE |
7483 | * sysdep.c (croak): Move decl from here to syssignal.h. |
7484 | * syssignal.h (croak): Put it here, so the API can be checked when | |
7485 | 'croak' is called from dissociate_if_controlling_tty. | |
7486 | ||
1717ede2 PE |
7487 | * minibuf.c: Make symbols static if they're not exported. |
7488 | (minibuf_save_list, choose_minibuf_frame): Now static. | |
7489 | * lisp.h (choose_minibuf_frame): Remove decl. | |
7490 | ||
fa5fb2bc PE |
7491 | * lisp.h (verify_bytepos, count_markers): Mark as externally visible. |
7492 | ||
1e3890d1 PE |
7493 | * lread.c: Make symbols static if they're not exported. |
7494 | (read_objects, initial_obarray, oblookup_last_bucket_number): | |
7495 | Now static. | |
7496 | (make_symbol): Remove; unused. | |
7497 | * lisp.h (initial_obarray, make_symbol): Remove decls. | |
7498 | ||
8a1414fa PE |
7499 | * keyboard.c: Make symbols static if they're not exported. |
7500 | (single_kboard, recent_keys_index, total_keys, recent_keys): | |
7501 | (this_command_key_count_reset, raw_keybuf, raw_keybuf_count): | |
7502 | (this_single_command_key_start, echoing, last_auto_save): | |
7503 | (read_key_sequence_cmd, dribble, recursive_edit_unwind): | |
7504 | (command_loop, echo_now, keyboard_init_hook, help_char_p): | |
7505 | (quit_throw_to_read_char, command_loop_2, top_level_1, poll_timer): | |
7506 | (Vlispy_mouse_stem, double_click_count): | |
7507 | Now static. | |
7508 | (force_auto_save_soon): Define only if SIGDANGER. | |
7509 | (ignore_mouse_drag_p): Now static if | |
7510 | !defined HAVE_WINDOW_SYSTEM || defined USE_GTK || defined HAVE_NS. | |
7511 | (print_help): Remove; unused. | |
7512 | (stop_character, last_timer_event): Mark as externally visible. | |
7513 | * keyboard.h (ignore_mouse_drag_p): Declare only if | |
7514 | defined HAVE_WINDOW_SYSTEM && !defined USE_GTK && !defined HAVE_NS. | |
7515 | (echo_now, help_char_p, quit_throw_to_read_char): Remove decls. | |
7516 | * lisp.h (echoing): Remove decl. | |
7517 | (force_auto_save_soon): Declare only if SIGDANGER. | |
7518 | * xdisp.c (redisplay_window): Simplify code, to make it more | |
7519 | obvious that ignore_mouse_drag_p is not accessed if !defined | |
7520 | USE_GTK && !defined HAVE_NS. | |
7521 | ||
93ea6e8f PE |
7522 | * intervals.c: Make symbols static if they're not exported. |
7523 | (merge_properties_sticky, merge_interval_right, delete_interval): | |
7524 | Now static. | |
7525 | * intervals.h (merge_interval_right, delete_interval): Remove decls. | |
7526 | ||
77382fcc PE |
7527 | * insdel.c: Make symbols static if they're not exported. |
7528 | However, leave prepare_to_modify_buffer alone. It's never | |
7529 | called from outside this function, but that appears to be a bug. | |
7530 | (combine_after_change_list, combine_after_change_buffer): | |
4889fc82 | 7531 | (adjust_after_replace, signal_before_change): Now static. |
77382fcc PE |
7532 | (adjust_after_replace_noundo): Remove; unused. |
7533 | * lisp.h (adjust_after_replace, adjust_after_replace_noundo): | |
4889fc82 | 7534 | (signal_before_change): Remove decls. |
77382fcc | 7535 | |
9306c32e PE |
7536 | * indent.c (val_compute_motion, val_vmotion): Now static. |
7537 | ||
cd44d2eb PE |
7538 | * image.c: Make symbols static if they're not exported. |
7539 | * dispextern.h (x_create_bitmap_from_xpm_data): Do not declare | |
7540 | if USE_GTK. | |
7541 | * image.c (x_create_bitmap_from_xpm_data): Do not define if USE_GTK. | |
7542 | (xpm_color_cache, ct_table, ct_colors_allocated): Now static. | |
7543 | ||
ad9a7a06 PE |
7544 | * fringe.c (standard_bitmaps): Now static. |
7545 | (max_used_fringe_bitmap): Now static, unless HAVE_NS. | |
7546 | ||
81626931 PE |
7547 | * frame.c: Make symbols static if they're not exported. |
7548 | (x_report_frame_params, make_terminal_frame): Now static. | |
7549 | (get_frame_param): Now static, unless HAVE_NS. | |
7550 | (x_fullscreen_adjust): Define if WINDOWSNT, not if HAVE_WINDOW_SYSTEM. | |
7551 | (x_get_resource_string): Remove; not used. | |
7552 | * frame.h (make_terminal_frame, x_report_frame_params): | |
7553 | (x_get_resource_string); Remove decls. | |
7554 | (x_fullscreen_adjust): Declare only if WINDOWSNT. | |
7555 | * lisp.h (get_frame_param): Declare only if HAVE_NS. | |
7556 | ||
239f9db9 PE |
7557 | * font.c, fontset.c: Make symbols static if they're not exported. |
7558 | * dispextern.h (FACE_SUITABLE_FOR_ASCII_CHAR_P): New macro. | |
7559 | (FACE_SUITABLE_FOR_CHAR_P): Use it. | |
7560 | * font.c (font_close_object): Now static. | |
7561 | * font.h (font_close_object): Remove. | |
7562 | * fontset.c (FONTSET_OBJLIST): Remove. | |
7563 | (free_realized_fontset) #if-0 the body, which does nothing. | |
7564 | (face_suitable_for_char_p): #if-0, as it's never called. | |
7565 | * fontset.h (face_suitable_for_char_p): Remove decl. | |
04f2d78b CB |
7566 | * xfaces.c (face_at_string_position): |
7567 | Use FACE_SUITABLE_FOR_ASCII_CHAR_P, not FACE_SUITABLE_FOR_CHAR_P, | |
239f9db9 PE |
7568 | since 0 is always ASCII. |
7569 | ||
dfcf3579 PE |
7570 | * fns.c (weak_hash_tables): Now static. |
7571 | ||
5045092b PE |
7572 | * fileio.c: Make symbols static if they're not exported. |
7573 | (auto_saving, auto_save_mode_bits, auto_save_error_occurred): | |
7574 | (Vwrite_region_annotation_buffers): Now static. | |
7575 | ||
57a96f5c PE |
7576 | * eval.c: Make symbols static if they're not exported. |
7577 | (backtrace_list, lisp_eval_depth, when_entered_debugger): Now static. | |
7578 | * lisp.h (backtrace_list): Remove decl. | |
7579 | ||
35f08c38 PE |
7580 | * emacs.c: Make symbols static if they're not exported. |
7581 | (malloc_state_ptr, malloc_using_checking, syms_of_emacs): | |
7582 | (fatal_error_code, fatal_error_signal_hook, standard_args): | |
7583 | Now static. | |
7584 | (fatal_error_signal): Now static, unless FLOAT_CATCH_SIGKILL. | |
7585 | (DEFINE_DUMMY_FUNCTION): Mark function as externally visible. | |
7586 | (__CTOR_LIST__, __DTOR_LIST__): Now externally visible. | |
7587 | * lisp.h (fatal_error_signal_hook): Remove decl. | |
7588 | (fatal_error_signal): Declare only if FLOAT_CATCH_SIGKILL. | |
7589 | ||
f44bd759 PE |
7590 | * editfns.c: Move a (normally-unused) function to its only use. |
7591 | * editfns.c, lisp.h (get_operating_system_release): Remove. | |
7592 | * process.c (init_process) [DARWIN_OS]: Do it inline, as it is not | |
7593 | worth the hassle of breaking this out. | |
7594 | ||
b532497d PE |
7595 | * xterm.c: Make symbols static if they're not exported. |
7596 | (x_raise_frame, x_lower_frame, x_wm_set_window_state): | |
7597 | (x_wm_set_icon_pixmap, x_initialize, XTread_socket_fake_io_error): | |
7598 | (x_destroy_window, x_delete_display): | |
7599 | Now static. | |
7600 | (x_dispatch_event): Now static if ! (USE_MOTIF || USE_X_TOOLKIT). | |
7601 | (x_mouse_leave): Remove; unused. | |
7602 | * xterm.h (x_display_info_for_name, x_raise_frame, x_lower_frame): | |
7603 | (x_destroy_window, x_wm_set_window_state, x_wm_set_icon_pixmap): | |
7604 | (x_delete_display, x_initialize, x_set_border_pixel, x_screen_planes): | |
7605 | Remove decls. | |
7606 | (x_mouse_leave): Declare only if WINDOWSNT. | |
7607 | (x_dispatch_event): Declare only if USE_MOTIF or USE_X_TOOLKIT. | |
7608 | (xic_create_fontsetname): Declare only if HAVE_X_WINDOWS && | |
7609 | USE_X_TOOLKIT. | |
7610 | ||
1675728f PE |
7611 | * ftxfont.c: Make symbols static if they're not exported. |
7612 | (ftxfont_driver): Export only if !defined HAVE_XFT && def8ined | |
7613 | HAVE_FREETYPE. | |
7614 | * font.h (ftxfont_driver): Likewise. | |
7615 | ||
e4cebfca PE |
7616 | * xfns.c: Make symbols static if they're not exported. |
7617 | (x_last_font_name, x_display_info_for_name): | |
7618 | (x_set_foreground_color, x_set_background_color, x_set_mouse_color): | |
7619 | (x_set_cursor_color, x_set_border_pixel, x_set_border_color): | |
7620 | (x_set_cursor_type, x_set_icon_type, x_set_icon_name): | |
7621 | (x_set_scroll_bar_foreground, x_set_scroll_bar_background): | |
7622 | (x_explicitly_set_name, x_set_title, xic_defaut_fontset, tip_timer): | |
7623 | (last_show_tip_args): Now static. | |
7624 | (xic_defaut_fontset, xic_create_fontsetname): Define only if | |
7625 | defined HAVE_X_WINDOWS && defined USE_X_TOOLKIT | |
7626 | (x_screen_planes): Remove; unused. | |
7627 | * dispextern.h (x_screen_planes): Remove decl. | |
7628 | ||
5bf46f05 PE |
7629 | * dispnew.c: Make symbols static if they're not exported. |
7630 | * dispextern.h (redraw_garbaged_frames, scrolling): | |
7631 | (increment_row_positions): Remove. | |
7632 | * dispnew.c (new_glyph_matrix, increment_row_positions, scrolling): | |
7633 | (delayed_size_change, glyph_matrix_count, glyph_pool_count): | |
7634 | Now static. | |
7635 | (redraw_garbaged_frames): Remove; unused. | |
7636 | ||
435f4c28 PE |
7637 | * xfaces.c: Make symbols static if they're not exported. |
7638 | * dispextern.h (ascii_face_of_lisp_face, free_realized_face): | |
7639 | Remove decls. | |
7640 | * xterm.h (defined_color): Remove decls. | |
7641 | (x_free_dpy_colors): Declare only if USE_X_TOOLKIT. | |
7642 | * xfaces.c (tty_suppress_bold_inverse_default_colors_p): | |
7643 | (menu_face_changed_default, defined_color, free_realized_face): | |
7644 | (x_free_dpy_colors): Define only if USE_X_TOOLKIT. | |
7645 | (ascii_face_of_lisp_face): Remove; unused. | |
7646 | ||
8524aef3 PE |
7647 | * xdisp.c: Make symbols static if they're not exported. |
7648 | * dispextern.h (scratch_glyph_row, window_box_edges): | |
7649 | (glyph_to_pixel_coords, set_cursor_from_row): | |
7650 | (get_next_display_element, set_iterator_to_next): | |
7651 | (highlight_trailing_whitespace, frame_to_window_pixel_xy): | |
7652 | (show_mouse_face): Remove decls | |
7653 | * frame.h (message_buf_print): Likewise. | |
7654 | * lisp.h (pop_message, set_message, check_point_in_composition): | |
7655 | Likewise. | |
7656 | * xterm.h (set_vertical_scroll_bar): Likewise. | |
7657 | * xdisp.c (list_of_error, Vmessage_stack, line_number_displayed): | |
7658 | (message_buf_print, scratch_glyph_row, displayed_buffer): | |
7659 | (set_iterator_to_next, pop_message, set_message, set_cursor_from_row): | |
7660 | (get_next_display_element, show_mouse_face, window_box_edges): | |
7661 | (frame_to_window_pixel_xy, check_point_in_composition): | |
7662 | (set_vertical_scroll_bar, highlight_trailing_whitespace): Now static. | |
7663 | (glyph_to_pixel_coords): Remove; unused. | |
7664 | ||
16390cd2 PE |
7665 | * dired.c (file_name_completion): Now static. |
7666 | ||
7667 | * dbusbind.c (xd_in_read_queued_messages): Now static. | |
7668 | ||
a25f4dfa PE |
7669 | * lisp.h (circular_list_error, FOREACH): Remove; unused. |
7670 | * data.c (circular_list_error): Remove. | |
7671 | ||
14a9c8df PE |
7672 | * commands.h (last_point_position, last_point_position_buffer): |
7673 | (last_point_position_window): Remove decls. | |
7674 | * keyboard.c: Make these variables static. | |
7675 | ||
04f2d78b CB |
7676 | * coding.h (coding, code_convert_region, encode_coding_gap): |
7677 | Remove decls. | |
74ab6df5 PE |
7678 | * coding.c (Vsjis_coding_system, Vbig5_coding_system): |
7679 | (iso_code_class, detect_coding, code_convert_region): Now static. | |
7680 | (encode_coding_gap): Remove; unused. | |
7681 | ||
38dfbee1 PE |
7682 | * chartab.c (chartab_chars, chartab_bits): Now static. |
7683 | ||
a2cb4e63 PE |
7684 | * charset.h (charset_iso_8859_1): Remove decl. |
7685 | * charset.c (charset_iso_8859_1, charset_emacs, map_charset_for_dump): | |
7686 | Now static. | |
7687 | ||
127198fd PE |
7688 | * ccl.h (check_ccl_update, Vccl_program_table): Remove decls. |
7689 | * ccl.c (Vccl_program_table): Now static. | |
7690 | (check_ccl_update): Remove; unused. | |
7691 | ||
d85b608f PE |
7692 | * category.c (SET_CATEGORY_SET, set_category_set): Move here. |
7693 | * category.h: ... from here. | |
7694 | * category.c (check_category_table, set_category_set): Now static. | |
7695 | ||
31cd66f3 PE |
7696 | * casetab.c (Vascii_upcase_table, Vascii_eqv_table): Now static. |
7697 | * lisp.h: Remove these decls. | |
7698 | ||
c358e587 PE |
7699 | * buffer.c (buffer_count): Remove unused var. |
7700 | ||
e78aecca PE |
7701 | * bidi.c (bidi_dump_cached_states): Mark as externally visible, |
7702 | so that it's not optimized away. | |
7703 | (bidi_ignore_explicit_marks_for_paragraph_level): Likewise. | |
7704 | * dispextern.h (bidi_dump_cached_states): Remove, since it's | |
7705 | exported only to the debugger. | |
7706 | ||
e192d7d3 | 7707 | * atimer.c (alarm_signal_handler, run_all_atimers): Now static. |
04f2d78b | 7708 | * atimer.h (run_all_atimers): Remove; not exported. |
e192d7d3 | 7709 | |
92470028 PE |
7710 | font.c: Make copy_font_spec and merge_font_spec ordinary C functions. |
7711 | * font.c (copy_font_spec): Rename from Fcopy_font_spec, since it | |
7712 | was inaccessible from Lisp. | |
7713 | (merge_font_spec): Likewise, renaming from Fmerge_font_spec. | |
7714 | * font.c, font.h, fontset.c, xfaces.c, xfont.c: Change all uses. | |
7715 | ||
244ed907 PE |
7716 | alloc.c: Import and export fewer symbols, and remove unused items. |
7717 | * lisp.h (suppress_checking, die): Declare only if ENABLE_CHECKING | |
7718 | is defined. | |
7719 | (suppress_checking): Add EXTERNALLY_VISIBLE attribute, so that | |
7720 | it's not optimized away by whole-program optimization. | |
7721 | (message_enable_multibyte, free_misc): Remove. | |
7722 | (catchlist, handlerlist, mark_backtrace): | |
7723 | Declare only if BYTE_MARK_STACK. | |
7724 | (mark_byte_stack): Likewise, fixing a ifdef-vs-if typo. | |
7725 | * alloc.c (pure): Export only if VIRT_ADDR_VARIES is defined. | |
7726 | (message_enable_multibyte): Remove decl. | |
7727 | (free_misc, interval_free_list, float_block, float_block_index): | |
7728 | (n_float_blocks, float_free_list, cons_block, cons_block_index): | |
7729 | (cons_free_list, last_marked_index): | |
7730 | Now static. | |
7731 | (suppress_checking, die): Define only if ENABLE_CHECKING is defined. | |
7732 | * eval.c (catchlist, handlerlist): Export only if BYTE_MARK_STACK. | |
7733 | (mark_backtrace): Define only if BYTE_MARK_STACK. | |
7734 | * xdisp.c (message_enable_multibyte): Now static. | |
7735 | ||
61c2b50e | 7736 | Declare Lisp_Object Q* variables to be 'static' if not exported. |
955cbe7b PE |
7737 | This makes it easier for human readers (and static analyzers) |
7738 | to see whether these variables are used from other modules. | |
7739 | * alloc.c, buffer.c, bytecode.c, callint.c, casetab.c, category.c: | |
7740 | * ccl.c, character.c, charset.c, cmds.c, coding.c, composite.c: | |
7741 | * data.c, dbusbind.c, dired.c, editfns.c, eval.c, fileio.c, fns.c: | |
7742 | * font.c, frame.c, fringe.c, ftfont.c, image.c, keyboard.c, keymap.c: | |
7743 | * lread.c, macros.c, minibuf.c, print.c, process.c, search.c: | |
7744 | * sound.c, syntax.c, textprop.c, window.c, xdisp.c, xfaces.c, xfns.c: | |
7745 | * xmenu.c, xselect.c: | |
7746 | Declare Q* vars static if they are not used in other modules. | |
7747 | * ccl.h, character.h, charset.h, coding.h, composite.h, font.h: | |
7748 | * frame.h, intervals.h, keyboard.h, lisp.h, process.h, syntax.h: | |
7749 | Remove decls of unexported vars. | |
7750 | * keyboard.h (EVENT_HEAD_UNMODIFIED): Remove now-unused macro. | |
7751 | ||
95c82688 PE |
7752 | * lisp.h (DEFINE_FUNC): Make sname 'static'. |
7753 | ||
16a97296 PE |
7754 | Make Emacs functions such as Fatom 'static' by default. |
7755 | This makes it easier for human readers (and static analyzers) | |
7756 | to see whether these functions can be called from other modules. | |
7757 | DEFUN now defines a static function. To make the function external | |
7758 | so that it can be used in other C modules, use the new macro DEFUE. | |
8bd7b830 PE |
7759 | * lisp.h (Funibyte_char_to_multibyte, Fsyntax_table_p): |
7760 | (Finit_image_library): | |
16a97296 PE |
7761 | (Feval_region, Fbacktrace, Ffetch_bytecode, Fswitch_to_buffer): |
7762 | (Ffile_executable_p, Fmake_symbolic_link, Fcommand_execute): | |
7763 | (Fget_process, Fdocumentation_property, Fbyte_code, Ffile_attributes): | |
7764 | Remove decls, since these functions are now static. | |
7765 | (Funintern, Fget_internal_run_time): New decls, since these functions | |
7766 | were already external. | |
95c82688 | 7767 | |
16a97296 PE |
7768 | * alloc.c, buffer.c, callint.c, callproc.c, casefiddle.c, casetab.c: |
7769 | * ccl.c, character.c, chartab.c, cmds.c, coding.c, data.c, dispnew.c: | |
7770 | * doc.c, editfns.c, emacs.c, eval.c, fileio.c, filelock.c, floatfns.c: | |
7771 | * fns.c, font.c, fontset.c, frame.c, image.c, indent.c: | |
7772 | * keyboard.c, keymap.c, lread.c: | |
7773 | * macros.c, marker.c, menu.c, minibuf.c, print.c, process.c, search.c: | |
7774 | * syntax.c, term.c, terminal.c, textprop.c, undo.c: | |
7775 | * window.c, xdisp.c, xfaces.c, xfns.c, xmenu.c, xsettings.c: | |
7776 | Mark functions with DEFUE instead of DEFUN, | |
7777 | if they are used in other modules. | |
7778 | * buffer.c (Fset_buffer_major_mode, Fdelete_overlay): New forward | |
7779 | decls for now-static functions. | |
7780 | * buffer.h (Fdelete_overlay): Remove decl. | |
7781 | * callproc.c (Fgetenv_internal): Mark as internal. | |
7782 | * composite.c (Fremove_list_of_text_properties): Remove decl. | |
7783 | (Fcomposition_get_gstring): New forward static decl. | |
7784 | * composite.h (Fcomposite_get_gstring): Remove decl. | |
7785 | * dired.c (Ffile_attributes): New forward static decl. | |
7786 | * doc.c (Fdocumntation_property): New forward static decl. | |
7787 | * eval.c (Ffetch_bytecode): New forward static decl. | |
7788 | (Funintern): Remove extern decl; now in .h file where it belongs. | |
7789 | * fileio.c (Fmake_symbolic_link): New forward static decl. | |
7790 | * image.c (Finit_image_library): New forward static decl. | |
7791 | * insdel.c (Fcombine_after_change_execute): Make forward decl static. | |
7792 | * intervals.h (Fprevious_property_change): | |
7793 | (Fremove_list_of_text_properties): Remove decls. | |
7794 | * keyboard.c (Fthis_command_keys): Remove decl. | |
7795 | (Fcommand_execute): New forward static decl. | |
7796 | * keymap.c (Flookup_key): New forward static decl. | |
7797 | (Fcopy_keymap): Now static. | |
7798 | * keymap.h (Flookup_key): Remove decl. | |
7799 | * process.c (Fget_process): New forward static decl. | |
7800 | (Fprocess_datagram_address): Mark as internal. | |
7801 | * syntax.c (Fsyntax_table_p): New forward static decl. | |
7802 | (skip_chars): Remove duplicate decl. | |
7803 | * textprop.c (Fprevious_property_change): New forward static decl. | |
7804 | * window.c (Fset_window_fringes, Fset_window_scroll_bars): | |
7805 | Now internal. | |
7806 | (Fset_window_margins, Fset_window_vscroll): New forward static decls. | |
7807 | * window.h (Fset_window_vscroll, Fset_window_margins): Remove decls. | |
7808 | ||
785bbd42 PE |
7809 | * editfns.c (Fformat): Remove unreachable code. |
7810 | ||
8b913b57 AS |
7811 | 2011-04-14 Andreas Schwab <schwab@linux-m68k.org> |
7812 | ||
7813 | * fileio.c (Finsert_file_contents): Fix typo in 2005-05-13 | |
7814 | change. (Bug#8496) | |
7815 | ||
a6744a35 EZ |
7816 | 2011-04-13 Eli Zaretskii <eliz@gnu.org> |
7817 | ||
7818 | * xdisp.c (handle_invisible_prop): Don't call bidi_paragraph_init | |
7819 | when at ZV. (Bug#8487) | |
7820 | ||
e7974947 AS |
7821 | 2011-04-12 Andreas Schwab <schwab@linux-m68k.org> |
7822 | ||
baad03f0 AS |
7823 | * charset.c (Fclear_charset_maps): Use xfree instead of free. |
7824 | (Bug#8437) | |
7825 | * keyboard.c (parse_tool_bar_item): Likewise. | |
7826 | * sound.c (sound_cleanup, alsa_close): Likewise. | |
7827 | * termcap.c (tgetent): Likewise. | |
7828 | * xfns.c (x_default_font_parameter): Likewise. | |
7829 | * xsettings.c (read_and_apply_settings): Likewise. | |
7830 | ||
e7974947 AS |
7831 | * alloc.c (overrun_check_malloc, overrun_check_realloc) |
7832 | (overrun_check_free): Protoize. | |
7833 | ||
28272684 PE |
7834 | 2011-04-12 Paul Eggert <eggert@cs.ucla.edu> |
7835 | ||
7836 | * sysdep.c (emacs_read, emacs_write): Check for negative sizes | |
7837 | since callers should never pass a negative size. | |
7838 | Change the signature to match that of plain 'read' and 'write'; see | |
7839 | <http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00397.html>. | |
7840 | * lisp.h: Update prototypes of emacs_write and emacs_read. | |
7841 | ||
11997c76 EZ |
7842 | 2011-04-11 Eli Zaretskii <eliz@gnu.org> |
7843 | ||
7844 | * xdisp.c (redisplay_window): Don't try to determine the character | |
7845 | position of the scroll margin if the window start point w->startp | |
e896f03c | 7846 | is outside the buffer's accessible region. (Bug#8468) |
11997c76 | 7847 | |
8a2cbd72 EZ |
7848 | 2011-04-10 Eli Zaretskii <eliz@gnu.org> |
7849 | ||
7850 | Fix write-region and its subroutines for buffers > 2GB. | |
7851 | * fileio.c (a_write, e_write): Modify declaration of arguments and | |
7852 | local variables to support buffers larger than 2GB. | |
7853 | (Fcopy_file): Use EMACS_INT for return value of emacs_read. | |
7854 | ||
7855 | * sysdep.c (emacs_write, emacs_read): Use ssize_t for last | |
7856 | argument, local variables, and return value. | |
7857 | ||
7858 | * lisp.h: Update prototypes of emacs_write and emacs_read. | |
7859 | ||
7860 | * sound.c (vox_write): Use ssize_t for return value of emacs_write. | |
7861 | ||
4073e537 | 7862 | 2011-04-10 Paul Eggert <eggert@cs.ucla.edu> |
eb3f1cc8 | 7863 | |
1ebfdcb6 PE |
7864 | * xdisp.c (vmessage): Use memchr, not strnlen, which some hosts lack. |
7865 | ||
b2ded58d PE |
7866 | Fix more problems found by GCC 4.6.0's static checks. |
7867 | ||
7d66342c PE |
7868 | * xdisp.c (vmessage): Use a better test for character truncation. |
7869 | ||
bbf47d44 PE |
7870 | * charset.c (load_charset_map): <, not <=, for optimization, |
7871 | and to avoid potential problems with integer overflow. | |
9248994d | 7872 | * chartab.c (sub_char_table_set_range, char_table_set_range): Likewise. |
f9a68bc5 | 7873 | * casetab.c (set_identity, shuffle): Likewise. |
3ab1c7ce | 7874 | * editfns.c (Fformat): Likewise. |
1e69125e | 7875 | * syntax.c (skip_chars): Likewise. |
3befa583 | 7876 | |
e3019616 PE |
7877 | * xmenu.c (set_frame_menubar): Allocate smaller local vectors. |
7878 | This also lets GCC 4.6.0 generate slightly better loop code. | |
7879 | ||
becfa255 PE |
7880 | * callint.c (Fcall_interactively): <, not <=, for optimization. |
7881 | (Fcall_interactively): Count the number of arguments produced, | |
7882 | not the number of arguments given. This is simpler and lets GCC | |
7883 | 4.6.0 generate slightly better code. | |
7884 | ||
dae0cd48 PE |
7885 | * ftfont.c: Distingish more carefully between FcChar8 and char. |
7886 | The previous code passed unsigned char * to a functions like | |
7887 | strlen and xstrcasecmp that expect char *, which does not | |
7888 | conform to the C standard. | |
7889 | (get_adstyle_property, ftfont_pattern_entity): Use FcChar8 for | |
7890 | arguments to FcPatternGetString, and explicitly cast FcChar8 * to | |
7891 | char * when the C standard requires it. | |
7892 | ||
76032d70 PE |
7893 | * keyboard.c (read_char): Remove unused var. |
7894 | ||
eb3f1cc8 PE |
7895 | * eval.c: Port to Windows vsnprintf (Bug#8435). |
7896 | Include <limits.h>. | |
7897 | (SIZE_MAX): Define if the headers do not. | |
7898 | (verror): Do not give up if vsnprintf returns a negative count. | |
7899 | Instead, grow the buffer. This ports to Windows vsnprintf, which | |
7900 | does not conform to C99. Problem reported by Eli Zaretskii. | |
7901 | Also, simplify the allocation scheme, by avoiding the need for | |
7902 | calling realloc, and removing the ALLOCATED variable. | |
7903 | ||
70476b54 PE |
7904 | * eval.c (verror): Initial buffer size is 4000 (not 200) bytes. |
7905 | ||
12020a9e PE |
7906 | Remove invocations of doprnt, as Emacs now uses vsnprintf. |
7907 | But keep the doprint source code for now, as we might revamp it | |
7908 | and use it again (Bug#8435). | |
ea6c7ae6 PE |
7909 | * lisp.h (doprnt): Remove. |
7910 | * Makefile.in (base_obj): Remove doprnt.o. | |
7911 | * deps.mk (doprnt.o): Remove. | |
7912 | ||
5fdb398c PE |
7913 | error: Print 32- and 64-bit integers portably (Bug#8435). |
7914 | Without this change, on typical 64-bit hosts error ("...%d...", N) | |
7915 | was used to print both 32- and 64-bit integers N, which relied on | |
7916 | undefined behavior. | |
61bdb816 | 7917 | * lisp.h, m/amdx86-64.h, m/ia64.h, m/ibms390x.h (pEd): New macro. |
5fdb398c PE |
7918 | * lisp.h (error, verror): Mark as printf-like functions. |
7919 | * eval.c (verror): Use vsnprintf, not doprnt, to do the real work. | |
7920 | Report overflow in size calculations when allocating printf buffer. | |
7921 | Do not truncate output string at its first null byte. | |
7922 | * xdisp.c (vmessage): Use vsnprintf, not doprnt, to do the real work. | |
7923 | Truncate the output at a character boundary, since vsnprintf does not | |
7924 | do that. | |
7925 | * charset.c (check_iso_charset_parameter): Convert internal | |
7926 | character to string before calling 'error', since %c now has the | |
7927 | printf meaning. | |
7928 | * coding.c (Fdecode_sjis_char, Fdecode_big5_char): Avoid int | |
7929 | overflow when computing char to be passed to 'error'. Do not | |
7930 | pass Lisp_Object to 'error'; pass the integer instead. | |
7931 | * nsfns.m (Fns_do_applescript): Use int, not long, since it's | |
7932 | formatted with plain %d. | |
7933 | ||
b189fa66 PE |
7934 | * eval.c (internal_lisp_condition_case): Don't pass spurious arg. |
7935 | ||
bff87ef0 PE |
7936 | * keyboard.c (access_keymap_keyremap): Print func name, not garbage. |
7937 | ||
7e2cac20 PE |
7938 | * coding.c (Fdecode_sjis_char): Don't assume CODE fits in int. |
7939 | ||
ce4d90b5 PE |
7940 | * xterm.c (x_catch_errors): Remove duplicate declaration. |
7941 | ||
266c9547 PE |
7942 | * term.c (maybe_fatal): Mark its 3rd arg as a printf format, too. |
7943 | ||
79c49ad2 PE |
7944 | * xdisp.c, lisp.h (message_nolog): Remove; unused. |
7945 | ||
368f4090 JM |
7946 | 2011-04-10 Jim Meyering <meyering@redhat.com> |
7947 | ||
7948 | use ssize_t and size_t for read- and write-like emacs_gnutls_* functions | |
7949 | * gnutls.c (emacs_gnutls_read): Adjust signature to be more read-like: | |
7950 | return ssize_t not "int", and use size_t as the buffer length. | |
7951 | (emacs_gnutls_write): Likewise, and make the buffer pointer "const". | |
7952 | * gnutls.h: Update declarations. | |
7953 | * process.c (read_process_output): Use ssize_t, to match. | |
7954 | (send_process): Likewise. | |
7955 | ||
a32d4040 CY |
7956 | 2011-04-09 Chong Yidong <cyd@stupidchicken.com> |
7957 | ||
7958 | * image.c (Fimagemagick_types): Doc fix, and comment cleanup. | |
7959 | ||
8546720e | 7960 | 2011-04-09 Chong Yidong <cyd@stupidchicken.com> |
aac0c6e3 | 7961 | |
04f2d78b CB |
7962 | * ftfont.c (get_adstyle_property, ftfont_pattern_entity): |
7963 | Use unsigned char, to match FcChar8 type definition. | |
aac0c6e3 | 7964 | |
8546720e GM |
7965 | * xterm.c (handle_one_xevent): |
7966 | * xmenu.c (create_and_show_popup_menu): | |
7967 | * xselect.c (x_decline_selection_request) | |
7968 | (x_reply_selection_request): Avoid type-punned deref of X events. | |
aac0c6e3 | 7969 | |
0a2f5c1a | 7970 | 2011-04-09 Eli Zaretskii <eliz@gnu.org> |
a53e2e89 EZ |
7971 | |
7972 | Fix some uses of `int' instead of EMACS_INT. | |
7973 | * search.c (string_match_1, fast_string_match) | |
7974 | (fast_c_string_match_ignore_case, fast_string_match_ignore_case) | |
7975 | (scan_buffer, find_next_newline_no_quit) | |
7976 | (find_before_next_newline, search_command, Freplace_match) | |
7977 | (Fmatch_data): Make some `int' variables be EMACS_INT. | |
7978 | ||
7979 | * xdisp.c (display_count_lines): 3rd argument and return value now | |
7980 | EMACS_INT. All callers changed. | |
7981 | (pint2hrstr): Last argument is now EMACS_INT. | |
7982 | ||
7983 | * coding.c (detect_coding_utf_8, detect_coding_emacs_mule) | |
7984 | (detect_coding_iso_2022, detect_coding_sjis, detect_coding_big5) | |
7985 | (detect_coding_ccl, detect_coding_charset, decode_coding_utf_8) | |
7986 | (decode_coding_utf_16, decode_coding_emacs_mule) | |
7987 | (decode_coding_iso_2022, decode_coding_sjis, decode_coding_big5) | |
7988 | (decode_coding_ccl, decode_coding_charset) | |
7989 | <consumed_chars, consumed_chars_base>: Declare EMACS_INT. | |
7990 | (decode_coding_iso_2022, decode_coding_emacs_mule) | |
7991 | (decode_coding_sjis, decode_coding_big5, decode_coding_charset) | |
7992 | <char_offset, last_offset>: Declare EMACS_INT. | |
7993 | (encode_coding_utf_8, encode_coding_utf_16) | |
7994 | (encode_coding_emacs_mule, encode_invocation_designation) | |
7995 | (encode_designation_at_bol, encode_coding_iso_2022) | |
7996 | (encode_coding_sjis, encode_coding_big5, encode_coding_ccl) | |
7997 | (encode_coding_raw_text, encode_coding_charset) <produced_chars>: | |
7998 | Declare EMACS_INT. | |
7999 | (ASSURE_DESTINATION): Declare more_bytes EMACS_INT. | |
8000 | (encode_invocation_designation): Last argument P_NCHARS is now | |
8001 | EMACS_INT. | |
8002 | (decode_eol): Declare pos_byte, pos, and pos_end EMACS_INT. | |
8003 | (produce_chars): from_nchars and to_nchars are now EMACS_INT. | |
8004 | ||
8005 | * coding.h (struct coding_system) <head_ascii>: Declare EMACS_INT. | |
8006 | All users changed. | |
8007 | ||
8008 | * ccl.c (Fccl_execute_on_string): Declare some variables | |
8009 | EMACS_INT. | |
8010 | ||
8546720e | 8011 | 2011-04-08 Samuel Thibault <sthibault@debian.org> (tiny change) |
0080dc6b SS |
8012 | |
8013 | * term.c (init_tty): Fix incorrect ifdef placement (Bug#8450). | |
8014 | ||
4e19a977 CS |
8015 | 2011-03-19 Christoph Scholtes <cschol2112@googlemail.com> |
8016 | ||
8017 | * process.c (Fformat_network_address): Doc fix. | |
8018 | ||
87302331 R |
8019 | 2011-04-08 T.V. Raman <tv.raman.tv@gmail.com> (tiny change) |
8020 | ||
ee7683eb | 8021 | * xml.c (parse_region): Avoid creating spurious whitespace nodes. |
87302331 | 8022 | |
cbb59342 CY |
8023 | 2011-04-08 Chong Yidong <cyd@stupidchicken.com> |
8024 | ||
8025 | * keyboard.c (read_char): Call Lisp function help-form-show, | |
8026 | instead of using internal_with_output_to_temp_buffer. | |
8027 | (Qhelp_form_show): New var. | |
e0d38eeb | 8028 | (syms_of_keyboard): Use DEFSYM macro. |
cbb59342 CY |
8029 | |
8030 | * print.c (internal_with_output_to_temp_buffer): Function deleted. | |
8031 | ||
8032 | * lisp.h (internal_with_output_to_temp_buffer): Remove prototype. | |
8033 | ||
e67a13ab CY |
8034 | 2011-04-06 Chong Yidong <cyd@stupidchicken.com> |
8035 | ||
04f2d78b CB |
8036 | * process.c (Flist_processes): Remove to Lisp. |
8037 | (list_processes_1): Delete. | |
e67a13ab | 8038 | |
973f782d EZ |
8039 | 2011-04-06 Eli Zaretskii <eliz@gnu.org> |
8040 | ||
7c106b1e EZ |
8041 | * msdos.c (careadlinkat, careadlinkatcwd): MS-DOS replacements. |
8042 | ||
973f782d EZ |
8043 | * w32.c (careadlinkat, careadlinkatcwd): New always-fail stubs. |
8044 | ||
41cf7d1a | 8045 | 2011-04-06 Paul Eggert <eggert@cs.ucla.edu> |
27ccc379 | 8046 | |
ca23cc88 PE |
8047 | Fix more problems found by GCC 4.6.0's static checks. |
8048 | ||
f390e2d5 PE |
8049 | * xmenu.c (Fx_popup_dialog): Don't assume string is free of formats. |
8050 | ||
42eea0d0 PE |
8051 | * menu.c (Fx_popup_menu): Don't assume error_name lacks printf formats. |
8052 | ||
b69769da | 8053 | * lisp.h (message, message_nolog, fatal): Mark as printf-like. |
1e973bc7 | 8054 | |
f9541e84 PE |
8055 | * xdisp.c (vmessage): Mark as a printf-like function. |
8056 | ||
13841b55 PE |
8057 | * term.c (vfatal, maybe_fatal): Mark as printf-like functions. |
8058 | ||
c136c10f PE |
8059 | * sound.c (sound_warning): Don't crash if arg contains a printf format. |
8060 | ||
5e2d4a30 PE |
8061 | * image.c (tiff_error_handler, tiff_warning_handler): Mark as |
8062 | printf-like functions. | |
8063 | (tiff_load): Add casts to remove these marks before passing them | |
8064 | to system-supplied API. | |
8065 | ||
583f48b9 PE |
8066 | * eval.c (Fsignal): Remove excess argument to 'fatal'. |
8067 | ||
b25d760e PE |
8068 | * coding.c (EMIT_ONE_BYTE, EMIT_TWO_BYTES): Use unsigned, not int. |
8069 | This avoids several warnings with gcc -Wstrict-overflow. | |
d5efd1d1 PE |
8070 | (DECODE_COMPOSITION_RULE): If the rule is invalid, goto invalid_code |
8071 | directly, rather than having caller test rule sign. This avoids | |
8072 | some unnecessary tests. | |
8073 | * composite.h (COMPOSITION_ENCODE_RULE_VALID): New macro. | |
8074 | (COMPOSITION_ENCODE_RULE): Arguments now must be valid. This | |
8075 | affects only one use, in DECODE_COMPOSITION_RULE, which is changed. | |
b25d760e | 8076 | |
bc7b6697 | 8077 | * xfont.c (xfont_text_extents): Remove var that was set but not used. |
625a3eb1 | 8078 | (xfont_open): Avoid unnecessary tests. |
bc7b6697 | 8079 | |
27ccc379 PE |
8080 | * composite.c (composition_gstring_put_cache): Use unsigned integer. |
8081 | ||
dcd5c89a PE |
8082 | * composite.h, composite.c (composition_gstring_put_cache): |
8083 | Use EMACS_INT, not int, for length. | |
8084 | ||
b13a45c6 PE |
8085 | * composite.h (COMPOSITION_DECODE_REFS): New macro, |
8086 | breaking out part of COMPOSITION_DECODE_RULE. | |
8087 | (COMPOSITION_DECODE_RULE): Use it. | |
8088 | * composite.c (get_composition_id): Remove unused local vars, | |
8089 | by using the new macro. | |
8090 | ||
1e792e4d PE |
8091 | * textprop.c (set_text_properties_1): Change while to do-while, |
8092 | since the condition is always true at first. | |
8093 | ||
dc6c6455 | 8094 | * intervals.c (graft_intervals_into_buffer): Mark var as used. |
aa86731f PE |
8095 | (interval_deletion_adjustment): Return unsigned value. |
8096 | All uses changed. | |
dc6c6455 | 8097 | |
aba7731a PE |
8098 | * process.c (list_processes_1, create_pty, read_process_output): |
8099 | (exec_sentinel): Remove vars that were set but not used. | |
afd4052b | 8100 | (create_pty): Remove unnecessary "volatile"s. |
bc57d757 | 8101 | (Fnetwork_interface_info): Avoid possibility of int overflow. |
82eaa333 | 8102 | (read_process_output): Do adaptive read buffering even if carryover. |
fe07cdfa | 8103 | (read_process_output): Simplify nbytes computation if buffered. |
aba7731a | 8104 | |
fdfc4bf3 PE |
8105 | * bytecode.c (exec_byte_code): Rename local to avoid shadowing. |
8106 | ||
fca8fe46 | 8107 | * syntax.c (scan_words): Remove var that was set but not used. |
12cbf13f | 8108 | (update_syntax_table): Use unsigned instead of int. |
fca8fe46 | 8109 | |
06a0259a | 8110 | * lread.c (lisp_file_lexically_bound_p): Use ints rather than endptrs. |
3c346cc3 | 8111 | (lisp_file_lexically_bound_p, read1): Use unsigned instead of int. |
e6eb4e9e | 8112 | (safe_to_load_p): Make the end-of-loop test the inverse of the in-loop. |
06a0259a | 8113 | |
e7b9e80f PE |
8114 | * print.c (print_error_message): Avoid int overflow. |
8115 | ||
56201685 PE |
8116 | * font.c (font_list_entities): Redo for clarity, |
8117 | so that reader need not know FONT_DPI_INDEX + 1 == FONT_SPACING_INDEX. | |
8118 | ||
78834453 | 8119 | * font.c (font_find_for_lface, Ffont_get_glyphs): Remove unused vars. |
790771b1 | 8120 | (font_score): Avoid potential overflow in diff calculation. |
78834453 | 8121 | |
0bc0b309 | 8122 | * fns.c (substring_both): Remove var that is set but not used. |
8cd55cb4 | 8123 | (sxhash): Redo loop for clarity and to avoid wraparound warning. |
0bc0b309 | 8124 | |
e610eaca PE |
8125 | * eval.c (funcall_lambda): Rename local to avoid shadowing. |
8126 | ||
b895abce PE |
8127 | * alloc.c (mark_object_loop_halt, mark_object): Use size_t, not int. |
8128 | Otherwise, GCC 4.6.0 optimizes the loop check away since the check | |
8129 | can always succeed if overflow has undefined behavior. | |
8130 | ||
1f1d9321 | 8131 | * search.c (boyer_moore, wordify): Remove vars set but not used. |
6f076cc7 | 8132 | (wordify): Omit three unnecessary tests. |
1f1d9321 | 8133 | |
c59478bc PE |
8134 | * indent.c (MULTIBYTE_BYTES_WIDTH): Don't compute wide_column. |
8135 | All callers changed. This avoids the need for an unused var. | |
8136 | ||
79b73827 PE |
8137 | * casefiddle.c (casify_region): Remove var that is set but not used. |
8138 | ||
a4db5dfe PE |
8139 | * dired.c (file_name_completion): Remove var that is set but not used. |
8140 | ||
43aae36e PE |
8141 | * fileio.c (Finsert_file_contents): Make EOF condition clearer. |
8142 | ||
2a47c44d | 8143 | * fileio.c (Finsert_file_contents): Avoid signed integer overflow. |
163c5f32 | 8144 | (Finsert_file_contents): Remove unnecessary code checking fd. |
2a47c44d | 8145 | |
a37c69bf PE |
8146 | * minibuf.c (read_minibuf_noninteractive): Use size_t for sizes. |
8147 | Check for integer overflow on size calculations. | |
8148 | ||
328ab8e7 PE |
8149 | * buffer.c (Fprevious_overlay_change): Remove var that is set |
8150 | but not used. | |
8151 | ||
e5a2a5cb PE |
8152 | * keyboard.c (menu_bar_items, read_char_minibuf_menu_prompt): |
8153 | Remove vars that are set but not used. | |
8d84a6eb | 8154 | (timer_check_2): Don't assume timer-list and idle-timer-list are lists. |
6b043475 | 8155 | (timer_check_2): Mark vars as initialized. |
e5a2a5cb | 8156 | |
a60e5f68 PE |
8157 | * gtkutil.c (xg_get_file_with_chooser): Mark var as initialized. |
8158 | ||
f661cb61 | 8159 | * image.c (lookup_image): Remove var that is set but not used. |
35fa624f | 8160 | (xbm_load): Use parse_p, for gcc -Werror=unused-but-set-variable. |
f661cb61 | 8161 | |
f0397f5a PE |
8162 | * fontset.c (Finternal_char_font, Ffontset_info): Remove vars |
8163 | that are set but not used. | |
8164 | ||
8664db06 | 8165 | * xfns.c (make_invisible_cursor): Don't return garbage |
03733ee7 | 8166 | if XCreateBitmapFromData fails (Bug#8410). |
8664db06 | 8167 | |
6abdaa4a PE |
8168 | * xselect.c (x_get_local_selection, x_handle_property_notify): |
8169 | Remove vars that are set but not used. | |
8170 | ||
0ce7538d | 8171 | * xfns.c (x_create_tip_frame): Remove var that is set but not used. |
6abdaa4a | 8172 | (make_invisible_cursor): Initialize a possibly-uninitialized variable. |
0ce7538d | 8173 | |
9ae848fc PE |
8174 | * xterm.c (x_scroll_bar_to_input_event) [!USE_GTK]: |
8175 | Remove var that is set but not used. | |
0b918413 PE |
8176 | (scroll_bar_windows_size): Now size_t, not int. |
8177 | (x_send_scroll_bar_event): Use size_t, not int, for sizes. | |
8178 | Check for overflow. | |
9ae848fc | 8179 | |
a5a62657 PE |
8180 | * xfaces.c (realize_named_face): Remove vars that are set but not used. |
8181 | (map_tty_color) [!defined MSDOS]: Likewise. | |
8182 | ||
5c5cdd39 PE |
8183 | * term.c (tty_write_glyphs): Use size_t; this avoids overflow warning. |
8184 | ||
66ebf983 PE |
8185 | * coding.c: Remove vars that are set but not used. |
8186 | (DECODE_COMPOSITION_RULE): Remove 2nd arg, which is unused. | |
8187 | All callers changed. | |
8188 | (decode_coding_utf_8, decode_coding_utf_16 decode_coding_emacs_mule): | |
8189 | (decode_coding_iso_2022, encode_coding_sjis, encode_coding_big5): | |
8190 | (decode_coding_charset): Remove vars that are set but not used. | |
8191 | ||
1be4d761 PE |
8192 | * bytecode.c (Fbyte_code) [!defined BYTE_CODE_SAFE]: Remove var |
8193 | that is set but not used. | |
8194 | ||
47553fa8 PE |
8195 | * print.c (print_object): Remove var that is set but not used. |
8196 | ||
1f7196bf | 8197 | Replace 2 copies of readlink code with 1 gnulib version (Bug#8401). |
d1fdcab7 PE |
8198 | The gnulib version avoids calling malloc in the usual case, |
8199 | and on 64-bit hosts doesn't have some arbitrary 32-bit limits. | |
8200 | * fileio.c (Ffile_symlink_p): Use emacs_readlink. | |
8201 | * filelock.c (current_lock_owner): Likewise. | |
8202 | * lisp.h (READLINK_BUFSIZE, emacs_readlink): New function. | |
8203 | * sysdep.c: Include allocator.h, careadlinkat.h. | |
8204 | (emacs_no_realloc_allocator): New static constant. | |
8205 | (emacs_readlink): New function. | |
fdb61804 PE |
8206 | * deps.mk (sysdep.o): Depend on ../lib/allocator.h and on |
8207 | ../lib/careadlinkat.h. | |
d1fdcab7 | 8208 | |
f84c17c7 SM |
8209 | 2011-04-04 Stefan Monnier <monnier@iro.umontreal.ca> |
8210 | ||
8211 | * keyboard.c (safe_run_hook_funcall): Fix last change (don't stop at the | |
8212 | first non-nil return value). | |
8213 | ||
ef3862ad JD |
8214 | 2011-04-03 Jan Djärv <jan.h.d@swipnet.se> |
8215 | ||
8216 | * nsterm.m (ns_update_auto_hide_menu_bar): Define MAC_OS_X_VERSION_10_6 | |
8217 | if not defined (Bug#8403). | |
8218 | ||
376a7006 JB |
8219 | 2011-04-02 Juanma Barranquero <lekktu@gmail.com> |
8220 | ||
8221 | * xdisp.c (display_count_lines): Remove parameter `start', | |
8222 | unused since 1998-01-01T02:27:27Z!rms@gnu.org. All callers changed. | |
8223 | (get_char_face_and_encoding): Remove parameter `multibyte_p', | |
8224 | unused since 2008-05-14T01:40:23Z!handa@m17n.org. All callers changed. | |
8225 | (fill_stretch_glyph_string): Remove parameters `row' and `area', | |
8226 | unused at least since Kim's GUI unification at 2003-03-16T20:45:46Z!storm@cua.dk | |
8227 | and thereabouts. All callers changed. | |
8228 | (get_per_char_metric): Remove parameter `f', unused since | |
8229 | 2008-05-14T01:40:23Z!handa@m17n.org. All callers changed. | |
8230 | ||
6ca3801d JM |
8231 | 2011-04-02 Jim Meyering <meyering@redhat.com> |
8232 | ||
8233 | do not dereference NULL upon failed strdup | |
8234 | * nsfont.m (ns_descriptor_to_entity): Use xstrdup, not strdup. | |
8235 | (ns_get_family): Likewise. | |
8236 | ||
d8e2b5ba JB |
8237 | 2011-04-02 Juanma Barranquero <lekktu@gmail.com> |
8238 | ||
8239 | * eval.c (unwind_to_catch) [DEBUG_GCPRO]: Remove redundant assignment. | |
8240 | ||
8c74fcbd JD |
8241 | 2011-04-02 Jan Djärv <jan.h.d@swipnet.se> |
8242 | ||
8243 | * nsterm.m (ns_update_auto_hide_menu_bar): Only for OSX 10.6 or | |
8244 | later (Bug#8403). | |
8245 | ||
7200d79c SM |
8246 | 2011-04-01 Stefan Monnier <monnier@iro.umontreal.ca> |
8247 | ||
03408648 | 8248 | Add lexical binding. |
7200d79c | 8249 | |
03408648 SM |
8250 | * window.c (Ftemp_output_buffer_show): New fun. |
8251 | (Fsave_window_excursion): | |
8252 | * print.c (Fwith_output_to_temp_buffer): Move to subr.el. | |
8253 | ||
8254 | * lread.c (lisp_file_lexically_bound_p): New function. | |
8255 | (Fload): Bind Qlexical_binding. | |
8256 | (readevalloop): Remove `evalfun' arg. | |
8257 | Bind Qinternal_interpreter_environment. | |
8258 | (Feval_buffer): Bind Qlexical_binding. | |
8259 | (defvar_int, defvar_bool, defvar_lisp_nopro, defvar_kboard): | |
8260 | Mark as dynamic. | |
8261 | (syms_of_lread): Declare `lexical-binding'. | |
8262 | ||
8263 | * lisp.h (struct Lisp_Symbol): New field `declared_special'. | |
8264 | ||
8265 | * keyboard.c (eval_dyn): New fun. | |
8266 | (menu_item_eval_property): Use it. | |
ca105506 SM |
8267 | |
8268 | * image.c (parse_image_spec): Use Ffunctionp. | |
ca105506 | 8269 | |
03408648 SM |
8270 | * fns.c (concat, mapcar1): Accept byte-code-functions. |
8271 | ||
8272 | * eval.c (Fsetq): Handle lexical vars. | |
8273 | (Fdefun, Fdefmacro, Ffunction): Make closures when needed. | |
8274 | (Fdefconst, Fdefvaralias, Fdefvar): Mark as dynamic. | |
8275 | (FletX, Flet): Obey lexical binding. | |
8276 | (Fcommandp): Handle closures. | |
8277 | (Feval): New `lexical' arg. | |
8278 | (eval_sub): New function extracted from Feval. Use it almost | |
8279 | everywhere where Feval was used. Look up vars in lexical env. | |
8280 | Handle closures. | |
8281 | (Ffunctionp): Move from subr.el. | |
8282 | (Ffuncall): Handle closures. | |
8283 | (apply_lambda): Remove `eval_flags'. | |
8284 | (funcall_lambda): Handle closures and new byte-code-functions. | |
8285 | (Fspecial_variable_p): New function. | |
8286 | (syms_of_eval): Initialize the Vinternal_interpreter_environment var, | |
8287 | but without exporting it to Lisp. | |
23aba0ea | 8288 | |
23aba0ea | 8289 | * doc.c (Fdocumentation, store_function_docstring): |
03408648 | 8290 | * data.c (Finteractive_form): Handle closures. |
23aba0ea | 8291 | |
03408648 SM |
8292 | * callint.c (Fcall_interactively): Preserve lexical-binding mode for |
8293 | interactive spec. | |
ba83908c | 8294 | |
04f2d78b CB |
8295 | * bytecode.c (Bstack_ref, Bstack_set, Bstack_set2, BdiscardN): |
8296 | New byte-codes. | |
03408648 SM |
8297 | (exec_byte_code): New function extracted from Fbyte_code to handle new |
8298 | calling convention for byte-code-functions. Add new byte-codes. | |
ba83908c | 8299 | |
03408648 | 8300 | * buffer.c (defvar_per_buffer): Set new `declared_special' field. |
e2abe5a1 | 8301 | |
03408648 | 8302 | * alloc.c (Fmake_symbol): Init new `declared_special' field. |
e2abe5a1 | 8303 | |
e2abce01 JB |
8304 | 2011-03-31 Juanma Barranquero <lekktu@gmail.com> |
8305 | ||
8306 | * xdisp.c (redisplay_internal): Fix prototype. | |
8307 | ||
63696a73 | 8308 | 2011-03-31 Eli Zaretskii <eliz@gnu.org> |
09725d26 | 8309 | |
63696a73 | 8310 | * xdisp.c (SCROLL_LIMIT): New macro. |
04f2d78b CB |
8311 | (try_scrolling): Use it when setting scroll_limit. |
8312 | Limit scrolling to 100 screen lines. | |
63696a73 EZ |
8313 | (redisplay_window): Even when falling back on "recentering", |
8314 | position point in the window according to scroll-conservatively, | |
8315 | scroll-margin, and scroll-*-aggressively variables. (Bug#6671) | |
8316 | ||
8317 | (try_scrolling): When point is above the window, allow searching | |
8318 | as far as scroll_max, or one screenful, to compute vertical | |
8319 | distance from PT to the scroll margin position. This prevents | |
8320 | try_scrolling from unnecessarily failing when | |
8321 | scroll-conservatively is set to a value slightly larger than the | |
8322 | window height. Clean up the case of PT below the margin at bottom | |
8323 | of window: scroll_max can no longer be INT_MAX. When aggressive | |
8324 | scrolling is in use, don't let point enter the opposite scroll | |
8325 | margin as result of the scroll. | |
8326 | (syms_of_xdisp) <scroll-conservatively>: Document the | |
09725d26 EZ |
8327 | threshold of 100 lines for never-recentering scrolling. |
8328 | ||
e4cc2dfc JB |
8329 | 2011-03-31 Juanma Barranquero <lekktu@gmail.com> |
8330 | ||
8331 | * dispextern.h (move_it_by_lines): | |
8332 | * xdisp.c (move_it_by_lines): Remove parameter `need_y_p', unused | |
8333 | since 2000-12-29T14:24:09Z!gerd@gnu.org. All callers changed. | |
8334 | (message_log_check_duplicate): Remove parameters `prev_bol' and | |
8335 | `this_bol', unused since 1998-01-01T02:27:27Z!rms@gnu.org. All callers changed. | |
8336 | (redisplay_internal): Remove parameter `preserve_echo_area', | |
8337 | unused since 1999-07-21T21:43:52Z!gerd@gnu.org. All callers changed. | |
8338 | ||
8339 | * indent.c (Fvertical_motion): | |
8340 | * window.c (window_scroll_pixel_based, Frecenter): | |
8341 | Don't pass `need_y_p' to `move_it_by_lines'. | |
8342 | ||
1c470562 SM |
8343 | 2011-03-30 Stefan Monnier <monnier@iro.umontreal.ca> |
8344 | ||
44f230aa SM |
8345 | * eval.c (struct backtrace): Don't cheat with negative numbers, but do |
8346 | steal a few bits to be more compact. | |
8347 | (interactive_p, Fbacktrace, Fbacktrace_frame, mark_backtrace): | |
8348 | Remove unneeded casts. | |
8349 | ||
1c470562 SM |
8350 | * bytecode.c (Fbyte_code): CAR and CDR can GC. |
8351 | ||
888adce9 ZK |
8352 | 2011-03-30 Zachary Kanfer <zkanfer@gmail.com> (tiny change) |
8353 | ||
8354 | * keyboard.c (Fexecute_extended_command): Do log the "suggest key | |
8355 | binding" message (bug#7967). | |
8356 | ||
f838ed7b PE |
8357 | 2011-03-30 Paul Eggert <eggert@cs.ucla.edu> |
8358 | ||
77861b95 PE |
8359 | Fix more problems found by GCC 4.6.0's static checks. |
8360 | ||
de6dbc14 PE |
8361 | * unexelf.c (unexec) [! (defined _SYSTYPE_SYSV || defined __sgi)]: |
8362 | Remove unused local var. | |
8363 | ||
f838ed7b PE |
8364 | * editfns.c (Fmessage_box): Remove unused local var. |
8365 | ||
792c7b2b PE |
8366 | * xdisp.c (try_window_reusing_current_matrix, x_produce_glyphs): |
8367 | (note_mode_line_or_margin_highlight, note_mouse_highlight): | |
8368 | Omit unused local vars. | |
c499e557 | 8369 | * window.c (shrink_windows): Omit unused local var. |
b01a1c29 | 8370 | * menu.c (digest_single_submenu): Omit unused local var. |
0bc32927 PE |
8371 | * dispnew.c (update_window) [PERIODIC_PREEMPTION_CHECKING]: |
8372 | Omit unused local var. | |
8373 | ||
ba0165e1 PE |
8374 | * keyboard.c (parse_modifiers_uncached, parse_modifiers): |
8375 | Don't assume string length fits in int. | |
32ad8845 | 8376 | (keyremap_step, read_key_sequence): Use size_t for sizes. |
48011560 | 8377 | (read_key_sequence): Don't check last_real_key_start redundantly. |
ba0165e1 | 8378 | |
3c59b4c9 PE |
8379 | * callproc.c (Fcall_process, Fcall_process_region): Use SAFE_ALLOCA |
8380 | instead of alloca (Bug#8344). | |
8381 | ||
a3eed478 | 8382 | * eval.c (Fbacktrace): Don't assume nargs fits in int. |
5d5d959d | 8383 | (Fbacktrace_frame): Don't assume nframes fits in int. |
a3eed478 | 8384 | |
eb4d412d PE |
8385 | * syntax.c (scan_sexps_forward): Avoid pointer wraparound. |
8386 | ||
1658b401 PE |
8387 | * xterm.c (x_make_frame_visible, same_x_server): Redo to avoid overflow |
8388 | concerns. | |
8389 | ||
8390 | * term.c (produce_glyphless_glyph): Remove unnecessary test. | |
8391 | ||
8392 | * cm.c (calccost): Turn while-do into do-while, for clarity. | |
44f730c8 | 8393 | |
9a2c6e05 PE |
8394 | * keyboard.c (syms_of_keyboard): Use the same style as later |
8395 | in this function when indexing through an array. This also | |
8396 | works around GCC bug 48267. | |
8397 | ||
03d0a109 PE |
8398 | * image.c (tiff_load): Fix off-by-one image count (Bug#8336). |
8399 | ||
44f730c8 PE |
8400 | * xselect.c (x_check_property_data): Return correct size (Bug#8335). |
8401 | ||
fe75f926 PE |
8402 | * chartab.c (sub_char_table_ref_and_range): Redo for slight |
8403 | efficiency gain, and to bypass a gcc -Wstrict-overflow warning. | |
8404 | ||
ffa8c828 PE |
8405 | * keyboard.c, keyboard.h (num_input_events): Now size_t. |
8406 | This avoids undefined behavior on integer overflow, and is a bit | |
8407 | more convenient anyway since it is compared to a size_t variable. | |
8408 | ||
c5101a77 PE |
8409 | Variadic C functions now count arguments with size_t, not int. |
8410 | This avoids an unnecessary limitation on 64-bit machines, which | |
8411 | caused (substring ...) to crash on large vectors (Bug#8344). | |
8412 | * lisp.h (struct Lisp_Subr.function.aMANY): Now takes size_t, not int. | |
8413 | (DEFUN_ARGS_MANY, internal_condition_case_n, safe_call): Likewise. | |
77861b95 | 8414 | All variadic functions and their callers changed accordingly. |
c5101a77 PE |
8415 | (struct gcpro.nvars): Now size_t, not int. All uses changed. |
8416 | * data.c (arith_driver, float_arith_driver): Likewise. | |
8417 | * editfns.c (general_insert_function): Likewise. | |
8418 | * eval.c (struct backtrace.nargs, interactive_p) | |
8419 | (internal_condition_case_n, run_hook_with_args, apply_lambda) | |
8420 | (funcall_lambda, mark_backtrace): Likewise. | |
8421 | * fns.c (concat): Likewise. | |
8422 | * frame.c (x_set_frame_parameters): Likewise. | |
8423 | * fns.c (get_key_arg): Now accepts and returns size_t, and returns | |
8424 | 0 if not found, not -1. All callers changed. | |
8425 | ||
dd3f25f7 PE |
8426 | * alloc.c (garbage_collect): Don't assume stack size fits in int. |
8427 | (stack_copy_size): Now size_t, not int. | |
8428 | (stack_copy, stack_copy_size): Define only if MAX_SAVE_STACK > 0. | |
8429 | ||
461c2ab9 JB |
8430 | 2011-03-28 Juanma Barranquero <lekktu@gmail.com> |
8431 | ||
8432 | * coding.c (encode_designation_at_bol): Remove parameter `charbuf_end', | |
8433 | unused since 2002-03-01T01:17:24Z!handa@m17n.org and 2008-02-01T16:01:31Z!miles@gnu.org. | |
8434 | All callers changed. | |
8435 | ||
8436 | * lisp.h (multibyte_char_to_unibyte): | |
8437 | * character.c (multibyte_char_to_unibyte): Remove parameter `rev_tbl', | |
8438 | unused since 2002-03-01T01:16:34Z!handa@m17n.org and 2008-02-01T16:01:31Z!miles@gnu.org. | |
8439 | * character.h (CHAR_TO_BYTE8): | |
8440 | * cmds.c (internal_self_insert): | |
8441 | * editfns.c (general_insert_function): | |
8442 | * keymap.c (push_key_description): | |
8443 | * search.c (Freplace_match): | |
8444 | * xdisp.c (message_dolog, set_message_1): All callers changed. | |
8445 | ||
f6d62986 SM |
8446 | 2011-03-28 Stefan Monnier <monnier@iro.umontreal.ca> |
8447 | ||
8448 | * keyboard.c (safe_run_hook_funcall): New function. | |
8449 | (safe_run_hooks_1, safe_run_hooks_error, safe_run_hooks): On error, | |
8450 | don't set the hook to nil, but remove the offending function instead. | |
8451 | (Qcommand_hook_internal): Remove, unused. | |
8452 | (syms_of_keyboard): Don't initialize Qcommand_hook_internal nor define | |
8453 | Vcommand_hook_internal. | |
8454 | ||
8455 | * eval.c (enum run_hooks_condition): Remove. | |
8456 | (funcall_nil, funcall_not): New functions. | |
8457 | (run_hook_with_args): Call each function through a `funcall' argument. | |
8458 | Remove `cond' argument, now redundant. | |
8459 | (Frun_hooks, Frun_hook_with_args, Frun_hook_with_args_until_success) | |
8460 | (Frun_hook_with_args_until_failure): Adjust accordingly. | |
8461 | (run_hook_wrapped_funcall, Frun_hook_wrapped): New functions. | |
8462 | ||
1db5b1ad JB |
8463 | 2011-03-28 Juanma Barranquero <lekktu@gmail.com> |
8464 | ||
8465 | * dispextern.h (string_buffer_position): Remove declaration. | |
8466 | ||
8467 | * print.c (strout): Remove parameter `multibyte', unused since | |
8468 | 1999-08-21T19:30:21Z!gerd@gnu.org. All callers changed. | |
8469 | ||
8470 | * search.c (boyer_moore): Remove parameters `len', `pos' and `lim', | |
8471 | never used since function introduction in 1998-02-08T21:33:56Z!rms@gnu.org. | |
8472 | All callers changed. | |
8473 | ||
8474 | * w32.c (_wsa_errlist): Use braces for struct initializers. | |
8475 | ||
8476 | * xdisp.c (string_buffer_position_lim): Remove parameter `w', | |
8477 | never used since function introduction in 2001-03-09T18:41:50Z!gerd@gnu.org. | |
8478 | All callers changed. | |
8479 | (string_buffer_position): Likewise. Also, make static (it's never | |
8480 | used outside xdisp.c). | |
8481 | (cursor_row_p): Remove parameter `w', unused since | |
8482 | 2000-10-17T16:08:57Z!gerd@gnu.org. All callers changed. | |
8483 | (decode_mode_spec): Remove parameter `precision', introduced during | |
8484 | Gerd Moellmann's rewrite at 1999-07-21T21:43:52Z!gerd@gnu.org, but never used. | |
8485 | All callers changed. | |
8486 | ||
5ffb62aa JD |
8487 | 2011-03-27 Jan Djärv <jan.h.d@swipnet.se> |
8488 | ||
8489 | * nsterm.m (syms_of_nsterm): Use doc: for ns-auto-hide-menu-bar. | |
8490 | ||
461c2ab9 | 8491 | 2011-03-27 Anders Lindgren <andlind@gmail.com> |
f0a1382a JD |
8492 | |
8493 | * nsterm.m (ns_menu_bar_is_hidden): New variable. | |
8494 | (ns_constrain_all_frames, ns_menu_bar_should_be_hidden) | |
8495 | (ns_update_auto_hide_menu_bar): New functions. | |
8496 | (ns_update_begin): Call ns_update_auto_hide_menu_bar. | |
8497 | (applicationDidBecomeActive): Call ns_update_auto_hide_menu_bar and | |
8498 | ns_constrain_all_frames. | |
8499 | (constrainFrameRect): Return at once if ns_menu_bar_should_be_hidden. | |
8500 | (syms_of_nsterm): DEFVAR ns-auto-hide-menu-bar, init to Qnil. | |
8501 | ||
5c380ffb JD |
8502 | 2011-03-27 Jan Djärv <jan.h.d@swipnet.se> |
8503 | ||
8504 | * nsmenu.m (runDialogAt): Remove argument to timer_check. | |
8505 | ||
9af30bdf GM |
8506 | 2011-03-27 Glenn Morris <rgm@gnu.org> |
8507 | ||
8508 | * syssignal.h: Replace RETSIGTYPE with void. | |
8509 | * atimer.c, data.c, dispnew.c, emacs.c, floatfns.c, keyboard.c: | |
8510 | * keyboard.h, lisp.h, process.c, sysdep.c, xterm.c: | |
8511 | Replace SIGTYPE with void everywhere. | |
8512 | * s/usg5-4-common.h (SIGTYPE): Remove definition. | |
8513 | * s/template.h (SIGTYPE): Remove commented out definition. | |
8514 | ||
e2abce01 JB |
8515 | 2011-03-26 Eli Zaretskii <eliz@gnu.org> |
8516 | ||
8517 | * xdisp.c (redisplay_window): Don't check buffer's clip_changed | |
8518 | flag as a prerequisite for invoking try_scrolling. (Bug#6671) | |
8519 | ||
f868cd8a JB |
8520 | 2011-03-26 Juanma Barranquero <lekktu@gmail.com> |
8521 | ||
59eb0929 JB |
8522 | * w32.c (read_unc_volume): Use parameter `henum', instead of |
8523 | global variable `wget_enum_handle'. | |
8524 | ||
8525 | * keymap.c (describe_vector): Remove parameters `indices' and | |
8526 | `char_table_depth', unused since 2002-03-01T01:43:26Z!handa@m17n.org. | |
8527 | (describe_map, Fdescribe_vector): Adjust calls to `describe_vector'. | |
8528 | ||
f868cd8a JB |
8529 | * keyboard.h (timer_check, show_help_echo): Remove unused parameters. |
8530 | ||
8531 | * keyboard.c (timer_check): Remove parameter `do_it_now', | |
8532 | unused since 1996-04-12T06:01:29Z!rms@gnu.org. | |
8533 | (show_help_echo): Remove parameter `ok_to_overwrite_keystroke_echo', | |
8534 | unused since 2008-04-19T19:30:53Z!monnier@iro.umontreal.ca. | |
8535 | ||
8536 | * keyboard.c (read_char): | |
8537 | * w32menu.c (w32_menu_display_help): | |
8538 | * xmenu.c (show_help_event, menu_help_callback): | |
8539 | Adjust calls to `show_help_echo'. | |
8540 | ||
8541 | * gtkutil.c (xg_maybe_add_timer): | |
8542 | * keyboard.c (readable_events): | |
8543 | * process.c (wait_reading_process_output): | |
8544 | * xmenu.c (x_menu_wait_for_event): Adjust calls to `timer_check'. | |
8545 | ||
8546 | * insdel.c (adjust_markers_gap_motion): | |
8547 | Remove; no-op since 1998-01-02T21:29:48Z!rms@gnu.org. | |
8548 | (gap_left, gap_right): Don't call it. | |
8549 | ||
2ecf6fdb CY |
8550 | 2011-03-25 Chong Yidong <cyd@stupidchicken.com> |
8551 | ||
8552 | * xdisp.c (handle_fontified_prop): Discard changes to clip_changed | |
8553 | incurred during fontification. | |
8554 | ||
6b1f9ba4 JB |
8555 | 2011-03-25 Juanma Barranquero <lekktu@gmail.com> |
8556 | ||
8557 | * buffer.c (defvar_per_buffer): Remove unused parameter `doc'. | |
8558 | (DEFVAR_PER_BUFFER): Don't pass it. | |
8559 | ||
8560 | * dispnew.c (row_equal_p, add_row_entry): Remove unused parameter `w'. | |
8561 | (scrolling_window): Don't pass it. | |
8562 | ||
0f4a96b5 JB |
8563 | 2011-03-25 Juanma Barranquero <lekktu@gmail.com> |
8564 | ||
8565 | * dispextern.h (glyph_matric): Use #if GLYPH_DEBUG, not #ifdef. | |
8566 | ||
8567 | * fileio.c (check_executable) [DOS_NT]: Remove unused variables `len' | |
8568 | and `suffix'. | |
8569 | (Fset_file_selinux_context) [HAVE_LIBSELINUX]: Move here declaration | |
8570 | of variables specific to SELinux and computation of `encoded_absname'. | |
8571 | ||
8572 | * image.c (XPutPixel): Remove unused variable `height'. | |
8573 | ||
8574 | * keyboard.c (make_lispy_event): Remove unused variable `hpos'. | |
8575 | ||
8576 | * unexw32.c (get_section_info): Remove unused variable `section'. | |
8577 | ||
8578 | * w32.c (stat): Remove unused variables `drive_root' and `devtype'. | |
8579 | (system_process_attributes): Remove unused variable `sess'. | |
8580 | (sys_read): Remove unused variable `err'. | |
8581 | ||
8582 | * w32fns.c (top): Wrap variables with #if GLYPH_DEBUG, not #ifdef. | |
8583 | (w32_wnd_proc): Remove unused variable `isdead'. | |
8584 | (unwind_create_frame): Use #if GLYPH_DEBUG, not #ifdef. | |
8585 | (Fx_server_max_request_size): Remove unused variable `dpyinfo'. | |
8586 | (x_create_tip_frame): Remove unused variable `tem'. | |
8587 | ||
8588 | * w32inevt.c (w32_console_read_socket): | |
8589 | Remove unused variable `no_events'. | |
8590 | ||
8591 | * w32term.c (x_draw_composite_glyph_string_foreground): | |
8592 | Remove unused variable `width'. | |
8593 | ||
1149507c JB |
8594 | 2011-03-24 Juanma Barranquero <lekktu@gmail.com> |
8595 | ||
8596 | * w32term.c (x_set_glyph_string_clipping): | |
8597 | Don't pass uninitialized region to CombineRgn. | |
8598 | ||
9c88f339 JB |
8599 | 2011-03-23 Juanma Barranquero <lekktu@gmail.com> |
8600 | ||
8601 | * w32fns.c (x_set_menu_bar_lines): Remove unused variable `olines'. | |
8602 | (w32_wnd_proc): Pass NULL to Windows API, not uninitialized buffer. | |
8603 | (Fx_close_connection): Remove unused variable `i'. | |
8604 | ||
8605 | * w32font.c (w32font_draw): Return number of glyphs. | |
8606 | (w32font_open_internal): Remove unused variable `i'. | |
8607 | (w32font_driver): Add missing initializer. | |
8608 | ||
8609 | * w32menu.c (utf8to16): Remove unused variable `utf16'. | |
8610 | (fill_in_menu): Remove unused variable `items_added'. | |
8611 | ||
8612 | * w32term.c (last_mouse_press_frame): Remove static global variable. | |
8613 | (w32_clip_to_row): Remove unused variable `f'. | |
8614 | (x_delete_terminal): Remove unused variable `i'. | |
8615 | ||
8616 | * w32uniscribe.c (uniscribe_shape): Remove unused variable `nclusters'. | |
8617 | (NOTHING): Remove unused static global variable. | |
8618 | (uniscribe_check_otf): Remove unused variable `table'. | |
8619 | (uniscribe_font_driver): Add missing initializers. | |
8620 | ||
dee091a3 JD |
8621 | 2011-03-23 Julien Danjou <julien@danjou.info> |
8622 | ||
8623 | * term.c (Fsuspend_tty, Fresume_tty): | |
8624 | * minibuf.c (read_minibuf, run_exit_minibuf_hook): | |
8625 | * window.c (temp_output_buffer_show): | |
8626 | * insdel.c (signal_before_change): | |
8627 | * frame.c (Fhandle_switch_frame): | |
8628 | * fileio.c (Fdo_auto_save): | |
8629 | * emacs.c (Fkill_emacs): | |
8630 | * editfns.c (save_excursion_restore): | |
8631 | * cmds.c (internal_self_insert): | |
8632 | * callint.c (Fcall_interactively): | |
8633 | * buffer.c (Fkill_all_local_variables): | |
8634 | * keyboard.c (Fcommand_execute, Fsuspend_emacs, safe_run_hooks_1): | |
8635 | Use Frun_hooks. | |
0f4a96b5 | 8636 | (command_loop_1): Use Frun_hooks. Call safe_run_hooks |
e9fce1ac | 8637 | unconditionally since it does the check itself. |
dee091a3 | 8638 | |
2c520ab5 | 8639 | 2011-03-23 Paul Eggert <eggert@cs.ucla.edu> |
f0641eff | 8640 | |
c9c49752 PE |
8641 | Fix more problems found by GCC 4.5.2's static checks. |
8642 | ||
8abc3f12 PE |
8643 | * coding.c (encode_coding_raw_text): Avoid unnecessary test |
8644 | the first time through the loop, since we know p0 < p1 then. | |
8645 | This also avoids a gcc -Wstrict-overflow warning. | |
8646 | ||
a2d26660 PE |
8647 | * lisp.h (SAFE_ALLOCA, SAFE_ALLOCA_LISP): Avoid 'int' overflow |
8648 | leading to a memory leak, possible in functions like | |
8649 | load_charset_map_from_file that can allocate an unbounded number | |
b12ef411 | 8650 | of objects (Bug#8318). |
a2d26660 | 8651 | |
916c72e9 PE |
8652 | * xmenu.c (set_frame_menubar): Use EMACS_UINT, not int, for indexes |
8653 | that could (at least in theory) be that large. | |
8654 | ||
19ab8a18 PE |
8655 | * xdisp.c (message_log_check_duplicate): Return unsigned long, not int. |
8656 | This is less likely to overflow, and avoids undefined behavior if | |
8657 | overflow does occur. All callers changed. Use strtoul to scan | |
8658 | for the unsigned long integer. | |
b7cbbd6f PE |
8659 | (pint2hrstr): Simplify and tune code slightly. |
8660 | This also avoids a (bogus) GCC warning with gcc -Wstrict-overflow. | |
19ab8a18 | 8661 | |
f0641eff PE |
8662 | * scroll.c (do_scrolling): Work around GCC bug 48228. |
8663 | See <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48228>. | |
8664 | ||
7f650bb9 PE |
8665 | * frame.c (Fmodify_frame_parameters): Simplify loop counter. |
8666 | This also avoids a warning with gcc -Wstrict-overflow. | |
39f5e519 PE |
8667 | (validate_x_resource_name): Simplify count usage. |
8668 | This also avoids a warning with gcc -Wstrict-overflow. | |
7f650bb9 | 8669 | |
37dd57d1 PE |
8670 | * fileio.c (Fcopy_file): Report error if fchown or fchmod |
8671 | fail (Bug#8306). | |
81e56e61 | 8672 | |
699979fc | 8673 | * emacs.c (Fdaemon_initialized): Do not ignore I/O errors (Bug#8303). |
dc1ca6a8 | 8674 | |
401bf9b4 PE |
8675 | * process.c (Fmake_network_process): Use socklen_t, not int, |
8676 | where POSIX says socklen_t is required in portable programs. | |
8677 | This fixes a porting bug on hosts like 64-bit HP-UX, where | |
591b2973 | 8678 | socklen_t is wider than int (Bug#8277). |
401bf9b4 PE |
8679 | (Fmake_network_process, server_accept_connection): |
8680 | (wait_reading_process_output, read_process_output): | |
8681 | Likewise. | |
8682 | ||
b93aacde PE |
8683 | * process.c: Rename or move locals to avoid shadowing. |
8684 | (list_processes_1, Fmake_network_process): | |
8685 | (read_process_output_error_handler, exec_sentinel_error_handler): | |
8686 | Rename or move locals. | |
4dc343ee | 8687 | (Fmake_network_process): Define label "retry_connect" only if needed. |
0da49335 | 8688 | (Fnetwork_interface_info): Fix pointer signedness. |
f990b4e5 | 8689 | (process_send_signal): Add cast to avoid pointer signedness problem. |
7b808126 | 8690 | (FIRST_PROC_DESC, IF_NON_BLOCKING_CONNECT): Remove unused macros. |
c939f91b | 8691 | (create_process): Use 'volatile' to avoid vfork clobbering (Bug#8298). |
b93aacde | 8692 | |
af8a867c | 8693 | Make tparam.h and terminfo.c consistent. |
44f230aa SM |
8694 | * cm.c (tputs, tgoto, BC, UP): Remove extern decls. |
8695 | Include tparam.h instead, since it declares them. | |
af8a867c PE |
8696 | * cm.h (PC): Remove extern decl; tparam.h now does this. |
8697 | * deps.mk (cm.o, terminfo.o): Depend on tparam.h. | |
8698 | * terminfo.c: Include tparam.h, to check interfaces. | |
8699 | (tparm): Make 1st arg a const pointer in decl. Put it at top level. | |
8700 | (tparam): Adjust signature to match interface in tparam.h; | |
8701 | this removes some undefined behavior. Check that outstring and len | |
8702 | are zero, which they always are with Emacs. | |
8703 | * tparam.h (PC, BC, UP): New extern decls. | |
8704 | ||
0248044d | 8705 | * xftfont.c (xftfont_shape): Now static, and defined only if needed. |
001a7ab4 | 8706 | (xftfont_open): Rename locals to avoid shadowing. |
0248044d | 8707 | |
8ff096c1 | 8708 | * ftfont.c (ftfont_resolve_generic_family): Fix pointer signedness. |
a00924bb PE |
8709 | (ftfont_otf_capability, ftfont_shape): Omit decls if not needed. |
8710 | (OTF_TAG_SYM): Omit macro if not needed. | |
e932860f | 8711 | (ftfont_list): Remove unused local. |
49eaafba PE |
8712 | (get_adstyle_property, ftfont_pattern_entity): |
8713 | (ftfont_lookup_cache, ftfont_open, ftfont_anchor_point): | |
8714 | Rename locals to avoid shadowing. | |
8ff096c1 | 8715 | |
e2be39f6 PE |
8716 | * xfont.c (xfont_list_family): Mark var as initialized. |
8717 | ||
c9735e30 PE |
8718 | * xml.c (make_dom): Now static. |
8719 | ||
8f5201ae PE |
8720 | * composite.c (composition_compute_stop_pos): Rename local to |
8721 | avoid shadowing. | |
b246f932 PE |
8722 | (composition_reseat_it): Remove unused locals. |
8723 | (find_automatic_composition, composition_adjust_point): Likewise. | |
80e079b2 | 8724 | (composition_update_it): Mark var as initialized. |
11b61122 PE |
8725 | (find_automatic_composition): Mark vars as initialized, |
8726 | with a FIXME (Bug#8290). | |
8f5201ae | 8727 | |
760fbc2c PE |
8728 | character.h: Rename locals to avoid shadowing. |
8729 | * character.h (PREV_CHAR_BOUNDARY, FETCH_STRING_CHAR_ADVANCE): | |
8730 | (FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE, FETCH_CHAR_ADVANCE): | |
8731 | (FETCH_CHAR_ADVANCE_NO_CHECK, INC_POS, DEC_POS, BUF_INC_POS): | |
8732 | (BUF_DEC_POS): Be more systematic about renaming local temporaries | |
8733 | to avoid shadowing. | |
8734 | ||
ff08eb85 PE |
8735 | * textprop.c (property_change_between_p): Remove; unused. |
8736 | ||
fc7bf025 PE |
8737 | * intervals.c (interval_start_pos): Now static. |
8738 | ||
235d7abc PE |
8739 | * intervals.h (CHECK_TOTAL_LENGTH): Avoid empty "else". |
8740 | ||
44f230aa SM |
8741 | * atimer.c (start_atimer, append_atimer_lists, set_alarm): |
8742 | Rename locals to avoid shadowing. | |
3e7d6594 | 8743 | |
50060332 PE |
8744 | * sound.c (wav_play, au_play, Fplay_sound_internal): |
8745 | Fix pointer signedness. | |
d01f234b | 8746 | (alsa_choose_format): Remove unused local var. |
c83b8872 PE |
8747 | (wav_play): Initialize a variable to 0, to prevent undefined |
8748 | behavior (Bug#8278). | |
50060332 | 8749 | |
c4fc4e30 PE |
8750 | * region-cache.c (insert_cache_boundary): Redo var to avoid shadowing. |
8751 | ||
918436ed PE |
8752 | * region-cache.h (pp_cache): New decl, for gcc -Wmissing-prototypes. |
8753 | ||
c939f91b PE |
8754 | * callproc.c (Fcall_process): Use 'volatile' to avoid vfork |
8755 | clobbering (Bug#8298). | |
b9c7f648 PE |
8756 | * sysdep.c (sys_subshell): Likewise. |
8757 | Previously, the sys_subshell 'volatile' was incorrectly IF_LINTted out. | |
7e9123a2 | 8758 | |
6bd8c144 PE |
8759 | * lisp.h (child_setup): Now NO_RETURN unless DOS_NT. |
8760 | This should get cleaned up, so that child_setup has the | |
8761 | same signature on all platforms. | |
8762 | ||
7710357c | 8763 | * callproc.c (call_process_cleanup): Now static. |
cb1d0ef7 | 8764 | (relocate_fd): Rename locals to avoid shadowing. |
7710357c | 8765 | |
c59da222 CY |
8766 | 2011-03-22 Chong Yidong <cyd@stupidchicken.com> |
8767 | ||
8768 | * xterm.c (x_clear_frame): Remove XClearWindow call. This appears | |
8769 | not to be necessary, and produces flickering. | |
8770 | ||
66b87493 GM |
8771 | 2011-03-20 Glenn Morris <rgm@gnu.org> |
8772 | ||
8773 | * config.in: Remove file. | |
8774 | ||
45b6f6d5 JB |
8775 | 2011-03-20 Juanma Barranquero <lekktu@gmail.com> |
8776 | ||
8777 | * minibuf.c (Vcompleting_read_function): Don't declare, global variables | |
8778 | are now in src/globals.h. | |
8779 | (syms_of_minibuf): Remove spurious & from previous change. | |
8780 | ||
cd394be1 | 8781 | 2011-03-20 Leo Liu <sdl.web@gmail.com> |
3ec03f7e LL |
8782 | |
8783 | * minibuf.c (completing-read-function): New variable. | |
8784 | (completing-read-default): Rename from completing-read. | |
8785 | (completing-read): Call completing-read-function. | |
8786 | ||
b14e3e21 CY |
8787 | 2011-03-19 Juanma Barranquero <lekktu@gmail.com> |
8788 | ||
8789 | * xfaces.c (Fx_load_color_file): | |
8790 | Read color file from absolute filename (bug#8250). | |
8791 | ||
f2b726e6 JB |
8792 | 2011-03-19 Juanma Barranquero <lekktu@gmail.com> |
8793 | ||
8794 | * makefile.w32-in: Update dependencies. | |
8795 | ||
09f6ff02 EZ |
8796 | 2011-03-17 Eli Zaretskii <eliz@gnu.org> |
8797 | ||
8798 | * makefile.w32-in ($(BLD)/unexw32.$(O)): Depend on $(SRC)/unexec.h. | |
8799 | ||
29a6015a PE |
8800 | 2011-03-17 Paul Eggert <eggert@cs.ucla.edu> |
8801 | ||
a3a6c54e PE |
8802 | Fix more problems found by GCC 4.5.2's static checks. |
8803 | ||
b766f867 PE |
8804 | * process.c (make_serial_process_unwind, send_process_trap): |
8805 | (sigchld_handler): Now static. | |
8806 | ||
be02381c PE |
8807 | * process.c (allocate_pty): Let PTY_ITERATION declare iteration vars. |
8808 | That way, the code declares only the vars that it needs. | |
8809 | * s/aix4-2.h (PTY_ITERATION): Declare iteration vars. | |
8810 | * s/cygwin.h (PTY_ITERATION): Likewise. | |
8811 | * s/darwin.h (PTY_ITERATION): Likewise. | |
8812 | * s/gnu-linux.h (PTY_ITERATION): Likewise. | |
8813 | ||
57048744 PE |
8814 | * s/irix6-5.h (PTY_OPEN): Declare stb, to loosen coupling. |
8815 | * process.c (allocate_pty): Don't declare stb unless it's needed. | |
8816 | ||
7914961c | 8817 | * bytecode.c (MAYBE_GC): Rewrite so as not to use empty "else". |
615f2d59 PE |
8818 | (CONSTANTLIM): Remove; unused. |
8819 | (METER_CODE, Bscan_buffer, Bread_char, Bset_mark): | |
8820 | Define only if needed. | |
7914961c | 8821 | |
b3967b18 PE |
8822 | * unexelf.c (unexec): Name an expression, |
8823 | to avoid gcc -Wbad-function-cast warning. | |
9ae71512 PE |
8824 | Use a different way to cause a compilation error if anyone uses |
8825 | n rather than nn, a way that does not involve shadowing. | |
73366a00 | 8826 | (ELF_BSS_SECTION_NAME, OLD_PROGRAM_H): Remove; unused. |
b3967b18 | 8827 | |
29a6015a PE |
8828 | * deps.mk (unexalpha.o): Remove; unused. |
8829 | ||
43cfc33e | 8830 | New file unexec.h, the (simple) interface for unexec (Bug#8267). |
7feda0d2 | 8831 | * unexec.h: New file. |
ce701a33 PE |
8832 | * deps.mk (emacs.o, unexaix.o, unexcw.o, unexcoff.o, unexelf.o): |
8833 | (unexhp9k800.o, unexmacosx.o, unexsol.o, unexw32.o): | |
8834 | Depend on unexec.h. | |
8835 | * emacs.c [!defined CANNOT_DUMP]: Include unexec.h. | |
8836 | * unexaix.c, unexcoff.c, unexcw.c, unexelf.c, unexhp9k800.c: | |
8837 | * unexmacosx.c, unexsol.c, unexw32.c: Include unexec.h. | |
381259ef | 8838 | Change as necessary to match prototype in unexec.h. |
ce701a33 | 8839 | |
01f44d5a PE |
8840 | * syntax.c (Fforward_comment, scan_lists): Rename locals to avoid |
8841 | shadowing. | |
4f63c6bb | 8842 | (back_comment, skip_chars): Mark vars as initialized. |
01f44d5a | 8843 | |
a6670b0b PE |
8844 | * character.h (FETCH_STRING_CHAR_ADVANCE_NO_CHECK, BUF_INC_POS): |
8845 | Rename locals to avoid shadowing. | |
8846 | ||
cef2010d | 8847 | * lread.c (read1): Rewrite so as not to use empty "else". |
0902fe45 | 8848 | (Fload, readevalloop, read1): Rename locals to avoid shadowing. |
cef2010d | 8849 | |
d4d7173a PE |
8850 | * print.c (Fredirect_debugging_output): Fix pointer signedess. |
8851 | ||
f08b802a PE |
8852 | * lisp.h (debug_output_compilation_hack): Add decl here, to avoid |
8853 | warning when compiling print.c. | |
8854 | ||
3ddb0639 PE |
8855 | * font.c (font_unparse_fcname): Abort in an "impossible" situation |
8856 | instead of using an uninitialized var. | |
5ad03b97 | 8857 | (font_sort_entities): Mark var as initialized. |
3ddb0639 | 8858 | |
170a2692 PE |
8859 | * character.h (FETCH_CHAR_ADVANCE): Rename locals to avoid shadowing. |
8860 | ||
e663c700 PE |
8861 | * font.c (font_unparse_xlfd): Don't mix pointers to variables with |
8862 | pointers to constants. | |
89bc529a | 8863 | (font_parse_fcname): Remove unused vars. |
7b81e2d0 | 8864 | (font_delete_unmatched): Now static. |
ea838e10 | 8865 | (font_get_spec): Remove; unused. |
13a547c6 PE |
8866 | (font_style_to_value, font_prop_validate_style, font_unparse_fcname): |
8867 | (font_update_drivers, Ffont_get_glyphs, font_add_log): | |
8868 | Rename or move locals to avoid shadowing. | |
e663c700 | 8869 | |
2a80c887 | 8870 | * fns.c (require_nesting_list, require_unwind): Now static. |
612f56df | 8871 | (Ffillarray): Rename locals to avoid shadowing. |
2a80c887 | 8872 | |
1384fa33 | 8873 | * floatfns.c (domain_error2): Define only if needed. |
a885e2ed | 8874 | (Ffrexp, Fldexp): Rename locals to avoid shadowing. |
1384fa33 | 8875 | |
8b2c52e9 PE |
8876 | * alloc.c (mark_backtrace): Move decl from here ... |
8877 | * lisp.h: ... to here, so that it can be checked. | |
8878 | ||
475545b5 | 8879 | * eval.c (call_debugger, do_debug_on_call, grow_specpdl): Now static. |
d28a2170 | 8880 | (Fdefvar): Rewrite so as not to use empty "else". |
cfcbfb1a PE |
8881 | (lisp_indirect_variable): Name an expression, |
8882 | to avoid gcc -Wbad-function-cast warning. | |
1faed8ae | 8883 | (Fdefvar): Rename locals to avoid shadowing. |
475545b5 | 8884 | |
b1349114 | 8885 | * callint.c (quotify_arg, quotify_args): Now static. |
a3e8cbda | 8886 | (Fcall_interactively): Rename locals to avoid shadowing. |
b0e80955 | 8887 | Use const pointer when appropriate. |
b1349114 | 8888 | |
a2928364 PE |
8889 | * lisp.h (get_system_name, get_operating_system_release): |
8890 | Move decls here, to check interfaces. | |
8891 | * process.c (get_operating_system_release): Move decl to lisp.h. | |
8892 | * xrdb.c (get_system_name): Likewise. | |
63c5d10b PE |
8893 | * editfns.c (init_editfns, Fuser_login_name, Fuser_uid): |
8894 | (Fuser_real_uid, Fuser_full_name): Remove unnecessary casts, | |
8895 | some of which prompt warnings from gcc -Wbad-function-cast. | |
545b49b4 PE |
8896 | (Fformat_time_string, Fencode_time, Finsert_char): |
8897 | (Ftranslate_region_internal, Fformat): | |
8898 | Rename or remove local vars to avoid shadowing. | |
9710023e | 8899 | (Ftranslate_region_internal): Mark var as initialized. |
63c5d10b | 8900 | |
a415e694 PE |
8901 | * doc.c (Fdocumentation, Fsnarf_documentation): Move locals to |
8902 | avoid shadowing. | |
8903 | ||
8ef4622d PE |
8904 | * lisp.h (eassert): Check that the argument compiles, even if |
8905 | ENABLE_CHECKING is not defined. | |
8906 | ||
946f9a5b PE |
8907 | * data.c (Findirect_variable): Name an expression, to avoid |
8908 | gcc -Wbad-function-cast warning. | |
112396d6 | 8909 | (default_value, arithcompare, arith_driver, arith_error): Now static. |
b9b84fa9 | 8910 | (store_symval_forwarding): Rename local to avoid shadowing. |
44f230aa SM |
8911 | (Fmake_variable_buffer_local, Fmake_local_variable): |
8912 | Mark variables as initialized. | |
52746918 | 8913 | (do_blv_forwarding, do_symval_forwarding): Remove; unused. |
946f9a5b | 8914 | |
e5aab7e7 | 8915 | * alloc.c (check_cons_list): Do not define unless GC_CHECK_CONS_LIST. |
ae35e756 PE |
8916 | (Fmake_vector, Fvector, Fmake_byte_code, Fgarbage_collect): |
8917 | Rename locals to avoid shadowing. | |
dff45157 PE |
8918 | (mark_stack): Move local variables into the #ifdef region where |
8919 | they're used. | |
7bc26fdb PE |
8920 | (BLOCK_INPUT_ALLOC, UNBLOCK_INPUT_ALLOC): Define only if |
8921 | ! defined SYSTEM_MALLOC && ! defined SYNC_INPUT, as they are not | |
8922 | needed otherwise. | |
8923 | (CHECK_ALLOCATED): Define only if GC_CHECK_MARKED_OBJECTS. | |
8924 | (GC_STRING_CHARS): Remove; not used. | |
d40d4be1 | 8925 | (Fmemory_limit): Cast sbrk's returned value to char *. |
ae35e756 | 8926 | |
e5aab7e7 PE |
8927 | * lisp.h (check_cons_list): Declare if GC_CHECK_CONS_LIST; this |
8928 | avoids undefined behavior in theory. | |
8929 | ||
4da60324 PE |
8930 | * regex.c (IF_LINT): Add defn, for benefit of ../lib-src. |
8931 | ||
88043301 PE |
8932 | Use functions, not macros, for up- and down-casing (Bug#8254). |
8933 | * buffer.h (DOWNCASE_TABLE, UPCASE_TABLE, DOWNCASE, UPPERCASEP): | |
8934 | (NOCASEP, LOWERCASEP, UPCASE, UPCASE1): Remove. All callers changed | |
8935 | to use the following functions instead of these macros. | |
8936 | (downcase): Adjust to lack of DOWNCASE_TABLE. Return int, not | |
8937 | EMACS_INT, since callers assume the returned value fits in int. | |
8938 | (upcase1): Likewise, for UPCASE_TABLE. | |
8939 | (uppercasep, lowercasep, upcase): New static inline functions. | |
0da09c43 | 8940 | * editfns.c (Fchar_equal): Remove no-longer-needed workaround for |
db69b0cd | 8941 | the race-condition problem in the old DOWNCASE. |
88043301 | 8942 | |
19ed5445 PE |
8943 | * regex.c (CHARSET_LOOKUP_RANGE_TABLE_RAW, POP_FAILURE_REG_OR_COUNT): |
8944 | Rename locals to avoid shadowing. | |
8945 | (regex_compile, re_match_2_internal): Move locals to avoid shadowing. | |
abbd1bcf PE |
8946 | (regex_compile, re_search_2, re_match_2_internal): |
8947 | Remove unused local vars. | |
952db0d7 PE |
8948 | (FREE_VAR): Rewrite so as not to use empty "else", |
8949 | which gcc can warn about. | |
da053e48 | 8950 | (regex_compile, re_match_2_internal): Mark locals as initialized. |
b313f9d8 PE |
8951 | (RETALLOC_IF): Define only if needed. |
8952 | (WORDCHAR_P): Likewise. This one is never needed, but is used | |
8953 | only in a comment talking about a compiler bug, so put inside | |
8954 | the #if 0 of that comment. | |
8955 | (CHARSET_LOOKUP_BITMAP, FAIL_STACK_FULL, RESET_FAIL_STACK): | |
8956 | (PUSH_FAILURE_ELT, BUF_PUSH_3, STOP_ADDR_VSTRING): | |
8957 | Remove; unused. | |
19ed5445 | 8958 | |
1f3561e4 | 8959 | * search.c (boyer_moore): Rename locals to avoid shadowing. |
76ef09b7 PE |
8960 | * character.h (FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE): |
8961 | (PREV_CHAR_BOUNDARY): Likewise. | |
1f3561e4 | 8962 | |
ded6f8f7 PE |
8963 | * search.c (simple_search): Remove unused var. |
8964 | ||
dbd37a95 PE |
8965 | * dired.c (compile_pattern): Move decl from here ... |
8966 | * lisp.h: ... to here, so that it can be checked. | |
8967 | (struct re_registers): New forward decl. | |
8968 | ||
7e47afad PE |
8969 | * character.h (INC_POS, DEC_POS): Rename locals to avoid shadowing. |
8970 | ||
85f24f61 PE |
8971 | * indent.c (MULTIBYTE_BYTES_WIDTH): New args bytes, width. |
8972 | All uses changed. | |
8973 | (MULTIBYTE_BYTES_WIDTH, scan_for_column, compute_motion): | |
8974 | Rename locals to avoid shadowing. | |
5671df8f | 8975 | (Fvertical_motion): Mark locals as initialized. |
85f24f61 | 8976 | |
181aa2be | 8977 | * casefiddle.c (casify_object, casify_region): Now static. |
e45a141a | 8978 | (casify_region): Mark local as initialized. |
181aa2be | 8979 | |
930d429c PE |
8980 | * cmds.c (internal_self_insert): Rename local to avoid shadowing. |
8981 | ||
7082eac6 PE |
8982 | * lisp.h (GCPRO2_VAR, GCPRO3_VAR, GCPRO4_VAR, GCPRO5_VAR, GCPRO6_VAR): |
8983 | New macros, so that the caller can use some names other than | |
8984 | gcpro1, gcpro2, etc. | |
8985 | (GCPRO2, GCPRO3, GCPRO4, GCPRO5, GCPRO6): Reimplement in terms | |
8986 | of the new macros. | |
8987 | (GCPRO1_VAR, UNGCPRO_VAR): Change the meaning of the second | |
8988 | argument, for consistency with GCPRO2_VAR, etc: it is now the | |
8989 | prefix of the variable, not the variable itself. All uses | |
8990 | changed. | |
38b2c076 PE |
8991 | * dired.c (directory_files_internal, file_name_completion): |
8992 | Rename locals to avoid shadowing. | |
8993 | ||
15206ed9 PE |
8994 | Fix a race condition diagnosed by gcc -Wsequence-point (Bug#8254). |
8995 | An expression of the form (DOWNCASE (x) == DOWNCASE (y)), found in | |
8996 | dired.c's scmp function, had undefined behavior. | |
8997 | * lisp.h (DOWNCASE_TABLE, UPCASE_TABLE, DOWNCASE, UPPERCASEP): | |
8998 | (NOCASEP, LOWERCASEP, UPCASE, UPCASE1): Move from here ... | |
8999 | * buffer.h: ... to here, because these macros use current_buffer, | |
9000 | and the new implementation with inline functions needs to have | |
9001 | current_buffer in scope now, rather than later when the macros | |
9002 | are used. | |
9003 | (downcase, upcase1): New static inline functions. | |
9004 | (DOWNCASE, UPCASE1): Reimplement using these functions. | |
9005 | This avoids undefined behavior in expressions like | |
9006 | DOWNCASE (x) == DOWNCASE (y), which previously suffered | |
9007 | from race conditions in accessing the global variables | |
9008 | case_temp1 and case_temp2. | |
9009 | * casetab.c (case_temp1, case_temp2): Remove; no longer needed. | |
9010 | * lisp.h (case_temp1, case_temp2): Remove their decls. | |
9011 | * character.h (ASCII_CHAR_P): Move from here ... | |
9012 | * lisp.h: ... to here, so that the inline functions mentioned | |
9013 | above can use them. | |
9014 | ||
4a6bea26 PE |
9015 | * dired.c (directory_files_internal_unwind): Now static. |
9016 | ||
f14b7e14 PE |
9017 | * fileio.c (file_name_as_directory, directory_file_name): |
9018 | (barf_or_query_if_file_exists, auto_save_error, auto_save_1): | |
9019 | Now static. | |
2893f146 PE |
9020 | (file_name_as_directory): Use const pointers when appropriate. |
9021 | (Fexpand_file_name): Likewise. In particular, newdir might | |
9022 | point at constant storage, so make it a const pointer. | |
fd4ead52 | 9023 | (Fmake_directory_internal, Fread_file_name): Remove unused vars. |
b14aac08 PE |
9024 | (Ffile_selinux_context, Fset_file_selinux_context): Fix pointer |
9025 | signedness issues. | |
f839df0c PE |
9026 | (Fset_file_times, Finsert_file_contents, auto_save_error): |
9027 | Rename locals to avoid shadowing. | |
f14b7e14 | 9028 | |
5716756e | 9029 | * minibuf.c (choose_minibuf_frame_1): Now static. |
62137a95 PE |
9030 | (Ftry_completion, Fall_completions): Rename or remove locals |
9031 | to avoid shadowing. | |
5716756e | 9032 | |
b4c3046a PE |
9033 | * marker.c (bytepos_to_charpos): Remove; unused. |
9034 | ||
b45db522 PE |
9035 | * lisp.h (verify_bytepos, count_markers): New decls, |
9036 | so that gcc does not warn that these functions aren't declared. | |
9037 | ||
85876d07 PE |
9038 | * insdel.c (check_markers, make_gap_larger, make_gap_smaller): |
9039 | (reset_var_on_error, Fcombine_after_change_execute_1): Now static. | |
f0cb4a60 | 9040 | (CHECK_MARKERS): Redo to avoid gcc -Wempty-body diagnostic. |
40ef059e | 9041 | (copy_text): Remove unused local var. |
85876d07 | 9042 | |
03d78a21 | 9043 | * filelock.c (within_one_second): Now static. |
b3dd38ab | 9044 | (lock_file_1): Rename local to avoid shadowing. |
03d78a21 | 9045 | |
5df8f01b PE |
9046 | * buffer.c (fix_overlays_before): Mark locals as initialized. |
9047 | (fix_start_end_in_overlays): Likewise. This function should be | |
9048 | simplified by using pointers-to-pointers, but that's a different | |
9049 | matter. | |
b1d876f1 | 9050 | (switch_to_buffer_1): Now static. |
8f54f30a PE |
9051 | (Fkill_buffer, record_buffer, Fbury_buffer, Fset_buffer_multibyte): |
9052 | (report_overlay_modification): Rename locals to avoid shadowing. | |
c3bd59b5 | 9053 | |
a70072c9 | 9054 | * sysdep.c (system_process_attributes): Rename vars to avoid shadowing. |
fbd02d7b | 9055 | Fix pointer signedness issue. |
edced198 PE |
9056 | (sys_subshell): Mark local as volatile if checking for lint, |
9057 | to suppress a gcc -Wclobbered warning that does not seem to be right. | |
15dfd3d9 | 9058 | (MAXPATHLEN): Define only if needed. |
a70072c9 | 9059 | |
a0977c44 PE |
9060 | * process.c (serial_open, serial_configure): Move decls from here ... |
9061 | * systty.h: ... to here, so that they can be checked. | |
9062 | ||
a884fdcc PE |
9063 | * fns.c (get_random, seed_random): Move extern decls from here ... |
9064 | * lisp.h: ... to here, so that they can be checked. | |
9065 | ||
604efe86 | 9066 | * sysdep.c (reset_io): Now static. |
b8950c94 | 9067 | (wait_for_termination_signal): Remove; unused. |
604efe86 | 9068 | |
38fc62d9 PE |
9069 | * keymap.c (keymap_parent, keymap_memberp, map_keymap_internal): |
9070 | (copy_keymap_item, append_key, push_text_char_description): | |
9071 | Now static. | |
1004a21a | 9072 | (Fwhere_is_internal): Don't test CONSP (sequences) unnecessarily. |
dbbb8427 | 9073 | (DENSE_TABLE_SIZE): Remove; unused. |
c1141155 PE |
9074 | (get_keymap, access_keymap, Fdefine_key, Fwhere_is_internal): |
9075 | (describe_map_tree): | |
9076 | Rename locals to avoid shadowing. | |
38fc62d9 | 9077 | |
2f2650da PE |
9078 | * keyboard.c: Declare functions static if they are not used elsewhere. |
9079 | (echo_char, echo_dash, cmd_error, top_level_2): | |
9080 | (poll_for_input, handle_async_input): Now static. | |
69a058fa PE |
9081 | (read_char, kbd_buffer_get_event, make_lispy_position): |
9082 | (make_lispy_event, make_lispy_movement, apply_modifiers): | |
9083 | (decode_keyboard_code, tty_read_avail_input, menu_bar_items): | |
9084 | (parse_tool_bar_item, read_key_sequence, Fread_key_sequence): | |
9085 | (Fread_key_sequence_vector): Rename locals to avoid shadowing. | |
c8a06054 | 9086 | (read_key_sequence, read_char): Mark locals as initialized. |
3ac94672 | 9087 | (Fexit_recursive_edit, Fabort_recursive_edit): Mark with NO_RETURN. |
2f2650da | 9088 | |
a053e86c | 9089 | * keyboard.h (make_ctrl_char): New decl. |
da2f2dd9 PE |
9090 | (mark_kboards): Move decl here ... |
9091 | * alloc.c (mark_kboards): ... from here. | |
a053e86c | 9092 | |
4752793e PE |
9093 | * lisp.h (force_auto_save_soon): New decl. |
9094 | ||
74f10ca7 | 9095 | * emacs.c (init_cmdargs): Rename local to avoid shadowing. |
244fc23d PE |
9096 | (DEFINE_DUMMY_FUNCTION): New macro. |
9097 | (__do_global_ctors, __do_global_ctors_aux, __do_global_dtors, __main): | |
9098 | Use it. | |
c03cd23f PE |
9099 | (main): Add casts to avoid warnings |
9100 | if GCC considers string literals to be constants. | |
74f10ca7 | 9101 | |
022e70d4 PE |
9102 | * lisp.h (fatal_error_signal): Add decl, since it's exported. |
9103 | ||
59d6fe83 PE |
9104 | * dbusbind.c: Pointer signedness fixes. |
9105 | (xd_signature, xd_append_arg, xd_initialize): | |
9106 | (Fdbus_call_method, Fdbus_call_method_asynchronously): | |
9107 | (Fdbus_method_return_internal, Fdbus_method_error_internal): | |
9108 | (Fdbus_send_signal, xd_read_message_1, Fdbus_register_service): | |
9109 | (Fdbus_register_signal): Use SSDATA when the context wants char *. | |
9110 | ||
78320123 PE |
9111 | * dbusbind.c (Fdbus_init_bus): Add cast to avoid warning |
9112 | if GCC considers string literals to be constants. | |
49cebcca | 9113 | (Fdbus_register_service, Fdbus_register_method): Remove unused vars. |
78320123 | 9114 | |
35ac2a97 SM |
9115 | 2011-03-16 Stefan Monnier <monnier@iro.umontreal.ca> |
9116 | ||
fb103ca9 SM |
9117 | * print.c (PRINT_CIRCLE_CANDIDATE_P): New macro. |
9118 | (print_preprocess, print_object): New macro to fix last change. | |
9119 | ||
35ac2a97 SM |
9120 | * print.c (print_preprocess): Don't forget font objects. |
9121 | ||
62973b41 JB |
9122 | 2011-03-16 Juanma Barranquero <lekktu@gmail.com> |
9123 | ||
9124 | * emacs.c (USAGE3): Doc fixes. | |
9125 | ||
0e48bb22 AS |
9126 | 2011-03-15 Andreas Schwab <schwab@linux-m68k.org> |
9127 | ||
9128 | * coding.c (detect_coding_iso_2022): Reorganize code to clarify | |
9129 | structure. | |
9130 | ||
7684e57b JB |
9131 | 2011-03-14 Juanma Barranquero <lekktu@gmail.com> |
9132 | ||
9133 | * lisp.h (VWindow_system, Qfile_name_history): | |
9134 | * keyboard.h (lispy_function_keys) [WINDOWSNT]: | |
9135 | * w32term.h (w32_system_caret_hwnd, w32_system_caret_height) | |
9136 | (w32_system_caret_x, w32_system_caret_y): Declare extern. | |
9137 | ||
9138 | * w32select.c: Don't #include "keyboard.h". | |
c96bbc66 | 9139 | (run_protected): Add extern declaration for waiting_for_input. |
7684e57b JB |
9140 | |
9141 | * w32.c (Qlocal, noninteractive1, inhibit_window_system): | |
9142 | * w32console.c (detect_input_pending, read_input_pending) | |
9143 | (encode_terminal_code): | |
9144 | * w32fns.c (quit_char, lispy_function_keys, Qtooltip) | |
9145 | (w32_system_caret_hwnd, w32_system_caret_height, w32_system_caret_x) | |
9146 | (w32_system_caret_y, Qfile_name_history): | |
9147 | * w32font.c (w32font_driver, QCantialias, QCotf, QClang): | |
9148 | * w32inevt.c (reinvoke_input_signal, lispy_function_keys): | |
9149 | * w32menu.c (Qmenu_bar, QCtoggle, QCradio, Qoverriding_local_map) | |
9150 | (Qoverriding_terminal_local_map, Qmenu_bar_update_hook): | |
9151 | * w32proc.c (Qlocal, report_file_error): | |
9152 | * w32term.c (Vwindow_system, updating_frame): | |
9153 | * w32uniscribe.c (initialized, uniscribe_font_driver): | |
9154 | Remove unneeded extern declarations. | |
9155 | ||
2aa46d6c CY |
9156 | 2011-03-14 Chong Yidong <cyd@stupidchicken.com> |
9157 | ||
c96bbc66 | 9158 | * buffer.c (Fmake_indirect_buffer): Fix incorrect assertions. |
2aa46d6c | 9159 | |
cffc6f3b CY |
9160 | 2011-03-13 Chong Yidong <cyd@stupidchicken.com> |
9161 | ||
9162 | * buffer.h (BUF_BEGV, BUF_BEGV_BYTE, BUF_ZV, BUF_ZV_BYTE, BUF_PT) | |
9163 | (BUF_PT_BYTE): Rewrite to handle indirect buffers (Bug#8219). | |
9164 | These macros can no longer be used for assignment. | |
9165 | ||
44f230aa SM |
9166 | * buffer.c (Fget_buffer_create, Fmake_indirect_buffer): |
9167 | Assign struct members directly, instead of using BUF_BEGV etc. | |
cffc6f3b CY |
9168 | (record_buffer_markers, fetch_buffer_markers): New functions for |
9169 | recording and fetching special buffer markers. | |
9170 | (set_buffer_internal_1, set_buffer_temp): Use them. | |
9171 | ||
9172 | * lread.c (unreadchar): Use SET_BUF_PT_BOTH. | |
9173 | ||
9174 | * insdel.c (adjust_point): Use SET_BUF_PT_BOTH. | |
9175 | ||
9176 | * intervals.c (temp_set_point_both): Use SET_BUF_PT_BOTH. | |
9177 | (get_local_map): Use SET_BUF_BEGV_BOTH and SET_BUF_ZV_BOTH. | |
9178 | ||
9179 | * xdisp.c (hscroll_window_tree): | |
9180 | (reconsider_clip_changes): Use PT instead of BUF_PT. | |
9181 | ||
d251f04b EZ |
9182 | 2011-03-13 Eli Zaretskii <eliz@gnu.org> |
9183 | ||
9184 | * makefile.w32-in ($(BLD)/editfns.$(O)): Depend on | |
9185 | $(EMACS_ROOT)/lib/intprops.h. | |
9186 | ||
f0c77cd1 PE |
9187 | 2011-03-13 Paul Eggert <eggert@cs.ucla.edu> |
9188 | ||
3eca4629 PE |
9189 | Fix more problems found by GCC 4.5.2's static checks. |
9190 | ||
7c86ee98 PE |
9191 | * gtkutil.c (xg_get_pixbuf_from_pixmap): Add cast from char * |
9192 | to unsigned char * to avoid compiler diagnostic. | |
b0afc268 PE |
9193 | (xg_free_frame_widgets): Make it clear that a local variable is |
9194 | needed only if USE_GTK_TOOLTIP. | |
01e0b5ad PE |
9195 | (gdk_window_get_screen): Make it clear that this macro is needed |
9196 | only if USE_GTK_TOOLTIP. | |
1e5524e7 PE |
9197 | (int_gtk_range_get_value): New function, which avoids a diagnostic |
9198 | from gcc -Wbad-function-cast. | |
9199 | (xg_set_toolkit_scroll_bar_thumb): Use it. | |
9200 | (xg_tool_bar_callback, xg_tool_item_stale_p): Rewrite to avoid | |
9201 | diagnostic from gcc -Wbad-function-cast. | |
65dc836c PE |
9202 | (get_utf8_string, xg_get_file_with_chooser): |
9203 | Rename locals to avoid shadowing. | |
9204 | (create_dialog): Move locals to avoid shadowing. | |
7c86ee98 | 9205 | |
41729b81 PE |
9206 | * xgselect.c (xg_select): Remove unused var. |
9207 | ||
f0c77cd1 PE |
9208 | * image.c (four_corners_best): Mark locals as initialized. |
9209 | (gif_load): Initialize transparent_p to zero (Bug#8238). | |
9210 | Mark another local as initialized. | |
ec6cf4c6 | 9211 | (my_png_error, my_error_exit): Mark with NO_RETURN. |
f0c77cd1 | 9212 | |
ce0ad53d | 9213 | * image.c (clear_image_cache): Now static. |
d5d5a617 | 9214 | (DIM, HAVE_STDLIB_H_1): Remove unused macros. |
e22cffbc | 9215 | (xpm_load): Redo to avoid "discards qualifiers" gcc warning. |
77a765fd PE |
9216 | (x_edge_detection): Remove unnecessary cast that |
9217 | gcc -Wbad-function-cast diagnoses. | |
2037898d | 9218 | (gif_load): Fix pointer signedness. |
6ae141d6 PE |
9219 | (clear_image_cache, xbm_read_bitmap_data, x_detect_edges): |
9220 | (jpeg_load, gif_load): Rename locals to avoid shadowing. | |
ce0ad53d | 9221 | |
33383987 | 9222 | 2011-03-12 Paul Eggert <eggert@cs.ucla.edu> |
3eca4629 | 9223 | |
d32df629 PE |
9224 | Improve quality of tests for time stamp overflow. |
9225 | For example, without this patch (encode-time 0 0 0 1 1 | |
9226 | 1152921504606846976) returns the obviously-bogus value (-948597 | |
9227 | 62170) on my RHEL 5.5 x86-64 host. With the patch, it correctly | |
9228 | reports time overflow. See | |
9229 | <http://lists.gnu.org/archive/html/emacs-devel/2011-03/msg00470.html>. | |
b8d9bd41 PE |
9230 | * deps.mk (editfns.o): Depend on ../lib/intprops.h. |
9231 | * editfns.c: Include limits.h and intprops.h. | |
9232 | (TIME_T_MIN, TIME_T_MAX): New macros. | |
9233 | (time_overflow): Move earlier, to before first use. | |
9234 | (hi_time, lo_time): New functions, for an accurate test for | |
9235 | out-of-range times. | |
9236 | (Fcurrent_time, Fget_internal_run_time, make_time): Use them. | |
9237 | (Fget_internal_run_time): Don't assume time_t fits in int. | |
9238 | (make_time): Use list2 instead of Fcons twice. | |
9239 | (Fdecode_time): More accurate test for out-of-range times. | |
9240 | (check_tm_member): New function. | |
9241 | (Fencode_time): Use it, to test for out-of-range times. | |
d32df629 PE |
9242 | (lisp_time_argument): Don't rely on undefined left-shift and |
9243 | right-shift behavior when checking for time stamp overflow. | |
8be6f318 | 9244 | |
fe31d94c PE |
9245 | * editfns.c (time_overflow): New function, refactoring common code. |
9246 | (Fformat_time_string, Fdecode_time, Fencode_time): | |
9247 | (Fcurrent_time_string): Use it. | |
9248 | ||
8be6f318 PE |
9249 | Move 'make_time' to be next to its inverse 'lisp_time_argument'. |
9250 | * dired.c (make_time): Move to ... | |
9251 | * editfns.c (make_time): ... here. | |
9252 | * systime.h: Note the move. | |
9253 | ||
09d9db2c | 9254 | 2011-03-12 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
c47cbdfd | 9255 | |
126bc0dc YM |
9256 | * fringe.c (update_window_fringes): Remove unused variables. |
9257 | ||
c47cbdfd YM |
9258 | * unexmacosx.c (copy_data_segment): Also copy __got section. |
9259 | (Bug#8223) | |
9260 | ||
7ac80be9 EZ |
9261 | 2011-03-12 Eli Zaretskii <eliz@gnu.org> |
9262 | ||
c96bbc66 | 9263 | * termcap.c [MSDOS]: Include "msdos.h". |
058e5dad EZ |
9264 | (find_capability, tgetnum, tgetflag, tgetstr, tputs, tgetent): |
9265 | Constify `char *' arguments and their references according to | |
9266 | prototypes in tparam.h. | |
9267 | ||
ecb0f94d | 9268 | * deps.mk (termcap.o): Depend on tparam.h and msdos.h. |
058e5dad | 9269 | |
7ac80be9 EZ |
9270 | * msdos.c (XMenuAddPane): 3rd argument is `const char *' now. |
9271 | Adapt all references accordingly. | |
9272 | ||
9273 | * msdos.h (XMenuAddPane): 3rd argument is `const char *' now. | |
9274 | ||
ef1fd07e TT |
9275 | 2011-03-11 Tom Tromey <tromey@redhat.com> |
9276 | ||
9277 | * buffer.c (syms_of_buffer): Remove obsolete comment. | |
9278 | ||
7ef4b50c EZ |
9279 | 2011-03-11 Eli Zaretskii <eliz@gnu.org> |
9280 | ||
9281 | * termhooks.h (encode_terminal_code): Declare prototype. | |
9282 | ||
9283 | * msdos.c (encode_terminal_code): Don't declare prototype. | |
9284 | ||
9285 | * term.c (encode_terminal_code): Now external again, used by | |
9286 | w32console.c and msdos.c. | |
9287 | ||
44f230aa SM |
9288 | * makefile.w32-in ($(BLD)/term.$(O), ($(BLD)/tparam.$(O)): |
9289 | Depend on $(SRC)/tparam.h, see 2011-03-11T07:24:21Z!eggert@cs.ucla.edu. | |
7ef4b50c | 9290 | |
4b1ec863 | 9291 | 2011-03-11 Paul Eggert <eggert@cs.ucla.edu> |
f78faa98 | 9292 | |
1714f52b | 9293 | Fix some minor problems found by GCC 4.5.2's static checks. |
83316bf4 | 9294 | |
4b1ec863 PE |
9295 | * fringe.c (update_window_fringes): Mark locals as initialized |
9296 | (Bug#8227). | |
9297 | (destroy_fringe_bitmap, init_fringe_bitmap): Now static. | |
bf60f616 | 9298 | |
524c7aa6 PE |
9299 | * alloc.c (mark_fringe_data): Move decl from here ... |
9300 | * lisp.h (mark_fringe_data) [HAVE_WINDOW_SYSTEM]: ... to here, | |
9301 | to check its interface. | |
9302 | (init_fringe_once): Do not declare unless HAVE_WINDOW_SYSTEM. | |
9303 | ||
a5c0af81 | 9304 | * fontset.c (free_realized_fontset): Now static. |
7519b8cd | 9305 | (Fset_fontset_font): Rename local to avoid shadowing. |
cc6e5db1 | 9306 | (fontset_font): Mark local as initialized. |
a9a06e0b | 9307 | (FONTSET_SPEC, FONTSET_REPERTORY, RFONT_DEF_REPERTORY): Remove; unused. |
a5c0af81 | 9308 | |
b4716021 PE |
9309 | * xrdb.c: Include "xterm.h", to check x_load_resources's interface. |
9310 | ||
811e9bac | 9311 | * xselect.c (x_disown_buffer_selections): Remove; not used. |
7b83e2f1 | 9312 | (TRACE3) [!defined TRACE_SELECTION]: Remove; not used. |
aa0daa9f PE |
9313 | (x_own_selection, Fx_disown_selection_internal): Rename locals |
9314 | to avoid shadowing. | |
9315 | (x_handle_dnd_message): Remove local to avoid shadowing. | |
811e9bac | 9316 | |
7e3ab302 PE |
9317 | * lisp.h (GCPRO1_VAR, UNGCPRO_VAR): New macros, |
9318 | so that the caller can use some name other than gcpro1. | |
9319 | (GCPRO1, UNGCPRO): Reimplement in terms of the new macros. | |
58d2d479 PE |
9320 | * xfns.c (Fx_create_frame, x_create_tip_frame, Fx_show_tip): |
9321 | (Fx_backspace_delete_keys_p): | |
9322 | Use them to avoid shadowing, and rename vars to avoid shadowing. | |
9323 | (x_decode_color, x_set_name, x_window): Now static. | |
6b437900 | 9324 | (Fx_create_frame): Add braces to silence GCC warning. |
c0951e53 | 9325 | (Fx_file_dialog, Fx_select_font): Fix pointer signedness. |
06b0c8a0 PE |
9326 | (x_real_positions, xg_set_icon_from_xpm_data, x_create_tip_frame): |
9327 | Remove unused locals. | |
7e3ab302 PE |
9328 | (Fx_create_frame, x_create_tip_frame, Fx_show_tip): |
9329 | (Fx_backspace_delete_keys_p): Rename locals to avoid shadowing. | |
9330 | Some of these renamings use the new GCPRO1_VAR and UNGCPRO_VAR | |
9331 | macros. | |
f78faa98 | 9332 | |
e2b13473 PE |
9333 | * xterm.h (x_mouse_leave): New decl. |
9334 | ||
77f23912 PE |
9335 | * xterm.c (x_copy_dpy_color, x_focus_on_frame, x_unfocus_frame): |
9336 | Remove unused functions. | |
cdf4ba58 PE |
9337 | (x_shift_glyphs_for_insert, XTflash, XTring_bell): |
9338 | (x_calc_absolute_position): Now static. | |
7411c686 | 9339 | (XTread_socket): Don't define label "out" unless it's used. |
2b07bcff | 9340 | Don't declare local "event" unless it's used. |
ed7bf3a5 PE |
9341 | (x_iconify_frame, x_free_frame_resources): Don't declare locals |
9342 | unless they are used. | |
38d0b34a PE |
9343 | (XEMBED_VERSION, xembed_set_info): Don't define unless needed. |
9344 | (x_fatal_error_signal): Remove; not used. | |
a6067996 PE |
9345 | (x_draw_image_foreground, redo_mouse_highlight, XTmouse_position): |
9346 | (x_scroll_bar_report_motion, handle_one_xevent, x_draw_bar_cursor): | |
9347 | (x_error_catcher, x_connection_closed, x_error_handler): | |
9348 | (x_error_quitter, xembed_send_message, x_iconify_frame): | |
9349 | (my_log_handler): Rename locals to avoid shadowing. | |
28f1c698 | 9350 | (x_delete_glyphs, x_ins_del_lines): Mark with NO_RETURN. |
2a8fade0 | 9351 | (x_connection_closed): Tell GCC not to suggest NO_RETURN. |
77f23912 | 9352 | |
44f230aa SM |
9353 | * xfaces.c (clear_face_cache, Fx_list_fonts, Fface_font): |
9354 | Rename or move locals to avoid shadowing. | |
6b463e58 | 9355 | (tty_defined_color, merge_face_heights): Now static. |
5967d051 | 9356 | (free_realized_faces_for_fontset): Remove; not used. |
1e9966ea PE |
9357 | (Fx_list_fonts): Mark variable that gcc -Wuninitialized |
9358 | does not deduce is never used uninitialized. | |
73719eba PE |
9359 | (STRDUPA, LSTRDUPA, FONT_POINT_SIZE_QUANTUM): Remove; not used. |
9360 | (LFACEP): Define only if XASSERTS, as it's not needed otherwise. | |
071048a3 | 9361 | |
426994c3 | 9362 | * terminal.c (store_terminal_param): Now static. |
5489860b | 9363 | |
032f1620 | 9364 | * xmenu.c (menu_highlight_callback): Now static. |
9d66f88e | 9365 | (set_frame_menubar): Remove unused local. |
d4323972 | 9366 | (xmenu_show): Rename parameter to avoid shadowing. |
6d1f7fee PE |
9367 | (xmenu_show, xdialog_show, xmenu_show): Make local pointers "const" |
9368 | since they might point to immutable storage. | |
281585b0 PE |
9369 | (next_menubar_widget_id): Declare only if USE_X_TOOLKIT, |
9370 | since it's unused otherwise. | |
032f1620 | 9371 | |
367c19e5 | 9372 | * xdisp.c (produce_glyphless_glyph): Initialize lower_xoff. |
53df7c11 | 9373 | Add a FIXME, since the code still doesn't look right. (Bug#8215) |
9f36b9fd PE |
9374 | (Fcurrent_bidi_paragraph_direction): Simplify slightly; this |
9375 | avoids a gcc -Wuninitialized diagnostic. | |
0e086e8f | 9376 | (display_line, BUILD_COMPOSITE_GLYPH_STRING, draw_glyphs): |
44a3a108 PE |
9377 | (note_mouse_highlight): Mark variables that gcc -Wuninitialized |
9378 | does not deduce are never used uninitialized. | |
70739cbe | 9379 | |
07b48fa9 PE |
9380 | * lisp.h (IF_LINT): New macro, copied from ../lib-src/emacsclient.c. |
9381 | ||
8868a238 | 9382 | * xdisp.c (redisplay_window): Rename local to avoid shadowing. |
4554d213 PE |
9383 | * window.c (window_loop, size_window): |
9384 | (run_window_configuration_change_hook, enlarge_window): Likewise. | |
8868a238 | 9385 | |
7e5cf297 | 9386 | * window.c (display_buffer): Now static. |
d6550a9f PE |
9387 | (size_window): Mark variables that gcc -Wuninitialized |
9388 | does not deduce are never used uninitialized. | |
a586633d PE |
9389 | * window.h (check_all_windows): New decl, to forestall |
9390 | gcc -Wmissing-prototypes diagnostic. | |
5b555da1 | 9391 | * dispextern.h (bidi_dump_cached_states): Likewise. |
7e5cf297 | 9392 | |
f6095868 PE |
9393 | * charset.h (CHECK_CHARSET_GET_CHARSET): Rename locals to avoid |
9394 | shadowing. | |
9395 | * charset.c (map_charset_for_dump, Fchar_charset): Likewise. | |
726929c4 PE |
9396 | Include <limits.h>. |
9397 | (Fsort_charsets): Redo min/max calculation to shorten the code a bit | |
9398 | and to avoid gcc -Wuninitialized warning. | |
89ef49df PE |
9399 | (load_charset_map): Mark variables that gcc -Wuninitialized |
9400 | does not deduce are never used uninitialized. | |
53df7c11 | 9401 | (load_charset): Abort instead of using uninitialized var (Bug#8229). |
f6095868 | 9402 | |
f38b440c PE |
9403 | * coding.c (coding_set_source, coding_set_destination): |
9404 | Use "else { /* comment */ }" rather than "else /* comment */;" | |
9405 | for clarity, and to avoid gcc -Wempty-body warning. | |
2735d060 PE |
9406 | (Fdefine_coding_system_internal): Don't redeclare 'i' inside |
9407 | a block, when the outer 'i' will do. | |
9408 | (decode_coding_utf_8, decode_coding_utf_16, detect_coding_emacs_mule): | |
9409 | (emacs_mule_char, decode_coding_emacs_mule, detect_coding_iso_2022): | |
9410 | (decode_coding_iso_2022, decode_coding_sjis, decode_coding_big5): | |
9411 | (decode_coding_raw_text, decode_coding_charset, get_translation_table): | |
9412 | (Fdecode_sjis_char, Fdefine_coding_system_internal): | |
9413 | Rename locals to avoid shadowing. | |
9414 | * character.h (FETCH_STRING_CHAR_ADVANCE): Likewise. | |
e2f1bab9 PE |
9415 | * coding.c (emacs_mule_char, encode_invocation_designation): |
9416 | Now static, since they're not used elsewhere. | |
413bb2db | 9417 | (decode_coding_iso_2022): Add "default: abort ();" as a safety check. |
c4a63b12 | 9418 | (decode_coding_object, encode_coding_object, detect_coding_system): |
ee05f961 PE |
9419 | (decode_coding_emacs_mule): Mark variables that gcc |
9420 | -Wuninitialized does not deduce are never used uninitialized. | |
160b01f6 PE |
9421 | (detect_coding_iso_2022): Initialize a local variable that might |
9422 | be used uninitialized. Leave a FIXME because it's not clear that | |
53df7c11 | 9423 | this initialization is needed. (Bug#8211) |
5f58e762 PE |
9424 | (ISO_CODE_LF, ISO_CODE_CR, CODING_ISO_FLAG_EUC_TW_SHIFT): |
9425 | (ONE_MORE_BYTE_NO_CHECK, UTF_BOM, UTF_16_INVALID_P): | |
9426 | (SHIFT_OUT_OK, ENCODE_CONTROL_SEQUENCE_INTRODUCER): | |
9427 | (ENCODE_DIRECTION_R2L, ENCODE_DIRECTION_L2R): | |
9428 | Remove unused macros. | |
f38b440c | 9429 | |
232b38b9 | 9430 | * category.c (hash_get_category_set): Remove unused local var. |
9f3b5e69 | 9431 | (copy_category_table): Now static, since it's not used elsewhere. |
d0891610 | 9432 | * character.c (string_count_byte8): Likewise. |
232b38b9 | 9433 | |
fb90da1b PE |
9434 | * ccl.c (CCL_WRITE_STRING, CCL_ENCODE_CHAR, Fccl_execute_on_string): |
9435 | (Fregister_code_conversion_map): Rename locals to avoid shadowing. | |
9436 | ||
fb93dbc2 PE |
9437 | * chartab.c (copy_sub_char_table): Now static, since it's not used |
9438 | elsewhere. | |
5c156ace PE |
9439 | (sub_char_table_ref_and_range, char_table_ref_and_range): |
9440 | Rename locals to avoid shadowing. | |
bbcd0949 | 9441 | (ASET_RANGE, GET_SUB_CHAR_TABLE): Remove unused macros. |
fb93dbc2 | 9442 | |
7d3b3862 | 9443 | * bidi.c (bidi_check_type): Now static, since it's not used elsewhere. |
630d6892 | 9444 | (BIDI_BOB): Remove unused macro. |
7d3b3862 | 9445 | |
6be7d3da PE |
9446 | * cm.c (cmgoto): Mark variables that gcc -Wuninitialized does not |
9447 | deduce are never used uninitialized. | |
c2ed9c8b | 9448 | * term.c (encode_terminal_code): Likewise. |
6be7d3da | 9449 | |
75f8807f | 9450 | * term.c (encode_terminal_code): Now static. Remove unused local. |
72abad34 | 9451 | |
50938595 PE |
9452 | * tparam.h: New file. |
9453 | * term.c, tparam.h: Include it. | |
9454 | * deps.mk (term.o, tparam.o): Depend on tparam.h. | |
9455 | * term.c (tputs, tgetent, tgetflag, tgetnum, tparam, tgetstr): | |
9456 | Move these decls to tparam.h, and make them agree with what | |
9457 | is actually in tparam.c. The previous trick of using incompatible | |
9458 | decls in different modules does not conform to the C standard. | |
9459 | All callers of tparam changed to use tparam's actual API. | |
9460 | * tparam.c (tparam1, tparam, tgoto): | |
9461 | Use const pointers where appropriate. | |
9462 | ||
fbceeba2 PE |
9463 | * cm.c (calccost, cmgoto): Use const pointers where appropriate. |
9464 | * cm.h (struct cm): Likewise. | |
9465 | * dispextern.h (do_line_insertion_deletion_costs): Likewise. | |
9466 | * scroll.c (ins_del_costs, do_line_insertion_deletion_costs): Likewise. | |
9467 | * term.c (tty_ins_del_lines, calculate_costs, struct fkey_table): | |
9468 | (term_get_fkeys_1, append_glyphless_glyph, produce_glyphless_glyph): | |
9469 | (turn_on_face, init_tty): Likewise. | |
9470 | * termchar.h (struct tty_display_info): Likewise. | |
fbceeba2 | 9471 | |
7f3f1250 PE |
9472 | * term.c (term_mouse_position): Rename local to avoid shadowing. |
9473 | ||
e6ca6543 PE |
9474 | * alloc.c (mark_ttys): Move decl from here ... |
9475 | * lisp.h (mark_ttys): ... to here, so that it's checked against defn. | |
9476 | ||
c40f8d15 AS |
9477 | 2011-03-11 Andreas Schwab <schwab@linux-m68k.org> |
9478 | ||
9479 | * .gdbinit (pwinx, xbuffer): Fix access to buffer name. | |
9480 | ||
cfe0661d JB |
9481 | 2011-03-09 Juanma Barranquero <lekktu@gmail.com> |
9482 | ||
9483 | * search.c (compile_pattern_1): Remove argument regp, unused since | |
9484 | revid:rms@gnu.org-19941211082627-3x1g1wyqkjmwloig. | |
9485 | (compile_pattern): Don't pass it. | |
9486 | ||
0afb4571 J |
9487 | 2011-03-08 Jan Djärv <jan.h.d@swipnet.se> |
9488 | ||
9489 | * xterm.h (DEFAULT_GDK_DISPLAY): New define. | |
9490 | (GDK_WINDOW_XID, gtk_widget_get_preferred_size): New defines | |
9491 | for ! HAVE_GTK3. | |
9492 | (GTK_WIDGET_TO_X_WIN): Use GDK_WINDOW_XID. | |
9493 | ||
9494 | * xmenu.c (menu_position_func): Call gtk_widget_get_preferred_size. | |
9495 | ||
9496 | * gtkutil.c: Include gtkx.h if HAVE_GTK3. If ! HAVE_GTK3, define | |
9497 | gdk_window_get_screen, gdk_window_get_geometry, | |
9498 | gdk_x11_window_lookup_for_display and GDK_KEY_g. | |
9499 | (xg_set_screen): Use DEFAULT_GDK_DISPLAY. | |
9500 | (xg_get_pixbuf_from_pixmap): New function. | |
9501 | (xg_get_pixbuf_from_pix_and_mask): Change parameters from GdkPixmap | |
9502 | to Pixmap, take frame as parameter, remove GdkColormap parameter. | |
9503 | Call xg_get_pixbuf_from_pixmap instead of | |
9504 | gdk_pixbuf_get_from_drawable. | |
9505 | (xg_get_image_for_pixmap): Do not make GdkPixmaps, call | |
9506 | xg_get_pixbuf_from_pix_and_mask with Pixmap parameters instead. | |
9507 | (xg_check_special_colors): Use GtkStyleContext and its functions | |
9508 | for HAVE_GTK3. | |
9509 | (xg_prepare_tooltip, xg_hide_tooltip): Call gdk_window_get_screen. | |
9510 | (xg_prepare_tooltip, create_dialog, menubar_map_cb) | |
9511 | (xg_update_frame_menubar, xg_tool_bar_detach_callback) | |
44f230aa SM |
9512 | (xg_tool_bar_attach_callback, xg_update_tool_bar_sizes): |
9513 | Call gtk_widget_get_preferred_size. | |
0afb4571 J |
9514 | (xg_frame_resized): gdk_window_get_geometry only takes 5 |
9515 | parameters. | |
44f230aa SM |
9516 | (xg_win_to_widget, xg_event_is_for_menubar): |
9517 | Call gdk_x11_window_lookup_for_display. | |
0afb4571 J |
9518 | (xg_set_widget_bg): New function. |
9519 | (delete_cb): New function. | |
895009e1 | 9520 | (xg_create_frame_widgets): Connect delete-event to delete_cb. |
5c32d3f2 | 9521 | Call xg_set_widget_bg. Only set background pixmap for ! HAVE_GTK3 |
0afb4571 J |
9522 | (xg_set_background_color): Call xg_set_widget_bg. |
9523 | (xg_set_frame_icon): Call xg_get_pixbuf_from_pix_and_mask. | |
9524 | (xg_create_scroll_bar): vadj is a GtkAdjustment for HAVE_GTK3. | |
9525 | Only call gtk_range_set_update_policy if ! HAVE_GTK3. | |
9526 | (xg_make_tool_item): Only connect xg_tool_bar_item_expose_callback | |
9527 | if ! HAVE_GTK3. | |
9528 | (update_frame_tool_bar): Call gtk_widget_hide. | |
9529 | (xg_initialize): Use GDK_KEY_g. | |
9530 | ||
9531 | * xsmfns.c (gdk_set_sm_client_id): Define to gdk_set_sm_client_id | |
9532 | if ! HAVE_GTK3 | |
9533 | (x_session_initialize): Call gdk_x11_set_sm_client_id. | |
9534 | ||
9535 | * xterm.c (XFillRectangle): Use cairo routines for HAVE_GTK3. | |
9536 | (x_term_init): Disable Xinput(2) with GDK_CORE_DEVICE_EVENTS. | |
9537 | Load ~/emacs.d/gtkrc only for ! HAVE_GTK3. | |
9538 | ||
1c2cc4ef JB |
9539 | 2011-03-08 Juanma Barranquero <lekktu@gmail.com> |
9540 | ||
9541 | * w32xfns.c (select_palette): Check success of RealizePalette against | |
9542 | GDI_ERROR, not zero. | |
9543 | ||
33383987 | 9544 | See ChangeLog.11 for earlier changes. |
aac0c6e3 MR |
9545 | |
9546 | ;; Local Variables: | |
9547 | ;; coding: utf-8 | |
aac0c6e3 MR |
9548 | ;; End: |
9549 | ||
acaf905b | 9550 | Copyright (C) 2011-2012 Free Software Foundation, Inc. |
aac0c6e3 MR |
9551 | |
9552 | This file is part of GNU Emacs. | |
9553 | ||
9554 | GNU Emacs is free software: you can redistribute it and/or modify | |
9555 | it under the terms of the GNU General Public License as published by | |
9556 | the Free Software Foundation, either version 3 of the License, or | |
9557 | (at your option) any later version. | |
9558 | ||
9559 | GNU Emacs is distributed in the hope that it will be useful, | |
9560 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
9561 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
9562 | GNU General Public License for more details. | |
9563 | ||
9564 | You should have received a copy of the GNU General Public License | |
9565 | along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. |