1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-02 02:10:46 -08:00
Commit graph

108502 commits

Author SHA1 Message Date
Eli Zaretskii
c8e3a9c3db Fix bug #12805 with compilation error in the cygw32 build.
src/makefile.w32-in ($(BLD)/w32fns.$(O)): Depend on $(NT_INC)/unistd.h.
 src/w32fns.c Include unistd.h, to avoid compiler warnings on Cygwin.
 (emacs_abort) [CYGWIN]: Don't call _open_osfhandle; instead, use
 file descriptor 2 for standard error.
2012-11-05 18:30:45 +02:00
Eli Zaretskii
4f3f021d65 Avoid compiler warnings in the MS-Windows build.
nt/inc/unistd.h (tcgetpgrp, setsid): Provide prototypes.
2012-11-05 18:21:18 +02:00
Juanma Barranquero
efeccf10f0 nt/config.nt: Sync with autogen/config.in.
(DISPNEW_NEEDS_STDIO_EXT, GETPGRP_VOID, HAVE_SETPGID, HAVE_SETSID)
(PENDING_OUTPUT_COUNT, SETPGRP_RELEASES_CTTY): Remove.
2012-11-05 15:30:32 +01:00
Glenn Morris
eda33f7834 Auto-commit of generated files. 2012-11-05 06:17:32 -05:00
Chong Yidong
209c6a58b9 * process.c (wait_reading_process_output): Revert previous change. 2012-11-05 12:00:58 +08:00
Paul Eggert
dd0333b615 Assume at least POSIX.1-1988 for getpgrp, setpgid, setsid.
This removes code that has been obsolete since around 1990.
* admin/CPP-DEFINES (HAVE_SETPGID, HAVE_SETSID, SETPGRP_RELEASES_CTTY):
Remove; obsolete.
* configure.ac (setpgid, setsid): Assume their existence.
(AC_FUNC_GETPGRP, SETPGRP_RELEASES_CTTY): Remove; obsolete.
* src/callproc.c (Fcall_process):
* src/emacs.c (main):
* src/process.c (create_process):
* src/term.c (dissociate_if_controlling_tty):
Assume setsid exists.
* src/callproc.c (child_setup): Assume setpgid exists and behaves as
per POSIX.1-1988 or later.
* src/conf_post.h (setpgid) [!HAVE_SETPGID]: Remove.
* src/emacs.c (shut_down_emacs):
* src/sysdep.c (sys_suspend, init_foreground_group):
Assume getpgrp behaves as per POSIX.1-1998 or later.
* src/msdos.c (setpgrp): Remove.
(tcgetpgrp, setpgid, setsid): New functions.
* src/systty.h (EMACS_GETPGRP): Remove.  All callers now use getpgrp.
* src/term.c (no_controlling_tty): Remove; unused.
* src/w32proc.c (setpgrp): Remove.
(setsid, tcgetpgrp): New functions.

Fixes: debbugs:12800
2012-11-04 19:18:32 -08:00
Paul Eggert
8148369cfb Simplify by assuming __fpending.
Now that Emacs is using the gnulib fpending module,
there's no need for Emacs to have a separate implementation.
* configure.ac (stdio_ext.h, __fpending): Remove now-duplicate checks.
(PENDING_OUTPUT_COUNT, DISPNEW_NEEDS_STDIO_EXT): Remove.
* admin/CPP-DEFINES (PENDING_OUTPUT_COUNT): Remove.
* src/dispnew.c: Include <fpending.h>, not <stdio_ext.h>.
(update_frame_1): Use __fpending, not PENDING_OUTPUT_COUNT.
Do not assume that __fpending's result fits in int.
2012-11-04 17:59:00 -08:00
Paul Eggert
06b63c9b0c Remove EMACS_OUTQSIZE+sleep hack.
* dispnew.c (update_frame_1): Remove hack for terminals slower
than 2400 bps, which throttled Emacs by having it sleep.  This
code hasn't worked since at least 2007, when the multi-tty stuff
was added, and anyway those old terminals are long dead.
* systty.h (EMACS_OUTQSIZE): Remove; unused.  The macro isn't used even
without the dispnew.c change, as dispnew.c doesn't include systty.h.
2012-11-04 14:33:00 -08:00
Paul Eggert
76abf5e5a5 Fix data-loss with --version.
* emacs.c (close_output_streams): Use strerror, not emacs_strerror,
as we can't assume that emacs_strerror is initialized, and strerror
is good enough here.
(main): Invoke atexit earlier, to catch earlier instances of
sending data to stdout and exiting, e.g., "emacs --version >/dev/full".

