commit | 73093354418602a2ff5e43cb91a21b17fbf047d8 | [log] [tgz] |
---|---|---|
author | Anthony Liguori <aliguori@us.ibm.com> | Wed Jan 25 13:37:36 2012 -0600 |
committer | Anthony Liguori <aliguori@us.ibm.com> | Fri Jan 27 10:50:55 2012 -0600 |
tree | 3f387f7079e82dde5ff4af7e31935fa5bee9a540 | |
parent | 19b6914a00d3e7be447be418da661d4cd870ee03 [diff] [blame] |
qdev: change ambiguous qdev names Reported-by: Blue Swirl <blauwirbel@gmail.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
diff --git a/qom/object.c b/qom/object.c index ef37e08..a12895f 100644 --- a/qom/object.c +++ b/qom/object.c
@@ -87,6 +87,11 @@ g_assert(info->name != NULL); + if (type_table_lookup(info->name) != NULL) { + fprintf(stderr, "Registering `%s' which already exists\n", info->name); + abort(); + } + ti->name = g_strdup(info->name); ti->parent = g_strdup(info->parent);