Skip to content

Commit fe4a1e5

Browse files
committed
fix: C standard requires prototype (aws#805)
The latest compilers require all C functions to have a prototype to compile; adds the void prototype to those functions requiring this
1 parent 42f7af6 commit fe4a1e5

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

include/aws/cryptosdk/error.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ enum aws_cryptosdk_err {
6262
* Implicitly registers error strings for aws-c-common as well.
6363
*/
6464
AWS_CRYPTOSDK_API
65-
void aws_cryptosdk_load_error_strings();
65+
void aws_cryptosdk_load_error_strings(void);
6666

6767
#ifdef __cplusplus
6868
}

source/cipher.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -470,7 +470,7 @@ static int evp_gcm_encrypt_final(const struct aws_cryptosdk_alg_properties *prop
470470
return AWS_ERROR_SUCCESS;
471471
}
472472

473-
static inline void flush_openssl_errors() {
473+
static inline void flush_openssl_errors(void) {
474474
while (ERR_get_error() != 0) {
475475
}
476476
}

source/error.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,6 @@ static const struct aws_error_info error_info[] = {
3939
static const struct aws_error_info_list error_info_list = { .error_list = error_info,
4040
.count = sizeof(error_info) / sizeof(error_info[0]) };
4141

42-
void aws_cryptosdk_load_error_strings() {
42+
void aws_cryptosdk_load_error_strings(void) {
4343
aws_register_error_info(&error_info_list);
4444
}

0 commit comments

Comments
 (0)