aboutsummaryrefslogtreecommitdiff
path: root/src/util/gnunet-ecc.c
diff options
context:
space:
mode:
authorlurchi <lurchi@strangeplace.net>2019-06-27 10:49:40 +0200
committerlurchi <lurchi@strangeplace.net>2019-06-27 10:49:40 +0200
commitb9771c5f5edcbeb965fa291a281943d866c3ddb6 (patch)
treee53141e844dfe7032d018cb5bfebd31fe02f7816 /src/util/gnunet-ecc.c
parent0e7c93c3a0a3aa966503a8ae4caf3a21914e4126 (diff)
downloadgnunet-b9771c5f5edcbeb965fa291a281943d866c3ddb6.tar.gz
gnunet-b9771c5f5edcbeb965fa291a281943d866c3ddb6.zip
use GNUNET_strlcpy instead of strncpy where possible
Diffstat (limited to 'src/util/gnunet-ecc.c')
-rw-r--r--src/util/gnunet-ecc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/util/gnunet-ecc.c b/src/util/gnunet-ecc.c
index 27ef59c9f..94ffb4308 100644
--- a/src/util/gnunet-ecc.c
+++ b/src/util/gnunet-ecc.c
@@ -96,7 +96,7 @@ create_keys (const char *fn, const char *prefix)
96 } 96 }
97 if (NULL != prefix) 97 if (NULL != prefix)
98 { 98 {
99 strncpy (vanity, prefix, KEY_STR_LEN); 99 GNUNET_strlcpy (vanity, prefix, sizeof (vanity));
100 len = GNUNET_MIN (strlen (prefix), KEY_STR_LEN); 100 len = GNUNET_MIN (strlen (prefix), KEY_STR_LEN);
101 n = len * 5 / 8; 101 n = len * 5 / 8;
102 rest = len * 5 % 8; 102 rest = len * 5 % 8;