(file) Return to MessageQueue.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / Common

Diff for /pegasus/src/Pegasus/Common/MessageQueue.cpp between version 1.14 and 1.15

version 1.14, 2001/12/20 02:20:07 version 1.15, 2001/12/27 21:20:53
Line 187 
Line 187 
        handleEnqueue();        handleEnqueue();
 } }
  
   
   Boolean MessageQueue::accept_async(Message *message) throw(IPCException)
   {
      if(! message)
         throw NullPointer();
      if(_async == false)
         return false;
   
      if (getenv("PEGASUS_TRACE"))
      {
         cout << "==~ accept() ~== " << getQueueName() << ": ";
         message->print(cout);
      }
   
   
      // in derived methods, evaluate the message here to determine
      // whether or not you can handle it.
   
       _mut.lock(pegasus_thread_self());
       if (_back)
       {
          _back->_next = message;
          message->_prev = _back;
          message->_next = 0;
          _back = message;
       }
       else
       {
          _front = message;
          _back = message;
          message->_prev = 0;
          message->_next = 0;
       }
       message->_owner = this;
       _count++;
       _workSemaphore.signal();
       _mut.unlock();
   
      return true;
   }
   
   
 Message* MessageQueue::dequeue() throw(IPCException) Message* MessageQueue::dequeue() throw(IPCException)
 { {
    _mut.lock(pegasus_thread_self());    _mut.lock(pegasus_thread_self());


Legend:
Removed from v.1.14  
changed lines
  Added in v.1.15

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2