dbgIn.write(buffer, 0, len);
  public Value gzdeflate(InputStream data,                         @Optional("6") int level)  {    TempBuffer tempBuf = TempBuffer.allocate();    byte []buffer = tempBuf.getBuffer();    try {      Deflater deflater = new Deflater(level, true);      boolean isFinished = false;      TempStream out = new TempStream();      int dbg = _dbg++;      WriteStream dbgIn = Vfs.openWrite("file:/tmp/td" + dbg + ".in");      WriteStream dbgOut = Vfs.openWrite("file:/tmp/td" + dbg + ".out");      int len;      while (! isFinished) {        if (! isFinished && deflater.needsInput()) {          len = data.read(buffer, 0, buffer.length);	  dbgIn.write(buffer, 0, len);          if (len > 0)            deflater.setInput(buffer, 0, len);          else {            isFinished = true;            deflater.finish();          }        }        while ((len = deflater.deflate(buffer, 0, buffer.length)) > 0) {          out.write(buffer, 0, len, false);	  dbgOut.write(buffer, 0, len);        }      }      deflater.end();      dbgIn.close();      dbgOut.close();      return new TempBufferStringValue(out.getHead());    } catch (Exception e) {      throw QuercusModuleException.create(e);    } finally {      TempBuffer.free(tempBuf);    }  }