diff options
author | Niels De Graef <nielsdegraef@gmail.com> | 2023-01-22 19:27:26 +0100 |
---|---|---|
committer | Niels De Graef <nielsdegraef@gmail.com> | 2023-01-22 19:33:20 +0100 |
commit | 056d16fa27350066af51ed98803c87291d7200ef (patch) | |
tree | df4e9a960db5f870b63da53f8e409dc0e11ebeea | |
parent | a2d931ada6f0814b75efdb8f2a4bbf4105e82904 (diff) | |
download | gcr-nielsdg/use-docker-for-ci.tar.gz |
test-ssh-askpass: Use g_assert_no_errno()nielsdg/use-docker-for-ci
If `g_chmod()` fails for some reason, it's better to know why it's failing
-rw-r--r-- | gcr/test-ssh-askpass.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/gcr/test-ssh-askpass.c b/gcr/test-ssh-askpass.c index 0229436..b1bd959 100644 --- a/gcr/test-ssh-askpass.c +++ b/gcr/test-ssh-askpass.c @@ -77,8 +77,7 @@ test_ssh_keygen (Test *test, g_assert_cmpstr (password, ==, "booo"); - if (g_chmod (filename, 0600) < 0) - g_assert_not_reached (); + g_assert_no_errno (g_chmod (filename, 0600)); g_spawn_async (SRCDIR "/gcr/fixtures", argv, NULL, G_SPAWN_STDOUT_TO_DEV_NULL | G_SPAWN_SEARCH_PATH | G_SPAWN_DO_NOT_REAP_CHILD | G_SPAWN_CLOEXEC_PIPES, |