Fix #64: invalid 'n' argument in upload

Fixes two problems with "transfer-encoding: chunked":

- When method="curl", chunked decode is already performed but no
  Content-Length is available (hence the "invalid 'n' arg" error)
- When method="internal", chunked decoding simply was not performed