Fixes: debbugs:9574
2012-11-04 09:29:52 -08:00
Juanma Barranquero
f200a427ff nt/config.nt: Sync with autogen/config.in.
(GNULIB_CLOSE_STREAM, HAVE_DECL___FPENDING): New macros.
2012-11-04 13:44:58 +01:00
Glenn Morris
6163a6801e Auto-commit of loaddefs files. 2012-11-04 06:23:35 -05:00
Glenn Morris
3bf26e9640 Auto-commit of generated files. 2012-11-04 06:19:07 -05:00
Glenn Morris
9749e2b071 * lisp/vc/vc-svn.el (vc-svn-state-heuristic): Avoid calling svn.
Fixes: debbugs:7850
2012-11-03 21:13:13 -07:00
Michael Marchionna
8f31e74bc7 * nsterm.m: Add NSClearLineFunctionKey and keypad keys.
(keyDown): Remap keypad keys to X11 virtual key codes.

Fixes: debbugs:8680
2012-11-04 11:34:10 +08:00
Chong Yidong
2cbafa5672 * bookmark.el (bookmark-bmenu-switch-other-window): Avoid binding same-window-* variables. 2012-11-04 11:25:18 +08:00
Juri Linkov
85178ca136 Don't bind same-window-* in isearch.el commands.
* isearch.el (isearch-help-for-help, isearch-describe-bindings)
(isearch-describe-key, isearch-describe-mode): Use a display
action instead of binding same-window-* variables.

Fixes: debbugs:10040
2012-11-04 11:24:00 +08:00
Eli Zaretskii
3478f4b5c4 Fix order of entries in ChangeLog files. 2012-11-03 22:48:03 +02:00
Eli Zaretskii
3a7089c180 Fix Windows build as fallout from 2012-11-03T18:54:17Z!eggert@cs.ucla.edu.
nt/config.nt (PENDING_OUTPUT_N_BYTES): Define.

 lib/makefile.w32-in (GNULIBOBJS): Add $(BLD)/fpending.$(O) and
 $(BLD)/close-stream.$(O).
 ($(BLD)/close-stream.$(O)):
 ($(BLD)/fpending.$(O)): New dependencies.

Fixes: debbugs:9574
2012-11-03 22:43:29 +02:00
Glenn Morris
5ccd466c82 * admin/admin.el (set-copyright): Add msdos/sed2v2.inp. 2012-11-03 12:19:05 -07:00
Glenn Morris
f58542e151 Merge from emacs-24; up to 2012-11-03T05:11:34Z!dmantipov@yandex.ru 2012-11-03 12:14:22 -07:00
Glenn Morris
92246540b0 Further small cl.texi changes
* doc/misc/cl.texi (Creating Symbols, Random Numbers):
De-emphasize internal variables cl--gensym-counter and cl--random-state. 

* etc/NEWS: Related edits.

Fixes: debbugs:12788
2012-11-03 11:55:29 -07:00
Paul Eggert
7ccfb720b4 Fix data-loss with --batch.
* admin/merge-gnulib (GNULIB_MODULES): Add close-stream.
* lib/close-stream.c, lib/close-stream.h, lib/fpending.c
* lib/fpending.h, m4/close-stream.m4, m4/fpending.m4:
New files, from gnulib.
* lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
* src/emacs.c: Include <close-stream.h>.
(close_output_streams): New function.
(main): Pass it to atexit, so that Emacs closes stdout and stderr
and handles errors appropriately.
(Fkill_emacs): Don't worry about flushing, as close_output_stream
does that now.

