Ar an naoiú lá de mí Lúnasa, scríobh Raymond Toy:
This crash is something new in b32. My init code was running fine
until I updated my build to b32. It's not 100% repeatable, but I can
sometimes make it happen by clicking in the window while xemacs is
loading up my init files.
The below fixes a definite bug, and that bug may well have provoked your
crash. It’s odd that it has only started showing up now, though, so it may
be that instead some compiler somewhere was choking on using the result of
Fcharset_list() as the list to be looped over in the LIST_LOOP macro.
# HG changeset patch
# User Aidan Kehoe <kehoea(a)parhasard.net>
# Date 1344767556 -3600
# Node ID b0d40183ac7959bf1c6f5fe0df678f83b5c8b0ec
# Parent febc025c4e0c6f95a8adc7995a072205e56cdf07
GC protect a freshly-consed list, define_specifier_tag().
src/ChangeLog addition:
2012-08-12 Aidan Kehoe <kehoea(a)parhasard.net>
* specifier.c (define_specifier_tag):
GC protect the list that Fcharset_list () gave back, it's freshly
consed.
Clear the alist entries for this tag in CHARSET's tag list if the
charset_predicate is nil, so re-creating a charset tag works more
effectively.
* specifier.c (Fdefine_specifier_tag):
Device-type-specific tags *are* available, even if that device
type isn't; see specifier.el.
diff -r febc025c4e0c -r b0d40183ac79 src/ChangeLog
--- a/src/ChangeLog Mon Aug 06 13:07:55 2012 +0100
+++ b/src/ChangeLog Sun Aug 12 11:32:36 2012 +0100
@@ -1,3 +1,15 @@
+2012-08-12 Aidan Kehoe <kehoea(a)parhasard.net>
+
+ * specifier.c (define_specifier_tag):
+ GC protect the list that Fcharset_list () gave back, it's freshly
+ consed.
+ Clear the alist entries for this tag in CHARSET's tag list if the
+ charset_predicate is nil, so re-creating a charset tag works more
+ effectively.
+ * specifier.c (Fdefine_specifier_tag):
+ Device-type-specific tags *are* available, even if that device
+ type isn't; see specifier.el.
+
2012-08-06 Aidan Kehoe <kehoea(a)parhasard.net>
* lread.c (read1):
diff -r febc025c4e0c -r b0d40183ac79 src/specifier.c
--- a/src/specifier.c Mon Aug 06 13:07:55 2012 +0100
+++ b/src/specifier.c Sun Aug 12 11:32:36 2012 +0100
@@ -1162,15 +1162,18 @@
if (recompute_charsets)
{
-
- LIST_LOOP_2 (charset_name, Fcharset_list ())
+ GC_EXTERNAL_LIST_LOOP_2 (charset_name, Fcharset_list ())
{
Lisp_Object charset = Fget_charset (charset_name);
Lisp_Object tag_list = Fgethash (charset, Vcharset_tag_lists, Qnil);
Lisp_Object charpres;
- if (NILP (charset_predicate))
- continue;
+ if (NILP (charset_predicate))
+ {
+ Fputhash (charset, remassq_no_quit (tag, tag_list),
+ Vcharset_tag_lists);
+ continue;
+ }
charpres = call_charset_predicate (charset_predicate, charset);
@@ -1186,6 +1189,7 @@
Vcharset_tag_lists);
}
}
+ END_GC_EXTERNAL_LIST_LOOP (charset_name);
}
return Qt;
}
@@ -1222,9 +1226,6 @@
You can redefine an existing user-defined specifier tag. However, you
cannot redefine most of the built-in specifier tags \(the device types and
classes, `initial', and `final') or the symbols nil, t, `all', or
`global'.
-Note that if a device type is not supported in this XEmacs, it will not be
-available as a built-in specifier tag; this is probably something we should
-change.
*/
(tag, device_predicate, charset_predicate))
{
--
‘Liston operated so fast that he once accidentally amputated an assistant’s
fingers along with a patient’s leg, […] The patient and the assistant both
died of sepsis, and a spectator reportedly died of shock, resulting in the
only known procedure with a 300% mortality.’ (Atul Gawande, NEJM, 2012)
_______________________________________________
XEmacs-Patches mailing list
XEmacs-Patches(a)xemacs.org
http://lists.xemacs.org/mailman/listinfo/xemacs-patches