diff --git a/plugins/GSdx/boost_spsc_queue.hpp b/plugins/GSdx/boost_spsc_queue.hpp index cd595e95d9..eb8158598c 100644 --- a/plugins/GSdx/boost_spsc_queue.hpp +++ b/plugins/GSdx/boost_spsc_queue.hpp @@ -91,11 +91,12 @@ public: { size_t ret = arg + 1; #if 0 + // Initial boost code while (unlikely(ret >= max_size)) -#else - while (ret >= max_size) -#endif ret -= max_size; +#else + ret %= max_size; +#endif return ret; }