From 6130f4c3463d299e7c89032a9532641ee057e203 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Wed, 15 Nov 2017 22:03:53 +0100 Subject: [PATCH] ovs_events plugin: Replace strncpy() with sstrncpy(). CID: 179243 --- src/ovs_events.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ovs_events.c b/src/ovs_events.c index afa11997..bf457fdb 100644 --- a/src/ovs_events.c +++ b/src/ovs_events.c @@ -253,8 +253,8 @@ static int ovs_events_plugin_config(oconfig_item_t *ci) { ovs_events_config_free(); return -1; } - strncpy(ovs_events_ctx.config.ovs_db_serv, service, - sizeof(ovs_events_ctx.config.ovs_db_serv)); + sstrncpy(ovs_events_ctx.config.ovs_db_serv, service, + sizeof(ovs_events_ctx.config.ovs_db_serv)); sfree(service); } else if (strcasecmp("Socket", child->key) == 0) { if (cf_util_get_string_buffer( -- 2.30.2