src/lsa-segment-storage: fix convergence w/o content store

refs: #4430

Change-Id: I5124e9fd49bd9850c904c31d221b42b4249553a3
diff --git a/src/lsa-segment-storage.cpp b/src/lsa-segment-storage.cpp
index 3e85bd0..c384a53 100644
--- a/src/lsa-segment-storage.cpp
+++ b/src/lsa-segment-storage.cpp
@@ -107,7 +107,7 @@
 
     try {
       expirationTime = ndn::time::duration_cast<ndn::time::seconds>
-                       (ndn::time::system_clock::now() - ndn::time::fromIsoString(options.at(3)));
+                       (ndn::time::fromIsoString(options.at(3)) - ndn::time::system_clock::now());
     } catch (const std::exception& e) {
       NLSR_LOG_ERROR("Cannot extract expiration time from LSA content: " << e.what());
     }
diff --git a/src/publisher/segment-publisher.hpp b/src/publisher/segment-publisher.hpp
index 2938980..d80c90e 100644
--- a/src/publisher/segment-publisher.hpp
+++ b/src/publisher/segment-publisher.hpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /**
- * Copyright (c) 2014-2017,  Regents of the University of California,
+ * Copyright (c) 2014-2018,  Regents of the University of California,
  *                           Arizona Board of Regents,
  *                           Colorado State University,
  *                           University Pierre & Marie Curie, Sorbonne University,
@@ -105,7 +105,7 @@
 
       segmentBegin = segmentEnd;
       if (segmentBegin >= end) {
-        data->setFinalBlockId(segmentName[-1]);
+        data->setFinalBlock(segmentName[-1]);
       }
 
       publishSegment(data);