Problems solved
I’ve been able to finally solve my two blocking problems and push out some new Windows binaries for Redland.
The MySQL buffer overflow was being caused by the sprintf format string - Windows doesn’t understand %llu, so I had to replace that with an %I64u format code. This fixed the problem, but I need to figure out a long-term fix (probably something nasty involving preprocessor macros). I also picked up on a little bug - the storage name was being escaped, but the unescaped string was being passed to sprintf. Oops. Easy fix, part of the next patch.
The null serializers turned out to be a little change in the #defines; as a result all the serializers (and most of the parsers) were disabled. Adding the appropriate definitions fixed this.
May 25th, 2005 at 10:19 am
Good catch on the unescaped model name being used in the actual query.
Looking forward to the patch.
May 26th, 2005 at 12:48 am
The “c99″ way of doing portable 64bit types is to use “inttypes.h”, uint64_t and printf(”%-6″ PRIu64,var); the PRIu64 uses strong concatenation to get the wrong thing.
Unfortunately I don’t believe windows supports this, so you end up with
#ifdef WIN32
typedef u_int32_t uint32_t;
#define PRIu64 “I64u”
#else
#include
#endif