changeset: 4437:9bcdf9a3a783dd60aa09e1aadce72cca9d534e58
user: Jerry James <james(a)xemacs.org>
date: Mon Feb 04 21:41:27 2008 -0700
files: src/ChangeLog src/redisplay.c
description:
Use Dynarr_increment instead of Dynarr_add when building a line in place.
2008-02-03 Jerry James <james(a)xemacs.org>
* redisplay.c (generate_displayable_area): If a line has been
generated in place in the dynarray, use Dynarr_increment instead
of Dynarr_add.
* redisplay.c (regenerate_window): Ditto.
diff -r 0cee1ff42db4e80491b04d36066f37ff9794aff2 -r
9bcdf9a3a783dd60aa09e1aadce72cca9d534e58 src/ChangeLog
--- a/src/ChangeLog Sun Feb 03 10:35:25 2008 +0100
+++ b/src/ChangeLog Mon Feb 04 21:41:27 2008 -0700
@@ -1,3 +1,10 @@ 2008-02-01 Jerry James <james(a)xemacs.o
+2008-02-03 Jerry James <james(a)xemacs.org>
+
+ * redisplay.c (generate_displayable_area): If a line has been
+ generated in place in the dynarray, use Dynarr_increment instead
+ of Dynarr_add.
+ * redisplay.c (regenerate_window): Ditto.
+
2008-02-01 Jerry James <james(a)xemacs.org>
* event-Xt.c (emacs_Xt_event_handler): Remove unnecessary call to
diff -r 0cee1ff42db4e80491b04d36066f37ff9794aff2 -r
9bcdf9a3a783dd60aa09e1aadce72cca9d534e58 src/redisplay.c
--- a/src/redisplay.c Sun Feb 03 10:35:25 2008 +0100
+++ b/src/redisplay.c Mon Feb 04 21:41:27 2008 -0700
@@ -5395,8 +5395,12 @@ generate_displayable_area (struct window
else
dlp->clip = 0;
- assert (pos_of_dlp < 0 || pos_of_dlp == Dynarr_length (dla));
- Dynarr_add (dla, *dlp);
+ if (pos_of_dlp < 0)
+ Dynarr_add (dla, *dlp);
+ else if (pos_of_dlp == Dynarr_length (dla))
+ Dynarr_increment (dla);
+ else
+ ABORT ();
/* #### This type of check needs to be done down in the
generate_display_line call. */
@@ -5602,8 +5606,12 @@ Info on Re-entrancy crashes, with backtr
if (dlp->num_chars > w->max_line_len)
w->max_line_len = dlp->num_chars;
- assert (pos_of_dlp < 0 || pos_of_dlp == Dynarr_length (dla));
- Dynarr_add (dla, *dlp);
+ if (pos_of_dlp < 0)
+ Dynarr_add (dla, *dlp);
+ else if (pos_of_dlp == Dynarr_length (dla))
+ Dynarr_increment (dla);
+ else
+ ABORT ();
/* #### This isn't right, but it is close enough for now. */
w->window_end_pos[type] = start_pos;
_______________________________________________
XEmacs-Patches mailing list
XEmacs-Patches(a)xemacs.org
http://calypso.tux.org/cgi-bin/mailman/listinfo/xemacs-patches