Don't attempt to set nil values

Can (for example) cause NSString properties to be set to @"(null)"
Don't use static buffer, as it's not thread safe
Merge pull request #1 from Jeffrey903/master

Don't attempt to set nil values and don't use static buffer