2 Aesalon, a tool to visualize a program's behaviour at run-time.
3 Copyright (C) 2010, Aesalon Development Team.
5 Aesalon is distributed under the terms of the GNU GPLv3. For more
6 licensing information, see the file LICENSE included with the distribution.
8 @file monitor/src/vcommunication/LogSink.cpp
15 #include "vcommunication/LogSink.h"
17 #include "Coordinator.h"
18 #include "common/PathSanitizer.h"
21 namespace VCommunication
{
24 std::string filename
= Common::PathSanitizer::sanitize(Coordinator::instance()->vault()->get("logFile"));
30 m_fd
= open(filename
.c_str(), O_RDWR
);
32 sem_init(&m_logLock
, 0, 1);
38 sem_destroy(&m_logLock
);
43 void LogSink::sinkPacket(Packet
*packet
) {
44 if(m_fd
== -1) return;
53 } // namespace VCommunication
54 } // namespace Monitor