Follow-up Comment #2, bug #47847 (project gettext):
IMO the sentence "The value of a pointer becomes indeterminate when
the object it points to reaches the end of its lifetime." (ISO C 6.2.4) means
that you should not compare pointers to local variables which have gone out of
scope: The function
int foo (int x)
{
int *pa, *pb;
{ int a = x; pa = &a; }
{ int b = x; pb = &b; }
return pa == pb;
}
can return 0 or 1, depending on compiler optimizations. This explains the
coverity warning.
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?47847>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/