DragonFlyBSD Kernel Audit
DF-1522 / fix.diff
← back to finding ↓ download raw
--- a/sys/dev/netif/ath/ath_hal/ah.c
+++ b/sys/dev/netif/ath/ath_hal/ah.c
@@ -1408,7 +1408,7 @@
 		HALDEBUG(ah, HAL_DEBUG_ANY, "%s: no eeprom data!\n", __func__);
 		return AH_FALSE;
 	}
-	if (off > ATH_DATA_EEPROM_SIZE) {
+	if (off >= ATH_DATA_EEPROM_SIZE) {
 		HALDEBUG(ah, HAL_DEBUG_ANY, "%s: offset %x > %x\n",
 		    __func__, off, ATH_DATA_EEPROM_SIZE);
 		return AH_FALSE;