chiark / gitweb /
acpi: make sure we never free an uninitialized pointer
[elogind.git] / src / shared / acpi-fpdt.c
index a7c83ed8555987bb3b3dfa4dece2b182763a0969..af58c7cca6b81dd5e63067a8b4f04c2c3363aaf8 100644 (file)
@@ -81,7 +81,7 @@ struct acpi_fpdt_boot {
 };
 
 int acpi_get_boot_usec(usec_t *loader_start, usec_t *loader_exit) {
-        _cleanup_free_ char *buf;
+        _cleanup_free_ char *buf = NULL;
         struct acpi_table_header *tbl;
         size_t l;
         struct acpi_fpdt_header *rec;