summary refs log tree commit diff
path: root/src/platform/tests/test-link.c
diff options
context:
space:
mode:
authorMichael Biebl <biebl@debian.org>2015-01-22 00:29:39 +0100
committerMichael Biebl <biebl@debian.org>2015-01-22 00:29:39 +0100
commit2c032d8f1c6292c1338a615e6ec40252889ba85c (patch)
tree1f77182220b2b0264288ba4a476ab47e5bc48716 /src/platform/tests/test-link.c
parent33491bc4279481db8ae47213e34a6d695a0e8830 (diff)
Imported Upstream version 1.0.0 upstream/1.0.0
Diffstat (limited to 'src/platform/tests/test-link.c')
-rw-r--r--src/platform/tests/test-link.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/platform/tests/test-link.c b/src/platform/tests/test-link.c
index a3f757c2..8bd2ef44 100644
--- a/src/platform/tests/test-link.c
+++ b/src/platform/tests/test-link.c
@@ -1,3 +1,5 @@
+#include "config.h"
+
 #include "test-common.h"
 #include "nm-test-utils.h"
 
@@ -130,6 +132,7 @@ software_add (NMLinkType link_type, const char *name)
 	default:
 		g_error ("Link type %d unhandled.", link_type);
 	}
+	g_assert_not_reached ();
 }
 
 static void
@@ -188,12 +191,12 @@ test_slave (int master, int type, SignalData *master_changed)
 			/* Older team versions (e.g. Fedora 17) have a bug that team master stays
 			 * IFF_LOWER_UP even if its slave is down. Double check it with iproute2 and if
 			 * `ip link` also claims master to be up, accept it. */
-			char *stdout = NULL;
+			char *stdout_str = NULL;
 
-			nmtst_spawn_sync (NULL, &stdout, NULL, 0, "/sbin/ip", "link", "show", "dev", nm_platform_link_get_name (master));
+			nmtst_spawn_sync (NULL, &stdout_str, NULL, 0, "/sbin/ip", "link", "show", "dev", nm_platform_link_get_name (master));
 
-			g_assert (strstr (stdout, "LOWER_UP"));
-			g_free (stdout);
+			g_assert (strstr (stdout_str, "LOWER_UP"));
+			g_free (stdout_str);
 		} else
 			g_assert_not_reached ();
 	}
@@ -379,7 +382,7 @@ test_team (void)
 }
 
 static void
-test_vlan ()
+test_vlan (void)
 {
 	test_software (NM_LINK_TYPE_VLAN, "vlan");
 }