unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Harald Maier <harald@maierh.de>
To: bug-gnu-emacs@gnu.org
Cc: emacs-pretest-bug@gnu.org
Subject: bug#1075: 23.0.60; [NS] wrong number of arguments in call to ns_free_indexed_color
Date: Fri, 03 Oct 2008 19:24:54 +0200	[thread overview]
Message-ID: <m2myhlr3q1.fsf@ate.maierh> (raw)
In-Reply-To: 48E62E8B.5010905@lysator.liu.se

Lennart Staflin <lenst@lysator.liu.se> writes:

> After a crash I with ns_free_indexed_color, and x_clear_image_1 on the
> stack. I noticed that x_clear_image_1 calls ns_free_indexed_color with
> only one argument, but it takes two arguments. Perhaps that explains a
> number of crashes in ns_free_indexed_color.
>
> //Lennart Staflin
>
>
> In GNU Emacs 23.0.60.1 (powerpc-apple-darwin8.11.0, *Step 9.0)
> of 2008-10-03 on sin
> Windowing system distributor `Apple', version 49.46.48
> configured using `configure '--with-ns' '--enable-maintainer-mode'
> --without-x' '--with-jpeg' '--with-gif' '--with-png' 'CFLAGS=-g''

I am facing this bug too. Here is a full backtrace. It happens
for me intermittent.

Harald

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x00000028
0x0015e306 in ns_free_indexed_color (idx=0, f=0x0) at nsterm.m:1310
(gdb) bt
#0  0x0015e306 in ns_free_indexed_color (idx=0, f=0x0) at nsterm.m:1310
#1  0x0018513a in x_clear_image_1 (f=<value temporarily unavailable, due to optimizations>, img=0x195778f0, pixmap_p=<value temporarily unavailable, due to optimizations>, mask_p=1, colors_p=1) at image.c:1627
#2  0x00184b93 in free_image (f=0x0, img=0x195778f0) at image.c:1322
#3  0x001854db in clear_image_cache (f=0x8b7150, filter=25165833) at image.c:1836
#4  0x001855b6 in clear_image_caches (filter=25165833) at image.c:1873
#5  0x00035868 in redisplay_internal (preserve_echo_area=<value temporarily unavailable, due to optimizations>) at xdisp.c:12060
#6  0x00035d28 in redisplay_preserve_echo_area (from_where=13) at xdisp.c:12094
#7  0x00146de7 in status_notify (deleting_process=0x0) at process.c:6906
#8  0x001498dc in wait_reading_process_output (time_limit=30, microsecs=0, read_kbd=-1, do_display=1, wait_for_cell=25165833, wait_proc=0x0, just_wait_proc=0) at process.c:4678
#9  0x0000c296 in sit_for (timeout=240, reading=1, do_display=1) at dispnew.c:6619
#10 0x0009bbf8 in read_char (commandflag=1, nmaps=6, maps=0xbfffdfd0, prev_event=25165833, used_mouse_menu=0xbfffe0d8, end_time=0x0) at keyboard.c:2895
#11 0x0009dc3b in read_key_sequence (keybuf=0xbfffe198, bufsize=30, prompt=25165833, dont_downcase_last=0, can_return_switch_frame=1, fix_current_buffer=1) at keyboard.c:9349
#12 0x000a012a in command_loop_1 () at keyboard.c:1620
#13 0x00101ffd in internal_condition_case (bfun=0x9fef0 <command_loop_1>, handlers=25205497, hfun=0x96ba0 <cmd_error>) at eval.c:1511
#14 0x0008ff38 in command_loop_2 () at keyboard.c:1338
#15 0x00101edc in internal_catch (tag=0, func=0x8fef0 <command_loop_2>, arg=25165833) at eval.c:1247
#16 0x0008fc8e in command_loop () at keyboard.c:1317
#17 0x0008fd52 in recursive_edit_1 () at keyboard.c:942
#18 0x0008fed1 in Frecursive_edit () at keyboard.c:1004
#19 0x0008eb6b in main (argc=1, argv=0xbfffe5a4) at emacs.c:1689

(gdb) bt full
#0  0x0015e306 in ns_free_indexed_color (idx=0, f=0x0) at nsterm.m:1310
        color_table = <value temporarily unavailable, due to optimizations>
