⬢ DragonFlyBSD Kernel Audit
DF-5682 / fix.diff
← back to finding ↓ download raw
--- a/sys/libprop/prop_number.c
+++ b/sys/libprop/prop_number.c
@@ -376,9 +376,12 @@ prop_number_copy(prop_number_t opn)
  *	prop_number_unsigned --
  *	Returns true if the prop_number_t has an unsigned value.
  */
+
 bool
 prop_number_unsigned(prop_number_t pn)
 {
 
+	if (! prop_object_is_number(pn))
+		return (false);
+
 	return (pn->pn_value.pnv_is_unsigned);
 }