projects
/
platform
/
kernel
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9d30a94
)
efi_loader: '.' and '..' are directories
author
Heinrich Schuchardt
<xypron.glpk@gmx.de>
Tue, 9 Feb 2021 16:45:33 +0000
(17:45 +0100)
committer
Heinrich Schuchardt
<xypron.glpk@gmx.de>
Sun, 14 Feb 2021 09:34:15 +0000
(10:34 +0100)
'.' and '..' are directories. So when looking for capsule files it is
sufficient to check that the attribute EFI_FILE_DIRECTORY is not set. We
don't have to check for these special names.
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
lib/efi_loader/efi_capsule.c
patch
|
blob
|
history
diff --git
a/lib/efi_loader/efi_capsule.c
b/lib/efi_loader/efi_capsule.c
index
0d5a7b6
..
d39d731
100644
(file)
--- a/
lib/efi_loader/efi_capsule.c
+++ b/
lib/efi_loader/efi_capsule.c
@@
-753,9
+753,7
@@
static efi_status_t efi_capsule_scan_dir(u16 ***files, unsigned int *num)
if (!tmp_size)
break;
- if (!(dirent->attribute & EFI_FILE_DIRECTORY) &&
- u16_strcmp(dirent->file_name, L".") &&
- u16_strcmp(dirent->file_name, L".."))
+ if (!(dirent->attribute & EFI_FILE_DIRECTORY))
count++;
}