FreeBSD: minor_t needs to be signed so that -1 is recognized as such

zfsdev_close sets zs_minor to -1 to avoid duplicate calls to
destroy. This doesn't mix well with the current u_int used.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Signed-off-by: Matt Macy <mmacy@FreeBSD.org>
Closes #11437
This commit is contained in:
Matthew Macy 2021-01-07 10:41:27 -08:00 committed by GitHub
parent 06346cc5b5
commit f11b09dec3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -64,7 +64,7 @@ typedef u_int uint_t;
typedef u_char uchar_t;
typedef u_short ushort_t;
typedef u_long ulong_t;
typedef u_int minor_t;
typedef int minor_t;
/* END CSTYLED */
#ifndef _OFF64_T_DECLARED
#define _OFF64_T_DECLARED