<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -82,37 +82,9 @@ Please, contact me with any questions, comments, suggestions, or problems. I try
 to  make the time to answer every request. If you would like to submit a bug, or
 file an enhancement request, please [create a new ticket with Lighthouse] [1].
 
-Those  wishing  to  contribute  to  the  project  should  begin by obtaining the
-latest source with Git:
-
-    $ git clone git://github.com/eczarny/xmlrpc.git XMLRPC
-
-Now that you have a copy of the project, create a new local branch:
-
-    $ git checkout -b my-bug-fix
-
-This new branch, my-bug-fix, is where all of your changes should go.
-
-There  is  always  the possibility that new changes will be pushed to the remote
-repository while you make your changes in the my-bug-fix branch. The best way to
-keep  up-to-date  with  these changes is to pull them from the remote repository
-and use them as the new base for the my-bug-fix branch:
-
-    $ git checkout master
-    $ git pull
-    $ git rebase master my-bug-fix
-
-The changes from the remote repository are pulled into your local master branch,
-providing  you with the most recent base to apply your changes. The changes from
-your my-bug-fix branch will then use the most recent changes you pulled from the
-remote repository as their base.
-
-Finally, create the patch that you plan on submitting:
-
-    $ git format-patch master --stdout &gt; my-bug-fix.diff
-
-This  patch,  my-bug-fix.diff, now contains all of your changes. Please, be sure
-to provide your patch with a detailed description of your changes.
+Those  wishing to contribute to the project should begin by obtaining the latest
+source  with  Git. The project is hosted on GitHub, making it easy for anyone to
+make contributions. Simply create a fork and make your changes.
 
 # Have any questions or suggestions?
 </diff>
      <filename>README.markdown</filename>
    </modified>
    <modified>
      <diff>@@ -33,6 +33,7 @@
 #import &quot;XMLRPCConnectionManager.h&quot;
 #import &quot;XMLRPCRequest.h&quot;
 #import &quot;XMLRPCResponse.h&quot;
+#import &quot;NSStringAdditions.h&quot;
 
 @interface XMLRPCConnection (XMLRPCConnectionPrivate)
 </diff>
      <filename>XMLRPCConnection.m</filename>
    </modified>
    <modified>
      <diff>@@ -47,9 +47,25 @@ static XMLRPCConnectionManager *sharedInstance = nil;
 
 #pragma mark -
 
++ (id)allocWithZone: (NSZone *)zone {
+    @synchronized(self) {
+        if (!sharedInstance) {
+            sharedInstance = [super allocWithZone: zone];
+            
+            return sharedInstance;
+        }
+    }
+    
+    return nil;
+}
+
+#pragma mark -
+
 + (XMLRPCConnectionManager *)sharedManager {
-    if (!sharedInstance) {
-        sharedInstance = [[XMLRPCConnectionManager alloc] init];
+    @synchronized(self) {
+        if (!sharedInstance) {
+            [[self alloc] init];
+        }
     }
     
     return sharedInstance;</diff>
      <filename>XMLRPCConnectionManager.m</filename>
    </modified>
    <modified>
      <diff>@@ -90,9 +90,9 @@
         id parameter = nil;
         
         while (parameter = [enumerator nextObject]) {
-            [buffer appendString: @&quot;&lt;param&gt;&quot;];
+            [buffer appendString: @&quot;\n&lt;param&gt;\n&quot;];
             [buffer appendString: [self encodeObject: parameter]];
-            [buffer appendString: @&quot;&lt;/param&gt;&quot;];
+            [buffer appendString: @&quot;\n&lt;/param&gt;&quot;];
         }
     }
     
@@ -252,11 +252,10 @@
 }
 
 - (NSString *)encodeDate: (NSDate *)date {
-    unsigned components = kCFCalendarUnitYear | kCFCalendarUnitMonth | kCFCalendarUnitDay | kCFCalendarUnitHour | kCFCalendarUnitMinute | kCFCalendarUnitSecond;
-    NSDateComponents *dateComponents = [[NSCalendar currentCalendar] components: components fromDate: date];
-    NSString *buffer = [NSString stringWithFormat: @&quot;%.4d%.2d%.2dT%.2d:%.2d:%.2d&quot;, [dateComponents year], [dateComponents month], [dateComponents day], [dateComponents hour], [dateComponents minute], [dateComponents second], nil];
-    
-    return [self valueTag: @&quot;dateTime.iso8601&quot; value: buffer];
+	NSString *buffer = [date descriptionWithCalendarFormat: @&quot;%Y%m%dT%H:%M:%SZ&quot;
+		timeZone: [NSTimeZone timeZoneWithAbbreviation:@&quot;GMT&quot;] locale: nil];
+
+	return [self valueTag: @&quot;dateTime.iso8601&quot; value: buffer];
 }
 
 - (NSString *)encodeData: (NSData *)data {</diff>
      <filename>XMLRPCEncoder.m</filename>
    </modified>
    <modified>
      <diff>@@ -261,7 +261,7 @@
                 break;
             case XMLRPCEventBasedParserElementTypeString:
                 myElementValue = [self parseString: (NSString *)previousElementValue];
-                
+                if (myElementValue == NULL) { myElementValue = @&quot;&quot;; }
                 [previousElementValue release];
                 
                 break;
@@ -280,6 +280,10 @@
             default:
                 break;
         }
+        if(myElementValue == NULL)
+        {
+          [NSException raise:@&quot;Bad input data&quot; format:@&quot;Data for key %@ is invalid&quot;, elementName];
+        }
         
         [self addValueToParent];
         </diff>
      <filename>XMLRPCEventBasedParser.m</filename>
    </modified>
    <modified>
      <diff>@@ -43,12 +43,13 @@
         XMLRPCEventBasedParser *parser = [[XMLRPCEventBasedParser alloc] initWithData: data];
         
         if (!parser) {
-            return nil;
+          NSLog(@&quot;%s XML Parsing failed for the following input:&quot;, _cmd);
+          NSLog(@&quot;%s %@&quot;, _cmd, [[NSString alloc] initWithData: data encoding: NSISOLatin1StringEncoding]);
+          return nil;
         }
     
         myBody = [[NSString alloc] initWithData: data encoding: NSUTF8StringEncoding];
         myObject = [[parser parse] retain];
-        
         isFault = [parser isFault];
         
         [parser release];</diff>
      <filename>XMLRPCResponse.m</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>2c4b2d49dec47a750faa07ec258cc9c6d0108a31</id>
    </parent>
    <parent>
      <id>795faf91b7ee02c7230e41e15cc20bfab3ace174</id>
    </parent>
  </parents>
  <author>
    <name>Andrea Nall</name>
    <email>anall@andreanall.com</email>
  </author>
  <url>http://github.com/anall/xmlrpc/commit/c009fdb61920ac0cda4a35ff2348aa42aa012695</url>
  <id>c009fdb61920ac0cda4a35ff2348aa42aa012695</id>
  <committed-date>2009-05-18T04:24:18-07:00</committed-date>
  <authored-date>2009-05-18T04:24:18-07:00</authored-date>
  <message>Merge branch 'master' of git://github.com/anall/xmlrpc</message>
  <tree>88348beeab38ae551bdfe3e1a029c7fef8f0b145</tree>
  <committer>
    <name>Andrea Nall</name>
    <email>anall@andreanall.com</email>
  </committer>
</commit>
