Changeset 10919 for trunk/FACT++/src
- Timestamp:
- 06/07/11 22:14:11 (13 years ago)
- Location:
- trunk/FACT++/src
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/MessageDim.cc
r10570 r10919 1 1 #include "MessageDim.h" 2 3 #include <mutex> 2 4 3 5 #include "tools.h" … … 66 68 int MessageDimTX::Write(const Time &t, const string &txt, int qos) 67 69 { 70 static mutex mtx; 71 72 mtx.lock(); 73 68 74 MessageImp::Write(t, txt, qos); 69 75 … … 77 83 Out() << " !! " << t.GetAsStr() << " - Sending failed!" << endl; 78 84 85 mtx.unlock(); 86 79 87 return rc; 80 88 } 81 82 83 89 84 90 // ************************************************************************** -
trunk/FACT++/src/MessageImp.cc
r10508 r10919 13 13 14 14 #include <stdarg.h> 15 16 #include <mutex> 15 17 16 18 #include "tools.h" … … 105 107 int MessageImp::Write(const Time &time, const string &txt, int severity) 106 108 { 109 static mutex mtx; 110 111 mtx.lock(); 112 107 113 switch (severity) 108 114 { … … 116 122 } 117 123 fOut << time.GetAsStr() << " - " << txt << endl; 124 125 mtx.unlock(); 118 126 119 127 return 0;
Note:
See TracChangeset
for help on using the changeset viewer.