Skip to content

Commit

Permalink
fix list traversal bug in update_dcb()
Browse files Browse the repository at this point in the history
This caused the kernel to hang when loading NETDRIVE.SYS
  • Loading branch information
boeckmann authored and PerditionC committed Aug 6, 2024
1 parent ed2fd81 commit 42980df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kernel/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -567,7 +567,7 @@ STATIC VOID update_dcb(struct dhdr FAR * dhp)
{
struct dpb FAR *tmp_dpb;
/* find current end of dpb chain by following next pointers to end */
for (tmp_dpb = LoL->DPBp; (ULONG) tmp_dpb->dpb_next != 0xffffffffl; tmp_dpb = dpb->dpb_next)
for (tmp_dpb = LoL->DPBp; (ULONG) tmp_dpb->dpb_next != 0xffffffffl; tmp_dpb = tmp_dpb->dpb_next)
;
/* insert into chain [at end] */
tmp_dpb->dpb_next = dpb;
Expand Down

0 comments on commit 42980df

Please sign in to comment.