mirror of
https://github.com/samba-team/samba.git
synced 2024-12-24 21:34:56 +03:00
s4:torture:basic: fix valgrind 'Syscall param writev(vector[...])' error
smbtorture test base.aliases.setfileinfo_aliases.setfileinfo_aliases results in the following valgrind trace ==22757== Syscall param writev(vector[...]) points to uninitialised byte(s) ==22757== at 0xFBA2C87: writev (in /lib64/libc-2.19.so) ==22757== by 0x106CB033: writev_handler (async_sock.c:340) ==22757== by 0xF67812A: ??? (in /usr/lib64/libtevent.so.0.9.26) ==22757== by 0xF6765F6: ??? (in /usr/lib64/libtevent.so.0.9.26) ==22757== by 0xF6727FC: _tevent_loop_once (in /usr/lib64/libtevent.so.0.9.26) ==22757== by 0x5AE3400: smbcli_request_receive (rawrequest.c:416) ==22757== by 0x5AE6019: smb_raw_write_recv (rawreadwrite.c:303) ==22757== by 0x5AE63FD: smb_raw_write (rawreadwrite.c:344) ==22757== by 0x9BE50CA: smbcli_write (clireadwrite.c:118) ==22757== by 0x423C91: setfileinfo_aliases (aliases.c:327) ==22757== by 0x16B21D: wrap_simple_1smb_test (util_smb.c:856) ==22757== by 0x955368F: internal_torture_run_test (torture.c:442) ==22757== by 0x9553A6B: torture_run_test_restricted (torture.c:542) ==22757== by 0x2600A4: run_matching (smbtorture.c:110) ==22757== by 0x25FF66: run_matching (smbtorture.c:95) ==22757== by 0x25FF66: run_matching (smbtorture.c:95) ==22757== by 0x2601C5: torture_run_named_tests (smbtorture.c:143) ==22757== by 0x261E44: main (smbtorture.c:665) ==22757== Address 0x187dfee6 is 598 bytes inside a block of size 1,325 alloc'd ==22757== at 0x4C29110: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so) ==22757== by 0xF464A73: _talloc_pooled_object (in /usr/lib64/libtalloc.so.2.1.5) ==22757== by 0xF67366D: _tevent_req_create (in /usr/lib64/libtevent.so.0.9.26) ==22757== by 0xB0D49FF: smb1cli_req_create (smbXcli_base.c:1322) ==22757== by 0x5ADFAB7: smbcli_transport_setup_subreq (clitransport.c:254) ==22757== by 0x5ADFC37: smbcli_transport_send (clitransport.c:326) ==22757== by 0x5AE33C3: smbcli_request_send (rawrequest.c:400) ==22757== by 0x5AE5FDD: smb_raw_write_send (rawreadwrite.c:289) ==22757== by 0x5AE63E6: smb_raw_write (rawreadwrite.c:343) ==22757== by 0x9BE50CA: smbcli_write (clireadwrite.c:118) ==22757== by 0x423C91: setfileinfo_aliases (aliases.c:327) ==22757== by 0x16B21D: wrap_simple_1smb_test (util_smb.c:856) ==22757== by 0x955368F: internal_torture_run_test (torture.c:442) ==22757== by 0x9553A6B: torture_run_test_restricted (torture.c:542) ==22757== by 0x2600A4: run_matching (smbtorture.c:110) ==22757== by 0x25FF66: run_matching (smbtorture.c:95) ==22757== by 0x25FF66: run_matching (smbtorture.c:95) ==22757== by 0x2601C5: torture_run_named_tests (smbtorture.c:143) ==22757== by 0x261E44: 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
a5ce559a80
commit
6806c1486e
@ -306,6 +306,7 @@ static bool setfileinfo_aliases(struct torture_context *tctx, struct smbcli_stat
|
||||
const char *fname = "\\setfileinfo_aliases.txt";
|
||||
int fnum;
|
||||
|
||||
ZERO_STRUCT(t2);
|
||||
t2.in.max_param = 2;
|
||||
t2.in.max_data = 0;
|
||||
t2.in.max_setup = 0;
|
||||
@ -315,7 +316,6 @@ static bool setfileinfo_aliases(struct torture_context *tctx, struct smbcli_stat
|
||||
t2.in.setup = &setup;
|
||||
t2.in.params = data_blob_talloc_zero(tctx, 6);
|
||||
t2.in.data = data_blob(NULL, 0);
|
||||
ZERO_STRUCT(t2.out);
|
||||
|
||||
smbcli_unlink(cli->tree, fname);
|
||||
fnum = create_complex_file(cli, cli, fname);
|
||||
|
Loading…
Reference in New Issue
Block a user