diff options
author | Stephen Gallagher <sgallagh@redhat.com> | 2012-07-09 11:46:39 -0400 |
---|---|---|
committer | Stephen Gallagher <sgallagh@redhat.com> | 2012-07-09 13:49:21 -0400 |
commit | d7abad9b7a25ad82c5290ce6abecfd2f0e6da03b (patch) | |
tree | 5a1dd39a79bd5657103cbb96f48d0a1c53187032 | |
parent | 898eb701893c3df1bd9f536c47555db39a10667c (diff) | |
download | sssd-d7abad9b7a25ad82c5290ce6abecfd2f0e6da03b.tar.gz sssd-d7abad9b7a25ad82c5290ce6abecfd2f0e6da03b.tar.bz2 sssd-d7abad9b7a25ad82c5290ce6abecfd2f0e6da03b.zip |
Fix incorrect return value in tests
Coverity #12798
-rw-r--r-- | src/tests/krb5_utils-tests.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/tests/krb5_utils-tests.c b/src/tests/krb5_utils-tests.c index 58121299..5fee4544 100644 --- a/src/tests/krb5_utils-tests.c +++ b/src/tests/krb5_utils-tests.c @@ -389,6 +389,7 @@ START_TEST(test_cc_dir_create) ret = cc_dir_create(residual, illegal_re, uid, gid, true); fail_unless(ret == EOK, "cc_dir_create failed\n"); ret = rmdir(dirname); + if (ret < 0) ret = errno; fail_unless(ret == 0, "Cannot remove %s: %s\n", dirname, strerror(ret)); talloc_free(residual); @@ -401,6 +402,7 @@ START_TEST(test_cc_dir_create) ret = cc_dir_create(residual, illegal_re, uid, gid, true); fail_unless(ret == EOK, "cc_dir_create failed\n"); ret = rmdir(dirname); + if (ret < 0) ret = errno; fail_unless(ret == 0, "Cannot remove %s: %s\n", dirname, strerror(ret)); talloc_free(residual); free(cwd); |