sysstatemgmt/systemstatemgr/ss/src/fireandforget.cpp
changeset 76 cb32bcc88bad
parent 0 4e1aa6a622a0
equal deleted inserted replaced
73:d38941471f1c 76:cb32bcc88bad
     1 // Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
     1 // Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     3 // This component and the accompanying materials are made available
     4 // under the terms of "Eclipse Public License v1.0"
     4 // under the terms of "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
    15 
    15 
    16 #include "fireandforget.h"
    16 #include "fireandforget.h"
    17 #include "timeoutwaiter.h"
    17 #include "timeoutwaiter.h"
    18 #include "ssmdebug.h"
    18 #include "ssmdebug.h"
    19 
    19 
       
    20 #include <f32file.h>
       
    21 
    20 _LIT(KApStartDLL, "apstart.dll");
    22 _LIT(KApStartDLL, "apstart.dll");
    21 _LIT( KSysMonProxyDLL, "loadsysmon.dll" );
    23 _LIT( KSysMonProxyDLL, "loadsysmon.dll" );
    22 typedef CApaStarter* (*TFuncNewL)( void );
    24 typedef CApaStarter* (*TFuncNewL)( void );
    23 typedef MSsmLoadSysMon* (*TFuncCreateL)( void );
    25 typedef MSsmLoadSysMon* (*TFuncCreateL)( void );
    24 
    26 
    73 		// This is done only when trying to start an already running server(process), as when we try to start an application 
    75 		// This is done only when trying to start an already running server(process), as when we try to start an application 
    74 		// which is already running, it doesn't return KErrAlreadyExists.  It would be started as another instance of same application.
    76 		// which is already running, it doesn't return KErrAlreadyExists.  It would be started as another instance of same application.
    75 		TFullName searchTerm(iStartupProperties->FileName());
    77 		TFullName searchTerm(iStartupProperties->FileName());
    76 		_LIT(KSearchAny, "*");
    78 		_LIT(KSearchAny, "*");
    77 		searchTerm += KSearchAny;
    79 		searchTerm += KSearchAny;
    78  	    TFindProcess find(searchTerm);
    80  	    TFindProcess find(TParsePtrC(searchTerm).NameAndExt());
    79 		TFullName name;
    81 		TFullName name;
    80 		err = find.Next(name);
    82 		err = find.Next(name);
    81 		if(err == KErrNone)
    83 		if(err == KErrNone)
    82 			{
    84 			{
    83 			err = iProcess.Open(find);
    85 			err = iProcess.Open(find);