diff --git a/crypto/Makefile b/crypto/Makefile index ca5d034b5..b6dbeeedb 100644 --- a/crypto/Makefile +++ b/crypto/Makefile @@ -7,9 +7,6 @@ ifneq ($(CLANG_VERSION),) $(if $(shell [ $(CLANG_VERSION_MAJOR) -ge 13 ] && echo "OK"), \ $(eval CLANG_AT_LEAST_13 := true), \ $(eval CLANG_AT_LEAST_13 := false)) -$(if $(shell [ $(CLANG_VERSION_MAJOR) -ge 15 ] && echo "OK"), \ - $(eval CLANG_AT_LEAST_15 := true), \ - $(eval CLANG_AT_LEAST_15 := false)) endif ifeq ($(FUZZER),1) @@ -73,12 +70,6 @@ ZKP_PATH = ../vendor/secp256k1-zkp # this is specific for 64-bit builds CFLAGS += -DSECP256K1_CONTEXT_SIZE=208 -# TODO remove this workaround once possible -ifeq ($(CLANG_AT_LEAST_15),true) -$(warning "warning: suppressing clang-15 `-Wstrict-prototypes` compiler warning for `zkp_context.c` as workaround") -zkp_context.o: CFLAGS += -Wno-strict-prototypes -endif - VALGRIND ?= 1 ifeq ($(VALGRIND),1) CFLAGS += -DVALGRIND diff --git a/crypto/zkp_context.c b/crypto/zkp_context.c index 6416b7868..964140f06 100644 --- a/crypto/zkp_context.c +++ b/crypto/zkp_context.c @@ -51,7 +51,7 @@ int secp256k1_context_writable_randomize(secp256k1_context *context_writable) { bool zkp_context_is_initialized(void) { return context != NULL; } // returns 0 on success -int zkp_context_init() { +int zkp_context_init(void) { assert(context == NULL); const unsigned int context_flags = @@ -78,7 +78,7 @@ int zkp_context_init() { return 0; } -void zkp_context_destroy() { +void zkp_context_destroy(void) { assert(context != NULL); secp256k1_context_preallocated_destroy(context); @@ -87,14 +87,14 @@ void zkp_context_destroy() { context = NULL; } -const secp256k1_context *zkp_context_get_read_only() { +const secp256k1_context *zkp_context_get_read_only(void) { assert(context != NULL); return context; } // returns NULL if context cannot be acquired -secp256k1_context *zkp_context_acquire_writable() { +secp256k1_context *zkp_context_acquire_writable(void) { assert(context != NULL); // We don't expect the context to be used by multiple threads @@ -105,7 +105,7 @@ secp256k1_context *zkp_context_acquire_writable() { return context; } -void zkp_context_release_writable() { +void zkp_context_release_writable(void) { assert(context != NULL); atomic_flag_clear(&locked);