forked from Bananymous/banan-os
Kernel: Make PARTUUID matching case insensitive
Case sensitivity made it super annoying to work with :)
This commit is contained in:
parent
1de6de975a
commit
3573656244
|
@ -8,6 +8,7 @@
|
||||||
#include <kernel/Storage/Partition.h>
|
#include <kernel/Storage/Partition.h>
|
||||||
#include <kernel/Timer/Timer.h>
|
#include <kernel/Timer/Timer.h>
|
||||||
|
|
||||||
|
#include <ctype.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
|
|
||||||
namespace Kernel
|
namespace Kernel
|
||||||
|
@ -28,7 +29,9 @@ namespace Kernel
|
||||||
if (!static_cast<Device*>(inode.ptr())->is_partition())
|
if (!static_cast<Device*>(inode.ptr())->is_partition())
|
||||||
return BAN::Iteration::Continue;
|
return BAN::Iteration::Continue;
|
||||||
auto* partition = static_cast<Partition*>(inode.ptr());
|
auto* partition = static_cast<Partition*>(inode.ptr());
|
||||||
if (partition->uuid() != uuid)
|
ASSERT(partition->uuid().size() == uuid.size());
|
||||||
|
for (size_t i = 0; i < uuid.size(); i++)
|
||||||
|
if (tolower(uuid[i]) != tolower(partition->uuid()[i]))
|
||||||
return BAN::Iteration::Continue;
|
return BAN::Iteration::Continue;
|
||||||
result = partition;
|
result = partition;
|
||||||
return BAN::Iteration::Break;
|
return BAN::Iteration::Break;
|
||||||
|
|
Loading…
Reference in New Issue