Skip to content

Commit

Permalink
cpl_spawn.cpp: fix linking with FreeBSD (found with CheriBSD)
Browse files Browse the repository at this point in the history
  • Loading branch information
rouault committed Jun 12, 2022
1 parent 2bd16c4 commit 4ff30d5
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion port/cpl_spawn.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,11 @@
#include <crt_externs.h>
#define environ (*_NSGetEnviron())
#else
extern char** environ;
#if defined(__FreeBSD__)
extern __attribute__((__weak__)) char **environ;
#else
extern char** environ;
#endif
#endif
#endif
#endif
Expand Down

0 comments on commit 4ff30d5

Please sign in to comment.