refactor: remove ret from secp256k1_ec_pubkey_serialize

This commit is contained in:
kevkevinpal
2025-12-09 16:08:35 -05:00
parent e7f7083b53
commit 3daab83a60

View File

@@ -268,7 +268,6 @@ int secp256k1_ec_pubkey_parse(const secp256k1_context* ctx, secp256k1_pubkey* pu
int secp256k1_ec_pubkey_serialize(const secp256k1_context* ctx, unsigned char *output, size_t *outputlen, const secp256k1_pubkey* pubkey, unsigned int flags) {
secp256k1_ge Q;
size_t len;
int ret = 0;
VERIFY_CHECK(ctx != NULL);
ARG_CHECK(outputlen != NULL);
@@ -287,9 +286,9 @@ int secp256k1_ec_pubkey_serialize(const secp256k1_context* ctx, unsigned char *o
secp256k1_eckey_pubkey_serialize65(&Q, output);
*outputlen = 65;
}
ret = 1;
return 1;
}
return ret;
return 0;
}
int secp256k1_ec_pubkey_cmp(const secp256k1_context* ctx, const secp256k1_pubkey* pubkey0, const secp256k1_pubkey* pubkey1) {