outstream = new ChunkedOutputStream(outstream);
}
if (contentLength >= 0) {
// don't need a watcher here - we're reading from something local,
// not server-side.
instream = new ContentLengthInputStream(instream, contentLength);
}
byte[] tmp = new byte[4096];
int total = 0;
int i = 0;