|
reSIProcate/DialogUsageManager
9680
|
00001 #include "resip/dum/DumThread.hxx" 00002 #include "resip/dum/DialogUsageManager.hxx" 00003 #include "rutil/Logger.hxx" 00004 00005 #define RESIPROCATE_SUBSYSTEM Subsystem::DUM 00006 00007 using namespace resip; 00008 00009 DumThread::DumThread(DialogUsageManager& dum) 00010 : mDum(dum) 00011 { 00012 } 00013 00014 void 00015 DumThread::thread() 00016 { 00017 while (!isShutdown()) 00018 { 00019 try 00020 { 00021 std::auto_ptr<Message> msg(mDum.mFifo.getNext(1000)); // Only need to wake up to see if we are shutdown 00022 if (msg.get()) 00023 { 00024 mDum.internalProcess(msg); 00025 } 00026 } 00027 catch (BaseException& e) 00028 { 00029 WarningLog (<< "Unhandled exception: " << e); 00030 } 00031 } 00032 } 00033 00034 /* ==================================================================== 00035 * The Vovida Software License, Version 1.0 00036 * 00037 * Copyright (c) 2000 Vovida Networks, Inc. All rights reserved. 00038 * 00039 * Redistribution and use in source and binary forms, with or without 00040 * modification, are permitted provided that the following conditions 00041 * are met: 00042 * 00043 * 1. Redistributions of source code must retain the above copyright 00044 * notice, this list of conditions and the following disclaimer. 00045 * 00046 * 2. Redistributions in binary form must reproduce the above copyright 00047 * notice, this list of conditions and the following disclaimer in 00048 * the documentation and/or other materials provided with the 00049 * distribution. 00050 * 00051 * 3. The names "VOCAL", "Vovida Open Communication Application Library", 00052 * and "Vovida Open Communication Application Library (VOCAL)" must 00053 * not be used to endorse or promote products derived from this 00054 * software without prior written permission. For written 00055 * permission, please contact vocal@vovida.org. 00056 * 00057 * 4. Products derived from this software may not be called "VOCAL", nor 00058 * may "VOCAL" appear in their name, without prior written 00059 * permission of Vovida Networks, Inc. 00060 * 00061 * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED 00062 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 00063 * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE AND 00064 * NON-INFRINGEMENT ARE DISCLAIMED. IN NO EVENT SHALL VOVIDA 00065 * NETWORKS, INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT DAMAGES 00066 * IN EXCESS OF $1,000, NOR FOR ANY INDIRECT, INCIDENTAL, SPECIAL, 00067 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 00068 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 00069 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY 00070 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 00071 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE 00072 * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH 00073 * DAMAGE. 00074 * 00075 * ==================================================================== 00076 * 00077 * This software consists of voluntary contributions made by Vovida 00078 * Networks, Inc. and many individuals on behalf of Vovida Networks, 00079 * Inc. For more information on Vovida Networks, Inc., please see 00080 * <http://www.vovida.org/>. 00081 * 00082 */
1.7.5.1