]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
test/filestore/test_idempotent.cc: prefer prefix ++operator for iterators
authorDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Mon, 18 Mar 2013 13:38:49 +0000 (14:38 +0100)
committerDanny Al-Gaaf <danny.al-gaaf@bisect.de>
Mon, 18 Mar 2013 13:38:49 +0000 (14:38 +0100)
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
src/test/filestore/test_idempotent.cc

index 9feba3f9f6a9f76031aa190e11af718318d8a137..6be706d97b6fcef013886fd024def6c2cb651a80 100644 (file)
@@ -38,7 +38,7 @@ typename T::iterator rand_choose(T &cont) {
   int index = rand() % cont.size();
   typename T::iterator retval = cont.begin();
 
-  for (; index > 0; --index) retval++;
+  for (; index > 0; --index) ++retval;
   return retval;
 }