mirror of
https://github.com/Fennix-Project/Kernel.git
synced 2025-05-27 15:04:33 +00:00
Do not loop if the next hook is null
This commit is contained in:
parent
a09790e4f2
commit
fe64c55afc
@ -45,7 +45,7 @@ namespace Driver
|
||||
for (size_t j = 0; j < sizeof(drv.InterruptHook) / sizeof(drv.InterruptHook[0]); j++)
|
||||
{
|
||||
if (!drv.InterruptHook[j])
|
||||
continue;
|
||||
break;
|
||||
delete drv.InterruptHook[j], drv.InterruptHook[j] = nullptr;
|
||||
}
|
||||
if (drv.MemTrk)
|
||||
@ -70,7 +70,7 @@ namespace Driver
|
||||
for (size_t i = 0; i < sizeof(drv.InterruptHook) / sizeof(drv.InterruptHook[0]); i++)
|
||||
{
|
||||
if (!drv.InterruptHook[i])
|
||||
continue;
|
||||
break;
|
||||
delete drv.InterruptHook[i], drv.InterruptHook[i] = nullptr;
|
||||
}
|
||||
delete drv.MemTrk, drv.MemTrk = nullptr;
|
||||
|
Loading…
x
Reference in New Issue
Block a user