[openssl-commits] [openssl] master update
Emilia Kasper
emilia at openssl.org
Thu May 12 16:48:14 UTC 2016
The branch master has been updated
via d82c27589b5f9e9128f1ae9fce89fadd03c1c229 (commit)
from 6302bbd21a79bd2ed59f214d6d042031384b4d12 (commit)
- Log -----------------------------------------------------------------
commit d82c27589b5f9e9128f1ae9fce89fadd03c1c229
Author: Emilia Kasper <emilia at openssl.org>
Date: Wed May 11 22:41:29 2016 +0200
Appease ubsan
ERR_LIB_USER has value 128, and shifting into the sign bit upsets the
shift sanitizer.
Reviewed-by: Rich Salz <rsalz at openssl.org>
-----------------------------------------------------------------------
Summary of changes:
include/openssl/err.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/openssl/err.h b/include/openssl/err.h
index e41fdc3..ce3283e 100644
--- a/include/openssl/err.h
+++ b/include/openssl/err.h
@@ -235,7 +235,7 @@ typedef struct err_state_st {
# define KDFerr(f,r) ERR_PUT_error(ERR_LIB_KDF,(f),(r),OPENSSL_FILE,OPENSSL_LINE)
# define ERR_PACK(l,f,r) \
- ( (((l) & 0x0FF) << 24L) | (((f) & 0xFFF) << 12L) | ((r) & 0xFFF) )
+ ( ((unsigned int)((l) & 0x0FF) << 24L) | (((f) & 0xFFF) << 12L) | ((r) & 0xFFF) )
# define ERR_GET_LIB(l) (int)((((unsigned long)l)>>24L)&0xffL)
# define ERR_GET_FUNC(l) (int)((((unsigned long)l)>>12L)&0xfffL)
# define ERR_GET_REASON(l) (int)((l)&0xfffL)
More information about the openssl-commits
mailing list