[freetds] CS_INT size bug

Norbert Sendetzky norbert at linuxnetworks.de
Sun Sep 3 13:52:26 EDT 2006

On Sunday 03 September 2006 18:00, freetds-request at lists.ibiblio.org wrote:
> > The 32 bit types CS_INT and tds_sysdep_int32_type are incorrectly defined
> > to "int", which is only true for 32bit plattforms.
> tds_sysdep_public.h is generated by the configure script, which tests the
> machine it's run on and sets the size of tds_sysdep_int32_type accordingly.
> If you were to run configure on a 32-bit machine and move the resulting
> source code tree to a 64-bit one, I'd expect the error you're encountering
> (unless you used the --build option).
> If you didn't do anything so fancy, please have a look at config.log and
> let us know what hardware architecture you're using.  Maybe the
> config.guess file has become outdated.

I'm using a standard 32bit x86 machine.

The problem I'm facing are lots of warnings when compiling the sybase backend 
of my library (OpenDBX, http://www.linuxnetworks.de/opendbx/) against FreeTDS 
instead of the Sybase ctlib.

In Sybase' ctlib, CS_INT is defined as "long" and as "int" in FreeTDS which is 
problematic when using printf() functions. This is because of the different 
expectations gcc/printf have when handling "%d" and "%ld" modifiers.

OpenPGP public key

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.ibiblio.org/pipermail/freetds/attachments/20060903/ed56d3cf/attachment.bin 

More information about the FreeTDS mailing list