diff --git a/model/sync-app-data-publish.cc b/model/sync-app-data-publish.cc
index bc1281b..faaf482 100644
--- a/model/sync-app-data-publish.cc
+++ b/model/sync-app-data-publish.cc
@@ -42,7 +42,7 @@
 }
 
 uint32_t
-AppDataPublish::getHighestSeq (const string &prefix, uint32_t session)
+AppDataPublish::getNextSeq (const string &prefix, uint32_t session)
 {
   unordered_map<string, Seq>::iterator i = m_sequenceLog.find(prefix);
 
@@ -62,22 +62,22 @@
   uint32_t seq = 0;
 	try
 		{
-			seq =  getHighestSeq(name, session);
+			seq =  getNextSeq(name, session);
 		}
 	catch (GetSeqException &e){
     m_sequenceLog.erase(name);
 	}
 
-  Seq s;
-  s.session = session;
-  s.seq = seq;
-  m_sequenceLog[name] = s;
-
   ostringstream contentNameWithSeqno;
   contentNameWithSeqno << name << "/" << session << "/" << seq;
 
   m_ccnxHandle->publishData (contentNameWithSeqno.str (), dataBuffer, freshness);
 
+  Seq s;
+  s.session = session;
+  s.seq = seq + 1;
+  m_sequenceLog[name] = s;
+
   unordered_map<pair<string, uint32_t>, string>::iterator it = m_recentData.find(make_pair(name, session));
   if (it != m_recentData.end()) 
     m_recentData.erase(it);
diff --git a/model/sync-app-data-publish.h b/model/sync-app-data-publish.h
index 204a076..85bb9ae 100644
--- a/model/sync-app-data-publish.h
+++ b/model/sync-app-data-publish.h
@@ -68,7 +68,7 @@
    * @param session session
    */
   uint32_t
-  getHighestSeq (const std::string &prefix, uint32_t session);
+  getNextSeq (const std::string &prefix, uint32_t session);
 
   /**
    * @brief publish data for a name prefix, updates the corresponding
diff --git a/model/sync-app-socket.cc b/model/sync-app-socket.cc
index 3dca250..fb6779d 100644
--- a/model/sync-app-socket.cc
+++ b/model/sync-app-socket.cc
@@ -46,7 +46,7 @@
 bool SyncAppSocket::publish (const string &prefix, uint32_t session, const string &dataBuffer, int freshness)
 {
   m_publisher.publishData (prefix, session, dataBuffer, freshness);
-  m_syncLogic.addLocalNames (prefix, session, m_publisher.getHighestSeq (prefix, session));
+  m_syncLogic.addLocalNames (prefix, session, m_publisher.getNextSeq (prefix, session));
 }
 
 }
diff --git a/test/test_data_fetch_and_publish.cc b/test/test_data_fetch_and_publish.cc
index a442830..b1e7647 100644
--- a/test/test_data_fetch_and_publish.cc
+++ b/test/test_data_fetch_and_publish.cc
@@ -67,7 +67,7 @@
   TestStructApp bar;
 	
   string interest = "/april/fool";
-  string seq[5] = {"1", "2", "3", "4", "5"};
+  string seq[5] = {"0", "1", "2", "3", "4" };
   string str[5] = {"panda", "express", "tastes", "so", "good"};
 
   for (int i = 0; i < 5; i++) {
@@ -86,10 +86,10 @@
     publisher.publishData(interest, 0, str[i - 1], 5);
   }
 
-  BOOST_CHECK_EQUAL(publisher.getHighestSeq(interest, 0), 5);
+  BOOST_CHECK_EQUAL(publisher.getNextSeq(interest, 0), 5);
   BOOST_CHECK_EQUAL(publisher.getRecentData(interest, 0), str[4]);
 
-  fetcher.onUpdate (interest, SeqNo (0,5), SeqNo (0,0));
+  fetcher.onUpdate (interest, SeqNo (0,4), SeqNo (0,-1));
   // give time for ccnd to react
   sleep(1);
   BOOST_CHECK_EQUAL(foo.toString(), bar.toString());
@@ -99,7 +99,7 @@
     bind(&TestStructApp::erase, &bar, _1, _2);
   fetcher.setDataCallback(eraseFunc);
 
-  fetcher.onUpdate (interest, SeqNo (0,5), SeqNo (0,0));
+  fetcher.onUpdate (interest, SeqNo (0,4), SeqNo (0,-1));
   // give time for ccnd to react
   sleep(1);
   TestStructApp poo;
