we must use HTTPMemoryDownloadNoFreeCopy or 1 byte gets cut off the output
refactored