Irfan DANISH Irfan DANISH - 4 days ago 4
HTTP Question

What does HTTP status code 0 mean

I am working on iOS project.

In this application I am downloading images from server.

Problem:

While downloading images I am getting Request Timeout. According to documentation HTTP status code of request timeout is

408
.

But in my application I am getting HTTP status code
0
with following error

Error Domain=NSURLErrorDomain Code=-1001 "The request timed out." UserInfo=0xb9af710 {NSErrorFailingURLStringKey=http://xxxx.com/resources/p/PNG/1383906967_5621_63.jpg, NSErrorFailingURLKey=http://xxxx.com/resources/p/PNG/1383906967_5621_63.jpg, NSLocalizedDescription=The request timed out., NSUnderlyingError=0x13846870 "The request timed out."}


During search over internet I found no information about HTTP Status Code 0.

Can anyone explain this to me?

Answer

There is no HTTP status code 0. What you see is a 0 returned by the API/library that you are using. You will have to check the documentation for that.

Comments