1
0
mirror of https://github.com/systemd/systemd.git synced 2024-11-05 06:52:22 +03:00

test: fix rename_noreplace() test

This corrects the fix b81b9d406d, making the test operate like it was
originally.
This commit is contained in:
Lennart Poettering 2020-01-28 21:40:03 +01:00
parent 3c7b4ebf94
commit bcb1eadc0c

View File

@ -739,7 +739,7 @@ static void test_rename_noreplace(void) {
STRV_FOREACH(b, (char**) table) {
_cleanup_free_ char *w = NULL;
w = strjoin(w, *b);
w = strjoin(z, *b);
assert_se(w);
if (access(w, F_OK) < 0) {
@ -747,7 +747,7 @@ static void test_rename_noreplace(void) {
continue;
}
assert_se(rename_noreplace(AT_FDCWD, w, AT_FDCWD, y) == -EEXIST);
assert_se(rename_noreplace(AT_FDCWD, x, AT_FDCWD, w) == -EEXIST);
}
y = strjoin(z, "/somethingelse");