git.stg.codes
/
stg.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge remote-tracking branch 'origin/ticket42' into stg-2.409
[stg.git]
/
projects
/
stargazer
/
eventloop.cpp
diff --git
a/projects/stargazer/eventloop.cpp
b/projects/stargazer/eventloop.cpp
index dd17de9b07a3c9ee6f488817b38fc9dcc8925adb..36a77e9e21929c26e19e3ad9ecea86559eed0a1e 100644
(file)
--- a/
projects/stargazer/eventloop.cpp
+++ b/
projects/stargazer/eventloop.cpp
@@
-1,3
+1,4
@@
+#include <csignal>
#include <cerrno>
#include <cstring>
#include <cerrno>
#include <cstring>
@@
-53,12
+54,16
@@
return NULL;
void EVENT_LOOP::Runner()
{
void EVENT_LOOP::Runner()
{
+sigset_t signalSet;
+sigfillset(&signalSet);
+pthread_sigmask(SIG_BLOCK, &signalSet, NULL);
+
_stopped = false;
printfd(__FILE__, "EVENT_LOOP::Runner - Before start\n");
while (_running)
{
{
_stopped = false;
printfd(__FILE__, "EVENT_LOOP::Runner - Before start\n");
while (_running)
{
{
- STG_LOCKER lock(&_mutex
, __FILE__, __LINE__
);
+ STG_LOCKER lock(&_mutex);
// Check for any actions...
if (empty())
{
// Check for any actions...
if (empty())
{
@@
-96,7
+101,7
@@
EVENT_LOOP & EVENT_LOOP_SINGLETON::GetInstance()
// Double-checking technique
if (!_instance)
{
// Double-checking technique
if (!_instance)
{
- STG_LOCKER lock(&singletonMutex
, __FILE__, __LINE__
);
+ STG_LOCKER lock(&singletonMutex);
if (!_instance)
{
CreateInstance();
if (!_instance)
{
CreateInstance();