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