File: 30outstream.patch

package info (click to toggle)
libterm-readline-gnu-perl 1.24-2~bpo70%2B1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy-backports
  • size: 556 kB
  • sloc: perl: 1,664; ansic: 112; makefile: 10
file content (17 lines) | stat: -rw-r--r-- 509 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# 30outstream.patch by Niko Tyni <ntyni@iki.fi>
# DP: Fix SIGSEGV after "|" command. (#236018)
--- a/Gnu.xs
+++ b/Gnu.xs
@@ -3166,6 +3166,12 @@
 	      PerlIO_releaseFILE(outstreamPIO, rl_outstream);
 #endif
 	    rl_outstream = PerlIO_findFILE(stream);
+	    /*
+	     * Debian-specific addition fixing a segfault with "PERLIO=stdio"
+	     * see http://bugs.debian.org/350991
+	     */
+	    if (!rl_outstream)
+	      rl_outstream = stdout;
 	    RETVAL = outstreamPIO = stream;
 #ifdef __CYGWIN__
 	    {