Browse Source

const GetSize()

openssl
orignal 3 days ago
parent
commit
09ae278306
  1. 4
      libi2pd/Queue.h

4
libi2pd/Queue.h

@ -84,7 +84,7 @@ namespace util
return m_Queue.empty (); return m_Queue.empty ();
} }
int GetSize () int GetSize () const
{ {
std::unique_lock<std::mutex> l(m_QueueMutex); std::unique_lock<std::mutex> l(m_QueueMutex);
return m_Queue.size (); return m_Queue.size ();
@ -134,7 +134,7 @@ namespace util
private: private:
std::list<Element> m_Queue; std::list<Element> m_Queue;
std::mutex m_QueueMutex; mutable std::mutex m_QueueMutex;
std::condition_variable m_NonEmpty; std::condition_variable m_NonEmpty;
}; };
} }

Loading…
Cancel
Save