qemu with hax to log dma reads & writes jcs.org/2018/11/12/vfio

test-throttle: Fix uninitialized use of burst_length

ThrottleState::cfg of the static variable 'ts' is reassigned with the
local one in the do_test_accounting() and then is passed to the
throttle_account() with uninitialized member LeakyBucket::burst_length.

Signed-off-by: Andrey Shinkevich <andrey.shinkevich@virtuozzo.com>
Message-Id: <1564502498-805893-2-git-send-email-andrey.shinkevich@virtuozzo.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>

authored by

Andrey Shinkevich and committed by
Paolo Bonzini
ef0aa6af de428cea

+2
+2
tests/test-throttle.c
··· 558 558 BucketType index; 559 559 int i; 560 560 561 + throttle_config_init(&cfg); 562 + 561 563 for (i = 0; i < 3; i++) { 562 564 BucketType index = to_test[is_ops][i]; 563 565 cfg.buckets[index].avg = avg;