meshing/IO.cpp
//scans until end of line is read
scans until end of line is read
scans until end of line is read
bool fgetline(FILE* f, char* buf,int bufsize)
{
  int c;
  int i=0;
  while(true) {
    c = fgetc(f);
    if(c == EOF) {
      buf[i] = 0;
      return false;
    }
    if(c == '\n') {
      buf[i] = 0;
      return true;
    }
    buf[i] = c;
    i++;
  }
  return false;
}
bool fgetline ( FILE * f , char * buf , int bufsize ) { int c ; int i = 0 ; while ( true ) { c = fgetc ( f ) ; if ( c == EOF ) { buf [ i ] = 0 ; return false ; } if ( c == ' \n ' ) { buf [ i ] = 0 ; return true ; } buf [ i ] = c ; i ++ ; } return false ; }
scans until end of line is read
scans until end of line is read
//read until end of line