bug-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #34482] -[NSURLConnection sendSynchronousRequest:returningResponse:


From: julian
Subject: [bug #34482] -[NSURLConnection sendSynchronousRequest:returningResponse:error:] doesn't set response
Date: Wed, 05 Oct 2011 13:26:24 +0000
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/534.50 (KHTML, like Gecko) Version/5.1 Safari/534.50

URL:
  <http://savannah.gnu.org/bugs/?34482>

                 Summary: -[NSURLConnection
sendSynchronousRequest:returningResponse:error:] doesn't set response 
                 Project: GNUstep
            Submitted by: julian_
            Submitted on: Mi 05 Okt 2011 13:26:23 GMT
                Category: Base/Foundation
                Severity: 3 - Normal
              Item Group: None
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any

    _______________________________________________________

Details:

-[NSURLConnection sendSynchronousRequest:returningResponse:error:] doesn't set
any response, it is nil even if the call succeeds, so i have to use this code
(inline may eat some obvious asterisks):


NSError *_error = nil;
NSHTTPURLResponse *response = NULL;
NSData *_data = [NSURLConnection sendSynchronousRequest:request
returningResponse:&response error:&_error];

if (_data
#ifndef GNUSTEP
        && response && ([response statusCode] == 200)
#endif
        && (_error == nil))
{
 // handle success
}
else
{
 // handle failure
}
   




    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?34482>

_______________________________________________
  Nachricht geschickt von/durch Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]