mirror of
https://github.com/postgres/postgres.git
synced 2025-07-27 12:41:57 +03:00
Replace some strncpy() by strlcpy().
This commit is contained in:
@ -8,7 +8,7 @@
|
||||
* Darko Prenosil <Darko.Prenosil@finteh.hr>
|
||||
* Shridhar Daithankar <shridhar_daithankar@persistent.co.in>
|
||||
*
|
||||
* $PostgreSQL: pgsql/contrib/dblink/dblink.c,v 1.61 2007/01/05 22:19:17 momjian Exp $
|
||||
* $PostgreSQL: pgsql/contrib/dblink/dblink.c,v 1.62 2007/02/07 00:52:35 petere Exp $
|
||||
* Copyright (c) 2001-2007, PostgreSQL Global Development Group
|
||||
* ALL RIGHTS RESERVED;
|
||||
*
|
||||
@ -2248,7 +2248,7 @@ createNewConnection(const char *name, remoteConn * rconn)
|
||||
errmsg("duplicate connection name")));
|
||||
|
||||
hentry->rconn = rconn;
|
||||
strncpy(hentry->name, name, NAMEDATALEN - 1);
|
||||
strlcpy(hentry->name, name, sizeof(hentry->name));
|
||||
}
|
||||
|
||||
static void
|
||||
|
Reference in New Issue
Block a user