X-Git-Url: https://git.pterodactylus.net/?p=fms.git;a=blobdiff_plain;f=src%2Ffreenet%2Fintroductionpuzzleinserter.cpp;fp=src%2Ffreenet%2Fintroductionpuzzleinserter.cpp;h=6904186b8fb87179cb8971f082333ce29bd10ebc;hp=b185b9d4a90f6b48a7126ebf574c7e347a698f02;hb=fcb124f8d6d3f5678e82049fb8e5e23c8cfaec6d;hpb=a558b16c8034966d14e1d63db44dcb952d849618 diff --git a/src/freenet/introductionpuzzleinserter.cpp b/src/freenet/introductionpuzzleinserter.cpp index b185b9d..6904186 100644 --- a/src/freenet/introductionpuzzleinserter.cpp +++ b/src/freenet/introductionpuzzleinserter.cpp @@ -52,7 +52,8 @@ void IntroductionPuzzleInserter::CheckForNeededInsert() // identity doesn't have any non-solved puzzles for today - start a new insert if(rs2.Empty()==true) { - if(m_lastinserted.find(rs.GetInt(0))==m_lastinserted.end() || m_lastinserted[rs.GetInt(0)]<=lastinsert) + // make sure we are on the next day or the appropriate amount of time has elapsed since the last insert + if(m_lastinserted.find(rs.GetInt(0))==m_lastinserted.end() || m_lastinserted[rs.GetInt(0)]<=lastinsert || m_lastinserted[rs.GetInt(0)].day()!=now.day()) { StartInsert(rs.GetInt(0)); m_lastinserted[rs.GetInt(0)]=now;