Skip to content

Commit 56e4a31

Browse files
committed
Fix conflicting declaration of basename function
error: conflicting declaration of ‘const char* basename(const char*)’ with ‘C’ linkage
1 parent 0b6a999 commit 56e4a31

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/bncsutil/checkrevision.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@ MEXP(int) extractMPQNumber(const char* mpqName)
124124
return mpqNum;
125125
}
126126

127+
#if !__GNUC__
127128
const char* basename(const char* file_name)
128129
{
129130
const char* base;
@@ -135,6 +136,7 @@ const char* basename(const char* file_name)
135136

136137
return ++base;
137138
}
139+
#endif
138140

139141
MEXP(int) checkRevision(const char* formula, const char* files[], int numFiles,
140142
int mpqNumber, unsigned long* checksum)

0 commit comments

Comments
 (0)