Re: Fix memcmp() with different sizes. - Mailing list pgsql-patches

From Tom Lane
Subject Re: Fix memcmp() with different sizes.
Date
Msg-id 19532.1075828150@sss.pgh.pa.us
Whole thread Raw
In response to Re: Fix memcmp() with different sizes.  (Kurt Roeckx <Q@ping.be>)
List pgsql-patches
Kurt Roeckx <Q@ping.be> writes:
> That assumes the memcmp starts from the first char and not from
> the last.  If it starts from the last you have undefined
> behaviour.

Hmm.  I suppose you could get a reference off the end of memory;
pretty improbable but we have actually seen similar bugs in the field.
Okay, will fix.

            regards, tom lane

pgsql-patches by date:

Previous
From: Kurt Roeckx
Date:
Subject: Re: Fix memcmp() with different sizes.
Next
From: Tom Lane
Date:
Subject: Re: fix memcpy() overlap