Fixes: debbugs:9574
2012-11-03 11:54:17 -07:00
Glenn Morris
376a8e83bb Rename cl-random-time to cl--random-time
* emacs-lisp/cl-lib.el (cl--random-time): Rename from cl-random-time. 
(cl--gensym-counter, cl--random-state): Update callers.
* emacs-lisp/cl-extra.el (cl-make-random-state): Update callers.

Fixes: debbugs:12773
2012-11-03 11:36:09 -07:00
Paul Eggert
0b3d4a4756 Fix a race condition that causes Emacs to mess up glib.
The symptom is a diagnostic "GLib-WARNING **: In call to
g_spawn_sync(), exit status of a child process was requested but
SIGCHLD action was set to SIG_IGN and ECHILD was received by
waitpid(), so exit status can't be returned."  The diagnostic
is partly wrong, as the SIGCHLD action is not set to SIG_IGN.
The real bug is a race condition between Emacs and glib: Emacs
does a waitpid (-1, ...) and reaps glib's subprocess by mistake,
so that glib can't find it.  Work around the bug by invoking
waitpid only on subprocesses that Emacs itself creates.
* process.c (create_process, record_child_status_change):
Don't use special value -1 in pid field, as the caller now must
know the pid rather than having the callee infer it.  The
inference was sometimes incorrect anyway, due to another race.
(create_process): Set new 'alive' member if child is created.
(process_status_retrieved): New function.
(record_child_status_change): Use it.
Accept negative 1st argument, which means to wait for the
processes that Emacs already knows about.  Move special-case code
for DOS_NT (which lacks WNOHANG) here, from caller.  Keep track of
processes that have already been waited for, by testing and
clearing new 'alive' member.
(CAN_HANDLE_MULTIPLE_CHILDREN): Remove, as record_child_status_change
now does this internally.
(handle_child_signal): Let record_child_status_change do all
the work, since we do not want to reap all exited child processes,
only the child processes that Emacs itself created.
* process.h (Lisp_Process): New boolean member 'alive'.

Fixes: debbugs:8855
2012-11-03 11:32:41 -07:00
Glenn Morris
4913840013 Rename cl-loop-handler, cl-loop-for-handler back to their original names
* lisp/emacs-lisp/cl-macs.el (cl-parse-loop-clause):
Rename handler properties back from cl-- to cl-.

Fixes: debbugs:12788
2012-11-03 11:32:09 -07:00
Glenn Morris
3a4d19175a More general edits for cl.texi Appendices 2012-11-03 11:23:38 -07:00
Paul Eggert
0d879dca46 Omit duplicate definitions no longer needed with gcc -g3.
* lisp.h (GCTYPEBITS, GCALIGNMENT, ARRAY_MARK_FLAG, PSEUDOVECTOR_FLAG)
(VALMASK, MOST_POSITIVE_FIXNUM, MOST_NEGATIVE_FIXNUM):
Define only as macros.  There's no longer any need to also define
these symbols as enums or as constants, since we now assume
gcc -g3 when debugging.
2012-11-03 11:19:50 -07:00
Glenn Morris
5c677d4410 * lisp/emacs-lisp/cl-macs.el (cl-do-all-symbols): Add doc string. 2012-11-03 11:03:39 -07:00
Glenn Morris
685b00269d Further edits for doc/misc/cl.texi
* cl.texi: Further general copyedits.
(List Functions): Remove copy-tree, standard elisp for some time.
(Efficiency Concerns): Comment out examples that no longer apply.
(Compiler Optimizations): Rename from "Optimizing Compiler"; reword.
2012-11-03 10:56:30 -07:00
Chong Yidong
77f6eafeca * lispref/objects.texi: Fix last change. 2012-11-04 00:54:11 +08:00
Chong Yidong
85fabcb7ee * process.c (wait_reading_process_output): Clean up last change. 2012-11-04 00:36:23 +08:00
Chong Yidong
893cc45585 Fix a race condition in wait_reading_process_output (tiny change).
* src/process.c (wait_reading_process_output): Avoid a race condition
with SIGIO delivery.

