Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/dm release proplib iterator in failure paths.
details: https://anonhg.NetBSD.org/src/rev/098027e5a298
branches: trunk
changeset: 325437:098027e5a298
user: mlelstv <mlelstv%NetBSD.org@localhost>
date: Tue Dec 24 22:14:07 2013 +0000
description:
release proplib iterator in failure paths.
diffstat:
sys/dev/dm/dm_ioctl.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diffs (40 lines):
diff -r 47cdc1b291ab -r 098027e5a298 sys/dev/dm/dm_ioctl.c
--- a/sys/dev/dm/dm_ioctl.c Tue Dec 24 21:59:59 2013 +0000
+++ b/sys/dev/dm/dm_ioctl.c Tue Dec 24 22:14:07 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dm_ioctl.c,v 1.27 2013/10/18 19:56:30 christos Exp $ */
+/* $NetBSD: dm_ioctl.c,v 1.28 2013/12/24 22:14:07 mlelstv Exp $ */
/*
* Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -712,6 +712,7 @@
if ((dmv = dm_dev_lookup(name, uuid, minor)) == NULL) {
DM_REMOVE_FLAG(flags, DM_EXISTS_FLAG);
+ prop_object_iterator_release(iter);
return ENOENT;
}
aprint_debug("Loading table to device: %s--%d\n", name,
@@ -743,12 +744,14 @@
((target = dm_target_autoload(type)) == NULL)) {
dm_table_release(&dmv->table_head, DM_TABLE_INACTIVE);
dm_dev_unbusy(dmv);
+ prop_object_iterator_release(iter);
return ENOENT;
}
if ((table_en = kmem_alloc(sizeof(dm_table_entry_t),
KM_SLEEP)) == NULL) {
dm_table_release(&dmv->table_head, DM_TABLE_INACTIVE);
dm_dev_unbusy(dmv);
+ prop_object_iterator_release(iter);
return ENOMEM;
}
prop_dictionary_get_uint64(target_dict, DM_TABLE_START,
@@ -791,6 +794,7 @@
dm_dev_unbusy(dmv);
dm_target_unbusy(target);
+ prop_object_iterator_release(iter);
return ret;
}
last_table = table_en;
Home |
Main Index |
Thread Index |
Old Index