]> git.proxmox.com Git - mirror_qemu.git/blobdiff - qemu-timer.c
valgrind/i386: avoid false positives on KVM_SET_CLOCK ioctl
[mirror_qemu.git] / qemu-timer.c
index 9be1a4131d6318f7b6d3f93e3b1253f5884d82eb..00a5d35c3f64f5c9a65a5ade0e85273e3555e5c0 100644 (file)
@@ -126,6 +126,9 @@ static void qemu_clock_init(QEMUClockType type)
 {
     QEMUClock *clock = qemu_clock_ptr(type);
 
+    /* Assert that the clock of type TYPE has not been initialized yet. */
+    assert(main_loop_tlg.tl[type] == NULL);
+
     clock->type = type;
     clock->enabled = true;
     clock->last = INT64_MIN;