From 977eaa1eae53af7f418d87fcb42f4a4d34aad739 Mon Sep 17 00:00:00 2001 From: Zbigniew Jędrzejewski-Szmek Date: Mon, 9 Mar 2015 17:46:30 -0400 Subject: journal: fix return code Introduced in fa6ac76083b8ff. Might be related to CID #1261724, but I don't know if coverity can recurse this deep. --- src/journal/journal-file.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/journal') diff --git a/src/journal/journal-file.c b/src/journal/journal-file.c index f857a6aa37..8e7642710e 100644 --- a/src/journal/journal-file.c +++ b/src/journal/journal-file.c @@ -2651,10 +2651,8 @@ int journal_file_open( } r = mmap_cache_get(f->mmap, f->fd, f->prot, CONTEXT_HEADER, true, 0, PAGE_ALIGN(sizeof(Header)), &f->last_stat, &h); - if (r < 0) { - r = -errno; + if (r < 0) goto fail; - } f->header = h; -- cgit v1.2.3-54-g00ecf