const GetSize()

This commit is contained in:
orignal 2024-11-20 13:27:25 -05:00
parent d241e5d5cb
commit 09ae278306

View file

@ -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;
}; };
} }