summaryrefslogtreecommitdiff
path: root/src/screen.c
diff options
context:
space:
mode:
authorJérémie Courrèges-Anglas <jca@wxcvbn.org>2016-12-01 23:08:55 +0100
committerJérémie Courrèges-Anglas <jca@wxcvbn.org>2016-12-01 23:08:55 +0100
commit110e3829bf79da7153143f99d301c41cd4c4c777 (patch)
tree82fbf65e3557ac2f204b74c829de73d238785df3 /src/screen.c
parentf32bfb18f15244e1f2bd65064edbc6dbd167031b (diff)
downloadratpoison-110e3829bf79da7153143f99d301c41cd4c4c777.zip
Fix and simplify sfrestore
Use a scratch buffer for each screen, this simplifies a lot allocations and iterations, and allows restoring screens that contain more than one frame.
Diffstat (limited to 'src/screen.c')
-rw-r--r--src/screen.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/screen.c b/src/screen.c
index 77ce41d..fedddfa 100644
--- a/src/screen.c
+++ b/src/screen.c
@@ -320,6 +320,8 @@ init_screen (rp_screen *s)
/* Set the numset for the frames to our global numset. */
s->frames_numset = rp_frame_numset;
+ s->scratch_buffer = NULL;
+
/* Build the display string for each screen */
buf = sbuf_new (0);
sbuf_printf (buf, "DISPLAY=%s", DisplayString (dpy));