[RFC] - mysql-native rewrite

ollie ollie at home.net
Tue Oct 8 10:47:02 PDT 2013


On Sat, 28 Sep 2013 18:38:47 +0200, simendsjo wrote:

> I've been working on a more or less complete rewrite of the 
> mysql-native module.
> 

I think this is a great first step. Code is more readable, easier
to follow (compared to the pointer stuff in the original).

Code has some distinctly 64bit parts because Length Encoded Integer
can be as large as 48bits and consume functions use a mix of size_t
and (u)long. Code doesn't compile as is on 32bit machine (windows).
I have changed some (u)longs to size_t and put in some cast(size_t) on
the assumption that on a 32bit machine those values won't overflow a
uint and on 64bit machine the will be (u)long as written. It compiles
and works for some basic queries that I use. This is a hack, not a
solution to the problem.

Also, the socket reads are asserting because windows reads partial
packets. I change it to read until a full packet is read or an error
or disconnect is returned.

simendsjo, you have done a great job pushing this forward. Would you
consider putting it on your github account to receive some patches?

ollie


More information about the Digitalmars-d mailing list