From 471e59817e7b40656cab6db14b7116128b753e35 Mon Sep 17 00:00:00 2001 From: Karl Williamson Date: Sat, 24 Jul 2021 07:18:07 -0600 Subject: [PATCH] Storable: Save a '&' instr by casting to U8 --- dist/Storable/Storable.pm | 2 +- dist/Storable/Storable.xs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dist/Storable/Storable.pm b/dist/Storable/Storable.pm index 27c9cf54c345..c1c94f04c197 100644 --- a/dist/Storable/Storable.pm +++ b/dist/Storable/Storable.pm @@ -28,7 +28,7 @@ our @EXPORT_OK = qw( our ($canonical, $forgive_me); BEGIN { - our $VERSION = '3.23'; + our $VERSION = '3.24'; } our $recursion_limit; diff --git a/dist/Storable/Storable.xs b/dist/Storable/Storable.xs index 70dddf3f100c..30fd69fbece0 100644 --- a/dist/Storable/Storable.xs +++ b/dist/Storable/Storable.xs @@ -1247,7 +1247,7 @@ static const char byteorderstr_56[] = {BYTEORDER_BYTES_56, 0}; # define Sntohl(x) (x) # else static U32 Sntohl(U32 x) { - return ((x & 0xFF) << 24) + ((x * 0xFF00) << 8) + return (((U8) x) << 24) + ((x * 0xFF00) << 8) + ((x & 0xFF0000) >> 8) + ((x & 0xFF000000) >> 24); } # endif