X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=perlio.c;h=dd5f21c63d9d0cd1c9a6ff45c27441e67dd24879;hb=0dbd57a10c8cc972ad52305885705b0194739bca;hp=999b5fb19ffb4c3405265ca3f477aaa49f936ef2;hpb=be3c0a43e1e6b1244032726df02a3ab450a3c4be;p=p5sagit%2Fp5-mst-13.2.git diff --git a/perlio.c b/perlio.c index 999b5fb..dd5f21c 100644 --- a/perlio.c +++ b/perlio.c @@ -5,6 +5,11 @@ */ /* + * Hour after hour for nearly three weary days he had jogged up and down, + * over passes, and through long dales, and across many streams. + */ + +/* * If we have ActivePerl-like PERL_IMPLICIT_SYS then we need a dTHX to get * at the dispatch tables, even when we do not need it for other reasons. * Invent a dSYS macro to abstract this out @@ -187,6 +192,9 @@ PerlIO_fdupopen(pTHX_ PerlIO *f, CLONE_PARAMS *param, int flags) if (fd >= 0) { char mode[8]; int omode = fcntl(fd, F_GETFL); +#ifdef DJGPP + omode = djgpp_get_stream_mode(f); +#endif PerlIO_intmode2str(omode,mode,NULL); /* the r+ is a hack */ return PerlIO_fdopen(fd, mode);