1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-06 03:40:56 -08:00
Commit graph

109697 commits

Author SHA1 Message Date
Paul Eggert
6772211202 Close a race when statting and reading files.
* fileio.c (Finsert_file_contents): Use open+fstat, not stat+open.
This avoids a race if the file is renamed between stat and open.
This race is not the problem originally noted in Bug#13149;
see <http://bugs.gnu.org/13149#73> and later messages in the thread.
2013-01-17 21:12:08 -08:00
Michael Albinus
0eb8768885 * autorevert.el (auto-revert-notify-watch-descriptor): Make it
buffer local, again.  This was lost with the fix on 2013-01-12.
2013-01-17 20:12:40 +01:00
Glenn Morris
858c7150f6 Auto-commit of generated files. 2013-01-17 06:17:35 -05:00
Jürgen Hötzel
99d36ea8f6 * eshell/esh-util.el (eshell-path-env): Make it buffer local, in
order to support several eshell buffers in parallel.
2013-01-17 11:01:33 +01:00
Michael Albinus
68a08a32e3 * autorevert.el (auto-revert-use-notify): In the :set function, do
not modify `kill-buffer-hook'.
(auto-revert-notify-rm-watch): Remove
`auto-revert-notify-rm-watch' from `kill-buffer-hook'.
(auto-revert-notify-add-watch): Do not call
`auto-revert-notify-rm-watch', but add it to a buffer local
`kill-buffer-hook'.
2013-01-17 10:06:47 +01:00
Dmitry Antipov
468afbacea * lisp.h (toplevel): Add comment about using Lisp_Save_Value
objects, related functions and macros.
(make_save_value): Adjust prototype.
(make_save_pointer): New prototype.
(SAFE_NALLOCA): Fix indentation.  Use make_save_pointer.
(SAFE_ALLOCA_LISP): Adjust make_save_value usage.
* alloc.c (format_save_value): Rename to make_save_value.
(make_save_pointer): New function.
(record_xmalloc): Use make_save_pointer.
* dired.c, editfns.c, fileio.c, font.c, gtkutil.c, lread.c:
* nsmenu.m, nsterm.m, xfns.c, xmenu.c, xselect.c, keymap.c:
Change users of make_save_value to make_save_pointer.
Likewise for format_save_value and make_save_value.
2013-01-17 10:29:40 +04:00
Dmitry Antipov
0e70695aa4 * buffer.h (NARROWED, BUF_NARROWED): Drop unused macros.
(DECODE_POSITION, BUFFER_CHECK_INDIRECTION): Fix indentation.
* buffer.c (toplevel, syms_of_buffer): Drop old commented-out
debugging stubs.
2013-01-17 09:52:13 +04:00
Stefan Monnier
e59eee439c * lisp/emacs-lisp/trace.el (trace--read-args): Use a closure and an honest
call to `eval' rather than a backquoted lambda.
2013-01-16 14:06:15 -05:00
Paul Eggert
ffe04adc88 Merge from gnulib. 2013-01-16 09:45:39 -08:00
Glenn Morris
ac924f35e4 Auto-commit of generated files. 2013-01-16 06:17:35 -05:00
Paul Eggert
c4e2ba0a60 * configure.ac: Document that --enable-gcc-warnings emits errors.
Fixes: debbugs:13448
2013-01-15 22:04:58 -08:00
Glenn Morris
059fc5111d * lisp/gnus/smiley.el (smiley-style): Make the file loadable in batch mode.
Not likely to be very useful, of course, but helps with automated testing.
2013-01-15 21:46:25 -05:00
Paul Eggert
963ea40fe9 * src/alloc.c (free_save_value): Now static. 2013-01-15 13:38:58 -08:00
Paul Eggert
1a353a145d * make-docfile.c (write_globals): Make it a bit clearer.
This pacifies GCC 4.7.2 when Emacs is configured with
--enable-link-time-optimization and --enable-gcc-warnings.

Fixes: debbugs:13448
2013-01-15 13:26:01 -08:00
Dmitry Antipov
3346c1d0a8 * keymap.c (map_keymap_internal): Use format_save_value.
(map_keymap_char_table_item): Adjust accordingly.
* fileio.c (non_regular_fd, non_regular_inserted)
(non_regular_nbytes): Remove.
(Finsert_file_contents): Convert trytry to ptrdiff_t.  Use
format_save_value to pass parameters to read_non_regular.
(read_non_regular): Use XSAVE_ macros to extract parameters.
Adjust comment.
* xmenu.c (xmenu_show) [!USE_X_TOOLKIT && !USE_GTK]: Use
format_save_value.
(pop_down_menu) [!USE_X_TOOLKIT && !USE_GTK]: Adjust user.
2013-01-15 14:14:31 +04:00
Dmitry Antipov
2b30549c49 * src/lisp.h (XSAVE_POINTER, XSAVE_INTEGER): Change to allow extraction
from any Lisp_Save_Value slot.  Add type checking.
* src/alloc.c, src/dired.c, src/editfns.c, src/fileio.c, src/ftfont.c:
* src/gtkutil.c, src/keymap.c, src/lread.c, src/nsterm.h, src/nsmenu.c:
* src/xfns.c, src/xmenu.c, src/xselect.c: All users changed.
* admin/coccinelle/xsave.cocci: Semantic patch to adjust users of
XSAVE_POINTER and XSAVE_INTEGER macros.
2013-01-15 13:22:25 +04:00
Dmitry Antipov
1b971ac155 Some convenient bits to deal with Lisp_Save_Values.
* lisp.h (XSAVE_OBJECT): New macro to extract saved objects.
(allocate_misc): Remove prototype.
(format_save_value): New prototype.
* alloc.c (allocate_misc): Revert back to static.
(format_save_value): New function to build Lisp_Save_Value
object with the specified internal structure.
(make_save_value): Reimplement using format_save_value.
* editfns.c (save_excursion_save): Use format_save_value.
(save_excursion_restore): Use XSAVE_OBJECT.
2013-01-15 12:38:07 +04:00
Stefan Monnier
cb9c0a53bc * lisp/emacs-lisp/advice.el (ad-preactivate-advice): Adjust the cleanup to
the use of nadvice.el.
* lisp/emacs-lisp/nadvice.el (advice--tweak): Make it possible for `tweak'
to return an explicit nil.
(advice--remove-function): Change accordingly.
* test/automated/advice-tests.el: Split up.  Add advice-test-preactivate.
2013-01-15 01:05:22 -05:00
Stefan Monnier
ef8214345b * lisp/gnus/nnimap.el (nnimap-keepalive): Don't throw an error if there's no
more imap process running.
2013-01-14 23:26:28 -05:00
Stefan Monnier
6e8cd0aeca * lisp/progmodes/which-func.el (which-function): Silence imenu errors.
Fixes: debbugs:13433
2013-01-14 23:20:13 -05:00
Michael Mauger
4586ce8a59 * progmodes/sql.el: (sql-imenu-generic-expression):
(sql-mode-font-lock-object-name): Match schema qualified names.
(sql-connect): Use string keys.
(sql-product-interactive): Wait for interpreter prompt.
(sql-comint-oracle): Set process coding based on NLS_LANG.
2013-01-14 22:21:56 -05:00
Michael Mauger
9d55215c18 * progmodes/sql.el (sql-output-to-send): Remove, unused.
(sql-interactive-remove-continuation-prompt):
(sql-send-magic-terminator, sql-interactive-mode): Remove references.
2013-01-14 21:35:45 -05:00
Julien Danjou
982c5d68ff gnus-sum.el: gnus-sum: fix `gnus-summary-from-or-to-or-newsgroups' address comparison 2013-01-14 22:09:16 +00:00
Paul Eggert
c50cf2eac4 Avoid needless casts with XSAVE_POINTER.
* alloc.c (mark_object) [GC_MARK_STACK]:
* dired.c (directory_files_internal_unwind):
* fileio.c (do_auto_save_unwind):
* gtkutil.c (pop_down_dialog):
* keymap.c (map_keymap_char_table_item):
* lread.c (load_unwind):
* nsmenu.m (pop_down_menu):
* print.c (print_object) [GC_MARK_STACK]:
* xfns.c (clean_up_file_dialog):
* xmenu.c (cleanup_widget_value_tree):
Omit casts between XSAVE_POINTER and a pointer type.
2013-01-14 09:46:14 -08:00
Leo Liu
57dd9e6886 Sync window-point and point in calendar-redraw
Fixes: debbugs:13420
2013-01-14 23:39:04 +08:00
Glenn Morris
6f24caecb0 Auto-commit of loaddefs files. 2013-01-14 06:20:54 -05:00
Dmitry Antipov
b17b4d0ff0 * lisp.h (toplevel): Fix typo in comment. 2013-01-14 15:16:14 +04:00
Dmitry Antipov
9d5a1260b6 Fix compilation with GC_MARK_STACK == GC_USE_GCPROS_AS_BEFORE.
* eval.c (eval_sub): Protect `form' from being GCed before its
car and cdr becomes protected with the backtrace entry.
2013-01-14 15:07:50 +04:00
Dmitry Antipov
73ebd38f16 Make Lisp_Save_Value more versatile storage for up to four objects.
* lisp.h (toplevel): Enumeration to describe types of saved objects.
(struct Lisp_Save_Value): New layout.  Adjust comments.
(XSAVE_POINTER): New macro.
(XSAVE_INTEGER): Likewise.
(allocate_misc): Add prototype.
(free_misc): Likewise.
* alloc.c (allocate_misc): Now global.
(free_misc): Likewise.  Adjust comment.
(make_save_value): Use new Lisp_Save_Value layout.  Adjust comment.
(free_save_value): Likewise.
(mark_object): Likewise.
* editfns.c (save_excursion_save): Pack everything within
Lisp_Save_Value and so avoid xmalloc.
(save_excursion_restore): Adjust to match new layout.  Use free_misc
because we do not allocate extra memory any more.  Add eassert.
* print.c (print_object): New code to print Lisp_Save_Value.  Do not
rely on valid_lisp_object_p if !GC_MARK_STACK.  Adjust comments.
* dired.c, fileio.c, font.c, ftfont.c, gtkutil.c, keymap.c,
* lread.c, nsmenu.m, nsterm.h, xfns.c, xmenu.c, xselect.c:
Use XSAVE_POINTER and XSAVE_INTEGER where appropriate.
2013-01-14 13:55:21 +04:00
Glenn Morris
d6d02e06ee Remove compilation-error-regexp-alist-alist (presumed) extraneous backslash 2013-01-13 17:09:38 -08:00
Glenn Morris
51e7349210 Fix interpretation of gnu line.col1-col2 error message format
* lisp/progmodes/compile.el (compilation-error-regexp-alist-alist):
* test/automated/compile-tests.el (compile-tests--test-regexps-data):
Fix interpretation of gnu line.col1-col2 format.

