mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-24 04:13:28 +01:00
Fix some compiler warnings
This commit is contained in:
parent
a78ffd9e45
commit
f46f6aabb4
@ -3058,6 +3058,9 @@ tor_spawn_background(const char *const filename, const char **argv)
|
|||||||
HANDLE stderr_pipe_read = NULL;
|
HANDLE stderr_pipe_read = NULL;
|
||||||
HANDLE stderr_pipe_write = NULL;
|
HANDLE stderr_pipe_write = NULL;
|
||||||
|
|
||||||
|
STARTUPINFO siStartInfo;
|
||||||
|
BOOL retval = FALSE;
|
||||||
|
|
||||||
SECURITY_ATTRIBUTES saAttr;
|
SECURITY_ATTRIBUTES saAttr;
|
||||||
smartlist_t *argv_list;
|
smartlist_t *argv_list;
|
||||||
char *joined_argv;
|
char *joined_argv;
|
||||||
@ -3105,9 +3108,6 @@ tor_spawn_background(const char *const filename, const char **argv)
|
|||||||
|
|
||||||
joined_argv = smartlist_join_strings(argv_list, " ", 0, NULL);
|
joined_argv = smartlist_join_strings(argv_list, " ", 0, NULL);
|
||||||
|
|
||||||
STARTUPINFO siStartInfo;
|
|
||||||
BOOL retval = FALSE;
|
|
||||||
|
|
||||||
ZeroMemory(&process_handle.pid, sizeof(PROCESS_INFORMATION));
|
ZeroMemory(&process_handle.pid, sizeof(PROCESS_INFORMATION));
|
||||||
ZeroMemory(&siStartInfo, sizeof(STARTUPINFO));
|
ZeroMemory(&siStartInfo, sizeof(STARTUPINFO));
|
||||||
siStartInfo.cb = sizeof(STARTUPINFO);
|
siStartInfo.cb = sizeof(STARTUPINFO);
|
||||||
@ -3592,7 +3592,7 @@ tor_check_port_forwarding(const char *filename, int dir_port, int or_port,
|
|||||||
#define TIME_TO_EXEC_FWHELPER_FAIL 60
|
#define TIME_TO_EXEC_FWHELPER_FAIL 60
|
||||||
|
|
||||||
#ifdef MS_WINDOWS
|
#ifdef MS_WINDOWS
|
||||||
static process_handle_t child_handle = {0, NULL, NULL, {NULL}};
|
static process_handle_t child_handle = {0, NULL, NULL, {NULL, NULL, 0, 0}};
|
||||||
#else
|
#else
|
||||||
static process_handle_t child_handle;
|
static process_handle_t child_handle;
|
||||||
#endif
|
#endif
|
||||||
|
@ -1493,6 +1493,8 @@ test_util_spawn_background_partial_read(void *ptr)
|
|||||||
process_handle_t process_handle;
|
process_handle_t process_handle;
|
||||||
char stdout_buf[100], stderr_buf[100];
|
char stdout_buf[100], stderr_buf[100];
|
||||||
|
|
||||||
|
(void)ptr;
|
||||||
|
|
||||||
/* Start the program */
|
/* Start the program */
|
||||||
process_handle = tor_spawn_background(argv[0], argv);
|
process_handle = tor_spawn_background(argv[0], argv);
|
||||||
tt_int_op(process_handle.status, ==, expected_status);
|
tt_int_op(process_handle.status, ==, expected_status);
|
||||||
|
Loading…
Reference in New Issue
Block a user