Now on revision 111314. ------------------------------------------------------------ revno: 111314 committer: Paul Eggert branch nick: trunk timestamp: Sun 2012-12-23 22:24:08 -0800 message: Merge from gnulib. diff: === modified file 'ChangeLog' --- ChangeLog 2012-12-21 19:32:43 +0000 +++ ChangeLog 2012-12-24 06:24:08 +0000 @@ -1,3 +1,10 @@ +2012-12-24 Paul Eggert + + Merge from gnulib, incorporating: + 2012-12-21 AC_PROG_MKDIR_P: port workaround to pre-2.62 Autoconf + 2012-12-20 AC_PROG_MKDIR_P: don't workaround if not buggy + 2012-12-17 filemode, sys_stat: Handle MPX files a la AIX. + 2012-12-21 Akinori MUSHA (tiny change) * Makefile.in (install-arch-dep): Ignore chmod errors. (Bug#13233) === modified file 'lib/filemode.c' --- lib/filemode.c 2012-05-26 23:14:36 +0000 +++ lib/filemode.c 2012-12-24 06:24:08 +0000 @@ -78,7 +78,7 @@ return 'C'; if (S_ISDOOR (bits)) return 'D'; - if (S_ISMPB (bits) || S_ISMPC (bits)) + if (S_ISMPB (bits) || S_ISMPC (bits) || S_ISMPX (bits)) return 'm'; if (S_ISNWK (bits)) return 'n'; === modified file 'lib/sys_stat.in.h' --- lib/sys_stat.in.h 2012-11-30 18:25:59 +0000 +++ lib/sys_stat.in.h 2012-12-24 06:24:08 +0000 @@ -150,6 +150,10 @@ # endif #endif +#ifndef S_ISMPX /* AIX */ +# define S_ISMPX(m) 0 +#endif + #ifndef S_ISNAM /* Xenix */ # ifdef S_IFNAM # define S_ISNAM(m) (((m) & S_IFMT) == S_IFNAM) === modified file 'm4/gnulib-common.m4' --- m4/gnulib-common.m4 2012-06-22 17:20:00 +0000 +++ m4/gnulib-common.m4 2012-12-24 06:24:08 +0000 @@ -294,6 +294,8 @@ # for interoperability with automake-1.9.6 from autoconf-2.62. # Remove this macro when we can assume autoconf >= 2.62 or # autoconf >= 2.60 && automake >= 1.10. +# AC_AUTOCONF_VERSION was introduced in 2.62, so use that as the witness. +m4_ifndef([AC_AUTOCONF_VERSION],[ m4_ifdef([AC_PROG_MKDIR_P], [ dnl For automake-1.9.6 && autoconf < 2.62: Ensure MKDIR_P is AC_SUBSTed. m4_define([AC_PROG_MKDIR_P], @@ -304,13 +306,15 @@ [AC_REQUIRE([AM_PROG_MKDIR_P])dnl defined by automake MKDIR_P='$(mkdir_p)' AC_SUBST([MKDIR_P])])]) +]) # AC_C_RESTRICT # This definition overrides the AC_C_RESTRICT macro from autoconf 2.60..2.61, # so that mixed use of GNU C and GNU C++ and mixed use of Sun C and Sun C++ # works. # This definition can be removed once autoconf >= 2.62 can be assumed. -m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.62]),[-1],[ +# AC_AUTOCONF_VERSION was introduced in 2.62, so use that as the witness. +m4_ifndef([AC_AUTOCONF_VERSION],[ AC_DEFUN([AC_C_RESTRICT], [AC_CACHE_CHECK([for C/C++ restrict keyword], [ac_cv_c_restrict], [ac_cv_c_restrict=no ------------------------------------------------------------ revno: 111313 author: Andreas Schwab committer: Katsumi Yamaoka branch nick: trunk timestamp: Mon 2012-12-24 04:21:58 +0000 message: lisp/gnus/shr.el (shr-tag-em): Render em as italic, not bold diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2012-12-23 12:45:01 +0000 +++ lisp/gnus/ChangeLog 2012-12-24 04:21:58 +0000 @@ -1,3 +1,7 @@ +2012-12-23 Andreas Schwab + + * shr.el (shr-tag-em): Render em as italic, not bold. + 2012-12-23 Lars Ingebrigtsen * gnus-int.el (gnus-backend-trace): Factor out into its own function === modified file 'lisp/gnus/shr.el' --- lisp/gnus/shr.el 2012-10-09 02:28:34 +0000 +++ lisp/gnus/shr.el 2012-12-24 04:21:58 +0000 @@ -894,7 +894,7 @@ (shr-fontize-cont cont 'italic)) (defun shr-tag-em (cont) - (shr-fontize-cont cont 'bold)) + (shr-fontize-cont cont 'italic)) (defun shr-tag-strong (cont) (shr-fontize-cont cont 'bold)) ------------------------------------------------------------ revno: 111312 committer: Eli Zaretskii branch nick: trunk timestamp: Sun 2012-12-23 19:16:33 +0200 message: Don't fail in acl_set_file on MS-Windows if the operation is a no-op. src/w32.c (acl_set_file): If setting the file security descriptor fails, and the new DACL is identical to the existing one, silently return success. This fixes problems for users backing up their own files without having the necessary privileges for setting security descriptors. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-12-23 17:06:58 +0000 +++ src/ChangeLog 2012-12-23 17:16:33 +0000 @@ -1,5 +1,11 @@ 2012-12-23 Eli Zaretskii + * w32.c (acl_set_file): If setting the file security descriptor + fails, and the new DACL is identical to the existing one, silently + return success. This fixes problems for users backing up their + own files without having the necessary privileges for setting + security descriptors. + * w32proc.c (reader_thread): Do not index fd_info[] with negative values. (reader_thread): Exit when cp->status becomes STATUS_READ_ERROR === modified file 'src/w32.c' --- src/w32.c 2012-12-23 17:06:58 +0000 +++ src/w32.c 2012-12-23 17:16:33 +0000 @@ -4876,8 +4876,31 @@ retval = 0; errno = e; } - else if (err == ERROR_INVALID_OWNER) - errno = EPERM; + else if (err == ERROR_INVALID_OWNER || err == ERROR_NOT_ALL_ASSIGNED) + { + /* Maybe the requested ACL and the one the file already has are + identical, in which case we can silently ignore the + failure. (And no, Windows doesn't.) */ + acl_t current_acl = acl_get_file (fname, ACL_TYPE_ACCESS); + + errno = EPERM; + if (current_acl) + { + char *acl_from = acl_to_text (current_acl, NULL); + char *acl_to = acl_to_text (acl, NULL); + + if (acl_from && acl_to && xstrcasecmp (acl_from, acl_to) == 0) + { + retval = 0; + errno = e; + } + if (acl_from) + acl_free (acl_from); + if (acl_to) + acl_free (acl_to); + acl_free (current_acl); + } + } else if (err == ERROR_FILE_NOT_FOUND || err == ERROR_PATH_NOT_FOUND) errno = ENOENT; ------------------------------------------------------------ revno: 111311 committer: Eli Zaretskii branch nick: trunk timestamp: Sun 2012-12-23 19:06:58 +0200 message: Improve handling of subprocess shutdown on MS-Windows. src/w32proc.c (reader_thread): Do not index fd_info[] with negative values. (reader_thread): Exit when cp->status becomes STATUS_READ_ERROR after WaitForSingleObject returns normally. This expedites reader thread shutdown when delete_child triggers it. (reap_subprocess): More accurate commentary for why we call delete_child only when cp->fd is negative. src/w32.c (sys_close): Do not call delete_child on a subprocess whose handle is not yet closed. Instead, set its file descriptor to a negative value, so that reap_subprocess will call delete_child on that subprocess when its SIGCHLD arrives. This avoids closing handles used for communications between sys_select and reader_thread, which doesn't give sys_select a chance to notice that the process exited and invoke the SIGCHLD handler for it. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-12-23 12:35:37 +0000 +++ src/ChangeLog 2012-12-23 17:06:58 +0000 @@ -1,3 +1,22 @@ +2012-12-23 Eli Zaretskii + + * w32proc.c (reader_thread): Do not index fd_info[] with negative + values. + (reader_thread): Exit when cp->status becomes STATUS_READ_ERROR + after WaitForSingleObject returns normally. This expedites reader + thread shutdown when delete_child triggers it. + (reap_subprocess): More accurate commentary for why we call + delete_child only when cp->fd is negative. + + * w32.c (sys_close): Do not call delete_child on a subprocess + whose handle is not yet closed. Instead, set its file descriptor + to a negative value, so that reap_subprocess will call + delete_child on that subprocess when its SIGCHLD arrives. This + avoids closing handles used for communications between sys_select + and reader_thread, which doesn't give sys_select a chance to + notice that the process exited and invoke the SIGCHLD handler for + it. + 2012-12-23 Jan Djärv * nsfns.m (Fns_do_applescript): Run event loop until script has === modified file 'src/w32.c' --- src/w32.c 2012-12-21 19:32:43 +0000 +++ src/w32.c 2012-12-23 17:06:58 +0000 @@ -6401,7 +6401,21 @@ winsock_inuse--; /* count open sockets */ } - delete_child (cp); + /* If the process handle is NULL, it's either a socket + or serial connection, or a subprocess that was + already reaped by reap_subprocess, but whose + resources were not yet freed, because its output was + not fully read yet by the time it was reaped. (This + usually happens with async subprocesses whose output + is being read by Emacs.) Otherwise, this process was + not reaped yet, so we set its FD to a negative value + to make sure sys_select will eventually get to + calling the SIGCHLD handler for it, which will then + invoke waitpid and reap_subprocess. */ + if (cp->procinfo.hProcess == NULL) + delete_child (cp); + else + cp->fd = -1; } } } === modified file 'src/w32proc.c' --- src/w32proc.c 2012-12-21 19:32:43 +0000 +++ src/w32proc.c 2012-12-23 17:06:58 +0000 @@ -965,7 +965,7 @@ { int rc; - if (fd_info[cp->fd].flags & FILE_LISTEN) + if (cp->fd >= 0 && fd_info[cp->fd].flags & FILE_LISTEN) rc = _sys_wait_accept (cp->fd); else rc = _sys_read_ahead (cp->fd); @@ -993,6 +993,8 @@ "%lu for fd %ld\n", GetLastError (), cp->fd)); break; } + if (cp->status == STATUS_READ_ERROR) + break; } return 0; } @@ -1163,11 +1165,11 @@ cp->procinfo.hThread = NULL; } - /* For asynchronous children, the child_proc resources will be freed - when the last pipe read descriptor is closed; for synchronous - children, we must explicitly free the resources now because - register_child has not been called. */ - if (cp->fd == -1) + /* If cp->fd was not closed yet, we might be still reading the + process output, so don't free its resources just yet. The call + to delete_child on behalf of this subprocess will be made by + sys_read when the subprocess output is fully read. */ + if (cp->fd < 0) delete_child (cp); } ------------------------------------------------------------ revno: 111310 committer: Jan D. branch nick: trunk timestamp: Sun 2012-12-23 15:46:37 +0100 message: * TODO: Adjust entry about NS event loop. diff: === modified file 'etc/ChangeLog' --- etc/ChangeLog 2012-12-19 21:32:56 +0000 +++ etc/ChangeLog 2012-12-23 14:46:37 +0000 @@ -1,3 +1,7 @@ +2012-12-23 Jan Djärv + + * TODO: Adjust entry about NS event loop. + 2012-12-19 Michael Albinus * NEWS: Tramp implements `file-acl' and `set-file-acl'. === modified file 'etc/TODO' --- etc/TODO 2012-09-16 21:43:55 +0000 +++ etc/TODO 2012-12-23 14:46:37 +0000 @@ -614,13 +614,11 @@ *** Bugs -**** The event loop relies on polling and that hurts performance. - A better strategy is to have the select part in its own thread and let - the main thread communicate with that thread (see how Gdk does it for - inspiration). A problem is that redraw don't happen during resize, +**** The event loop does not redraw. + A problem is that redraw don't happen during resize, because we can't break out from the NSapp loop during resize. - There is a special trick to detect mouse press in the lower right - corner and track mouse movements, but this does not work well, and is + There was a special trick to detect mouse press in the lower right + corner and track mouse movements, but this did not work well, and was not scalable to the new Lion "resize on every window edge" behavior. **** (mouse-avoidance-mode 'banish) then minimize Emacs, will pop window back ------------------------------------------------------------ revno: 111309 author: Gnus developers committer: Katsumi Yamaoka branch nick: trunk timestamp: Sun 2012-12-23 12:45:01 +0000 message: Merge changes made in Gnus master 2012-12-23 Lars Ingebrigtsen * gnus-int.el (gnus-backend-trace): Factor out into its own function for reuse. (gnus-open-server): Use it to add more tracing. (gnus-finish-retrieve-group-infos): Add backend tracing. 2012-12-22 Philipp Haselwarter * gnus-sync.el (gnus-sync-file-encrypt-to, gnus-sync-save): Set epa-file-encrypt-to from variable to avoid querying. diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2012-12-14 04:26:47 +0000 +++ lisp/gnus/ChangeLog 2012-12-23 12:45:01 +0000 @@ -1,3 +1,15 @@ +2012-12-23 Lars Ingebrigtsen + + * gnus-int.el (gnus-backend-trace): Factor out into its own function + for reuse. + (gnus-open-server): Use it to add more tracing. + (gnus-finish-retrieve-group-infos): Add backend tracing. + +2012-12-22 Philipp Haselwarter + + * gnus-sync.el (gnus-sync-file-encrypt-to, gnus-sync-save): Set + epa-file-encrypt-to from variable to avoid querying. + 2012-12-14 Akinori MUSHA (tiny change) * sieve-mode.el (sieve-font-lock-keywords): === modified file 'lisp/gnus/gnus-int.el' --- lisp/gnus/gnus-int.el 2012-08-31 04:39:30 +0000 +++ lisp/gnus/gnus-int.el 2012-12-23 12:45:01 +0000 @@ -249,16 +249,18 @@ (defvar gnus-backend-trace nil) +(defun gnus-backend-trace (type form) + (with-current-buffer (get-buffer-create "*gnus trace*") + (buffer-disable-undo) + (goto-char (point-max)) + (insert (format-time-string "%H:%M:%S") + (format " %s %S\n" type form)))) + (defun gnus-open-server (gnus-command-method) "Open a connection to GNUS-COMMAND-METHOD." (when (stringp gnus-command-method) (setq gnus-command-method (gnus-server-to-method gnus-command-method))) - (when gnus-backend-trace - (with-current-buffer (get-buffer-create "*gnus trace*") - (buffer-disable-undo) - (goto-char (point-max)) - (insert (format-time-string "%H:%M:%S") - (format " %S\n" gnus-command-method)))) + (gnus-backend-trace :opening gnus-command-method) (let ((elem (assoc gnus-command-method gnus-opened-servers)) (server (gnus-method-to-server-name gnus-command-method))) ;; If this method was previously denied, we just return nil. @@ -333,6 +335,7 @@ (save-excursion (gnus-agent-possibly-synchronize-flags-server gnus-command-method))) + (gnus-backend-trace :opened gnus-command-method) result))))) (defun gnus-close-server (gnus-command-method) @@ -353,9 +356,13 @@ "Read and update infos from GNUS-COMMAND-METHOD." (when (stringp gnus-command-method) (setq gnus-command-method (gnus-server-to-method gnus-command-method))) - (funcall (gnus-get-function gnus-command-method 'finish-retrieve-group-infos) - (nth 1 gnus-command-method) - infos data)) + (gnus-backend-trace :finishing gnus-command-method) + (prog1 + (funcall (gnus-get-function gnus-command-method + 'finish-retrieve-group-infos) + (nth 1 gnus-command-method) + infos data) + (gnus-backend-trace :finished gnus-command-method))) (defun gnus-retrieve-group-data-early (gnus-command-method infos) "Start early async retrieval of data from GNUS-COMMAND-METHOD." === modified file 'lisp/gnus/gnus-sync.el' --- lisp/gnus/gnus-sync.el 2012-12-06 03:30:23 +0000 +++ lisp/gnus/gnus-sync.el 2012-12-23 12:45:01 +0000 @@ -138,6 +138,11 @@ (defvar gnus-sync-newsrc-loader nil "Carrier for newsrc data") +(defcustom gnus-sync-file-encrypt-to nil + "If non-nil, `epa-file-encrypt-to' is set from this for encrypting the Sync + file." + :group 'gnus-sync) + (defcustom gnus-sync-lesync-name (system-name) "The LeSync name for this machine." :group 'gnus-sync @@ -762,6 +767,9 @@ (progn (let ((coding-system-for-write gnus-ding-file-coding-system) (standard-output (current-buffer))) + (when gnus-sync-file-encrypt-to + (set (make-local-variable 'epa-file-encrypt-to) + gnus-sync-file-encrypt-to)) (princ (format ";; -*- mode:emacs-lisp; coding: %s; -*-\n" gnus-ding-file-coding-system)) (princ ";; Gnus sync data v. 0.0.1\n") ------------------------------------------------------------ revno: 111308 fixes bug: http://debbugs.gnu.org/12969 committer: Jan D. branch nick: trunk timestamp: Sun 2012-12-23 13:35:37 +0100 message: * nsfns.m (Fns_do_applescript): Run event loop until script has been executed. (ns_run_ascript): Chech as_script for nil, set to nil after executing script. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-12-22 19:09:52 +0000 +++ src/ChangeLog 2012-12-23 12:35:37 +0000 @@ -1,3 +1,10 @@ +2012-12-23 Jan Djärv + + * nsfns.m (Fns_do_applescript): Run event loop until script has + been executed (Bug#12969). + (ns_run_ascript): Chech as_script for nil, set to nil after + executing script. + 2012-12-22 Martin Rudalics * window.c (Fselect_window): Reword doc-string (Bug#13248). === modified file 'src/nsfns.m' --- src/nsfns.m 2012-12-06 13:48:11 +0000 +++ src/nsfns.m 2012-12-23 12:35:37 +0000 @@ -2106,7 +2106,9 @@ void ns_run_ascript (void) { - as_status = ns_do_applescript (as_script, as_result); + if (! NILP (as_script)) + as_status = ns_do_applescript (as_script, as_result); + as_script = Qnil; } DEFUN ("ns-do-applescript", Fns_do_applescript, Sns_do_applescript, 1, 1, 0, @@ -2143,11 +2145,14 @@ data2: NSAPP_DATA2_RUNASSCRIPT]; [NSApp postEvent: nxev atStart: NO]; - [NSApp run]; + + // If there are other events, the event loop may exit. Keep running + // until the script has been handeled. */ + while (! NILP (as_script)) + [NSApp run]; status = as_status; as_status = 0; - as_script = Qnil; as_result = 0; unblock_input (); if (status == 0) ------------------------------------------------------------ revno: 111307 committer: Glenn Morris branch nick: trunk timestamp: Sat 2012-12-22 18:41:17 -0800 message: Mention self-registration for ftp uploads diff: === modified file 'admin/make-tarball.txt' --- admin/make-tarball.txt 2012-11-24 15:24:40 +0000 +++ admin/make-tarball.txt 2012-12-23 02:41:17 +0000 @@ -66,9 +66,8 @@ 11. Now you should upload the files to the GNU ftp server. In order to do that, you must be registered as an Emacs maintainer and have your - GPG key acknowledged by the ftp people. Mail - for instructions. - + GPG key acknowledged by the ftp people. For instructions, see + http://www.gnu.org/prep/maintain/html_node/Automated-Upload-Registration.html You can use the gnupload script to upload each FILE, like this: gnupload --to alpha.gnu.org:emacs/pretest FILE (for a pretest) gnupload --to ftp.gnu.org:emacs FILE (for a release)