1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-23 03:21:12 +03:00

StrNCpy -> strlcpy (not complete)

This commit is contained in:
Peter Eisentraut
2007-02-10 14:58:55 +00:00
parent 1a1474b4c0
commit 4ab8fcba8a
16 changed files with 58 additions and 58 deletions

View File

@ -9,7 +9,7 @@
* Portions Copyright (c) 1996-2007, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* $PostgreSQL: pgsql/src/backend/libpq/crypt.c,v 1.72 2007/01/05 22:19:29 momjian Exp $
* $PostgreSQL: pgsql/src/backend/libpq/crypt.c,v 1.73 2007/02/10 14:58:54 petere Exp $
*
*-------------------------------------------------------------------------
*/
@ -110,7 +110,7 @@ md5_crypt_verify(const Port *port, const char *role, char *client_pass)
{
char salt[3];
StrNCpy(salt, port->cryptSalt, 3);
strlcpy(salt, port->cryptSalt, sizeof(salt));
crypt_pwd = crypt(shadow_pass, salt);
break;
}