Files at this revision

API Documentation at this revision

Comitter:
pclary
Date:
Sat Nov 03 19:08:56 2012 +0000
Parent:
3:1a33490e1990
Commit message:
Fixed GCC warning

Changed in this revision

CircularBuffer.h Show annotated file Show diff for this revision Revisions of this file
diff -r 1a33490e1990 -r 13b626890ad4 CircularBuffer.h
--- a/CircularBuffer.h	Mon Aug 06 06:13:11 2012 +0000
+++ b/CircularBuffer.h	Sat Nov 03 19:08:56 2012 +0000
@@ -77,7 +77,7 @@
  */
 template <typename T, int S>
 inline void CircularBuffer<T, S>::push(T value) {
-    headIndex = ++headIndex % S;
+    ++headIndex %= S;
     data[headIndex] = value;
 }