emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] emacs-24 r117374: Attempt to fix bug #17962 with SIGSEGV i


From: Eli Zaretskii
Subject: [Emacs-diffs] emacs-24 r117374: Attempt to fix bug #17962 with SIGSEGV in display_line.
Date: Sat, 12 Jul 2014 10:29:48 +0000
User-agent: Bazaar (2.6b2)

------------------------------------------------------------
revno: 117374
revision-id: address@hidden
parent: address@hidden
fixes bug: http://debbugs.gnu.org/17962
committer: Eli Zaretskii <address@hidden>
branch nick: emacs-24
timestamp: Sat 2014-07-12 13:29:13 +0300
message:
  Attempt to fix bug #17962 with SIGSEGV in display_line.
  
   src/xdisp.c (display_line): Don't call FETCH_BYTE with argument less than 1.
modified:
  src/ChangeLog                  changelog-20091113204419-o5vbwnq5f7feedwu-1438
  src/xdisp.c                    xdisp.c-20091113204419-o5vbwnq5f7feedwu-240
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog     2014-07-12 09:25:29 +0000
+++ b/src/ChangeLog     2014-07-12 10:29:13 +0000
@@ -1,5 +1,8 @@
 2014-07-12  Eli Zaretskii  <address@hidden>
 
+       * xdisp.c (display_line): Don't call FETCH_BYTE with argument less
+       than 1.  (Bug#17962)
+
        * w32fns.c (Fx_file_dialog): Mention in the doc string the
        behavior on Windows 7 and later when the function is repeatedly
        invoked with the same value of DIR.  (Bug#17950)

=== modified file 'src/xdisp.c'
--- a/src/xdisp.c       2014-07-08 15:12:39 +0000
+++ b/src/xdisp.c       2014-07-12 10:29:13 +0000
@@ -20512,7 +20512,10 @@
          row->truncated_on_right_p = 1;
          it->continuation_lines_width = 0;
          reseat_at_next_visible_line_start (it, 0);
-         row->ends_at_zv_p = FETCH_BYTE (IT_BYTEPOS (*it) - 1) != '\n';
+         if (IT_BYTEPOS (*it) <= BEG_BYTE)
+           row->ends_at_zv_p = true;
+         else
+           row->ends_at_zv_p = FETCH_BYTE (IT_BYTEPOS (*it) - 1) != '\n';
          break;
        }
     }


reply via email to

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