Module Name:    src
Committed By:   joe
Date:           Tue Feb 25 02:10:13 UTC 2025

Modified Files:
        src/sys/dev/pci: if_iavf.c

Log Message:
initialize post to 0

this prevents the use of unitialized variable when we hit an error branch
on the first attempt/iteration that will cause it to break out of the do while
loop


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/dev/pci/if_iavf.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/pci/if_iavf.c
diff -u src/sys/dev/pci/if_iavf.c:1.18 src/sys/dev/pci/if_iavf.c:1.19
--- src/sys/dev/pci/if_iavf.c:1.18	Sat Jun 29 12:11:12 2024
+++ src/sys/dev/pci/if_iavf.c	Tue Feb 25 02:10:13 2025
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_iavf.c,v 1.18 2024/06/29 12:11:12 riastradh Exp $	*/
+/*	$NetBSD: if_iavf.c,v 1.19 2025/02/25 02:10:13 joe Exp $	*/
 
 /*
  * Copyright (c) 2013-2015, Intel Corporation
@@ -75,7 +75,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_iavf.c,v 1.18 2024/06/29 12:11:12 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_iavf.c,v 1.19 2025/02/25 02:10:13 joe Exp $");
 
 #include <sys/param.h>
 #include <sys/types.h>
@@ -2518,6 +2518,7 @@ iavf_rxfill(struct iavf_softc *sc, struc
 	if (slots == 0)
 		return 0;
 
+	post = 0;
 	error = 0;
 	prod = rxr->rxr_prod;
 

Reply via email to