http_client: fix compiling if mem_size_t is smaller than size_t

This commit is contained in:
goldsimon 2018-03-21 09:33:00 +01:00
parent c881c48eed
commit c974fc9d43

View File

@ -727,7 +727,7 @@ httpc_fs_init(httpc_filestate_t **filestate_out, const char* local_file_name,
file_len = strlen(local_file_name);
alloc_len = sizeof(httpc_filestate_t) + file_len + 1;
filestate = (httpc_filestate_t *)mem_malloc(alloc_len);
filestate = (httpc_filestate_t *)mem_malloc((mem_size_t)alloc_len);
if (filestate == NULL) {
return ERR_MEM;
}