summaryrefslogtreecommitdiff
path: root/misc.h
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2019-05-25 07:02:32 -0400
committerJeffrey Walton <noloader@gmail.com>2019-05-25 07:02:32 -0400
commitf90c162b68a8878f0f633cad03f851f7110af431 (patch)
tree47a3b74b981a79540136e27bb86ec27097131351 /misc.h
parentfc10a7f1ea56b0c3c3ca7db8fa4de868cf3daad2 (diff)
downloadcryptopp-git-f90c162b68a8878f0f633cad03f851f7110af431.tar.gz
Fix IncrementCounterByOne
This was introduced earlier in the day when clearing a Valgrind finding. It tested good with the self tests. However, we double process byte[0] if there's a carry.
Diffstat (limited to 'misc.h')
-rw-r--r--misc.h3
1 files changed, 0 insertions, 3 deletions
diff --git a/misc.h b/misc.h
index 52ece09c..d836aaa2 100644
--- a/misc.h
+++ b/misc.h
@@ -1232,9 +1232,6 @@ inline void IncrementCounterByOne(byte *inout, unsigned int size)
carry = ! ++inout[size-1];
size--;
}
-
- if (carry && size == 0)
- inout[0]++;
}
/// \brief Performs an addition with carry on a block of bytes