* [PATCH] [LIB] sysfs: free used resources
@ 2011-07-24 22:50 Davidlohr Bueso
2011-07-26 10:13 ` Karel Zak
0 siblings, 1 reply; 2+ messages in thread
From: Davidlohr Bueso @ 2011-07-24 22:50 UTC (permalink / raw)
To: Karel Zak; +Cc: util-linux
From: Davidlohr Bueso <dave@gnu.org>
Date: Sun, 24 Jul 2011 11:22:52 -0400
In the sysfs lib example, we should be using sysfs_deinit() to free used resources and for correct usage.
Signed-off-by: Davidlohr Bueso <dave@gnu.org>
---
lib/sysfs.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/lib/sysfs.c b/lib/sysfs.c
index b9ddc67..7bcdaba 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
--
1.7.4.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-07-26 10:13 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-24 22:50 [PATCH] [LIB] sysfs: free used resources Davidlohr Bueso
2011-07-26 10:13 ` Karel Zak
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox