Skip to content

Commit

Permalink
ACPICA: debugger: remove leading whitespaces when converting a string…
Browse files Browse the repository at this point in the history
… to a buffer

ACPICA commit 1b7228072f254a5b02625586ff7d561757b7fc2d

By removing leading whitespaces, the conversion computes the
correct number of elements in a given buffer or field encoding
that contains leading whitespaces.

Link: https://github.com/acpica/acpica/commit/1b722807
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Erik Schmauss authored and Rafael J. Wysocki committed Oct 28, 2019
1 parent 02b04f1 commit 45abdc9
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions drivers/acpi/acpica/dbconvert.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,10 @@ acpi_db_convert_to_buffer(char *string, union acpi_object *object)
u8 *buffer;
acpi_status status;

/* Skip all preceding white space */

acpi_ut_remove_whitespace(&string);

/* Generate the final buffer length */

for (i = 0, length = 0; string[i];) {
Expand Down

0 comments on commit 45abdc9

Please sign in to comment.