From 9ea857cf0f1324852f06c0cef7543752b617cdea Mon Sep 17 00:00:00 2001 From: Mariusz Zaborski Date: Sun, 18 Mar 2018 15:09:55 +0000 Subject: [PATCH] Remove unneeded variable which was introduced in r328472. Pointed out by: pjd@ --- sys/geom/label/g_label.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/sys/geom/label/g_label.c b/sys/geom/label/g_label.c index 6a9cfc05e94..c16afbdde3f 100644 --- a/sys/geom/label/g_label.c +++ b/sys/geom/label/g_label.c @@ -200,7 +200,6 @@ g_label_create(struct gctl_req *req, struct g_class *mp, struct g_provider *pp, struct g_provider *pp2; struct g_consumer *cp; char name[64]; - int n; g_topology_assert(); @@ -214,8 +213,7 @@ g_label_create(struct gctl_req *req, struct g_class *mp, struct g_provider *pp, } gp = NULL; cp = NULL; - n = snprintf(name, sizeof(name), "%s/%s", dir, label); - if (n >= sizeof(name)) { + if (snprintf(name, sizeof(name), "%s/%s", dir, label) >= sizeof(name)) { if (req != NULL) gctl_error(req, "Label name %s is too long.", label); return (NULL);