git: a276bb4794af - main - geom: Correct use of expand_number()

From: Dag-Erling Smørgrav <des_at_FreeBSD.org>
Date: Sat, 09 Aug 2025 13:14:26 UTC
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)) {