From a3576b784de04e41181a90174370fedf1d2eb507 Mon Sep 17 00:00:00 2001 From: Al Stone Date: Tue, 25 Feb 2020 11:56:15 -0700 Subject: [PATCH] Correct an ARMv7 patch Signed-off-by: Al Stone --- utstring.patch | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/utstring.patch b/utstring.patch index c6af4bd..757fc2a 100644 --- a/utstring.patch +++ b/utstring.patch @@ -1,16 +1,28 @@ -On ARMv7, GCC catches this particular problem and reports trying -to copy a string into a space too small; it counts the terminating -NULL as part of the char[]. - diff -Naur acpica-unix2-20200214.orig/source/components/utilities/utstring.c acpica-unix2-20200214/source/components/utilities/utstring.c --- acpica-unix2-20200214.orig/source/components/utilities/utstring.c 2020-02-14 10:33:55.000000000 -0700 -+++ acpica-unix2-20200214/source/components/utilities/utstring.c 2020-02-24 16:52:24.623218044 -0700 ++++ acpica-unix2-20200214/source/components/utilities/utstring.c 2020-02-25 11:21:31.329016004 -0700 @@ -185,7 +185,7 @@ { UINT32 i; BOOLEAN FoundBadChar = FALSE; - UINT32 OriginalName; -+ char OriginalName[ACPI_NAMESEG_SIZE+1]; ++ char OriginalName[ACPI_NAMESEG+SIZE+1]; ACPI_FUNCTION_NAME (UtRepairName); +@@ -228,13 +228,13 @@ + { + ACPI_WARNING ((AE_INFO, + "Invalid character(s) in name (0x%.8X), repaired: [%4.4s]", +- OriginalName, Name)); ++ (unsigned int)OriginalName, Name)); + } + else + { + ACPI_DEBUG_PRINT ((ACPI_DB_INFO, + "Invalid character(s) in name (0x%.8X), repaired: [%4.4s]", +- OriginalName, Name)); ++ (unsigned int)OriginalName, Name)); + } + } + }