mirror of
https://github.com/postgres/postgres.git
synced 2025-07-07 00:36:50 +03:00
Fix various infelicities that have snuck into usage of errdetail() and
friends. Avoid double translation of some messages, ensure other messages are exposed for translation (and make them follow the style guidelines), avoid unsafe passing of an unpredictable message text as a format string.
This commit is contained in:
@ -38,7 +38,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/commands/vacuumlazy.c,v 1.104 2008/03/10 02:04:09 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/commands/vacuumlazy.c,v 1.105 2008/03/24 19:12:49 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -212,10 +212,10 @@ lazy_vacuum_rel(Relation onerel, VacuumStmt *vacstmt,
|
||||
(errmsg("relation \"%s.%s\" contains more than \"max_fsm_pages\" pages with useful free space",
|
||||
get_namespace_name(RelationGetNamespace(onerel)),
|
||||
RelationGetRelationName(onerel)),
|
||||
errhint((vacrelstats->tot_free_pages > vacrelstats->rel_pages * 0.20 ?
|
||||
/* Only suggest VACUUM FULL if 20% free */
|
||||
"Consider using VACUUM FULL on this relation or increasing the configuration parameter \"max_fsm_pages\"." :
|
||||
"Consider increasing the configuration parameter \"max_fsm_pages\"."))));
|
||||
/* Only suggest VACUUM FULL if > 20% free */
|
||||
(vacrelstats->tot_free_pages > vacrelstats->rel_pages * 0.20) ?
|
||||
errhint("Consider using VACUUM FULL on this relation or increasing the configuration parameter \"max_fsm_pages\".") :
|
||||
errhint("Consider increasing the configuration parameter \"max_fsm_pages\".")));
|
||||
|
||||
/* Update statistics in pg_class */
|
||||
vac_update_relstats(RelationGetRelid(onerel),
|
||||
|
Reference in New Issue
Block a user