mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-26 15:50:07 +01:00
keyfile: fix chmod() error checking
This commit is contained in:
parent
b8fc83a7cf
commit
3f1b47b3c3
1 changed files with 1 additions and 1 deletions
|
|
@ -443,7 +443,7 @@ write_connection (NMConnection *connection,
|
|||
unlink (path);
|
||||
} else {
|
||||
err = chmod (path, S_IRUSR | S_IWUSR);
|
||||
if (err > 0) {
|
||||
if (err) {
|
||||
g_set_error (error, NM_SETTINGS_ERROR, NM_SETTINGS_ERROR_INTERNAL_ERROR,
|
||||
"%s.%d: error setting permissions on '%s': %d", __FILE__,
|
||||
__LINE__, path, errno);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue