mmserv/sts/stsserver/src/stsserverexe.cpp
branchRCL_3
changeset 20 0ac9a5310753
parent 19 095bea5f582e
child 21 999b2818a0eb
equal deleted inserted replaced
19:095bea5f582e 20:0ac9a5310753
     1 /*
       
     2  * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
       
     3  * All rights reserved.
       
     4  * This component and the accompanying materials are made available
       
     5  * under the terms of "Eclipse Public License v1.0"
       
     6  * which accompanies this distribution, and is available
       
     7  * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8  *
       
     9  * Initial Contributors:
       
    10  * Nokia Corporation - initial contribution.
       
    11  *
       
    12  * Contributors:
       
    13  *
       
    14  * Description:
       
    15  * The file containt the main method of the STS Server.
       
    16  */
       
    17 
       
    18 //  Include Files  
       
    19 #include <ecom/ecom.h>
       
    20 #include "stsserver.h"
       
    21 
       
    22 TInt E32Main()
       
    23     {
       
    24     __UHEAP_MARK;
       
    25     TInt returnValue = KErrNoMemory;
       
    26 
       
    27     RThread myThread;
       
    28     myThread.SetPriority(EPriorityAbsoluteRealTime1);
       
    29     myThread.Close();
       
    30 
       
    31     CTrapCleanup* cleanup = CTrapCleanup::New();
       
    32 
       
    33     if (cleanup)
       
    34         {
       
    35         // Run the server and request a process rendezvous.
       
    36         TRAP( returnValue, CStsServer::RunServerL() );
       
    37         delete cleanup;
       
    38         }
       
    39     REComSession::FinalClose();
       
    40     __UHEAP_MARKEND;
       
    41 
       
    42     return returnValue;
       
    43     } // end E32Main