#1  0x0018513a in x_clear_image_1 (f=<value temporarily unavailable, due to optimizations>, img=0x195778f0, pixmap_p=<value temporarily unavailable, due to optimizations>, mask_p=1, colors_p=1) at image.c:1627
No locals.
#2  0x00184b93 in free_image (f=0x0, img=0x195778f0) at image.c:1322
        c = (struct image_cache *) 0x16f0c540
#3  0x001854db in clear_image_cache (f=0x8b7150, filter=25165833) at image.c:1836
        img = (struct image *) 0x195778f0
        t = {
  tv_sec = 1218913349, 
  tv_usec = 686755
}
        old = 1218911549
        i = 3
        nfreed = 2
        c = (struct image_cache *) 0x16f0c540
#4  0x001855b6 in clear_image_caches (filter=25165833) at image.c:1873
        tail = 4300800
#5  0x00035868 in redisplay_internal (preserve_echo_area=<value temporarily unavailable, due to optimizations>) at xdisp.c:12060
        w = (struct window *) 0x195978f0
        f = <value temporarily unavailable, due to optimizations>
        pause = 0
        must_finish = 1
        tlbufpos = {
  charpos = 425537696, 
  bytepos = 425537696
}
        number_of_visible_frames = 1
        polling_stopped_here = 1
        old_frame = 9138516
        consider_all_windows_p = <value temporarily unavailable, due to optimizations>
#6  0x00035d28 in redisplay_preserve_echo_area (from_where=13) at xdisp.c:12094
No locals.
#7  0x00146de7 in status_notify (deleting_process=0x0) at process.c:6906
        proc = 422480020
        buffer = 425665812
        tail = <value temporarily unavailable, due to optimizations>
        msg = 51929347
#8  0x001498dc in wait_reading_process_output (time_limit=30, microsecs=0, read_kbd=-1, do_display=1, wait_for_cell=25165833, wait_proc=0x0, just_wait_proc=0) at process.c:4678
        Atemp = {
  fds_bits = {0 <repeats 32 times>}
}
        Ctemp = {
  fds_bits = {0 <repeats 32 times>}
}
        timeout_reduced_for_timers = 1
        channel = <value temporarily unavailable, due to optimizations>
        nfds = 1
        Available = {
  fds_bits = {128, 0 <repeats 31 times>}
}
        Connecting = {
  fds_bits = {0 <repeats 32 times>}
}
        check_connect = 0
        check_delay = 0
        no_avail = <value temporarily unavailable, due to optimizations>
        xerrno = <value temporarily unavailable, due to optimizations>
        proc = <value temporarily unavailable, due to optimizations>
        timeout = {
  tv_sec = 0, 
  tv_usec = 0
}
        end_time = {
  tv_sec = 1218913379, 
  tv_usec = 636576
}
        wait_channel = -1
        got_some_input = 1
#9  0x0000c296 in sit_for (timeout=240, reading=1, do_display=1) at dispnew.c:6619
        sec = <value temporarily unavailable, due to optimizations>
        usec = 0
#10 0x0009bbf8 in read_char (commandflag=1, nmaps=6, maps=0xbfffdfd0, prev_event=25165833, used_mouse_menu=0xbfffe0d8, end_time=0x0) at keyboard.c:2895
        tem0 = <value temporarily unavailable, due to optimizations>
        delay_level = 4
        buffer_size = <value temporarily unavailable, due to optimizations>
        c = 25165833
        count = <value temporarily unavailable, due to optimizations>
        jmpcount = 2
        local_getcjmp = {918399, 0, 8098, 633595, 981200, 3440316, 0, 3440316, -1073750152, -1073750544, 25165855, 662, 635534, 23, 31, 31, 33554432, -1073807305}
        save_jump = {0 <repeats 18 times>}
        key_already_recorded = 0
        tem = <value temporarily unavailable, due to optimizations>
        save = <value temporarily unavailable, due to optimizations>
        previous_echo_area_message = 25165833
        also_record = 25165833
        reread = 0
        polling_stopped_here = <value temporarily unavailable, due to optimizations>
        orig_kboard = (struct kboard *) 0x83b140
