Download client library

Hi,

I am using download client for downloading a file.

I am using download_client_get and get fragments in callback.

When the file requested is short in the callback I have the received buffer

without any headers, while when the file is big, 1M for example, every chunk

has an http header.

I am asking if this depends on the server? If it possible to have only the payload and

not the headers or should I implement code to strip.

Is there any config for the library to have header stripped for example.

Thanks very much for help.

Best Regards 

  • Hi,

     

    When the file requested is short in the callback I have the received buffer

    without any headers, while when the file is big, 1M for example, every chunk

    has an http header.

    Is the issue you're describing here the range-request feature?

    This is default on, which allows a download to be resumed in case of network goes down.

     

    This can be disabled by setting CONFIG_DOWNLOAD_CLIENT_RANGE_REQUESTS=n

     

    Could you attach a log showing the behavior in question?

     

    Kind regards,

    Håkon

Related