Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Aug 18, 2010, 12:08:05 AM (14 years ago)
Author:
rgrieder
Message:

Only catch exceptions you actually expect. And rethrow unknown exceptions ("…" can also catch internal Microsoft exceptions like floating point exception).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/src/libraries/core/input/InputDevice.h

    r6746 r7174  
    4040#include <vector>
    4141#include <ois/OISInputManager.h>
     42#include <ois/OISException.h>
    4243
    4344#include "util/Clock.h"
     
    144145                oisInputManager_->destroyInputObject(oisDevice_);
    145146            }
    146             catch (...)
     147            catch (const OIS::Exception& ex)
    147148            {
    148                 COUT(1) << this->getClassName() << " destruction failed: " << Exception::handleMessage() << std::endl
     149                COUT(1) << this->getClassName() << " destruction failed: " << ex.eText << std::endl
    149150                        << "    Potential resource leak!" << std::endl;
    150151            }
Note: See TracChangeset for help on using the changeset viewer.