code: protected void wrapBuffer() throws IOException
      {
          if (size()==0)
              return;
  
          if (_buf!=_packet.getBuffer())
          {
              _packet=new AJP13ResponsePacket(_buf);
              _packet.prepare();
          }
  
          prewrite(_buf,0,AJP13ResponsePacket.__DATA_HDR);
          _packet.resetData();
          _packet.addByte(AJP13ResponsePacket.__SEND_BODY_CHUNK);
          _packet.setDataSize(size()-AJP13ResponsePacket.__HDR_SIZE);
          postwrite((byte)0);
      }
docs: /* ------------------------------------------------------------