[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] trunk r113852: Fix the Windows build broken by revision 11
From: |
Eli Zaretskii |
Subject: |
[Emacs-diffs] trunk r113852: Fix the Windows build broken by revision 113846. |
Date: |
Tue, 13 Aug 2013 18:01:30 +0000 |
User-agent: |
Bazaar (2.6b2) |
------------------------------------------------------------
revno: 113852
revision-id: address@hidden
parent: address@hidden
committer: Eli Zaretskii <address@hidden>
branch nick: trunk
timestamp: Tue 2013-08-13 21:01:18 +0300
message:
Fix the Windows build broken by revision 113846.
src/window.c (Fwindow_margins): Return nil when there's no marginal
area, as per the documented API.
src/w32term.c (x_scroll_bar_create): Use ALLOCATE_PSEUDOVECTOR, not
Fmake_vector, as scroll bar's struct members are not all Lisp
objects now. This avoids crashes in GC.
src/w32term.h (struct scroll_bar): Convert fringe_extended_p to a
bool, so its address could be taken.
modified:
src/ChangeLog changelog-20091113204419-o5vbwnq5f7feedwu-1438
src/w32term.c w32term.c-20091113204419-o5vbwnq5f7feedwu-950
src/w32term.h w32term.h-20091113204419-o5vbwnq5f7feedwu-954
src/window.c window.c-20091113204419-o5vbwnq5f7feedwu-231
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog 2013-08-13 17:45:34 +0000
+++ b/src/ChangeLog 2013-08-13 18:01:18 +0000
@@ -1,3 +1,15 @@
+2013-08-13 Eli Zaretskii <address@hidden>
+
+ * window.c (Fwindow_margins): Return nil when there's no marginal
+ area, as per the documented API.
+
+ * w32term.c (x_scroll_bar_create): Use ALLOCATE_PSEUDOVECTOR, not
+ Fmake_vector, as scroll bar's struct members are not all Lisp
+ objects now. This avoids crashes in GC.
+
+ * w32term.h (struct scroll_bar): Convert fringe_extended_p to a
+ bool, so its address could be taken.
+
2013-08-13 Lars Magne Ingebrigtsen <address@hidden>
* image.c (imagemagick_filename_hint): New function to possibly
=== modified file 'src/w32term.c'
--- a/src/w32term.c 2013-08-13 15:29:25 +0000
+++ b/src/w32term.c 2013-08-13 18:01:18 +0000
@@ -3757,7 +3757,7 @@
HWND hwnd;
SCROLLINFO si;
struct scroll_bar *bar
- = XSCROLL_BAR (Fmake_vector (make_number (VECSIZE (struct scroll_bar)),
Qnil));
+ = ALLOCATE_PSEUDOVECTOR (struct scroll_bar, fringe_extended_p, PVEC_OTHER);
Lisp_Object barobj;
block_input ();
=== modified file 'src/w32term.h'
--- a/src/w32term.h 2013-08-13 15:29:25 +0000
+++ b/src/w32term.h 2013-08-13 18:01:18 +0000
@@ -453,7 +453,9 @@
/* 1 if the background of the fringe that is adjacent to a scroll
bar is extended to the gap between the fringe and the bar. */
- unsigned fringe_extended_p : 1;
+ /* Note: this could be a bit field, but we need to take its address
+ in ALLOCATE_PSEUDOVECTOR (see x_scroll_bar_create). */
+ bool fringe_extended_p;
};
/* Turning a lisp vector value into a pointer to a struct scroll_bar. */
=== modified file 'src/window.c'
--- a/src/window.c 2013-08-13 14:45:58 +0000
+++ b/src/window.c 2013-08-13 18:01:18 +0000
@@ -6171,8 +6171,8 @@
(Lisp_Object window)
{
struct window *w = decode_live_window (window);
- return Fcons (make_number (w->left_margin_cols),
- make_number (w->right_margin_cols));
+ return Fcons (w->left_margin_cols ? make_number (w->left_margin_cols) : Qnil,
+ w->right_margin_cols ? make_number (w->right_margin_cols) :
Qnil);
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] trunk r113852: Fix the Windows build broken by revision 113846.,
Eli Zaretskii <=