mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-09-30 19:47:47 +03:00
Writes audit log in parallel mode
First version still missing the index among other things
This commit is contained in:
15
src/utils.cc
15
src/utils.cc
@@ -24,6 +24,13 @@
|
||||
#include <memory>
|
||||
#include <functional>
|
||||
|
||||
#if defined _MSC_VER
|
||||
#include <direct.h>
|
||||
#elif defined __GNUC__
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#endif
|
||||
|
||||
#include "modsecurity/modsecurity.h"
|
||||
|
||||
namespace ModSecurity {
|
||||
@@ -62,5 +69,13 @@ std::string ascTime(time_t *t) {
|
||||
}
|
||||
|
||||
|
||||
void createDir(std::string dir) {
|
||||
#if defined _MSC_VER
|
||||
_mkdir(dir.data());
|
||||
#elif defined __GNUC__
|
||||
mkdir(dir.data(), 0777);
|
||||
#endif
|
||||
}
|
||||
|
||||
} // namespace ModSecurity
|
||||
|
||||
|
Reference in New Issue
Block a user