mirror of
https://github.com/postgres/postgres.git
synced 2025-07-30 11:03:19 +03:00
Suppress possibly-uninitialized-variable warnings.
Apparently, Peter's compiler has faith that the switch test values here could never not be valid values of their enums. Mine does not, and I tend to agree with it.
This commit is contained in:
@ -3359,7 +3359,7 @@ aclcheck_error(AclResult aclerr, ObjectType objtype,
|
|||||||
break;
|
break;
|
||||||
case ACLCHECK_NO_PRIV:
|
case ACLCHECK_NO_PRIV:
|
||||||
{
|
{
|
||||||
const char *msg;
|
const char *msg = "???";
|
||||||
|
|
||||||
switch (objtype)
|
switch (objtype)
|
||||||
{
|
{
|
||||||
@ -3481,7 +3481,6 @@ aclcheck_error(AclResult aclerr, ObjectType objtype,
|
|||||||
case OBJECT_TSTEMPLATE:
|
case OBJECT_TSTEMPLATE:
|
||||||
case OBJECT_USER_MAPPING:
|
case OBJECT_USER_MAPPING:
|
||||||
elog(ERROR, "unsupported object type %d", objtype);
|
elog(ERROR, "unsupported object type %d", objtype);
|
||||||
msg = "???";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ereport(ERROR,
|
ereport(ERROR,
|
||||||
@ -3491,7 +3490,7 @@ aclcheck_error(AclResult aclerr, ObjectType objtype,
|
|||||||
}
|
}
|
||||||
case ACLCHECK_NOT_OWNER:
|
case ACLCHECK_NOT_OWNER:
|
||||||
{
|
{
|
||||||
const char *msg;
|
const char *msg = "???";
|
||||||
|
|
||||||
switch (objtype)
|
switch (objtype)
|
||||||
{
|
{
|
||||||
@ -3616,7 +3615,6 @@ aclcheck_error(AclResult aclerr, ObjectType objtype,
|
|||||||
case OBJECT_TSTEMPLATE:
|
case OBJECT_TSTEMPLATE:
|
||||||
case OBJECT_USER_MAPPING:
|
case OBJECT_USER_MAPPING:
|
||||||
elog(ERROR, "unsupported object type %d", objtype);
|
elog(ERROR, "unsupported object type %d", objtype);
|
||||||
msg = "???";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ereport(ERROR,
|
ereport(ERROR,
|
||||||
|
Reference in New Issue
Block a user