Now on revision 110128. ------------------------------------------------------------ revno: 110128 fixes bug: http://debbugs.gnu.org/11148 committer: Chong Yidong branch nick: trunk timestamp: Sat 2012-09-22 11:29:37 +0800 message: * frames.texi (Pop-Up Menus): Minor clarification for x-popup-menu. diff: === modified file 'doc/lispref/ChangeLog' --- doc/lispref/ChangeLog 2012-09-21 03:22:27 +0000 +++ doc/lispref/ChangeLog 2012-09-22 03:29:37 +0000 @@ -1,3 +1,7 @@ +2012-09-22 Chong Yidong + + * frames.texi (Pop-Up Menus): Minor clarification (Bug#11148). + 2012-09-21 Glenn Morris * debugging.texi (Using Debugger): Fix typo. === modified file 'doc/lispref/frames.texi' --- doc/lispref/frames.texi 2012-05-27 01:34:14 +0000 +++ doc/lispref/frames.texi 2012-09-22 03:29:37 +0000 @@ -1773,10 +1773,12 @@ (@var{title} @var{item1} @var{item2}...) @end example -Each item should normally be a cons cell @code{(@var{line} . @var{value})}, -where @var{line} is a string, and @var{value} is the value to return if -that @var{line} is chosen. An item can also be a string; this makes a -non-selectable line in the menu. +Each @var{item} should be a cons cell, @code{(@var{line} . @var{value})}, +where @var{line} is a string and @var{value} is the value to return if +that @var{line} is chosen. Unlike in a menu keymap, a @code{nil} +@var{value} does not make the menu item non-selectable. +Alternatively, each @var{item} can be a string rather than a cons +cell; this makes a non-selectable menu item. If the user gets rid of the menu without making a valid choice, for instance by clicking the mouse away from a valid choice or by typing ------------------------------------------------------------ revno: 110127 fixes bug: http://debbugs.gnu.org/8207 committer: Chong Yidong branch nick: trunk timestamp: Sat 2012-09-22 11:07:39 +0800 message: Fix auto-save and locking for indirect buffers. * lisp/simple.el (undo): Handle indirect buffers. * buffer.c (Fset_buffer_modified_p): Handle indirect buffers. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-09-21 03:03:48 +0000 +++ lisp/ChangeLog 2012-09-22 03:07:39 +0000 @@ -1,3 +1,7 @@ +2012-09-22 Chong Yidong + + * simple.el (undo): Handle indirect buffers (Bug#8207). + 2012-09-21 Leo Liu IDO: Disable match re-ordering for buffer switching. === modified file 'lisp/simple.el' --- lisp/simple.el 2012-09-07 08:58:31 +0000 +++ lisp/simple.el 2012-09-22 03:07:39 +0000 @@ -1855,9 +1855,13 @@ ;; another undo command will find the undo history empty ;; and will get another error. To begin undoing the undos, ;; you must type some other command. - (let ((modified (buffer-modified-p)) - (recent-save (recent-auto-save-p)) - message) + (let* ((modified (buffer-modified-p)) + ;; For an indirect buffer, look in the base buffer for the + ;; auto-save data. + (base-buffer (or (buffer-base-buffer) (current-buffer))) + (recent-save (with-current-buffer base-buffer + (recent-auto-save-p))) + message) ;; If we get an error in undo-start, ;; the next command should not be a "consecutive undo". ;; So set `this-command' to something other than `undo'. @@ -1935,7 +1939,8 @@ ;; Record what the current undo list says, ;; so the next command can tell if the buffer was modified in between. (and modified (not (buffer-modified-p)) - (delete-auto-save-file-if-necessary recent-save)) + (with-current-buffer base-buffer + (delete-auto-save-file-if-necessary recent-save))) ;; Display a message announcing success. (if message (message "%s" message)))) === modified file 'src/ChangeLog' --- src/ChangeLog 2012-09-22 02:26:05 +0000 +++ src/ChangeLog 2012-09-22 03:07:39 +0000 @@ -1,3 +1,8 @@ +2012-09-22 Chong Yidong + + * buffer.c (Fset_buffer_modified_p): Handle indirect buffers + (Bug#8207). + 2012-09-22 Kenichi Handa * composite.c (composition_reseat_it): Handle the case that a === modified file 'src/buffer.c' --- src/buffer.c 2012-09-15 07:06:56 +0000 +++ src/buffer.c 2012-09-22 03:07:39 +0000 @@ -1341,9 +1341,13 @@ /* If buffer becoming modified, lock the file. If buffer becoming unmodified, unlock the file. */ - fn = BVAR (current_buffer, file_truename); + struct buffer *b = current_buffer->base_buffer + ? current_buffer->base_buffer + : current_buffer; + + fn = BVAR (b, file_truename); /* Test buffer-file-name so that binding it to nil is effective. */ - if (!NILP (fn) && ! NILP (BVAR (current_buffer, filename))) + if (!NILP (fn) && ! NILP (BVAR (b, filename))) { bool already = SAVE_MODIFF < MODIFF; if (!already && !NILP (flag)) ------------------------------------------------------------ revno: 110126 [merge] committer: Kenichi Handa branch nick: trunk timestamp: Sat 2012-09-22 11:26:42 +0900 message: composite.c (composition_reseat_it): Handle the case that a grapheme cluster is not covered by a single font (Bug#12352). diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-09-21 03:52:23 +0000 +++ src/ChangeLog 2012-09-22 02:26:05 +0000 @@ -1,3 +1,8 @@ +2012-09-22 Kenichi Handa + + * composite.c (composition_reseat_it): Handle the case that a + grapheme cluster is not covered by a single font (Bug#12352). + 2012-09-21 Chong Yidong * image.c (define_image_type): Avoid adding duplicate types to @@ -163,7 +168,7 @@ (clean): Simplify nextstep entry. * ns.mk: Remove file. -2012-09-16 Kenichi Handa +2012-09-17 Kenichi Handa * font.c (Ffont_shape_gstring): Fix previous change; GLYPHs may not covert the last few charactes. === modified file 'src/composite.c' --- src/composite.c 2012-09-15 07:06:56 +0000 +++ src/composite.c 2012-09-22 02:15:29 +0000 @@ -1219,9 +1219,6 @@ ptrdiff_t bytepos, ptrdiff_t endpos, struct window *w, struct face *face, Lisp_Object string) { - if (endpos < 0) - endpos = NILP (string) ? BEGV : 0; - if (cmp_it->ch == -2) { composition_compute_stop_pos (cmp_it, charpos, bytepos, endpos, string); @@ -1230,6 +1227,9 @@ return 0; } + if (endpos < 0) + endpos = NILP (string) ? BEGV : 0; + if (cmp_it->ch < 0) { /* We are looking at a static composition. */ @@ -1277,36 +1277,23 @@ { ptrdiff_t cpos = charpos, bpos = bytepos; - while (1) - { - elt = XCAR (val); - if (cmp_it->lookback > 0) - { - cpos = charpos - cmp_it->lookback; - if (STRINGP (string)) - bpos = string_char_to_byte (string, cpos); - else - bpos = CHAR_TO_BYTE (cpos); - } - lgstring = autocmp_chars (elt, cpos, bpos, charpos + 1, w, face, - string); - if (composition_gstring_p (lgstring) - && cpos + LGSTRING_CHAR_LEN (lgstring) - 1 == charpos) - break; - /* Composition failed or didn't cover the current - character. */ - if (cmp_it->lookback == 0) - goto no_composition; - lgstring = Qnil; - /* Try to find a shorter composition that starts after CPOS. */ - composition_compute_stop_pos (cmp_it, charpos, bytepos, cpos, - string); - if (cmp_it->ch == -2 || cmp_it->stop_pos < charpos) - goto no_composition; - val = CHAR_TABLE_REF (Vcomposition_function_table, cmp_it->ch); - for (i = 0; i < cmp_it->rule_idx; i++, val = XCDR (val)); - } cmp_it->reversed_p = 1; + elt = XCAR (val); + if (cmp_it->lookback > 0) + { + cpos = charpos - cmp_it->lookback; + if (STRINGP (string)) + bpos = string_char_to_byte (string, cpos); + else + bpos = CHAR_TO_BYTE (cpos); + } + lgstring = autocmp_chars (elt, cpos, bpos, charpos + 1, w, face, + string); + if (! composition_gstring_p (lgstring) + || cpos + LGSTRING_CHAR_LEN (lgstring) - 1 != charpos) + /* Composition failed or didn't cover the current + character. */ + goto no_composition; } if (NILP (lgstring)) goto no_composition; @@ -1341,6 +1328,8 @@ /* BYTEPOS is calculated in composition_compute_stop_pos */ bytepos = -1; } + if (cmp_it->reversed_p) + endpos = -1; composition_compute_stop_pos (cmp_it, charpos, bytepos, endpos, string); return 0; } ------------------------------------------------------------ revno: 110125 committer: Paul Eggert branch nick: trunk timestamp: Fri 2012-09-21 12:28:41 -0700 message: * trouble.texi (Crashing): Document addr2line. diff: === modified file 'doc/emacs/ChangeLog' --- doc/emacs/ChangeLog 2012-09-19 06:51:33 +0000 +++ doc/emacs/ChangeLog 2012-09-21 19:28:41 +0000 @@ -1,3 +1,7 @@ +2012-09-21 Paul Eggert + + * trouble.texi (Crashing): Document addr2line. + 2012-09-19 Chong Yidong * killing.texi (Yanking): Minor clarification (Bug#12469). === modified file 'doc/emacs/trouble.texi' --- doc/emacs/trouble.texi 2012-09-04 18:29:04 +0000 +++ doc/emacs/trouble.texi 2012-09-21 19:28:41 +0000 @@ -308,13 +308,26 @@ @noindent The number @samp{11} is the system signal number that corresponds to -the problem, a segmentation fault here. The hexadecimal program -addresses can be useful in debugging sessions. For example, the GDB -command @samp{list *0x509af6} prints the source-code lines -corresponding to the @samp{emacs[0x509af6]} entry in the backtrace. - -The three dots at the end indicate that Emacs suppressed further -backtrace entries, in the interest of brevity. +the problem, a segmentation fault here. The three dots at the end +indicate that Emacs suppressed further backtrace entries, in the +interest of brevity. + +The hexadecimal program addresses can be useful in debugging sessions. +For example, the GDB command @samp{list *0x509af6} prints the +source-code lines corresponding to the @samp{emacs[0x509af6]} entry in +the backtrace. Or, if your system has @command{addr2line}, the +following shell command outputs a backtrace with source-code line +numbers: + +@example +sed -n 's/.*\[\(.*\)]$/\1/p' @var{backtrace} | + addr2line -Cfip -e @var{bindir}/emacs +@end example + +@noindent +Here, @var{backtrace} is the name of a text file containing a copy of +the backtrace, and @var{bindir} is the name of the directory that +contains the Emacs executable. @node After a Crash @subsection Recovery After a Crash ------------------------------------------------------------ revno: 110124 fixes bug: http://debbugs.gnu.org/12463 committer: Chong Yidong branch nick: trunk timestamp: Fri 2012-09-21 11:52:23 +0800 message: Fix list duplication error in define_image_type. * image.c (define_image_type): Avoid adding duplicate types to image_types. Suggested by Jörg Walter. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-09-21 03:03:48 +0000 +++ src/ChangeLog 2012-09-21 03:52:23 +0000 @@ -1,3 +1,8 @@ +2012-09-21 Chong Yidong + + * image.c (define_image_type): Avoid adding duplicate types to + image_types (Bug#12463). Suggested by Jörg Walter. + 2012-09-21 YAMAMOTO Mitsuharu * unexmacosx.c: Define LC_DATA_IN_CODE if not defined. === modified file 'src/image.c' --- src/image.c 2012-09-15 08:45:27 +0000 +++ src/image.c 2012-09-21 03:52:23 +0000 @@ -590,9 +590,15 @@ success = Qnil; else { + struct image_type *p; + Lisp_Object target_type = *(type->type); + for (p = image_types; p; p = p->next) + if (EQ (*(p->type), target_type)) + return Qt; + /* Make a copy of TYPE to avoid a bus error in a dumped Emacs. The initialized data segment is read-only. */ - struct image_type *p = xmalloc (sizeof *p); + p = xmalloc (sizeof *p); *p = *type; p->next = image_types; image_types = p; ------------------------------------------------------------ Use --include-merged or -n0 to see merged revisions.