Revision 72cf2d4f qdict.c

b/qdict.c
14 14
#include "qdict.h"
15 15
#include "qstring.h"
16 16
#include "qobject.h"
17
#include "sys-queue.h"
17
#include "qemu-queue.h"
18 18
#include "qemu-common.h"
19 19

  
20 20
static void qdict_destroy_obj(QObject *obj);
......
88 88
{
89 89
    QDictEntry *entry;
90 90

  
91
    LIST_FOREACH(entry, &qdict->table[hash], next)
91
    QLIST_FOREACH(entry, &qdict->table[hash], next)
92 92
        if (!strcmp(entry->key, key))
93 93
            return entry;
94 94

  
......
120 120
    } else {
121 121
        /* allocate a new entry */
122 122
        entry = alloc_entry(key, value);
123
        LIST_INSERT_HEAD(&qdict->table[hash], entry, next);
123
        QLIST_INSERT_HEAD(&qdict->table[hash], entry, next);
124 124
    }
125 125

  
126 126
    qdict->size++;
......
266 266

  
267 267
    entry = qdict_find(qdict, key, tdb_hash(key) % QDICT_HASH_SIZE);
268 268
    if (entry) {
269
        LIST_REMOVE(entry, next);
269
        QLIST_REMOVE(entry, next);
270 270
        qentry_destroy(entry);
271 271
        qdict->size--;
272 272
    }
......
284 284
    qdict = qobject_to_qdict(obj);
285 285

  
286 286
    for (i = 0; i < QDICT_HASH_SIZE; i++) {
287
        QDictEntry *entry = LIST_FIRST(&qdict->table[i]);
287
        QDictEntry *entry = QLIST_FIRST(&qdict->table[i]);
288 288
        while (entry) {
289
            QDictEntry *tmp = LIST_NEXT(entry, next);
290
            LIST_REMOVE(entry, next);
289
            QDictEntry *tmp = QLIST_NEXT(entry, next);
290
            QLIST_REMOVE(entry, next);
291 291
            qentry_destroy(entry);
292 292
            entry = tmp;
293 293
        }

Also available in: Unified diff