Skip to content

Commit

Permalink
fix: add function prototypes
Browse files Browse the repository at this point in the history
  • Loading branch information
e-kwsm committed Nov 9, 2023
1 parent 0e0b831 commit 28ff733
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions src/context.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ struct _msym_context {
* Public API
***********************/

msym_context msymCreateContext(){
msym_context msymCreateContext(void){
msym_context ctx = malloc(sizeof(struct _msym_context));
msym_thresholds_t *threshols = malloc(sizeof(msym_thresholds_t));

Expand All @@ -90,7 +90,7 @@ msym_context msymCreateContext(){
return NULL;
}

const msym_thresholds_t *msymGetDefaultThresholds(){
const msym_thresholds_t *msymGetDefaultThresholds(void){
return &default_thresholds;
}

Expand Down
4 changes: 2 additions & 2 deletions src/msym.h
Original file line number Diff line number Diff line change
Expand Up @@ -162,10 +162,10 @@ extern "C" {
} msym_character_table_t;


msym_context MSYM_EXPORT msymCreateContext();
msym_context MSYM_EXPORT msymCreateContext(void);
msym_error_t MSYM_EXPORT msymReleaseContext(msym_context ctx);

const msym_thresholds_t MSYM_EXPORT *msymGetDefaultThresholds();
const msym_thresholds_t MSYM_EXPORT *msymGetDefaultThresholds(void);
msym_error_t MSYM_EXPORT msymSetThresholds(msym_context ctx, const msym_thresholds_t *thresholds);
msym_error_t MSYM_EXPORT msymGetThresholds(msym_context ctx, const msym_thresholds_t **thresholds);
msym_error_t MSYM_EXPORT msymSetElements(msym_context ctx, int length, msym_element_t *elements);
Expand Down
2 changes: 1 addition & 1 deletion src/msym_error.c
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ void msymSetErrorDetails(const char *format, ...){
va_end(args);
}

const char MSYM_EXPORT *msymGetErrorDetails(){
const char MSYM_EXPORT *msymGetErrorDetails(void){
snprintf(err_details_ext, sizeof(err_details_ext), "%s",err_details); // Not really necessary
msymSetErrorDetails("");
return err_details_ext;
Expand Down
2 changes: 1 addition & 1 deletion src/msym_error.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ extern "C" {

const char *msymErrorString(msym_error_t error);
void msymSetErrorDetails(const char *format, ...);
const char *msymGetErrorDetails();
const char *msymGetErrorDetails(void);


#ifdef __cplusplus
Expand Down

0 comments on commit 28ff733

Please sign in to comment.