http://www.ousob.com --- Legacy Redefined #include <extend50.h> #define open _topen #define close _tclose #define lseek _tlseek #define read _tread #define write _twrite #define create _tcreat extern int _topen( char*, int); extern int _tclose( int ); extern long _tlseek( int, long, int); extern int _tread( int, char*, int); extern int _twrite( int, char*, int); extern int _tcreat( char*, int); CLIPPER b_readline() { register int ct = 0, i = 0; int bytesRead = 0; char buffr[1]; char buffer[1024]; int fileHandle = _parni(1); if( !ISNUM(1) ){ buffr[0] = NULL; _retc(buffr); return; } while( (bytesRead != read(fileHandle,buffr,1)) != 0 ){ buffer[ct] = *buffr; if( *buffr == '\n' ){ buffer[ct] = NULL; break; } ct++; } _retc(buffer); }