diff options
author | Kazuki Yamaguchi <k@rhe.jp> | 2023-06-07 03:46:43 +0900 |
---|---|---|
committer | Kazuki Yamaguchi <k@rhe.jp> | 2023-06-19 01:57:09 +0900 |
commit | af66b9b7203a22e6029872513c59a7284f381cf9 (patch) | |
tree | 1166589c210a8fe030973faeaeb80c816a85cccc | |
parent | 397ebbc62dafef02c9c47ea2d67fd31253f7b81b (diff) |
[ruby/openssl] 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.
https://github.com/ruby/openssl/commit/4b2ba7b022
-rw-r--r-- | ext/openssl/ossl_pkey.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/openssl/ossl_pkey.c b/ext/openssl/ossl_pkey.c index a5baa21820..9caeb5622a 100644 --- a/ext/openssl/ossl_pkey.c +++ b/ext/openssl/ossl_pkey.c @@ -276,9 +276,9 @@ struct pkey_blocking_generate_arg { EVP_PKEY_CTX *ctx; EVP_PKEY *pkey; int state; - int yield: 1; - int genparam: 1; - int interrupted: 1; + unsigned int yield: 1; + unsigned int genparam: 1; + unsigned int interrupted: 1; }; static VALUE |