mirror of
https://github.com/EnderIce2/Fennix.git
synced 2025-05-27 15:04:31 +00:00
fix(kernel/driver): filter out non-.drv files in driver loading
Signed-off-by: EnderIce2 <enderice2@protonmail.com>
This commit is contained in:
parent
a8e4dd08bb
commit
be72d2dc06
@ -82,6 +82,9 @@ namespace Driver
|
|||||||
if (!drvNode->IsRegularFile())
|
if (!drvNode->IsRegularFile())
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
if (std::string(drvNode->Path).find(".drv") == std::string::npos)
|
||||||
|
continue;
|
||||||
|
|
||||||
if (Execute::GetBinaryType(drvNode->Path) != Execute::BinTypeELF)
|
if (Execute::GetBinaryType(drvNode->Path) != Execute::BinTypeELF)
|
||||||
{
|
{
|
||||||
error("Driver %s is not an ELF binary", drvNode->Path.c_str());
|
error("Driver %s is not an ELF binary", drvNode->Path.c_str());
|
||||||
|
Loading…
x
Reference in New Issue
Block a user