libmount: fix uninitialized variable in sample

Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
Karel Zak 2011-06-08 11:22:25 +02:00
parent 6a76ceb1f5
commit a0c014dc4b
2 changed files with 3 additions and 2 deletions

View File

@ -101,7 +101,7 @@ static int print_all(struct libmnt_context *cxt, char *pattern, int show_label)
{
int rc = 0;
struct libmnt_table *tb;
struct libmnt_iter *itr;
struct libmnt_iter *itr = NULL;
struct libmnt_fs *fs;
struct libmnt_cache *cache = NULL;

View File

@ -712,7 +712,8 @@ int mnt_context_get_fstab(struct libmnt_context *cxt, struct libmnt_table **tb)
* @cxt: mount context
* @tb: returns mtab
*
* See also mnt_table_parse_mtab() for more details about mtab/mountinfo.
* See also mnt_table_parse_mtab() for more details about mtab/mountinfo. The
* result will deallocated by mnt_free_context(@cxt).
*
* Returns: 0 on success, negative number in case of error.
*/