Fixes: debbugs:13335
2013-01-13 17:08:13 -08:00
Romain Francoise
b35b088608 Delete merge marker. 2013-01-13 22:26:10 +01:00
Glenn Morris
c0511b5769 Merge from emacs-24; up to 2012-12-10T20:27:33Z!eggert@cs.ucla.edu 2013-01-13 12:03:01 -08:00
Glenn Morris
0b59090ba3 ChangeLog whitespace trivia 2013-01-13 11:58:02 -08:00
Glenn Morris
99548339e5 NEWS placeholder for scroll-bar-adjust-thumb-portion 2013-01-13 11:55:51 -08:00
Richard M. Stallman
9f7e86ef28 Doc fix. 2013-01-13 14:48:04 -05:00
Richard M. Stallman
4c0a6d4abd Fix bug that f in Rmail, in some situations, would insert entire Rmail file. 2013-01-13 14:46:27 -05:00
Jan Djärv
2e7a189249 Fix spelling error. 2013-01-13 20:36:05 +01:00
Eli Zaretskii
ad33a799f8 Avoid warnings from cus-start.el regarding scroll-bar-adjust-thumb-portion.
lisp/cus-start.el (all): Avoid warnings about
 scroll-bar-adjust-thumb-portion on platforms where it is not
 defined.