#11 0x0009dc3b in read_key_sequence (keybuf=0xbfffe198, bufsize=30, prompt=25165833, dont_downcase_last=0, can_return_switch_frame=1, fix_current_buffer=1) at keyboard.c:9349
        interrupted_kboard = (KBOARD *) 0x83b140
        key = 1058327
        used_mouse_menu = 0
        echo_local_start = 0
        last_real_key_start = 0
        keys_local_start = 0
        local_first_binding = 0
        from_string = 25165833
        count = 2
        t = 0
        echo_start = 0
        keys_start = 0
        nmaps = 6
        nmaps_allocated = 6
        defs = (Lisp_Object * volatile) 0xbfffdfa0
        submaps = (Lisp_Object * volatile) 0xbfffdfd0
        orig_local_map = 50222101
        orig_keymap = 25165833
        localized_local_map = 0
        first_binding = 0
        first_unbound = 31
        mock_input = 0
        fkey = {
  parent = 4941253, 
  map = 4941253, 
  start = 0, 
  end = 0
}
        keytran = {
  parent = 4386685, 
  map = 4386685, 
  start = 0, 
  end = 0
}
        indec = {
  parent = 4941261, 
  map = 4941261, 
  start = 0, 
  end = 0
}
        shift_translated = 0
        delayed_switch_frame = 25165833
        original_uppercase = -1073749720
        original_uppercase_position = -1
        starting_buffer = (struct buffer *) 0x19523aa0
        fake_prefixed_keys = 25165833
#12 0x000a012a in command_loop_1 () at keyboard.c:1620
        cmd = <value temporarily unavailable, due to optimizations>
        lose = <value temporarily unavailable, due to optimizations>
        nonundocount = 0
        keybuf = {35523785, 617387, 3441000, 25165833, -1073749464, 617600, 366757405, -1073749538, -1073749512, -1880941328, 4301001, 152, -1073749538, 25165833, 1, 10, 0, -1895817300, 6307477, 1, -1073749448, -1791741113, 50388496, 0, -1073749492, -1073749680, 0, 3866624, 25165833, 33476529}
        i = 1
        prev_modiff = 25222
        prev_buffer = (struct buffer *) 0x19523aa0
        already_adjusted = 0
#13 0x00101ffd in internal_condition_case (bfun=0x9fef0 <command_loop_1>, handlers=25205497, hfun=0x96ba0 <cmd_error>) at eval.c:1511
        val = <value temporarily unavailable, due to optimizations>
        c = {
  tag = 25165833, 
  val = 25165833, 
  next = 0xbfffe34c, 
  gcpro = 0x0, 
  jmp = {-1073806465, -1880940628, 8098, 1056523, 25165833, 25165833, 3440252, 3440316, -1073749272, -1073749456, 31, 662, 1056666, 1245207, 3407903, 3407903, -1073807360, -1073807305}, 
  backlist = 0x0, 
  handlerlist = 0x0, 
  lisp_eval_depth = 0, 
  pdlcount = 2, 
  poll_suppress_count = 1, 
  interrupt_input_blocked = 0, 
  byte_stack = 0x0
}
        h = {
  handler = 25205497, 
  var = 25165833, 
  chosen_clause = 25165881, 
  tag = 0xbfffe248, 
  next = 0x0
}
#14 0x0008ff38 in command_loop_2 () at keyboard.c:1338
        val = 0
#15 0x00101edc in internal_catch (tag=0, func=0x8fef0 <command_loop_2>, arg=25165833) at eval.c:1247
        c = {
  tag = 25201569, 
  val = 25165833, 
  next = 0x0, 
  gcpro = 0x0, 
  jmp = {-1791753345, 0, 8098, 1056313, -1791740947, 19216, 3440384, 3440316, -1073749048, -1073749200, 25296927, 662, 1056463, 25296919, 25296927, 25165855, 6291456, 4259895}, 
  backlist = 0x0, 
  handlerlist = 0x0, 
  lisp_eval_depth = 0, 
  pdlcount = 2, 
  poll_suppress_count = 1, 
  interrupt_input_blocked = 0, 
  byte_stack = 0x0
}
#16 0x0008fc8e in command_loop () at keyboard.c:1317
No locals.
#17 0x0008fd52 in recursive_edit_1 () at keyboard.c:942
        val = <value temporarily unavailable, due to optimizations>
#18 0x0008fed1 in Frecursive_edit () at keyboard.c:1004
        buffer = 25165833
