Skip to Content.
Sympa Menu

freetds - Re: tds_msg_info->msg_number should be TDS_UINT?

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Brian Bruns <camber AT ais.org>
  • To: TDS Development Group <freetds AT franklin.oit.unc.edu>
  • Subject: Re: tds_msg_info->msg_number should be TDS_UINT?
  • Date: Fri, 25 Jan 2002 20:33:14 -0500 (EST)



Patch away! I think this was the other half of the discussion on big
endian problems with msg number (which technically isn't a bigendian issue
at all). You can send it here or to me directly and I'll make sure it
gets checked in.

Brian

On Sat, 26 Jan 2002, Dave Brotherstone wrote:

> Hi,
> Is there any reason why tds_msg_info->msg_number isn't a TDS_UINT?
> There's a few points that it needs changing in, but it does mean that
> function set by dberrhandle() is called correctly for user errors - ie.
> errors over 50000 - which obviously don't fit into a signed TDS_SMALLINT.
> The problem is actually caused by line 48 of dbutil.c
>
> if( tds->msg_info->msg_number > 0 )
> {
> ... etc
>
> Of course, it's not >0 if its a signed small int, and the error is a user
> error > 32767 ;-)
>
> I've changed it at the various points, and tried it under PHP4/Apache and it
> works spot on (the php_sybase_err_handler routine wasn't being called for
> user errors, ie. anything over 32767 before).
>
> Shall I submit a patch, or just run and hide <g>
>
>
> Thanks,
> Dave.
>
>
>
>
> ---
> You are currently subscribed to freetds as: [camber AT ais.org]
> To unsubscribe, forward this message to $subst('Email.Unsub')
>





Archive powered by MHonArc 2.6.24.

Top of Page