diff options
author | Philip Withnall <philip.withnall@collabora.co.uk> | 2015-04-27 11:09:29 +0100 |
---|---|---|
committer | Philip Withnall <philip.withnall@collabora.co.uk> | 2015-04-27 11:12:08 +0100 |
commit | e4bf420dabb264e60b77c45da6376ea27a8bbfa1 (patch) | |
tree | 93fa74a3b8c7e27c134c58966343094f878a72fe | |
parent | 62e21438e2f159a36259bc0d6d2e1c661a671c2c (diff) | |
download | libsoup-e4bf420dabb264e60b77c45da6376ea27a8bbfa1.tar.gz |
tests: Set default values for some variables
This eliminates a compiler warning about potentially using uninitialised
variables. It’s not actually possible for this happen (the variables are
only used on conditional paths with the same conditions as those where
they were previously set), but it’s easy enough to make this change to
shut the compiler up.
https://bugzilla.gnome.org/show_bug.cgi?id=748514
-rw-r--r-- | tests/timeout-test.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/timeout-test.c b/tests/timeout-test.c index c783d9ab..96505e9b 100644 --- a/tests/timeout-test.c +++ b/tests/timeout-test.c @@ -54,8 +54,8 @@ do_msg_tests_for_session (SoupSession *timeout_session, SoupURI *fast_uri, SoupURI *slow_uri) { - SoupSocket *ret, *idle_first, *idle_second; - SoupSocket *plain_first, *plain_second; + SoupSocket *ret, *idle_first = NULL, *idle_second; + SoupSocket *plain_first = NULL, *plain_second; if (idle_session) { g_signal_connect (idle_session, "request-started", @@ -152,8 +152,8 @@ do_req_tests_for_session (SoupSession *timeout_session, SoupURI *fast_uri, SoupURI *slow_uri) { - SoupSocket *ret, *idle_first, *idle_second; - SoupSocket *plain_first, *plain_second; + SoupSocket *ret, *idle_first = NULL, *idle_second; + SoupSocket *plain_first = NULL, *plain_second; if (idle_session) { g_signal_connect (idle_session, "request-started", |