Skip to content

Commit d009a02

Browse files
andrewchiGitHub Enterprise
authored andcommitted
Merge pull request #346 from network-intelligence/dev
hotfix: inlining functions to respect ODR
2 parents 9139040 + db478c4 commit d009a02

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libmerc/base64.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
#include <cstring>
1010
#include <stdexcept>
1111

12-
std::string hex_encode(const unsigned char *src, size_t len) {
12+
inline std::string hex_encode(const unsigned char *src, size_t len) {
1313
char hex_table[] =
1414
{
1515
'0', '1', '2', '3',
@@ -52,7 +52,7 @@ static const unsigned char base64url_table[65] =
5252
* @src: Data to be encoded
5353
* @len: Length of the data to be encoded
5454
*/
55-
std::string base64_encode(const unsigned char *src, size_t len, const unsigned char table[65]=base64_table)
55+
inline std::string base64_encode(const unsigned char *src, size_t len, const unsigned char table[65]=base64_table)
5656
{
5757
unsigned char *out, *pos;
5858
const unsigned char *end, *in;

0 commit comments

Comments
 (0)