]> git.eshelyaron.com Git - emacs.git/commitdiff
(allocate_string) [GC_CHECK_STRING_BYTES]: Call
authorGerd Moellmann <gerd@gnu.org>
Wed, 18 Oct 2000 11:59:20 +0000 (11:59 +0000)
committerGerd Moellmann <gerd@gnu.org>
Wed, 18 Oct 2000 11:59:20 +0000 (11:59 +0000)
check_string_bytes only if not noninteractive, increase count to 50.

src/ChangeLog
src/alloc.c

index 9337d6b8e014c03ceb95f09c6c244243361aa59d..e7e83eef0f61cf6f49192ff815c5c71256d97181 100644 (file)
@@ -1,3 +1,20 @@
+2000-10-18  Gerd Moellmann  <gerd@gnu.org>
+
+       * xfns.c (x_to_xcolors, x_set_mouse_color, lookup_pixel_color)
+       (x_to_xcolors, png_load): Use x_query_color.
+
+       * xterm.c (x_color_cells, x_query_colors, x_query_color): New
+       functions.
+       (x_alloc_nearest_color): Use it to reduce calls to XQueryColors
+       which can be slow.
+       (x_copy_color, x_alloc_lighter_color): Likewise.
+
+       * xterm.h (struct x_display_info): Add color_cells and ncolor_cells.
+       (x_query_color, x_query_colors): Add prototype.
+
+       * alloc.c (allocate_string) [GC_CHECK_STRING_BYTES]: Call
+       check_string_bytes only if not noninteractive, increase count to 50.
+
 2000-10-18  Miles Bader  <miles@lsi.nec.co.jp>
 
        * insdel.c (adjust_markers_for_delete): Handle before-insertion
index a50eaa0a56039fe2504711a28037ac072ae2b9b7..510d4671183c0d9b5c120730cb648597f3d15e97 100644 (file)
@@ -1138,7 +1138,7 @@ allocate_string ()
   consing_since_gc += sizeof *s;
 
 #ifdef GC_CHECK_STRING_BYTES
-  if (++check_string_bytes_count == 10)
+  if (!noninteractive && ++check_string_bytes_count == 50)
     {
       check_string_bytes_count = 0;
       check_string_bytes ();