docs: function(buff, off, buff_size) {
      var n;
  
      if(!zip_initflag)
      {
  	zip_init_deflate();
  	zip_initflag = true;
  	if(zip_lookahead == 0) { // empty
  	    zip_complete = true;
  	    return 0;
  	}
      }
  
      if((n = zip_qcopy(buff, off, buff_size)) == buff_size)
  	return buff_size;
  
      if(zip_complete)
  	return n;
  
      if(zip_compr_level <= 3) // optimized for speed
  	zip_deflate_fast();
      else
  	zip_deflate_better();
      if(zip_lookahead == 0) {
  	if(zip_match_available != 0)
  	    zip_ct_tally(0, zip_window[zip_strstart - 1] & 0xff);
  	zip_flush_block(1);
  	zip_complete = true;
      }
      return n + zip_qcopy(buff, n + off, buff_size - n);
  }