#19 0x0008eb6b in main (argc=1, argv=0xbfffe5a4) at emacs.c:1689
        dummy = 0
        stack_bottom_variable = 0 '\000'
        do_initial_setlocale = 1
        skip_args = 0
        rlim = {
  rlim_cur = 8388608, 
  rlim_max = 67104768
}
        no_loadup = 0
        junk = 0x0










  reply	other threads:[~2008-10-03 17:24 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <0419D148-710C-48C8-9817-2D323CE8C693@gmail.com>
2008-07-21 16:36 ` bug#588: 23.0.60; with-ns emacs crash Lennart Staflin
2008-11-25  4:55   ` bug#588: marked as done (23.0.60; with-ns emacs crash) Emacs bug Tracking System
2008-07-21 18:17 ` bug#589: 23.0.60; repeated crashes Clifford Wulfman
2008-11-25  4:55   ` bug#589: marked as done (23.0.60; repeated crashes) Emacs bug Tracking System
2008-07-22 19:41 ` bug#596: 23.0.60; crash while running visiting a file in a buffer Clifford Wulfman
2008-11-25  4:55   ` bug#596: marked as done (23.0.60; crash while running visiting a file in a buffer) Emacs bug Tracking System
2008-07-24 14:11 ` bug#602: 23.0.60; Emacs.app crashes when trying to open new frame Clifford Wulfman
2008-11-25  4:55   ` bug#602: marked as done (23.0.60; Emacs.app crashes when trying to open new frame) Emacs bug Tracking System
2008-07-24 17:29 ` bug#605: 23.0.60; Cocoa Emacs crashes when Cmd-H is typed Clifford Wulfman
2008-11-25  4:55   ` bug#605: marked as done (23.0.60; Cocoa Emacs crashes when Cmd-H is typed) Emacs bug Tracking System
2008-07-24 20:12 ` bug#606: 23.0.60; Cocoa Emacs crashes in ns_free_indexed_color Clifford Wulfman
2008-11-25  4:55   ` bug#606: marked as done (23.0.60; Cocoa Emacs crashes in ns_free_indexed_color) Emacs bug Tracking System
2008-07-25 17:26 ` bug#609: 23.0.60; Cocoa Emacs crashes in ns_free_indexed_color Clifford Wulfman
2008-11-25  4:55   ` bug#609: marked as done (23.0.60; Cocoa Emacs crashes in ns_free_indexed_color) Emacs bug Tracking System
2008-08-23 22:22 ` bug#769: 23.0.60; crashing after sleep Clifford Wulfman
2008-11-25  4:55   ` bug#769: marked as done (23.0.60; crashing after sleep) Emacs bug Tracking System
2008-08-29 17:20 ` bug#822: 23.0.60; crash on font-panel selection Clifford Wulfman
2008-11-25  4:55   ` bug#822: marked as done (23.0.60; crash on font-panel selection) Emacs bug Tracking System
2008-08-29 19:41 ` bug#826: 23.0.60; emacs crashing after idle Clifford Wulfman
2008-11-25  4:55   ` bug#826: marked as done (23.0.60; emacs crashing after idle) Emacs bug Tracking System
2008-09-02 15:00 ` bug#863: 23.0.60; Crash in normal operation Clifford Wulfman
2008-11-25  4:55   ` bug#863: marked as done (23.0.60; Crash in normal operation) Emacs bug Tracking System
2008-09-12  6:50 ` bug#968: 23.0.60; CVS Emacs.app crashes randomly pat.maddox
     [not found]   ` <handler.968.B.122120224429237.ack@emacsbugs.donarmstrong.com>
2008-09-12 13:47     ` bug#968: Acknowledgement (23.0.60; CVS Emacs.app crashes randomly) Pat Maddox
2008-09-12 16:17   ` bug#968: 23.0.60; CVS Emacs.app crashes randomly Ted Zlatanov
2008-11-25  4:55   ` bug#968: marked as done (23.0.60; CVS Emacs.app crashes randomly) Emacs bug Tracking System
2008-10-03 14:39 ` bug#1075: 23.0.60; [NS] wrong number of arguments in call to ns_free_indexed_color Lennart Staflin
2008-10-03 17:24   ` Harald Maier [this message]
2008-10-03 17:53   ` Glenn Morris
2008-11-25  4:55   ` bug#1075: marked as done (23.0.60; [NS] wrong number of arguments in call to ns_free_indexed_color) Emacs bug Tracking System

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m2myhlr3q1.fsf@ate.maierh \
    --to=harald@maierh.de \
    --cc=1075@emacsbugs.donarmstrong.com \
    --cc=bug-gnu-emacs@gnu.org \
    --cc=emacs-pretest-bug@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).