Fixes: debbugs:11536
2012-11-03 23:44:59 +08:00
Chong Yidong
0f7b074f4a * lisp/cus-start.el: Make cursor-type customizable.
* src/buffer.c (cursor_type): Untabify docstring.

Fixes: debbugs:11633
2012-11-03 23:24:00 +08:00
Eli Zaretskii
858f0f24b1 Adapt MSDOS port to latest changes.
config.bat: Copy lib/execinfo.in.h to lib/execinfo.in-h if needed.

 msdos/sedlibmk.inp: Sync with changes in lib/Makefile.in.
 (HAVE_DECL_ENVIRON, GNULIB_ENVIRON): Edit to require declaration
 through lib/unistd.h.
 msdos/sed1v2.inp: Sync with changes in src/Makefile.in.
 msdos/sed2v2.inp: Sync with changes in src/config.in.

 src/lisp.mk: Adjust comments to the fact that term/internal is now
 loaded from loadup.el.
 src/msdos.c (msdos_abort): Rename from emacs_abort, and make static.
 (msdos_fatal_signal): New function.
 (XMenuActivate): Adjust the call to kbd_buffer_events_waiting to
 its argument list.
 src/conf_post.h (_GL_EXECINFO_INLINE) [MSDOS]: Define to "inline"
 for GCC versions before 4.
 (emacs_raise): Define to call msdos_fatal_signal.

 lisp/term/pc-win.el: Don't load term/internal from here.
 lisp/loadup.el: Load term/internal from here.
2012-11-03 15:58:33 +02:00
Eli Zaretskii
1d4341f988 Load term/internal from loadup.el. 2012-11-03 15:56:02 +02:00
Eli Zaretskii
b3cf17f695 Adapt the MSDOS build to the latest changes on mainline. 2012-11-03 15:48:33 +02:00
Fabián Ezequiel Gallina
12fd5ee1ae * progmodes/python.el (inferior-python-mode): Fix hang in
jit-lock.

Fixes: debbugs:12645
2012-11-03 09:20:02 -03:00
Jan Djärv
ad10696b89 Backport from trunk.
* widget.c (resize_cb): New function.
(EmacsFrameRealize): Add resize_cb as event handler.
(EmacsFrameResize): Check if all is up to date before changing frame
size.

Fixes: debbugs:12733
2012-11-03 12:33:28 +01:00
Chong Yidong
2395ab64f6 Clarify documentation about escape sequences in strings.
* objects.texi (General Escape Syntax): Clarify the explanation of
escape sequences.
(Non-ASCII in Strings): Clarify when a string is unibyte vs
multibyte.  Hex escapes do not automatically make a string multibyte.
2012-11-03 19:02:43 +08:00
Martin Rudalics
43bcfda6d8 Doc changes related to displaying buffers and quitting windows.
* window.el (switch-to-visible-buffer)
(switch-to-buffer-preserve-window-point): Fix doc-strings.

