Skip to content

Commit

Permalink
Merge pull request #13 from BSzili/master
Browse files Browse the repository at this point in the history
Add the missing extern "C" to some headers
  • Loading branch information
jonof authored Jan 7, 2021
2 parents ed8c505 + 0396d9f commit 824fdc2
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 0 deletions.
8 changes: 8 additions & 0 deletions include/mmulti.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
#ifndef __mmulti_h__
#define __mmulti_h__

#ifdef __cplusplus
extern "C" {
#endif

#define MAXMULTIPLAYERS 16

#define MMULTI_MODE_MS 0
Expand All @@ -28,5 +32,9 @@ int getpacket(int *other, unsigned char *bufptr);
void flushpackets(void);
void genericmultifunction(int other, unsigned char *bufptr, int messleng, int command);

#ifdef __cplusplus
}
#endif

#endif // __mmulti_h__

8 changes: 8 additions & 0 deletions include/osd.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ typedef struct {
#define OSDCMD_OK 0
#define OSDCMD_SHOWHELP 1

#ifdef __cplusplus
extern "C" {
#endif

// initializes things
void OSD_Init(void);

Expand Down Expand Up @@ -77,5 +81,9 @@ int OSD_Dispatch(const char *cmd);
// func = the entry point to the function
int OSD_RegisterFunction(const char *name, const char *help, int (*func)(const osdfuncparm_t*));

#ifdef __cplusplus
}
#endif

#endif // __osd_h__

13 changes: 13 additions & 0 deletions include/scriptfile.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
#ifndef __scriptfile_h__
#define __scriptfile_h__

#ifdef __cplusplus
extern "C" {
#endif

typedef struct {
char *textbuf;
unsigned int textlength;
Expand Down Expand Up @@ -27,3 +34,9 @@ int scriptfile_eof(scriptfile *sf);
int scriptfile_getsymbolvalue(const char *name, int *val);
int scriptfile_addsymbolvalue(const char *name, int val);
void scriptfile_clearsymbols(void);

#ifdef __cplusplus
}
#endif

#endif // __scriptfile_h__
8 changes: 8 additions & 0 deletions include/winlayer.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@
#ifndef __build_interface_layer__
#define __build_interface_layer__ WIN

#ifdef __cplusplus
extern "C" {
#endif

extern int backgroundidle; // set to 1 to tell winlayer to go to idle priority when inactive
extern unsigned maxrefreshfreq;

Expand All @@ -16,6 +20,10 @@ intptr_t win_gethinstance(void);
void win_allowtaskswitching(int onf);
int win_checkinstance(void);

#ifdef __cplusplus
}
#endif

#include "baselayer.h"

#else
Expand Down

0 comments on commit 824fdc2

Please sign in to comment.