fix a couple of warnings in test_json
fix warnings in test_threaded_calls
fix warnings in test_ndef_construction
don't do sizeof() on pointer

even in test
make functions static to drop warnings
use memcmp instead of strncmp to drop warnings in test