diff options
-rw-r--r-- | src/core/NetworkManagerUtils.c | 6 | ||||
-rw-r--r-- | src/core/NetworkManagerUtils.h | 1 | ||||
-rw-r--r-- | src/core/platform/tests/test-common.c | 4 | ||||
-rw-r--r-- | src/core/platform/tests/test-tc.c | 2 |
4 files changed, 11 insertions, 2 deletions
diff --git a/src/core/NetworkManagerUtils.c b/src/core/NetworkManagerUtils.c index 69b8d83ab4..0da8e0a949 100644 --- a/src/core/NetworkManagerUtils.c +++ b/src/core/NetworkManagerUtils.c @@ -1709,5 +1709,11 @@ nm_platform_get() void nm_linux_platform_setup(void) { + nm_platform_setup(nm_linux_platform_new(FALSE, FALSE, FALSE)); +} + +void +nm_linux_platform_setup_with_tc_cache(void) +{ nm_platform_setup(nm_linux_platform_new(FALSE, FALSE, TRUE)); } diff --git a/src/core/NetworkManagerUtils.h b/src/core/NetworkManagerUtils.h index af5b5a5ef2..a2ac732e83 100644 --- a/src/core/NetworkManagerUtils.h +++ b/src/core/NetworkManagerUtils.h @@ -277,6 +277,7 @@ NMPlatform *nm_platform_get(void); #define NM_PLATFORM_GET (nm_platform_get()) void nm_linux_platform_setup(void); +void nm_linux_platform_setup_with_tc_cache(void); /*****************************************************************************/ diff --git a/src/core/platform/tests/test-common.c b/src/core/platform/tests/test-common.c index 2fc9e836ea..ad6bc114bc 100644 --- a/src/core/platform/tests/test-common.c +++ b/src/core/platform/tests/test-common.c @@ -37,7 +37,9 @@ gboolean nmtstp_is_root_test(void) { g_assert(_nmtstp_setup_platform_func); - return _nmtstp_setup_platform_func == nm_linux_platform_setup; + return NM_IN_SET(_nmtstp_setup_platform_func, + nm_linux_platform_setup, + nm_linux_platform_setup_with_tc_cache); } gboolean diff --git a/src/core/platform/tests/test-tc.c b/src/core/platform/tests/test-tc.c index 8b7e4d4a94..ee7b861ec7 100644 --- a/src/core/platform/tests/test-tc.c +++ b/src/core/platform/tests/test-tc.c @@ -202,7 +202,7 @@ test_qdisc_tbf(void) /*****************************************************************************/ -NMTstpSetupFunc const _nmtstp_setup_platform_func = nm_linux_platform_setup; +NMTstpSetupFunc const _nmtstp_setup_platform_func = nm_linux_platform_setup_with_tc_cache; void _nmtstp_init_tests(int *argc, char ***argv) |