compiler warning read_objtype_from_string() - Mailing list pgsql-hackers

From Peter Eisentraut
Subject compiler warning read_objtype_from_string()
Date
Msg-id af08f995-bed9-5979-36af-c0dc6c3fb467@2ndquadrant.com
Whole thread Raw
Responses Re: compiler warning read_objtype_from_string()
List pgsql-hackers
I'm getting the following compiler warning (using nondefault
optimization options):

objectaddress.c: In function 'read_objtype_from_string':
objectaddress.c:2309:9: error: 'type' may be used uninitialized in this
function [-Werror=maybe-uninitialized] return type;

The comment for the function says
* Return ObjectType for the given object type as given by* getObjectTypeDescription; if no valid ObjectType code
exists,but it's a* possible output type from getObjectTypeDescription, return -1.
 

But the claim that it can return -1 does not seem supported by the code.

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



pgsql-hackers by date:

Previous
From: Mithun Cy
Date:
Subject: Re: Cache Hash Index meta page.
Next
From: Heikki Linnakangas
Date:
Subject: Re: Tuplesort merge pre-reading