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:
@@ -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);
|
||||
|
Reference in New Issue
Block a user