mirror of
https://github.com/openssl/openssl.git
synced 2024-11-21 01:15:20 +08:00
Appease ubsan
ERR_LIB_USER has value 128, and shifting into the sign bit upsets the shift sanitizer. Reviewed-by: Rich Salz <rsalz@openssl.org>
This commit is contained in:
parent
6302bbd21a
commit
d82c27589b
@ -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)
|
||||
|
Loading…
Reference in New Issue
Block a user