Skip to content

Commit 4b2ba7b

Browse files
committed
pkey: use unsigned type for bit fields
clang generates a warning: ../../../../ext/openssl/ossl_pkey.c:326:22: error: implicit truncation from 'int' to a one-bit wide bit-field changes value from 1 to -1 [-Werror,-Wsingle-bit-bitfield-constant-conversion] arg->interrupted = 1; ^ ~ 1 error generated.
1 parent cdec3c7 commit 4b2ba7b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

ext/openssl/ossl_pkey.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -276,9 +276,9 @@ struct pkey_blocking_generate_arg {
276276
EVP_PKEY_CTX *ctx;
277277
EVP_PKEY *pkey;
278278
int state;
279-
int yield: 1;
280-
int genparam: 1;
281-
int interrupted: 1;
279+
unsigned int yield: 1;
280+
unsigned int genparam: 1;
281+
unsigned int interrupted: 1;
282282
};
283283

284284
static VALUE

0 commit comments

Comments
 (0)