From c42f93511844b118ebb3920d2478c1df61475b1a Mon Sep 17 00:00:00 2001 From: Jon Lund Steffensen Date: Mon, 3 Nov 2014 20:37:48 -0500 Subject: Fix #112: Do not buffer lines from child indefinitely --- src/redshift-gtk/statusicon.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/redshift-gtk') diff --git a/src/redshift-gtk/statusicon.py b/src/redshift-gtk/statusicon.py index 3e66649..04a944f 100644 --- a/src/redshift-gtk/statusicon.py +++ b/src/redshift-gtk/statusicon.py @@ -164,9 +164,11 @@ class RedshiftStatusIcon(object): self.suspend_timer = None # Handle child input + # The buffer is encapsulated in a class so we + # can pass an instance to the child callback. class InputBuffer(object): - lines = [] buf = '' + self.input_buffer = InputBuffer() self.error_buffer = InputBuffer() @@ -316,7 +318,6 @@ class RedshiftStatusIcon(object): if sep == '': break ib.buf = last - ib.lines.append(first) if stdout: self.child_stdout_line_cb(first) -- cgit v1.2.3-70-g09d2