Fix memory leak on attach/resume.

This commit is contained in:
jmcneill 2008-05-14 12:15:47 +00:00
parent 1fec9888f6
commit 05f909b7fa
1 changed files with 5 additions and 2 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: asus_acpi.c,v 1.4 2008/05/05 00:14:11 jmcneill Exp $ */
/* $NetBSD: asus_acpi.c,v 1.5 2008/05/14 12:15:47 jmcneill Exp $ */
/*-
* Copyright (c) 2007, 2008 Jared D. McNeill <jmcneill@invisible.ca>
@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: asus_acpi.c,v 1.4 2008/05/05 00:14:11 jmcneill Exp $");
__KERNEL_RCSID(0, "$NetBSD: asus_acpi.c,v 1.5 2008/05/14 12:15:47 jmcneill Exp $");
#include <sys/types.h>
#include <sys/param.h>
@ -187,6 +187,9 @@ asus_init(device_t self)
if (ACPI_FAILURE(rv))
aprint_error_dev(self, "couldn't evaluate INIT: %s\n",
AcpiFormatException(rv));
if (ret.Pointer)
AcpiOsFree(ret.Pointer);
}
static bool