You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
SePlatform.h is included by SeExprBuiltins.h, and installed with the other includes, but it does a few pretty bad things on the windows platform, such as:
# define snprintf sprintf_s
(which totally breaks snprintf if compiling with mingw for example)
A public library include should not do such things (we had a hard time figuring out what was happening).
There are two alternatives:
1- do not include SePlatform.h in SeExprBuiltins.h, do not install it, and make sure the SeExpr public includes work without it.
2- leave all the #defines out of SePlatform.h and define these in a private include (e.g. SePrivate.h)
The text was updated successfully, but these errors were encountered:
devernay
added a commit
to MrKepzie/openfx-io
that referenced
this issue
Oct 6, 2015
We can take a look at fixing this. One other option would be to not use sprintf directly and instead make a function sePrintf() that is defined in a cpp so none of the platform specific stuff gets exported. I.e. we should probably not be defining things to things that might conflict with real functions... So...
#define SeExprSprintf sprintf
kind of defines might be better. I'll admit I haven't tried to build seexpr on windows with mingw32
SePlatform.h is included by SeExprBuiltins.h, and installed with the other includes, but it does a few pretty bad things on the windows platform, such as:
(which totally breaks snprintf if compiling with mingw for example)
A public library include should not do such things (we had a hard time figuring out what was happening).
There are two alternatives:
1- do not include SePlatform.h in SeExprBuiltins.h, do not install it, and make sure the SeExpr public includes work without it.
2- leave all the #defines out of SePlatform.h and define these in a private include (e.g. SePrivate.h)
The text was updated successfully, but these errors were encountered: