]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
Merge pull request #16120 from yanghonggang/master
authorSage Weil <sage@newdream.net>
Fri, 7 Jul 2017 02:39:00 +0000 (21:39 -0500)
committerGitHub <noreply@github.com>
Fri, 7 Jul 2017 02:39:00 +0000 (21:39 -0500)
os/filestore/FileJournal: FileJournal::open() close journal file before return error

Reviewed-by: Kefu Chai <kchai@redhat.com>
1  2 
src/os/filestore/FileJournal.cc

index 649e4460f22d6f272ff85604e5b6ff9be18dcc17,8eb053ef5e2e4acbfb300b4d45675e3412e03d9a..0491559aee98b3c6312cee268c520bd648abcb3a
@@@ -458,8 -465,17 +465,8 @@@ int FileJournal::open(uint64_t fs_op_se
  
    // find next entry
    read_pos = header.start;
-   uint64_t seq = header.start_seq;
+   seq = header.start_seq;
  
 -  // last_committed_seq is 1 before the start of the journal or
 -  // 0 if the start is 0
 -  last_committed_seq = seq > 0 ? seq - 1 : seq;
 -  if (last_committed_seq < fs_op_seq) {
 -    dout(2) << "open advancing committed_seq " << last_committed_seq
 -          << " to fs op_seq " << fs_op_seq << dendl;
 -    last_committed_seq = fs_op_seq;
 -  }
 -
    while (1) {
      bufferlist bl;
      off64_t old_pos = read_pos;