* windows.texi (Switching Buffers): Document option
switch-to-buffer-preserve-window-point.
(Display Action Functions): Document window-height and
window-width alist entries.
(Display Action Functions): Document
display-buffer-below-selected and
display-buffer-in-previous-window.
(Quitting Windows): Document quit-restore-window.  Rewrite
section.
(Window Configurations): In window-state-get mention that
argument window must be valid.
(Window Parameters): Document quit-restore window parameter
(Bug#12158).
2012-11-03 11:47:03 +01:00
Eli Zaretskii
67b50ba47b Fix bidi initialization in init_from_display_pos.
src/xdisp.c (init_from_display_pos): Fix initialization of the bidi
 iterator when starting in the middle of a display or overlay
 string.

Fixes: debbugs:12745
2012-11-03 11:25:34 +02:00
Dmitry Antipov
3737fee7e3 * frame.h (struct frame): Drop can_have_scroll_bars member
which is meaningless for a long time.  Adjust comments.
(FRAME_CAN_HAVE_SCROLL_BARS): Remove.
* frame.c, nsfns.m, term.c, w32fns.c, xfns.c: Adjust users.
2012-11-03 09:59:17 +04:00
Dmitry Antipov
b6a9e8b1a2 * window.c (decode_next_window_args): Update window arg after
calling decode_live_window and so fix crash reported at
http://lists.gnu.org/archive/html/emacs-devel/2012-11/msg00035.html
by Juanma Barranquero <lekktu@gmail.com>.
(Fwindow_body_width, Fwindow_body_height): Simplify a bit.
* font.c (Ffont_at): Likewise.
2012-11-03 09:11:34 +04:00
Glenn Morris
f7e65065fc Fix attribution in ChangeLog 2012-11-02 21:26:25 -04:00
Glenn Morris
c65b407b40 * doc/misc/cl.texi: Further general copyedits.
Eg, no longer distinguish between "the optimizing compiler" and "the
non-optimizing compiler" like they were different entities.
2012-11-02 21:19:40 -04:00
Gnus developers
a71e2379a3 Merge changes made in Gnus master
2012-10-05  Katsumi Yamaoka  <yamaoka@jpl.org>
 * gnus.texi (Mail Source Specifiers):
 Document :leave keyword used for pop mail source.
2012-10-25  Tassilo Horn  <tsdh@gnu.org>
 * gnus-dired.el (gnus-dired-attach): Attach to last used message buffer
 by default.  Patch provided by Stephen Eglen.
2012-10-05  Katsumi Yamaoka  <yamaoka@jpl.org>
 New UIDL implementation.
 * mail-source.el (mail-sources, mail-source-keyword-map):
 Add :leave as a pop3 keyword.
 (mail-source-fetch-pop): Bind pop3-leave-mail-on-server.
 * pop3.el (pop3-leave-mail-on-server): Allow number.
 (pop3-uidl-file, pop3-uidl-file-backup): New user options.
 (pop3-movemail): Add UIDL support.
 (pop3-send-streaming-command): Take a list of mail numbers instead of
 the number of mails.
 (pop3-write-to-file): Add X-UIDL header.
 (pop3-uidl-stat, pop3-uidl-dele, pop3-uidl-load, pop3-uidl-save)
 (pop3-uidl-add-xheader): New functions.
 * message.el (message-ignored-resent-headers):
 Add X-Content-Length and X-UIDL headers.
2012-11-02 23:37:02 +00:00
Glenn Morris
00a3b04173 No need for filecache.el to load find-lisp when compiling
* lisp/filecache.el (find-lisp-find-files): Autoload it.
(file-cache-add-directory-recursively): Don't require find-lisp.
2012-11-02 18:44:38 -04:00
Glenn Morris
11fef14abb * lisp/image.el (image-type-from-file-name): Trivial simplification. 2012-11-02 18:41:35 -04:00
Glenn Morris
3a6851d9b4 Decouple "noruntime" and "cl-functions" bytecomp warnings
* lisp/emacs-lisp/bytecomp.el (byte-compile-eval):
Decouple "noruntime" and "cl-functions" warnings.
2012-11-02 18:35:01 -04:00
Glenn Morris
7fbf8f7bd9 Undocument cl-floatp-safe, since it is no longer relevant
* doc/misc/cl.texi (Naming Conventions, Type Predicates, Macros)
(Predicates on Numbers): No longer mention cl-floatp-safe.
2012-11-02 18:29:56 -04:00