Added locking in  HttpEvent::attachAndSendAnswer