chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
journal: react with immediate rotation to a couple of more errors
[elogind.git]
/
src
/
journal
/
journal-file.c
diff --git
a/src/journal/journal-file.c
b/src/journal/journal-file.c
index 6460d70c4aef18c28223070150056bdbb0c45295..5d540a7d407da1be3babba109f7fdf210f08db6b 100644
(file)
--- a/
src/journal/journal-file.c
+++ b/
src/journal/journal-file.c
@@
-40,7
+40,7
@@
#define COMPRESSION_SIZE_THRESHOLD (512ULL)
/* This is the minimum journal file size */
#define COMPRESSION_SIZE_THRESHOLD (512ULL)
/* This is the minimum journal file size */
-#define JOURNAL_FILE_SIZE_MIN (64ULL*1024ULL)
+#define JOURNAL_FILE_SIZE_MIN (64ULL*1024ULL)
/* 64 KiB */
/* These are the lower and upper bounds if we deduce the max_use value
* from the file system size */
/* These are the lower and upper bounds if we deduce the max_use value
* from the file system size */
@@
-1887,7
+1887,10
@@
int journal_file_open_reliably(
char *p;
r = journal_file_open(fname, flags, mode, template, ret);
char *p;
r = journal_file_open(fname, flags, mode, template, ret);
- if (r != -EBADMSG)
+ if (r != -EBADMSG && /* corrupted */
+ r != -ENODATA && /* truncated */
+ r != -EHOSTDOWN && /* other machine */
+ r != -EPROTONOSUPPORT) /* incompatible feature */
return r;
if ((flags & O_ACCMODE) == O_RDONLY)
return r;
if ((flags & O_ACCMODE) == O_RDONLY)