while( (line=gzgets(128)) != BooleanValue.FALSE ) { oldLength = sbv.length(); line.appendTo( sbv );   if( sbv.length() < oldLength+128 ) { array.put( sbv.toString() ); sbv = new StringBuilderValue(); }
while ((line=gzgets(Integer.MAX_VALUE)) != BooleanValue.FALSE) { array.put(line);
  public Value gzfile()  {    Value line;    int oldLength = 0;     ArrayValue array = new ArrayValueImpl();    StringBuilderValue sbv = new StringBuilderValue();    try {      //read in String BuilderValue's initial capacity      while( (line=gzgets(128)) != BooleanValue.FALSE )      {        oldLength = sbv.length();        line.appendTo( sbv );        //if read less than the maximum, then know that a newline or EOF has been encountered        if( sbv.length() < oldLength+128 )        {          array.put( sbv.toString() );          sbv = new StringBuilderValue();        }      }      return array;    } catch (Exception e) {      throw QuercusModuleException.create(e);    }  }