Skip to content

Commit

Permalink
* view.c: Always call display() before close_error_pipe() to make
Browse files Browse the repository at this point in the history
  • Loading branch information
rillig committed Jul 13, 2005
1 parent ea48e88 commit de5d9b1
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2005-07-13 Roland Illig <[email protected]>

* view.c: Always call display() before close_error_pipe() to make
sure the screen looks nice.
http://mail.gnome.org/archives/mc-devel/2005-July/msg00194.html

2005-07-12 Roland Illig <[email protected]>

* view.c: Added some paragraph comments. Changed some literal
Expand Down
5 changes: 5 additions & 0 deletions src/view.c
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,7 @@ static void view_labels (WView * view);

static void view_init_growbuf (WView *);
static void view_place_cursor (WView *view);
static void display (WView *);

/* {{{ Helper Functions }}} */

Expand Down Expand Up @@ -406,6 +407,7 @@ view_growbuf_read_until (WView *view, offset_type ofs)
if (nread == 0) {
view->growbuf_finished = TRUE;
(void) pclose (view->ds_stdio_pipe);
display (view);
close_error_pipe (0, NULL);
view->ds_stdio_pipe = NULL;
return;
Expand Down Expand Up @@ -657,6 +659,7 @@ view_close_datasource (WView *view)
case DS_STDIO_PIPE:
if (view->ds_stdio_pipe != NULL) {
(void) pclose (view->ds_stdio_pipe);
display (view);
close_error_pipe (0, NULL);
view->ds_stdio_pipe = NULL;
}
Expand Down Expand Up @@ -1305,6 +1308,7 @@ view_load_command_output (WView *view, const char *command)
open_error_pipe ();
if ((fp = popen (command, "r")) == NULL) {
/* Avoid two messages. Message from stderr has priority. */
display (view);
if (!close_error_pipe (view_is_in_panel (view) ? -1 : 1, NULL))
view_show_error (view, _(" Cannot spawn child process "));
return FALSE;
Expand All @@ -1316,6 +1320,7 @@ view_load_command_output (WView *view, const char *command)
view_close_datasource (view);

/* Avoid two messages. Message from stderr has priority. */
display (view);
if (!close_error_pipe (view_is_in_panel (view) ? -1 : 1, NULL))
view_show_error (view, _("Empty output from child filter"));
return FALSE;
Expand Down

0 comments on commit de5d9b1

Please sign in to comment.