curl err: Encountered end of file