diff --git a/model/sync-logic.cc b/model/sync-logic.cc
index d4e5163..98fdb1a 100644
--- a/model/sync-logic.cc
+++ b/model/sync-logic.cc
@@ -38,6 +38,20 @@
 INIT_LOGGER ("SyncLogic");
 #endif
 
+
+#ifdef NS3_MODULE
+#define GET_RANDOM(var) var.GetValue ()
+#else
+#define GET_RANDOM(var) var ()
+#endif
+
+#define TIME_SECONDS_WITH_JITTER(sec) \
+  (TIME_SECONDS (sec) + TIME_MILLISECONDS (GET_RANDOM (m_reexpressionJitter)))
+
+#define TIME_MILLISECONDS_WITH_JITTER(sec) \
+  (TIME_MILLISECONDS (sec) + TIME_MILLISECONDS (GET_RANDOM (m_reexpressionJitter)))
+
+
 namespace Sync
 {
 
@@ -76,7 +90,7 @@
   m_ccnxHandle->setInterestFilter (m_syncPrefix,
                                    bind (&SyncLogic::respondSyncInterest, this, _1));
 
-  m_scheduler.schedule (TIME_SECONDS (0),
+  m_scheduler.schedule (TIME_SECONDS (0), // no need to add jitter
                         bind (&SyncLogic::sendSyncInterest, this),
                         REEXPRESSING_INTEREST);
 #endif
@@ -100,7 +114,7 @@
   m_ccnxHandle->setInterestFilter (m_syncPrefix,
                                    bind (&SyncLogic::respondSyncInterest, this, _1));
 
-  m_scheduler.schedule (TIME_SECONDS (0),
+  m_scheduler.schedule (TIME_SECONDS (0), // need to send first interests at exactly the same time
                         bind (&SyncLogic::sendSyncInterest, this),
                         REEXPRESSING_INTEREST);
 }
@@ -153,12 +167,6 @@
       m_ccnxHandle->publishData (interestName + "/state",
                                  lexical_cast<string> (m_state),
                                  m_syncResponseFreshness);
-      if (m_outstandingInterest == interestName)
-        {
-          m_scheduler.schedule (TIME_SECONDS (0),
-                                bind (&SyncLogic::sendSyncInterest, this),
-                                REEXPRESSING_INTEREST);
-        }
       return;
     }
 
@@ -175,6 +183,12 @@
           _LOG_TRACE ("processSyncInterest (): Same state. Adding to PIT");
           m_syncInterestTable.insert (interestName);
         }
+      
+      // !!! important change !!!
+      m_scheduler.cancel (REEXPRESSING_INTEREST);
+      m_scheduler.schedule (TIME_SECONDS_WITH_JITTER (m_syncInterestReexpress),
+                            bind (&SyncLogic::sendSyncInterest, this),
+                            REEXPRESSING_INTEREST);
       return;
     }
   
