1
0
mirror of https://github.com/postgres/postgres.git synced 2025-08-22 21:53:06 +03:00

This patches replaces a few more usages of strcpy() and sprintf() when

copying into a fixed-size buffer (in this case, a buffer of
NAMEDATALEN bytes). AFAICT nothing to worry about here, but worth
fixing anyway...

Neil Conway
This commit is contained in:
Bruce Momjian
2002-08-27 03:56:35 +00:00
parent e0a77f56e3
commit dd912c6977
5 changed files with 18 additions and 18 deletions

View File

@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/commands/tablecmds.c,v 1.33 2002/08/24 15:00:46 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/commands/tablecmds.c,v 1.34 2002/08/27 03:56:34 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -3370,8 +3370,8 @@ AlterTableCreateToastTable(Oid relOid, bool silent)
/*
* Create the toast table and its index
*/
sprintf(toast_relname, "pg_toast_%u", relOid);
sprintf(toast_idxname, "pg_toast_%u_index", relOid);
snprintf(toast_relname, NAMEDATALEN, "pg_toast_%u", relOid);
snprintf(toast_idxname, NAMEDATALEN, "pg_toast_%u_index", relOid);
/* this is pretty painful... need a tuple descriptor */
tupdesc = CreateTemplateTupleDesc(3, WITHOUTOID);