mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
hypervCreateEmbeddedParam: Don't count elements needlessly
'count' is not used after calculating it. Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Tim Wiederhake <twiederh@redhat.com>
This commit is contained in:
parent
23fbc0074e
commit
032af88d85
@ -274,16 +274,11 @@ GHashTable *
|
|||||||
hypervCreateEmbeddedParam(hypervWmiClassInfo *classInfo)
|
hypervCreateEmbeddedParam(hypervWmiClassInfo *classInfo)
|
||||||
{
|
{
|
||||||
size_t i;
|
size_t i;
|
||||||
size_t count;
|
|
||||||
g_autoptr(GHashTable) table = virHashNew(NULL);
|
g_autoptr(GHashTable) table = virHashNew(NULL);
|
||||||
XmlSerializerInfo *typeinfo = NULL;
|
XmlSerializerInfo *typeinfo = NULL;
|
||||||
|
|
||||||
typeinfo = classInfo->serializerInfo;
|
typeinfo = classInfo->serializerInfo;
|
||||||
|
|
||||||
/* loop through the items to find out how many fields there are */
|
|
||||||
for (count = 0; typeinfo[count].name != NULL; count++)
|
|
||||||
;
|
|
||||||
|
|
||||||
for (i = 0; typeinfo[i].name != NULL; i++) {
|
for (i = 0; typeinfo[i].name != NULL; i++) {
|
||||||
XmlSerializerInfo *item = &typeinfo[i];
|
XmlSerializerInfo *item = &typeinfo[i];
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user