for (;;) {
struct stat st;
struct dirent buf, *de;
- int k;
- k = readdir_r(d, &buf, &de);
- if (k != 0) {
- r = -k;
- goto finish;
- }
+ r = readdir_r(d, &buf, &de);
+ if (r != 0)
+ break;
if (!de)
break;
* if it already exists, so that we can flush
* it into the system journal */
- r = journal_file_open_reliably(fn, O_RDWR, 0640, NULL, &s->runtime_journal);
+ r = journal_file_open(fn, O_RDWR, 0640, NULL, &s->runtime_journal);
free(fn);
if (r < 0) {