X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=rts%2Feventlog%2FEventLog.c;h=ebfbb7b0e43bddeb107fd3c035a37319a891d67a;hb=c2beb20be49d8eff25404643f4e1adfac50a81f1;hp=ede1615139e03926895b55b622a113d12670c446;hpb=015d3d46b6de2f95386a515a7d166d996a0416db;p=ghc-hetmet.git diff --git a/rts/eventlog/EventLog.c b/rts/eventlog/EventLog.c index ede1615..ebfbb7b 100644 --- a/rts/eventlog/EventLog.c +++ b/rts/eventlog/EventLog.c @@ -288,6 +288,10 @@ initEventLogging(void) for (c = 0; c < n_caps; ++c) { postBlockMarker(&capEventBuf[c]); } + +#ifdef THREADED_RTS + initMutex(&eventBufMutex); +#endif } void @@ -448,9 +452,9 @@ void postCapMsg(Capability *cap, char *msg, va_list ap) postLogMsg(&capEventBuf[cap->no], EVENT_LOG_MSG, msg, ap); } -void postUserMsg(Capability *cap, char *msg) +void postUserMsg(Capability *cap, char *msg, va_list ap) { - postLogMsg(&capEventBuf[cap->no], EVENT_USER_MSG, msg, NULL); + postLogMsg(&capEventBuf[cap->no], EVENT_USER_MSG, msg, ap); } void closeBlockMarker (EventsBuf *ebuf)