@@ -202,7 +216,8 @@
                                m_syncResponseFreshness);
     if (m_outstandingInterest == interestName)
       {
-        m_scheduler.schedule (TIME_SECONDS (0),
+        m_scheduler.cancel (REEXPRESSING_INTEREST);
+        m_scheduler.schedule (TIME_SECONDS_WITH_JITTER (0),
                               bind (&SyncLogic::sendSyncInterest, this),
                               REEXPRESSING_INTEREST);
       }
@@ -218,18 +233,12 @@
         }
       else
         {
-          // m_recentUnknownDigests.insert (DigestTime (digest, TIME_NOW + TIME_SECONDS (m_unknownDigestStoreTime)));
+          m_recentUnknownDigests.insert (DigestTime (digest, TIME_NOW + TIME_SECONDS (m_unknownDigestStoreTime)));
           
-          uint32_t waitDelay =
-#ifndef NS3_MODULE
-            m_rangeUniformRandom ()
-#else
-            m_rangeUniformRandom.GetValue ()
-#endif
-            ;
-      
+          uint32_t waitDelay = GET_RANDOM (m_rangeUniformRandom);      
           _LOG_DEBUG ("Digest is not in the log. Schedule processing after small delay: " << waitDelay << "ms");
-          m_scheduler.schedule (TIME_MILLISECONDS (waitDelay) /*from 20 to 100ms*/,
+
+          m_scheduler.schedule (TIME_MILLISECONDS (waitDelay),
                                 bind (&SyncLogic::processSyncInterest, this, digest, interestName, true),
                                 DELAYED_INTEREST_PROCESSING);
         }
@@ -245,7 +254,8 @@
 
       if (m_outstandingInterest == interestName)
         {
-          m_scheduler.schedule (TIME_SECONDS (0),
+          m_scheduler.cancel (REEXPRESSING_INTEREST);
+          m_scheduler.schedule (TIME_SECONDS_WITH_JITTER (0),
                                 bind (&SyncLogic::sendSyncInterest, this),
                                 REEXPRESSING_INTEREST);
         }
@@ -340,7 +350,8 @@
   // if state has changed, then it is safe to express a new interest
   if (diffLog->getLeaves ().size () > 0)
     {
-      m_scheduler.schedule (TIME_SECONDS (0),
+      m_scheduler.cancel (REEXPRESSING_INTEREST);
+      m_scheduler.schedule (TIME_SECONDS_WITH_JITTER (0),
                             bind (&SyncLogic::sendSyncInterest, this),
                             REEXPRESSING_INTEREST);
     }
@@ -349,8 +360,7 @@
       // should not reexpress the same interest. Need at least wait for data lifetime
       // Otherwise we will get immediate reply from the local daemon and there will be 100% utilization
       m_scheduler.cancel (REEXPRESSING_INTEREST);
-      // m_scheduler.schedule (posix_time::seconds (0),
-      m_scheduler.schedule (TIME_MILLISECONDS (m_syncResponseFreshness) + TIME_MILLISECONDS (1),
+      m_scheduler.schedule (TIME_MILLISECONDS_WITH_JITTER (m_syncResponseFreshness),
                             bind (&SyncLogic::sendSyncInterest, this),
                             REEXPRESSING_INTEREST);
     }
@@ -382,7 +392,8 @@
         {
           _LOG_DEBUG ("Have satisfied our own interest. Scheduling interest reexpression");
           // we need to reexpress interest only if we satisfied our own interest
-          m_scheduler.schedule (TIME_SECONDS (0),
+          m_scheduler.cancel (REEXPRESSING_INTEREST);
+          m_scheduler.schedule (TIME_SECONDS_WITH_JITTER (0),
                                 bind (&SyncLogic::sendSyncInterest, this),
                                 REEXPRESSING_INTEREST);
         }
@@ -465,7 +476,7 @@
                               bind (&SyncLogic::processSyncData, this, _1, _2));
 
   m_scheduler.cancel (REEXPRESSING_INTEREST);
-  m_scheduler.schedule (TIME_SECONDS (m_syncInterestReexpress),
+  m_scheduler.schedule (TIME_SECONDS_WITH_JITTER (m_syncInterestReexpress),
                         bind (&SyncLogic::sendSyncInterest, this),
                         REEXPRESSING_INTEREST);
 }
diff --git a/waf-tools/ns3.py b/waf-tools/ns3.py
index 04a6e9b..8a1f33f 100644
--- a/waf-tools/ns3.py
+++ b/waf-tools/ns3.py
@@ -20,8 +20,13 @@
 def _check_dependencies(conf, required, mandatory):
     # Logs.pprint ('CYAN', '  + %s' % required)
     found = []
+    
+    libversion = "optimized"
+    if conf.options.ns3_debug:
+        libversion = "debug"
+    
     for module in required:
-        retval = conf.check_cfg(package = 'libns3-dev-%s-optimized' % module,
+        retval = conf.check_cfg(package = 'libns3-dev-%s-%s' % (module, libversion),
                                 args='--cflags --libs', mandatory=mandatory,
                                 msg="Checking for ns3-%s" % module,
                                 uselib_store='NS3_%s' % module.upper())
diff --git a/wscript b/wscript
index db7b242..ce56610 100644
--- a/wscript
+++ b/wscript
@@ -7,6 +7,7 @@
     opt.add_option('--no-debug',action='store_true',default=False,dest='no_debug',help='''Make an optimized build of the library (remove debugging code)''')
     opt.add_option('--log4cxx', action='store_true',default=False,dest='log4cxx',help='''Compile with log4cxx/native NS3 logging support''')
     opt.add_option('--ns3',     action='store_true',default=False,dest='ns3_enable',help='''Compile as NS-3 module''')
+    opt.add_option('--ns3-debug', action='store_true',default=False,dest='ns3_debug',help='''Link against debug NS3 libraries. Optimized version will be used otherwise''')
     opt.load('compiler_c')
     opt.load('compiler_cxx')
     opt.load('boost')
