summaryrefslogtreecommitdiff
path: root/sys/dev/microcode/aic7xxx
diff options
context:
space:
mode:
authorKenneth R Westerback <krw@cvs.openbsd.org>2003-08-28 02:24:05 +0000
committerKenneth R Westerback <krw@cvs.openbsd.org>2003-08-28 02:24:05 +0000
commit6df9ad5d42245d017dbdb8247b65aceab2a82c28 (patch)
treeadd5c0af9771af2c3ac39f6bded70e343b237209 /sys/dev/microcode/aic7xxx
parentb7f5d918f98ad0fd439d4f2ae542e17a35328990 (diff)
Fix use of uninitialized variable by porting NetBSD patch to correctly
initialize it. Said variable is used as the value of the define DOWNLOAD_CONST_COUNT in the generated file aic7xxxreg.h. This define is currently not used anywhere. Spotted and ok mickey@.
Diffstat (limited to 'sys/dev/microcode/aic7xxx')
-rw-r--r--sys/dev/microcode/aic7xxx/aicasm_symbol.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/microcode/aic7xxx/aicasm_symbol.c b/sys/dev/microcode/aic7xxx/aicasm_symbol.c
index 72104ffb4e1..1893e050405 100644
--- a/sys/dev/microcode/aic7xxx/aicasm_symbol.c
+++ b/sys/dev/microcode/aic7xxx/aicasm_symbol.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: aicasm_symbol.c,v 1.6 2002/11/19 18:36:18 jason Exp $ */
+/* $OpenBSD: aicasm_symbol.c,v 1.7 2003/08/28 02:24:04 krw Exp $ */
/*
* Aic7xxx SCSI host adapter firmware asssembler symbol table implementation
*
@@ -474,8 +474,7 @@ symtable_dump(ofile)
fprintf(ofile, "\n\n/* Downloaded Constant Definitions */\n");
- while (SLIST_FIRST(&download_constants) !=
- SLIST_END(&download_constants)) {
+ for (i = 0; SLIST_FIRST(&download_constants) != NULL; i++) {
symbol_node_t *curnode;
curnode = SLIST_FIRST(&download_constants);