Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 9 Aug 2025 13:14:26 GMT
From:      Dag-Erling =?utf-8?Q?Sm=C3=B8rgrav?= <des@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: a276bb4794af - main - geom: Correct use of expand_number()
Message-ID:  <202508091314.579DEQxf096378@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by des:

URL: https://cgit.FreeBSD.org/src/commit/?id=a276bb4794af2d425375810acf556cbad626cbc0

commit a276bb4794af2d425375810acf556cbad626cbc0
Author:     Dag-Erling Smørgrav <des@FreeBSD.org>
AuthorDate: 2025-08-09 13:14:01 +0000
Commit:     Dag-Erling Smørgrav <des@FreeBSD.org>
CommitDate: 2025-08-09 13:14:01 +0000

    geom: Correct use of expand_number()
    
    Several GEOM classes use G_TYPE_NUMBER for options where the argument
    (or at least the default value of -1) may be negative.
    
    PR:             288723
    Reviewed by:    imp
    Differential Revision:  https://reviews.freebsd.org/D51834
---
 sbin/geom/core/geom.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sbin/geom/core/geom.c b/sbin/geom/core/geom.c
index 950f6790b1a8..b78021194ddd 100644
--- a/sbin/geom/core/geom.c
+++ b/sbin/geom/core/geom.c
@@ -249,7 +249,7 @@ static void
 set_option(struct gctl_req *req, struct g_option *opt, const char *val)
 {
 	const char *optname;
-	uint64_t number;
+	int64_t number;
 	void *ptr;
 
 	if (G_OPT_ISMULTI(opt)) {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202508091314.579DEQxf096378>