Skip to content
Snippets Groups Projects
Commit 0cb59055 authored by Johan Schön's avatar Johan Schön
Browse files

gets now works with windows style text files.

Rev: lib/modules/Stdio.pmod:1.38
parent 4c6725ce
No related branches found
No related tags found
No related merge requests found
// $Id: Stdio.pmod,v 1.37 1999/01/30 01:22:09 grubba Exp $
// $Id: Stdio.pmod,v 1.38 1999/04/21 06:55:40 js Exp $
#include <string.h>
......@@ -394,7 +394,10 @@ class FILE {
string s;
s=b[bpos..bpos+bytes-1];
bpos += bytes+skip;
return s;
if(sizeof(s) && s[-1]=='\r')
return s[..sizeof(s)-2];
else
return s;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment