DragonFlyBSD Kernel Audit
DF-1763 / fix.diff
← back to finding ↓ download raw
diff --git a/sys/dev/disk/vpo/immio.c b/sys/dev/disk/vpo/immio.c
--- a/sys/dev/disk/vpo/immio.c
+++ b/sys/dev/disk/vpo/immio.c
@@ -699,6 +699,8 @@
 	/*
 	 * Send the command ...
 	 */
+	if (clen > 16)
+		clen = 16;
 	for (k = 0; k < clen; k+=2) {
 		if (imm_wait(vpo, VP0_FAST_SPINTMO) != (char)0xa8) {
 			*ret = VP0_ECMD_TIMEOUT;