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
1 changed files with 1 additions and 1 deletions
|
@ -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 a new issue