[subversion:65] appeasing clang static analyzer by useing 'copy' instead of 'create' in

  • From: itod@kenai.com
  • To: commits@mac-httpclient.kenai.com
  • Subject: [subversion:65] appeasing clang static analyzer by useing 'copy' instead of 'create' in
  • Date: Sun, 15 Feb 2009 23:34:48 +0000 (GMT)

Repository: subversion
Revision:   65
Author:     itod
Date:       2009-02-15 23:34:42 UTC
Link:      
http://kenai.com/projects/mac-httpclient/sources/subversion/revision/65

Log Message:
-----------
appeasing clang static analyzer by useing 'copy' instead of 'create' in
cocoa method name

Modified Paths:
--------------
    HTTPClient/src/HTTPServiceCFNetworkImpl.m

Diffs:
-----
Index: HTTPClient/src/HTTPServiceCFNetworkImpl.m
===================================================================
--- HTTPClient/src/HTTPServiceCFNetworkImpl.m   (revision 64)
+++ HTTPClient/src/HTTPServiceCFNetworkImpl.m   (revision 65)
@@ -18,8 +18,8 @@
                      followRedirects:(BOOL)followRedirects 
                    getFinalURLString:(NSString **)outFinalURLString;
 
-- (CFHTTPMessageRef)createHTTPRequestWithURL:(NSURL *)URL
method:(NSString *)method body:(NSString *)body headers:(NSArray
*)headers;
--
(CFHTTPMessageRef)createResponseBySendingHTTPRequest:(CFHTTPMessageRef)
req followRedirects:(BOOL)followRedirects;
+- (CFHTTPMessageRef)copyHTTPRequestWithURL:(NSURL *)URL
method:(NSString *)method body:(NSString *)body headers:(NSArray
*)headers;
+-
(CFHTTPMessageRef)copyResponseBySendingHTTPRequest:(CFHTTPMessageRef)re
q followRedirects:(BOOL)followRedirects;
 - (NSString *)rawStringForHTTPMessage:(CFHTTPMessageRef)message;
 -
(NSStringEncoding)stringEncodingForBodyOfHTTPMessage:(CFHTTPMessageRef)
message;
 
@@ -104,14 +104,14 @@
 
 - (NSString *)makeHTTPRequestWithURL:(NSURL *)URL method:(NSString
*)method body:(NSString *)body headers:(NSArray *)headers
followRedirects:(BOOL)followRedirects getFinalURLString:(NSString
**)outFinalURLString {
     NSString *result = nil;
-    CFHTTPMessageRef request = [self createHTTPRequestWithURL:URL
method:method body:body headers:headers];
+    CFHTTPMessageRef request = [self copyHTTPRequestWithURL:URL
method:method body:body headers:headers];
     CFHTTPMessageRef response = NULL;
     CFHTTPAuthenticationRef auth = NULL;
     NSInteger count = 0;
     
     while (1) {
         //    send request
-        response = [self createResponseBySendingHTTPRequest:request
followRedirects:followRedirects];
+        response = [self copyResponseBySendingHTTPRequest:request
followRedirects:followRedirects];
         
         if (!response) {
             result = nil;
@@ -170,7 +170,7 @@
             response = NULL;
         }
         
-        request = [self createHTTPRequestWithURL:URL method:method
body:body headers:headers];
+        request = [self copyHTTPRequestWithURL:URL method:method
body:body headers:headers];
         
         NSMutableDictionary *creds = [NSMutableDictionary
dictionaryWithObjectsAndKeys:
                                       username, 
kCFHTTPAuthenticationUsername,
@@ -212,7 +212,7 @@
 }
 
 
-- (CFHTTPMessageRef)createHTTPRequestWithURL:(NSURL *)URL
method:(NSString *)method body:(NSString *)body headers:(NSArray
*)headers {
+- (CFHTTPMessageRef)copyHTTPRequestWithURL:(NSURL *)URL
method:(NSString *)method body:(NSString *)body headers:(NSArray
*)headers {
     
     CFHTTPMessageRef message =
CFHTTPMessageCreateRequest(kCFAllocatorDefault, (CFStringRef)method,
(CFURLRef)URL, kCFHTTPVersion1_1);
     
@@ -235,7 +235,7 @@
 }
 
 
--
(CFHTTPMessageRef)createResponseBySendingHTTPRequest:(CFHTTPMessageRef)
req followRedirects:(BOOL)followRedirects {
+-
(CFHTTPMessageRef)copyResponseBySendingHTTPRequest:(CFHTTPMessageRef)re
q followRedirects:(BOOL)followRedirects {
     CFHTTPMessageRef response = NULL;
     NSMutableData *responseBodyData = [NSMutableData data];


[subversion:65] appeasing clang static analyzer by useing 'copy' instead of 'create' in

itod 02/15/2009
  • Mysql
  • Glassfish
  • Jruby
  • Rails
  • Nblogo
Terms of Use; Privacy Policy;
© 2010, Oracle Corporation and/or its affiliates
(revision 20120518.3c65429)
 
 
Close
loading
Please Confirm
Close