tests: sockettest: move declarations

Declare the structs: at the beginning of the block.

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
Ján Tomko 2020-07-28 20:10:53 +02:00
parent 8687408f90
commit 7923996d77

View File

@ -277,11 +277,11 @@ mymain(void)
do { \
virSocketAddr addr; \
struct testParseData data = { &addr, addrstr, family, pass }; \
struct testFormatData data2 = { &addr, addrstr, pass }; \
memset(&addr, 0, sizeof(addr)); \
if (virTestRun("Test parse " addrstr " family " #family, \
testParseHelper, &data) < 0) \
ret = -1; \
struct testFormatData data2 = { &addr, addrstr, pass }; \
if (virTestRun("Test format " addrstr " family " #family, \
testFormatHelper, &data2) < 0) \
ret = -1; \
@ -291,11 +291,11 @@ mymain(void)
do { \
virSocketAddr addr; \
struct testParseData data = { &addr, addrstr, family, true}; \
struct testFormatData data2 = { &addr, addrformated, pass }; \
memset(&addr, 0, sizeof(addr)); \
if (virTestRun("Test parse " addrstr " family " #family, \
testParseHelper, &data) < 0) \
ret = -1; \
struct testFormatData data2 = { &addr, addrformated, pass }; \
if (virTestRun("Test format " addrstr " family " #family, \
testFormatHelper, &data2) < 0) \
ret = -1; \