Fixed unused variable.
[bpdyndnsd] / src / updater.cpp
index 58648f6..2922cb7 100644 (file)
@@ -251,10 +251,9 @@ void Updater::update_services(bool changed_to_online) const
         if ( last_updates.size() > 0 )
         {
             bool ip_burnt = true;
-            string ip_next_to_last_update;
             int max_equal_updates_in_succession = service->get_max_equal_updates_in_succession();
             int i = 0;
-            for ( std::map<time_t,std::string>::reverse_iterator r_iter; (r_iter != last_updates.rend()) && (i < max_equal_updates_in_succession); r_iter++ )
+            for ( std::map<time_t,std::string>::reverse_iterator r_iter = last_updates.rbegin(); (r_iter != last_updates.rend()) && (i < max_equal_updates_in_succession); r_iter++ )
             {
                 if ( i == 0 )
                     lastupdated = r_iter->first;