Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitb7e1ae2

Browse files
committed
Restore psql's SIGPIPE setting if popen() fails.
Ancient oversight in PageOutput(): if popen() fails, we'd better resetthe SIGPIPE handler before returning stdout, because ClosePager() won't.Noticed while fixing the empty-PAGER issue.
1 parent18f8f78 commitb7e1ae2

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

‎src/fe_utils/print.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2884,6 +2884,8 @@ PageOutput(int lines, const printTableOpt *topt)
28842884
pagerpipe=popen(pagerprog,"w");
28852885
if (pagerpipe)
28862886
returnpagerpipe;
2887+
/* if popen fails, silently proceed without pager */
2888+
restore_sigpipe_trap();
28872889
}
28882890
}
28892891

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp