On Fri, Mar 19, 2010 at 9:07 AM, Matteo Beccati <p...@beccati.com> wrote: > > So, I tried to make some time and looked at the patch for 5.3. I have to say > that I haven't tested it nor I'm an expert by any means of the > sybase/mysql/freetds api. > > Here are my findings: > > 1. dblib_driver.c and the README were changed so that the driver will always > register as "dblib" > > Seems like a pretty big behaviour change, moreover completely unrelated to > the bug fix. >
Reverted in new patch version. > > 2. dblib_driver.c also contains whitespace changes, comments and dbsetopt vs > DBSETOPT > > Not sure how these are related to the bug fix. > Reverted. > > 3. lots of constants removed from php_pdo_dblib_int.h > > Can you explain why? I guess they were used for compatibility purposes. > Reverted, although these are likely for MS DBLIB which has a big-fat depreciation notice on it. These aliases really belong in the TDS lib header files, but this is for anther list. > > 4. pdo_dblib_stmt_describe > > this one looks suspicious: > > + col->name = (char*)dbcolname(H->link, colno+1); > + > + if (!strlen(col->name)) { > + spprintf(&tmp, 0, "computed%d", colno); > + strlcpy(col->name, tmp, strlen(tmp)+1); > + efree(tmp); > > Aren't you overwriting memory that belongs to the library? > Yes I was, and that's A Bad Thing. This has been removed in the revised patch. I removed the automagic column naming as the values are addressable by numeric keys. But I would like to know if anyone relies on this behavior. > > For now I couldn't find anything else to comment about, but I've had very > little time. > > > Cheers > -- > Matteo Beccati > > Development & Consulting - http://www.beccati.com/ > -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php