Skip to content
This repository was archived by the owner on Dec 26, 2022. It is now read-only.

Commit 60bb1ca

Browse files
committed
fix(utils): Add header guard
1 parent 53bb9e9 commit 60bb1ca

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

accelerator/apis.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ status_t api_find_transactions_by_tag(
9696
goto done;
9797
}
9898

99-
char *req_tag = (char*)malloc((NUM_TRYTES_TAG + 1) * sizeof(char));
99+
char* req_tag = (char*)malloc((NUM_TRYTES_TAG + 1) * sizeof(char));
100100
int obj_len = strlen(obj);
101101

102102
if (obj_len == NUM_TRYTES_TAG) {

utils/fill_nines.h

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,13 @@
1+
#ifndef UTILS_FILL_NINES_H_
2+
#define UTILS_FILL_NINES_H_
3+
14
#include "accelerator/errors.h"
25
#include "cclient/types/types.h"
36

7+
#ifdef __cplusplus
8+
extern "C" {
9+
#endif
10+
411
/**
512
* @brief Patch input string with nines into assigned length.
613
*
@@ -14,3 +21,8 @@
1421
*/
1522
status_t fill_nines(char* new_str, const char* const old_str,
1623
size_t new_str_len);
24+
#ifdef __cplusplus
25+
}
26+
#endif
27+
28+
#endif // UTILS_FILL_NINES_H_

0 commit comments

Comments
 (0)