From: Davidlohr Bueso Date: Sun, 24 Jul 2011 15:22:52 +0000 (-0400) Subject: sysfs: free used resources X-Git-Tag: v2.20-rc1~35 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=fb4a9e54fc937d5e182f64ae2d0b09a1e05a3d1b;p=thirdparty%2Futil-linux.git sysfs: free used resources In the sysfs lib example, we should be using sysfs_deinit() to free used resources and for correct usage. Signed-off-by: Davidlohr Bueso --- diff --git a/lib/sysfs.c b/lib/sysfs.c index b9ddc67f5e..7bcdabae28 100644 --- a/lib/sysfs.c +++ b/lib/sysfs.c @@ -488,6 +488,7 @@ int main(int argc, char *argv[]) printf("DEVNAME: %s\n", sysfs_get_devname(&cxt, path, sizeof(path))); + sysfs_deinit(&cxt); return EXIT_SUCCESS; } #endif