From 94f1563961ff007ad087a09bd2598d68ed95a620 Mon Sep 17 00:00:00 2001 From: krw Date: Thu, 2 Aug 2018 16:30:01 +0000 Subject: [PATCH] errno is never checked after a call to getuint64(). So there is no point to getuint64() setting it to EINVAL when the user enters an invalid value or aborts input with a ^D. --- sbin/disklabel/editor.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sbin/disklabel/editor.c b/sbin/disklabel/editor.c index af28cbc74eb..a9c2686d0d6 100644 --- a/sbin/disklabel/editor.c +++ b/sbin/disklabel/editor.c @@ -1,4 +1,4 @@ -/* $OpenBSD: editor.c,v 1.340 2018/07/12 16:59:59 krw Exp $ */ +/* $OpenBSD: editor.c,v 1.341 2018/08/02 16:30:01 krw Exp $ */ /* * Copyright (c) 1997-2000 Todd C. Miller @@ -1228,7 +1228,6 @@ getuint64(struct disklabel *lp, char *prompt, char *helpstring, return (rval); invalid: - errno = EINVAL; fputs("Invalid entry\n", stderr); return (CMD_BADVALUE); } -- 2.20.1