diff options
author | Thomas Haller <thaller@redhat.com> | 2019-01-31 17:08:03 +0100 |
---|---|---|
committer | Thomas Haller <thaller@redhat.com> | 2019-02-12 08:50:28 +0100 |
commit | a4fb6ddfca60c50cdf140d3f388209ace06e24ff (patch) | |
tree | 8df5cea166a835f58b4d51cbb12755b87cb29322 /shared | |
parent | 737ab51472a95df32d5f47633c0f01e22ff43950 (diff) | |
download | NetworkManager-a4fb6ddfca60c50cdf140d3f388209ace06e24ff.tar.gz |
all: replace g_strerror() calls with nm_strerror_native()
Diffstat (limited to 'shared')
-rw-r--r-- | shared/nm-utils/nm-io-utils.c | 14 | ||||
-rw-r--r-- | shared/nm-utils/nm-shared-utils.h | 2 |
2 files changed, 8 insertions, 8 deletions
diff --git a/shared/nm-utils/nm-io-utils.c b/shared/nm-utils/nm-io-utils.c index 091110e0a7..7a9b8b7752 100644 --- a/shared/nm-utils/nm-io-utils.c +++ b/shared/nm-utils/nm-io-utils.c @@ -50,7 +50,7 @@ _get_contents_error (GError **error, int errsv, const char *format, ...) G_FILE_ERROR, g_file_error_from_errno (errsv), "%s: %s", - msg, g_strerror (errsv)); + msg, nm_strerror_native (errsv)); g_free (msg); } return -errsv; @@ -302,7 +302,7 @@ nm_utils_file_get_contents (int dirfd, g_file_error_from_errno (errsv), "Failed to open file \"%s\" with openat: %s", filename, - g_strerror (errsv)); + nm_strerror_native (errsv)); return -NM_ERRNO_NATIVE (errsv); } } else { @@ -315,7 +315,7 @@ nm_utils_file_get_contents (int dirfd, g_file_error_from_errno (errsv), "Failed to open file \"%s\": %s", filename, - g_strerror (errsv)); + nm_strerror_native (errsv)); return -NM_ERRNO_NATIVE (errsv); } } @@ -364,7 +364,7 @@ nm_utils_file_set_contents (const char *filename, g_file_error_from_errno (errsv), "failed to create file %s: %s", tmp_name, - g_strerror (errsv)); + nm_strerror_native (errsv)); return FALSE; } @@ -383,7 +383,7 @@ nm_utils_file_set_contents (const char *filename, g_file_error_from_errno (errsv), "failed to write to file %s: %s", tmp_name, - g_strerror (errsv)); + nm_strerror_native (errsv)); return FALSE; } @@ -412,7 +412,7 @@ nm_utils_file_set_contents (const char *filename, g_file_error_from_errno (errsv), "failed to fsync %s: %s", tmp_name, - g_strerror (errsv)); + nm_strerror_native (errsv)); return FALSE; } } @@ -428,7 +428,7 @@ nm_utils_file_set_contents (const char *filename, "failed to rename %s to %s: %s", tmp_name, filename, - g_strerror (errsv)); + nm_strerror_native (errsv)); return FALSE; } diff --git a/shared/nm-utils/nm-shared-utils.h b/shared/nm-utils/nm-shared-utils.h index a8082d4cd0..fd2019349a 100644 --- a/shared/nm-utils/nm-shared-utils.h +++ b/shared/nm-utils/nm-shared-utils.h @@ -705,7 +705,7 @@ nm_utils_error_set_literal (GError **error, int error_code, const char *literal) NM_UTILS_ERROR_UNKNOWN, \ fmt, \ ##__VA_ARGS__, \ - g_strerror (({ \ + nm_strerror_native (({ \ const int _errsv = (errsv); \ \ ( _errsv >= 0 \ |