diff options
author | Thomas Haller <thaller@redhat.com> | 2019-01-31 17:22:18 +0100 |
---|---|---|
committer | Thomas Haller <thaller@redhat.com> | 2019-02-12 08:50:28 +0100 |
commit | 9beed4f661d0b8e02c16a616e7491baa42af0843 (patch) | |
tree | 73d89a906ec4399751dec36cee92bc0a918c0a93 /src/platform/tests | |
parent | a4fb6ddfca60c50cdf140d3f388209ace06e24ff (diff) | |
download | NetworkManager-9beed4f661d0b8e02c16a616e7491baa42af0843.tar.gz |
all: replace strerror() calls with nm_strerror_native()
Diffstat (limited to 'src/platform/tests')
-rw-r--r-- | src/platform/tests/test-common.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/platform/tests/test-common.c b/src/platform/tests/test-common.c index 8e29b5ce8d..c510710b17 100644 --- a/src/platform/tests/test-common.c +++ b/src/platform/tests/test-common.c @@ -1840,7 +1840,7 @@ nmtstp_namespace_create (int unshare_flags, GError **error) if (e != 0) { errsv = errno; g_set_error (error, NM_UTILS_ERROR, NM_UTILS_ERROR_UNKNOWN, - "pipe() failed with %d (%s)", errsv, strerror (errsv)); + "pipe() failed with %d (%s)", errsv, nm_strerror_native (errsv)); return FALSE; } @@ -1848,7 +1848,7 @@ nmtstp_namespace_create (int unshare_flags, GError **error) if (e != 0) { errsv = errno; g_set_error (error, NM_UTILS_ERROR, NM_UTILS_ERROR_UNKNOWN, - "pipe() failed with %d (%s)", errsv, strerror (errsv)); + "pipe() failed with %d (%s)", errsv, nm_strerror_native (errsv)); nm_close (pipefd_c2p[0]); nm_close (pipefd_c2p[1]); return FALSE; @@ -1858,7 +1858,7 @@ nmtstp_namespace_create (int unshare_flags, GError **error) if (pid < 0) { errsv = errno; g_set_error (error, NM_UTILS_ERROR, NM_UTILS_ERROR_UNKNOWN, - "fork() failed with %d (%s)", errsv, strerror (errsv)); + "fork() failed with %d (%s)", errsv, nm_strerror_native (errsv)); nm_close (pipefd_c2p[0]); nm_close (pipefd_c2p[1]); nm_close (pipefd_p2c[0]); @@ -1919,7 +1919,7 @@ nmtstp_namespace_create (int unshare_flags, GError **error) "child process failed for unknown reason"); } else { g_set_error (error, NM_UTILS_ERROR, NM_UTILS_ERROR_UNKNOWN, - "child process signaled failure %d (%s)", errsv, strerror (errsv)); + "child process signaled failure %d (%s)", errsv, nm_strerror_native (errsv)); } nm_close (pipefd_p2c[1]); kill (pid, SIGKILL); @@ -2074,14 +2074,14 @@ main (int argc, char **argv) if (unshare (CLONE_NEWNET | CLONE_NEWNS) != 0) { errsv = errno; - g_error ("unshare(CLONE_NEWNET|CLONE_NEWNS) failed with %s (%d)", strerror (errsv), errsv); + g_error ("unshare(CLONE_NEWNET|CLONE_NEWNS) failed with %s (%d)", nm_strerror_native (errsv), errsv); } /* We need a read-only /sys so that the platform knows there's no udev. */ mount (NULL, "/sys", "sysfs", MS_SLAVE, NULL); if (mount ("sys", "/sys", "sysfs", MS_RDONLY, NULL) != 0) { errsv = errno; - g_error ("mount(\"/sys\") failed with %s (%d)", strerror (errsv), errsv); + g_error ("mount(\"/sys\") failed with %s (%d)", nm_strerror_native (errsv), errsv); } } |