2013-01-13 19:47:45 +02:00
Jan Djärv
b826986f36 * nsfont.m (LCD_SMOOTHING_MARGIN): New define.
(nsfont_draw): Remove disabling of LCD smoothing.
(ns_glyph_metrics): Add LCD_SMOOTHING_MARGIN to bearings to fix
Bug#11484 with LCD smooting on.
2013-01-13 15:29:22 +01:00
Bastien Guerry
a89c8ef024 Merge Org 7.9.3d (commit e8f5b0ad). 2013-01-13 11:33:16 +01:00
Glenn Morris
f5e9cbd447 ChangeLog fix (no need to merge to trunk) 2013-01-12 11:31:25 -08:00
Jan Djärv
b86195e669 Add tiny change. 2013-01-11 06:10:11 +01:00
Jan Djärv
616763d517 Make scroll-bar-adjust-thumb-portion customizable, adjust documentation.
* lisp/cus-start.el (all): Add scroll-bar-adjust-thumb-portion.

* src/xterm.c (syms_of_xterm): Adjust documentation for
scroll-bar-adjust-thumb-portion.
2013-01-11 06:09:30 +01:00
Jan Djärv
ec782c5f13 Introduce scroll-bar-adjust-thumb-portion.
* xterm.c (scroll-bar-adjust-thumb-portion): New variable to
determine whether scroll bar thumb size should be adjusted or
not. Use variable for MOTIF.

* gtkutil.c (scroll-bar-adjust-thumb-portion): Use variable for
GTK.
2013-01-11 05:57:45 +01:00
Jan Djärv
eac4d08fb1 * nsterm.m (keyDown:): Set processingCompose to NO if an emacs key
event is generated.
(doCommandBySelector:): Set processingCompose to NO.
2013-01-13 13:08:31 +01:00
Jan Djärv
7bc916b48d * nsfont.m (ns_findfonts): Add block/unblock_input calls.
Remove check for fkeys count > zero, block/unblock fixes the real bug.
(nsfont_list_family): Add block/unblock_input calls.
(nsfont_open): Move block_input earlier.  Add unblock_input before early
return.
(nsfont_draw): Add block/unblock_input calls.
2013-01-13 13:05:17 +01:00
Stefan Monnier
e5b5a34dd1 * lisp/jit-lock.el (jit-lock-debug-mode): New minor mode.
(jit-lock--debug-fontifying): New var.
(jit-lock--debug-fontify): New function.
* lisp/subr.el (condition-case-unless-debug): Don't prevent catching the
error, just let the debbugger run.
* lisp/emacs-lisp/timer.el (timer-event-handler): Don't prevent debugging
timer code and don't drop errors silently.
2013-01-12 20:23:48 -05:00
Glenn Morris
5ca9b80e95 Remove <>, since makes contents invisible on http://ftp.gnu.org 2013-01-12 16:51:49 -08:00
Michael Albinus
71c661e4e6 * autorevert.el (auto-revert-notify-handler): Use `file-equal-p'. 2013-01-12 20:24:27 +01:00