emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Debugging printing to stderr prior glyph row values ....


From: Keith David Bershatsky
Subject: Re: Debugging printing to stderr prior glyph row values ....
Date: Thu, 23 May 2019 17:03:36 -0700

I got it to crash ... again.  "pgrowx previous_row" from gdb prints nothing and 
returns to a new gdb command prompt.

[CAVEAT:  I wanted a crash, so I did not insert a test for the 'used' member 
being greater than zero.]

Program received signal SIGSEGV, Segmentation fault.
0x0000000100045d3b in mc_draw_row (w=0x11b88b838, matrix=0x11b1d3210,
    row=0x105c89200, start=0x105d24e00, x=0, hpos_length=1, vpos=18,
    bottom_vpos=40, active_p=true, cursor_matrix=0x1011319c0, fc_x=770,
    ch_foreground=..., fc_foreground=..., mc_zv=16, mc_zv_byte=16,
    draw_p=false, from_where=SCRIBE_ONE) at xdisp.c:4605
4605      fprintf (stderr, "\nA.  vpos (%d) | glyph->charpos (%d) | posint (%d) 
| zv (%d) | zv_byte (%d)\n\


(gdb) pp w->contents

#<buffer *MC-TEST*>


(gdb) pgrowx previous_row


(gdb) pgrowx row

TEXT: 1 glyphs
  0    0: CHAR[ ] pos=-1 blev=0,btyp=UNDEF w=11 a+d=16+4 MB


(gdb) print vpos

$1 = 18


(gdb) print previous_row

$2 = (struct glyph_row *) 0x105c89100


(gdb) print *previous_row
$3 = {
  glyphs = {0x11a800000, 0x11a800000, 0x11a803520, 0x11a803520},
  used = {0, 0, 0, 0},
  hash = 0,
  x = 0,
  y = 344,
  pixel_width = 11,
  ascent = 16,
  height = 20,
  phys_ascent = 0,
  phys_height = 0,
  visible_height = 20,
  extra_line_spacing = 0,
  start = {
    pos = {
      charpos = 16,
      bytepos = 16
    },
    overlay_string_index = -1,
    string_pos = {
      charpos = -1,
      bytepos = -1
    },
    dpvec_index = -1
  },
  end = {
    pos = {
      charpos = 16,
      bytepos = 16
    },
    overlay_string_index = -1,
    string_pos = {
      charpos = -1,
      bytepos = -1
    },
    dpvec_index = -1
  },
  minpos = {
    charpos = 16,
    bytepos = 16
  },
  maxpos = {
    charpos = 16,
    bytepos = 16
  },
  overlay_arrow_bitmap = 0,
  left_user_fringe_bitmap = 0,
  right_user_fringe_bitmap = 0,
  left_fringe_bitmap = 0,
  right_fringe_bitmap = 0,
  left_user_fringe_face_id = 0,
  right_user_fringe_face_id = 0,
  left_fringe_face_id = 0,
  right_fringe_face_id = 0,
  left_fringe_offset = 0,
  right_fringe_offset = 0,
  fringe_bitmap_periodic_p = false,
  redraw_fringe_bitmaps_p = true,
  enabled_p = true,
  truncated_on_left_p = false,
  truncated_on_right_p = false,
  continued_p = false,
  displays_text_p = false,
  ends_at_zv_p = true,
  fill_line_p = false,
  indicate_empty_line_p = false,
  contains_overlapping_glyphs_p = false,
  full_width_p = false,
  mode_line_p = false,
  overlapped_p = false,
  ends_in_middle_of_char_p = false,
  starts_in_middle_of_char_p = false,
  overlapping_p = false,
  mouse_face_p = false,
  ends_in_newline_from_string_p = false,
  exact_window_width_line_p = false,
  cursor_in_fringe_p = false,
  ends_in_ellipsis_p = false,
  indicate_bob_p = false,
  indicate_top_line_p = false,
  indicate_eob_p = false,
  indicate_bottom_line_p = false,
  reversed_p = false,
  continuation_lines_width = 0,
  clip = 0x0
}

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

> Date: [05-23-2019 11:38:25] <23 May 2019 21:38:25 +0300>
> From: Eli Zaretskii <address@hidden>
> To: Keith David Bershatsky <address@hidden>
> CC: address@hidden
> Subject: Re: Debugging printing to stderr prior glyph row values ....
>
> > Date:  Thu, 23 May 2019 10:23:03 -0700
> > From:  Keith David Bershatsky <address@hidden>
> > Cc:  address@hidden
>
> > I will add a test for the `used` row member to ensure that it is positive.  
> > The crashing reported in the initial post only happens somtimes, so I'll 
> > need to do some further testing.
>
> Did you look at the problematic row with the GDB command "pgrowx"?
> It's important to understand what kind of glyphs are in that row and
> how many of them do you have there.
>
> * * *



reply via email to

[Prev in Thread] Current Thread [Next in Thread]