Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 117323
b: refs/heads/master
c: 4ca846e
h: refs/heads/master
i:
  117321: a302072
  117319: 3cdb0ec
v: v3
  • Loading branch information
Bob Moore authored and Len Brown committed Oct 23, 2008
1 parent f95c9d3 commit a732fbe
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e8707b340fb5b6313cde784b944a568dfd770ddd
refs/heads/master: 4ca846e9270f305ad19e61f6654664f31459f332
11 changes: 9 additions & 2 deletions trunk/drivers/acpi/executer/exconvrt.c
Original file line number Diff line number Diff line change
Expand Up @@ -512,9 +512,14 @@ acpi_ex_convert_to_string(union acpi_operand_object * obj_desc,
/*
* Create a new string object and string buffer
* (-1 because of extra separator included in string_length from above)
* Allow creation of zero-length strings from zero-length buffers.
*/
if (string_length) {
string_length--;
}

return_desc = acpi_ut_create_string_object((acpi_size)
(string_length - 1));
string_length);
if (!return_desc) {
return_ACPI_STATUS(AE_NO_MEMORY);
}
Expand All @@ -537,7 +542,9 @@ acpi_ex_convert_to_string(union acpi_operand_object * obj_desc,
* Null terminate the string
* (overwrites final comma/space from above)
*/
new_buf--;
if (obj_desc->buffer.length) {
new_buf--;
}
*new_buf = 0;
break;

Expand Down

0 comments on commit a732fbe

Please sign in to comment.