Re: pgsql: Clean up overly paranoid checks in mac8.c

From: Stephen Frost <sfrost(at)snowman(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql: Clean up overly paranoid checks in mac8.c
Date: 2017-03-16 03:39:49
Message-ID: 20170316033949.GI9812@tamriel.snowman.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

* Tom Lane (tgl(at)sss(dot)pgh(dot)pa(dot)us) wrote:
> I wrote:
> > Stephen Frost <sfrost(at)snowman(dot)net> writes:
> >> Clean up overly paranoid checks in mac8.c
>
> > termite thinks this wasn't quite right.
>
> On looking at it a bit more closely, I think you've forgotten that
> "char" is signed on some platforms and unsigned on others. I'd
> suggest putting explicit casts to unsigned char into these tests.

Right, going through it now and adjusting things to be more careful
about that.

Thanks!

Stephen

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Stephen Frost 2017-03-16 04:14:00 pgsql: Be more careful about signed vs. unsigned char
Previous Message Tom Lane 2017-03-16 03:38:16 Re: pgsql: Clean up overly paranoid checks in mac8.c