mirror of
https://github.com/samba-team/samba.git
synced 2025-01-22 22:04:08 +03:00
s4:torture:raw: fix 'Conditional jump or move' valgrind error.
smbtorture test raw.bench-tcon.bench-tcon produces the following valgrind trace ==32163== Conditional jump or move depends on uninitialised value(s) ==32163== at 0x1F9D61: rate_convert_secs (tconrate.c:149) ==32163== by 0x1FA04C: torture_bench_treeconnect (tconrate.c:189) ==32163== by 0x9553F62: wrap_simple_test (torture.c:632) ==32163== by 0x955368F: internal_torture_run_test (torture.c:442) ==32163== by 0x9553A6B: torture_run_test_restricted (torture.c:542) ==32163== by 0x260121: run_matching (smbtorture.c:110) ==32163== by 0x25FFE3: run_matching (smbtorture.c:95) ==32163== by 0x260242: torture_run_named_tests (smbtorture.c:143) ==32163== by 0x261EC1: main (smbtorture.c:665) ==32163== ==32163== Use of uninitialised value of size 8 ==32163== at 0xFB0B0BB: _itoa_word (in /lib64/libc-2.19.so) ==32163== by 0xFB0EAD2: vfprintf (in /lib64/libc-2.19.so) ==32163== by 0xFB15598: printf (in /lib64/libc-2.19.so) ==32163== by 0x1FA064: torture_bench_treeconnect (tconrate.c:188) ==32163== by 0x9553F62: wrap_simple_test (torture.c:632) ==32163== by 0x955368F: internal_torture_run_test (torture.c:442) ==32163== by 0x9553A6B: torture_run_test_restricted (torture.c:542) ==32163== by 0x260121: run_matching (smbtorture.c:110) ==32163== by 0x25FFE3: run_matching (smbtorture.c:95) ==32163== by 0x260242: torture_run_named_tests (smbtorture.c:143) ==32163== by 0x261EC1: main (smbtorture.c:665) Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Volker Lendecke <vl@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
This commit is contained in:
parent
04d70f5206
commit
bb0c4a95df
@ -161,7 +161,7 @@ bool torture_bench_treeconnect(struct torture_context *tctx)
|
||||
int nprocs = torture_setting_int(tctx, "nprocs", 4);
|
||||
|
||||
int *curr_counts = map_count_buffer(nprocs, sizeof(int));
|
||||
int *last_counts = talloc_array(NULL, int, nprocs);
|
||||
int *last_counts = talloc_zero_array(NULL, int, nprocs);
|
||||
|
||||
struct timeval now, last, start;
|
||||
int i, delta;
|
||||
|
Loading…
x
Reference in New Issue
Block a user