aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/utils/loadstor.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/utils/loadstor.h')
-rw-r--r--src/lib/utils/loadstor.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/utils/loadstor.h b/src/lib/utils/loadstor.h
index a6c2b7969..9ae9fda0e 100644
--- a/src/lib/utils/loadstor.h
+++ b/src/lib/utils/loadstor.h
@@ -47,7 +47,7 @@ namespace Botan {
template<typename T> inline byte get_byte(size_t byte_num, T input)
{
return static_cast<byte>(
- input >> ((sizeof(T)-1-(byte_num&(sizeof(T)-1))) << 3)
+ input >> (((~byte_num)&(sizeof(T)-1)) << 3)
);
}