xcfw/src/xcfwpanic.cpp
author MattD <mattd@symbian.org>
Thu, 01 Apr 2010 14:50:19 +0100
changeset 48 0d4ac38889fc
parent 0 79c6a41cd166
permissions -rw-r--r--
Merged in kashif's, fdim's and my removal of abld.bat and .cproject files onto the fixed up version of Christian's head.

/*
* Copyright (c) 2002-2005 Nokia Corporation and/or its subsidiary(-ies).
* All rights reserved.
* This component and the accompanying materials are made available
* under the terms of "Eclipse Public License v1.0"
* which accompanies this distribution, and is available
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
*
* Initial Contributors:
* Nokia Corporation - initial contribution.
*
* Contributors:
*
* Description:  Implements XCFW panic handling.
*
*/



//  INCLUDES
#include "xcfwpanic.h"

// -----------------------------------------------------------------------------
// TXCFWPanic::CheckPanic
// Panic with given code if aOK == EFalse
// -----------------------------------------------------------------------------
//
void TXCFWPanic::CheckPanic( TBool aOK, TInt aReason )
    {
#ifdef __XCFW_MODULE_TEST
#pragma BullseyeCoverage off
#endif
    if ( !aOK )
        {
        _LIT( KPanicText, "XML Content Framework" );
        User::Panic( KPanicText, aReason );            
        }
#ifdef __XCFW_MODULE_TEST
#pragma BullseyeCoverage on
#endif
    }

// -----------------------------------------------------------------------------
// TXCFWPanic::CheckLeaveL
// Leave with given code if aOK == EFalse
// -----------------------------------------------------------------------------
//
void TXCFWPanic::CheckLeaveL( TBool aOK, TInt aReason )
    {
#ifdef __XCFW_MODULE_TEST
#pragma BullseyeCoverage off
#endif
    if ( !aOK )
        {
        User::Leave( aReason );
        }
#ifdef __XCFW_MODULE_TEST
#pragma BullseyeCoverage on
#endif
    }


// End of file