[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: EXC_BAD_ACCESS on Mac
From: |
Paul Eggert |
Subject: |
Re: EXC_BAD_ACCESS on Mac |
Date: |
Mon, 17 Jun 2013 15:42:54 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130514 Thunderbird/17.0.6 |
On 06/17/13 12:44, Kazu Yamamoto (山本和彦) wrote:
> why is "first - row->glyphs[area]"
> equal to "last - row->glyphs[area]"?
It could be because of this code in draw_glyphs:
/* Let's rather be paranoid than getting a SEGV. */
end = min (end, row->used[area]);
start = clip_to_bounds (0, start, end);
Even if 'start < end' before this code
is executed, it could be that start == end afterwards.
What happens if you apply the following patch and compile
with -DENABLE_CHECKING?
=== modified file 'src/xdisp.c'
--- src/xdisp.c 2013-06-15 09:34:20 +0000
+++ src/xdisp.c 2013-06-17 22:31:35 +0000
@@ -23356,9 +23356,7 @@
ALLOCATE_HDC (hdc, f);
- /* Let's rather be paranoid than getting a SEGV. */
- end = min (end, row->used[area]);
- start = clip_to_bounds (0, start, end);
+ eassert (0 <= start && start <= end && end <= row->used[area]);
/* Translate X to frame coordinates. Set last_x to the right
end of the drawing area. */
- EXC_BAD_ACCESS on Mac, 山本和彦, 2013/06/16
- Re: EXC_BAD_ACCESS on Mac, Eli Zaretskii, 2013/06/17
- Re: EXC_BAD_ACCESS on Mac, 山本和彦, 2013/06/17
- Re: EXC_BAD_ACCESS on Mac,
Paul Eggert <=
- Re: EXC_BAD_ACCESS on Mac, 山本和彦, 2013/06/17
- Re: EXC_BAD_ACCESS on Mac, 山本和彦, 2013/06/17
- Re: EXC_BAD_ACCESS on Mac, Eli Zaretskii, 2013/06/17
- Re: EXC_BAD_ACCESS on Mac, 山本和彦, 2013/06/17
- Re: EXC_BAD_ACCESS on Mac, Jan Djärv, 2013/06/24
- Re: EXC_BAD_ACCESS on Mac, 山本和彦, 2013/06/24
- Re: EXC_BAD_ACCESS on Mac, Eli Zaretskii, 2013/06/18
- Re: EXC_BAD_ACCESS on Mac, 山本和彦, 2013/06/18
- Show all lines in marked buffers matching a regexp (with patch), Matthias Meulien, 2013/06/18
- Re: Show all lines in marked buffers matching a regexp (with patch), Juri Linkov, 2013/06/19