diff options
author | Jung-uk Kim <jkim@FreeBSD.org> | 2017-06-29 18:42:13 +0000 |
---|---|---|
committer | Jung-uk Kim <jkim@FreeBSD.org> | 2017-06-29 18:42:13 +0000 |
commit | 744d47ba98ced2e2a7d3aff2f894136544386e34 (patch) | |
tree | 917f6a025e019c7b80e50a45fa783593b4e3c19e /source/components/disassembler/dmopcode.c | |
parent | c457a42be4fca72c51fdca569271b62213d01a37 (diff) |
Notes
Diffstat (limited to 'source/components/disassembler/dmopcode.c')
-rw-r--r-- | source/components/disassembler/dmopcode.c | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/source/components/disassembler/dmopcode.c b/source/components/disassembler/dmopcode.c index 8d9b532a795e..8e4a0d5f7113 100644 --- a/source/components/disassembler/dmopcode.c +++ b/source/components/disassembler/dmopcode.c @@ -528,25 +528,30 @@ AcpiDmFieldPredefinedDescription ( /* Major cheat: We previously put the Tag ptr in the Node field */ Tag = ACPI_CAST_PTR (char, IndexOp->Common.Node); - if (!Tag) + if (!Tag || (*Tag == 0)) { return; } - /* Match the name in the info table */ + /* Is the tag a predefined name? */ Info = AcpiAhMatchPredefinedName (Tag); - if (Info) + if (!Info) { - AcpiOsPrintf (" // %4.4s: %s", Tag, - ACPI_CAST_PTR (char, Info->Description)); + /* Not a predefined name (does not start with underscore) */ + + return; } - /* AML buffer (String) was allocated in AcpiGetTagPathname */ + AcpiOsPrintf (" // %4.4s: %s", Tag, + ACPI_CAST_PTR (char, Info->Description)); - ACPI_FREE (IndexOp->Common.Value.String); + /* String contains the prefix path, free it */ + ACPI_FREE (IndexOp->Common.Value.String); + IndexOp->Common.Value.String = NULL; #endif + return; } |