Added tests for buffer overflow
Replaced global class buffer with local variants
Created method for closing connections
Moved retry code to own method
Added test for invalid timeout setting
Retry method implemented
Added check for range support
Added retry to getViaHttp