Commit d1386da0 authored by Johnny Jazeix's avatar Johnny Jazeix

mingw have sscanf and not sscanf_s

parent 9c91f0ed
......@@ -50,7 +50,7 @@
#include "common.hpp"
#include "Tools.hpp"
#ifdef WIN32
#ifdef WIN32 && !defined (__MINGW32__)
#define sscanf sscanf_s
#endif
/* -- */
......
......@@ -61,7 +61,9 @@
#endif /* defined(HAVE_GETOPT_H) */
#else
#define sscanf sscanf_s /*avoid a warning in Windows by using the securized version of scanf*/
#if !defined (__MINGW32__)
#define sscanf sscanf_s
#endif
#include <core/getopt.h>
#endif
......
......@@ -57,7 +57,7 @@
/* -- */
using namespace std;
#ifdef WIN32
#ifdef WIN32 && !defined (__MINGW32__)
#define sscanf sscanf_s
#define sprintf sprintf_s
#endif
......
......@@ -61,11 +61,12 @@
#include "parser/PajeParser/ParserDefinitionPaje.hpp"
#include "parser/PajeParser/ParserEventPaje.hpp"
/* -- */
using namespace std;
#ifdef WIN32
#ifdef WIN32 && !defined (__MINGW32__)
#define sscanf sscanf_s
#endif
using namespace std;
ParserEventPaje::ParserEventPaje(ParserDefinitionPaje *defs) {
_Definitions = defs;
}
......
......@@ -68,12 +68,12 @@ Q_DECLARE_METATYPE(Name);
Q_DECLARE_METATYPE(Date);
Q_DECLARE_METATYPE(String);
using namespace std;
#ifdef WIN32 // remove a warning and use a safe function
#ifdef WIN32 && !defined (__MINGW32__)
#define sscanf sscanf_s
#endif
using namespace std;
mt_ParserEventPaje::mt_ParserEventPaje(ParserDefinitionPaje *defs) {
_Definitions = defs;
}
......
......@@ -48,7 +48,7 @@
#include "trace/values/Value.hpp"
#include "trace/values/Hex.hpp"
#ifdef WIN32
#ifdef WIN32 && !defined (__MINGW32__)
#define sscanf sscanf_s
#endif
......
......@@ -49,7 +49,7 @@
#include "trace/values/Value.hpp"
#include "trace/values/Integer.hpp"
#ifdef WIN32
#ifdef WIN32 && !defined (__MINGW32__)
#define sscanf sscanf_s
#endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment