From f0e4df7d5f467e95ade6cbe46ece3a365809bd25 Mon Sep 17 00:00:00 2001 From: Peter Jones Date: Tue, 30 Apr 2013 10:58:59 -0400 Subject: [PATCH] Explain byte order handling better. Signed-off-by: Peter Jones --- fallback.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/fallback.c b/fallback.c index d3179b6..dab3d3d 100644 --- a/fallback.c +++ b/fallback.c @@ -365,9 +365,13 @@ try_boot_csv(EFI_FILE_HANDLE fh, CHAR16 *dirname, CHAR16 *filename) #endif CHAR16 *start = buffer; - /* If I create boot.csv with the efi shell's "edit" command, - * it starts with 0xfeff. I assume there's some reason for this, - * but it doesn't matter much to me... + /* The file may or may not start with the Unicode byte order marker. + * Sadness ensues. Since UEFI is defined as LE, I'm going to decree + * that these files must also be LE. + * + * IT IS THUS SO. + * + * But if we find the LE byte order marker, just skip it. */ if (*start == 0xfeff) start++;