--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/build.config.xml Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,190 @@
+<?xml version="1.0"?>
+<!DOCTYPE SystemDefinition SYSTEM "sysdef_1_4_0.dtd" [
+ <!ENTITY layer_real_source_path "sf/os/persistentdata" >
+]>
+
+<SystemDefinition name="persistentdata" schema="1.4.0">
+ <systemModel>
+ <layer name="os_layer">
+ <module name="featuremgmt">
+ <unit
+ name="featuremgr"
+ unitID="sos.featuremgr"
+ bldFile="&layer_real_source_path;/featuremgmt/featuremgr/group"
+ mrp="&layer_real_source_path;/featuremgmt/featuremgr/group/syslibs_featmgr.mrp"
+ />
+ <unit
+ name="featureregistry"
+ unitID="sos.featureregistry"
+ bldFile="&layer_real_source_path;/featuremgmt/featureregistry/group"
+ mrp="&layer_real_source_path;/featuremgmt/featureregistry/group/syslibs_featreg.mrp"
+ />
+ </module>
+
+ <module name="loggingservices">
+ <unit
+ name="eventlogger"
+ unitID="sos.eventlogger"
+ bldFile="&layer_real_source_path;/loggingservices/eventlogger/group"
+ mrp="&layer_real_source_path;/loggingservices/eventlogger/group/syslibs_logeng.mrp"
+ />
+ <unit
+ name="filelogger"
+ unitID="sos.filelogger"
+ bldFile="&layer_real_source_path;/loggingservices/filelogger/group"
+ mrp="&layer_real_source_path;/loggingservices/filelogger/group/comms-infras_flogger.mrp"
+ />
+ <unit
+ name="rfilelogger"
+ unitID="sos.rfilelogger"
+ bldFile="&layer_real_source_path;/loggingservices/rfilelogger/group"
+ mrp="&layer_real_source_path;/loggingservices/rfilelogger/group/testtools_utilities.mrp"
+ />
+ </module>
+
+ <module name="persistentstorage">
+ <unit
+ name="centralrepository"
+ unitID="sos.centralrepository"
+ bldFile="&layer_real_source_path;/persistentstorage/centralrepository/group"
+ mrp="&layer_real_source_path;/persistentstorage/centralrepository/group/syslibs_centralrepository.mrp"
+ />
+ <unit
+ name="dbms"
+ unitID="sos.dbms"
+ bldFile="&layer_real_source_path;/persistentstorage/dbms/group"
+ mrp="&layer_real_source_path;/persistentstorage/dbms/group/syslibs_dbms.mrp"
+ />
+ <unit
+ name="sql"
+ unitID="sos.sql"
+ bldFile="&layer_real_source_path;/persistentstorage/sql/group"
+ mrp="&layer_real_source_path;/persistentstorage/sql/group/syslibs_sql.mrp"
+ />
+ <unit
+ name="sqlite3api"
+ unitID="sos.sqlite3api"
+ bldFile="&layer_real_source_path;/persistentstorage/sqlite3api/group"
+ mrp="&layer_real_source_path;/persistentstorage/sqlite3api/group/syslibs_sqlite3.mrp"
+ />
+ <unit
+ name="store"
+ unitID="sos.store"
+ bldFile="&layer_real_source_path;/persistentstorage/store/group"
+ mrp="&layer_real_source_path;/persistentstorage/store/group/syslibs_store.mrp"
+ />
+ </module>
+
+ <module name="traceservices">
+ <unit
+ name="commsdebugutility"
+ unitID="sos.commsdebugutility"
+ bldFile="&layer_real_source_path;/traceservices/commsdebugutility/group"
+ mrp="&layer_real_source_path;/traceservices/commsdebugutility/group/comms-infras_commsdebugutility.mrp"
+ />
+ <unit
+ name="tracefw"
+ unitID="sos.tracefw"
+ bldFile="&layer_real_source_path;/traceservices/tracefw/group"
+ mrp="&layer_real_source_path;/traceservices/tracefw/ulogger/group/tools_debug_trace.mrp"
+ />
+ </module>
+ </layer>
+
+ <layer name="api_test_layer">
+ <module name="featuremgmt">
+ <unit
+ name="featuremgr"
+ unitID="sos.featuremgr.test"
+ bldFile="&layer_real_source_path;/featuremgmt/featuremgr/group"
+ mrp="&layer_real_source_path;/featuremgmt/featuremgr/group/syslibs_featmgr.mrp"
+ />
+ <unit
+ name="featureregistry"
+ unitID="sos.featureregistry.test"
+ bldFile="&layer_real_source_path;/featuremgmt/featureregistry/group"
+ mrp="&layer_real_source_path;/featuremgmt/featureregistry/group/syslibs_featreg.mrp"
+ />
+ </module>
+
+ <module name="loggingservices">
+ <unit
+ name="eventlogger"
+ unitID="sos.eventlogger.test"
+ bldFile="&layer_real_source_path;/loggingservices/eventlogger/group"
+ mrp="&layer_real_source_path;/loggingservices/eventlogger/group/syslibs_logeng.mrp"
+ />
+ <unit
+ name="filelogger"
+ unitID="sos.filelogger.test"
+ bldFile="&layer_real_source_path;/loggingservices/filelogger/group"
+ mrp="&layer_real_source_path;/loggingservices/filelogger/group/comms-infras_flogger.mrp"
+ />
+ <unit
+ name="rfilelogger"
+ unitID="sos.rfilelogger.test"
+ bldFile="&layer_real_source_path;/loggingservices/rfilelogger/group"
+ mrp="&layer_real_source_path;/loggingservices/rfilelogger/group/testtools_utilities.mrp"
+ />
+ </module>
+
+ <module name="persistentstorage">
+ <unit
+ name="centralrepository"
+ unitID="sos.centralrepository.test"
+ bldFile="&layer_real_source_path;/persistentstorage/centralrepository/group"
+ mrp="&layer_real_source_path;/persistentstorage/centralrepository/group/syslibs_centralrepository.mrp"
+ />
+ <unit
+ name="dbms"
+ unitID="sos.dbms.test"
+ bldFile="&layer_real_source_path;/persistentstorage/dbms/group"
+ mrp="&layer_real_source_path;/persistentstorage/dbms/group/syslibs_dbms.mrp"
+ />
+ <unit
+ name="sql"
+ unitID="sos.sql.test"
+ bldFile="&layer_real_source_path;/persistentstorage/sql/group"
+ mrp="&layer_real_source_path;/persistentstorage/sql/group/syslibs_sql.mrp"
+ />
+ <unit
+ name="sqlite3api"
+ unitID="sos.sqlite3api.test"
+ bldFile="&layer_real_source_path;/persistentstorage/sqlite3api/group"
+ mrp="&layer_real_source_path;/persistentstorage/sqlite3api/group/syslibs_sqlite3.mrp"
+ />
+ <unit
+ name="store"
+ unitID="sos.store.test"
+ bldFile="&layer_real_source_path;/persistentstorage/store/group"
+ mrp="&layer_real_source_path;/persistentstorage/store/group/syslibs_store.mrp"
+ />
+ </module>
+
+ <module name="traceservices">
+ <unit
+ name="commsdebugutility"
+ unitID="sos.commsdebugutility.test"
+ bldFile="&layer_real_source_path;/traceservices/commsdebugutility/group"
+ mrp="&layer_real_source_path;/traceservices/commsdebugutility/group/comms-infras_commsdebugutility.mrp"
+ />
+ <unit
+ name="tracefw"
+ unitID="sos.tracefw.test"
+ bldFile="&layer_real_source_path;/traceservices/tracefw/group"
+ mrp="&layer_real_source_path;/traceservices/tracefw/ulogger/group/tools_debug_trace.mrp"
+ />
+ </module>
+
+ <module name="burtestserver">
+ <unit
+ name="burtestserver"
+ unitID="sos.burtestserver.test"
+ bldFile="sf/os/buildtools/toolsandutils/burtestserver/Group"
+ mrp="sf/os/buildtools/toolsandutils/burtestserver/Group/testtools_burtestserver.mrp"
+ />
+ </module>
+ </layer>
+ </systemModel>
+</SystemDefinition>
+
Binary file featuremgmt/featuremgr/engineering/File Specification/FeatDB_XMLDataModel.EAP has changed
--- a/featuremgmt/featuremgr/engineering/File Specification/FeatDB_example.xml Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE featuredatabase SYSTEM "featuredatabase.dtd">
-<featuredatabase>
- <!-- Multiple featureset is possible and one featureset generate one set of oby and header files -->
- <featureset ibyname="feature.iby" hfilename="publicfeatureUID.h" namespace="NOemFeature">
- <!-- Following header info goes to generated .h file -->
- <hfileheader interfacestatus="@released" interfacevisibility="@publishedPartner">
- // publicfeatureUID.h
- //
- // Copyright (c) Symbian Software Ltd 2007. All rights reserved.
- //.......................................................................................
- </hfileheader>
- <!-- features an -->
- <feature uid="0x10279806" statusflags="0x0001" name="Fax" userdata="0x0001">
- <hrhmacro exclude="SYMBIAN_EXCLUDE_FAX"/>
- <comment>
- /**
- Feature = FAX, status = "Supported" this feature should go to SDK
- */
- </comment>
- </feature>
- <feature uid="0x10279808" statusflags="0x0001" name="Bluetooth" userdata="0x0001">
- <hrhmacro include="SYMBIAN_INCLUDE_INFRARED"/>
- <comment>
- /**
- Feature = FAX, status = "Supported" this feature should go to SDK
- */
- </comment>
- </feature>
- </featureset>
- <!-- DSR UID ranges allocated for features that default to reporting "feature supported" -->
- <defaultfeaturerange loweruid="0x10279806" higheruid="0x10281805">
- <comment>
- /**
- The UID ranges are allocated for features that default to reporting "feature supported"
- */
- </comment>
- </defaultfeaturerange>
-
-</featuredatabase>
--- a/featuremgmt/featuremgr/engineering/File Specification/featuredatabase.dtd Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,31 +0,0 @@
-<!ELEMENT hrhmacro EMPTY>
-<!ATTLIST hrhmacro
- exclude CDATA #IMPLIED
- include CDATA #IMPLIED
- infeaturesetiby CDATA #IMPLIED>
-
-<!ELEMENT hfileheader (#PCDATA)>
-<!ATTLIST hfileheader
- interfacestatus CDATA #REQUIRED
- interfacevisibility CDATA #REQUIRED>
-
-<!ELEMENT featureset ((hfileheader?, feature+))>
-<!ATTLIST featureset
- hfilename CDATA #IMPLIED
- ibyname CDATA #IMPLIED
- namespace CDATA #IMPLIED>
-
-<!ELEMENT featuredatabase ((featureset+, defaultfeaturerange*))>
-<!ELEMENT feature ((hrhmacro?, comment?))>
-<!ATTLIST feature
- name CDATA #REQUIRED
- statusflags CDATA #REQUIRED
- uid CDATA #REQUIRED
- userdata CDATA #IMPLIED>
-
-<!ELEMENT defaultfeaturerange ((comment?))>
-<!ATTLIST defaultfeaturerange
- higheruid CDATA #REQUIRED
- loweruid CDATA #REQUIRED>
-
-<!ELEMENT comment (#PCDATA)>
--- a/featuremgmt/featuremgr/engineering/reference_plugins/group/simple_feature_info_plugin.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/engineering/reference_plugins/group/simple_feature_info_plugin.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -22,8 +22,6 @@
USERINCLUDE ../inc
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-//SYSTEMINCLUDE /epoc32/include
-//SYSTEMINCLUDE /epoc32/include/ecom
SOURCEPATH ../src
SOURCE simple_feature_info_plugin.cpp
--- a/featuremgmt/featuremgr/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -22,13 +22,13 @@
PRJ_EXPORTS
-../inc/featmgr.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featmgr.h)
-../inc/featurecontrol.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featurecontrol.h)
-../inc/featurenotifier.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featurenotifier.h)
-../inc/featurecmn.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featurecmn.h)
-../inc/featdiscovery.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(featdiscovery.h)
-../inc/featureinfoplugin.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featureinfoplugin.h)
-../inc/featureinfoplugin.inl SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featureinfoplugin.inl)
+../inc/featmgr.h OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featmgr.h)
+../inc/featurecontrol.h OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featurecontrol.h)
+../inc/featurenotifier.h OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featurenotifier.h)
+../inc/featurecmn.h OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featurecmn.h)
+../inc/featdiscovery.h OS_LAYER_PUBLIC_EXPORT_PATH(featdiscovery.h)
+../inc/featureinfoplugin.h OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featureinfoplugin.h)
+../inc/featureinfoplugin.inl OS_LAYER_PLATFORM_EXPORT_PATH(featmgr/featureinfoplugin.inl)
#ifdef SYMBIAN_OLD_EXPORT_LOCATION
../inc/featurepanics.h /epoc32/include/featmgr/featurepanics.h
#endif
--- a/featuremgmt/featuremgr/group/featmgrserver.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/group/featmgrserver.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -13,21 +13,21 @@
// Description:
//
+#ifdef __FEATMGR_TESTCFG__
+TARGET test_featmgrserver.exe
+CAPABILITY AllFiles ProtServ ReadDeviceData
+#else
+TARGET featmgrserver.exe
+CAPABILITY ProtServ ReadDeviceData
+#endif // __FEATMGR_TESTCFG__
-#ifndef __FEATMGR_TESTCFG__
-TARGET featmgrserver.exe
// Since this is an exe with no alternate implementations,
// just use same UID for both UID2 and UID3
UID 0x10205054 0x10205054
-#else
-TARGET test_featmgrserver.exe
-UID 0x102836E5 0x102836E5
-#endif // __FEATMGR_TESTCFG__
TARGETTYPE exe
VENDORID 0x70000001
-CAPABILITY ProtServ ReadDeviceData
//CodeWarrior compilation options - disable the "illegal pragma" warning
OPTION CW -w noillpragmas
--- a/featuremgmt/featuremgr/src/inc/featmgrconfiguration.h Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/src/inc/featmgrconfiguration.h Tue Aug 31 16:57:14 2010 +0300
@@ -32,7 +32,7 @@
const TInt KDefaultFeatMgrTimer = (10*1000*1000);
#ifdef EXTENDED_FEATURE_MANAGER_TEST
const TInt KShutdownTimeout = 500000;
-const TInt KServerUid2Int = 0x102836E5;
+const TInt KServerUid2Int = 0x10205054;
#else
const TInt KServerUid2Int = 0x10205054;
#endif // EXTENDED_FEATURE_MANAGER_TEST
--- a/featuremgmt/featuremgr/src/serverexe/featmgrfeatureregistry.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/src/serverexe/featmgrfeatureregistry.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -163,6 +163,11 @@
}
else
{
+ TBitFlags32 flags = iFeatureList[index].FeatureFlags();
+ flags.Assign( EFeatureSupported, KFeatureUnsupported );
+ TUint32 data = iFeatureList[index].FeatureData();
+ TFeatureServerEntry entry( aFeature.FeatureUid(), flags, data );
+ aFeature = entry;
err = KFeatureUnsupported;
}
@@ -276,8 +281,19 @@
{
data = *aData;
}
- TFeatureServerEntry entry( aFeature, flags, data );
- err = SWICacheCommand(ESWISetFeatAndData, entry);
+
+ TFeatureServerEntry entry( aFeature, flags, data );
+
+ // If aData is not null, we want to change the user data too
+ // otherwise only change the feature status.
+ if( aData )
+ {
+ err = SWICacheCommand(ESWISetFeatAndData, entry);
+ }
+ else
+ {
+ err = SWICacheCommand(ESWISetFeat, entry);
+ }
}
else
{
@@ -1442,6 +1458,13 @@
EFeatureSupportUntouch,&data);
}
break;
+ case ESWISetFeat:
+ {
+ SetFeature( iSWICachedOperations[i].iFeatEntry.FeatureUid(),
+ iSWICachedOperations[i].iFeatEntry.FeatureFlags().Value(),
+ NULL);
+ }
+ break;
default:
break;
};
--- a/featuremgmt/featuremgr/src/serverexe/featmgrfeatureregistry.h Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/src/serverexe/featmgrfeatureregistry.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2007-2010 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"
@@ -69,7 +69,8 @@
ESWIAddFeat,
ESWIDeleteFeat,
ESWISetFeatAndData,
- ESWISetFeatData
+ ESWISetFeatData,
+ ESWISetFeat
};
/*
--- a/featuremgmt/featuremgr/src/serverexe/featmgrserver.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/src/serverexe/featmgrserver.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -317,9 +317,13 @@
TBool ret( EFalse );
// Use ECom to read information about existing interface implementations
- _LIT8( KEmptyString, "" );
+#ifndef EXTENDED_FEATURE_MANAGER_TEST
+ _LIT8( KResolverString, "" );
+#else
+ _LIT8( KResolverString, "efmtestplugin" ); //In test server we only want test plugins.
+#endif
TEComResolverParams resolverParams;
- resolverParams.SetDataType (KEmptyString);
+ resolverParams.SetDataType (KResolverString);
resolverParams.SetWildcardMatch (ETrue);
TCleanupItem cleanupItem( ResetAndDestroyArray, &implInfoArray );
@@ -327,9 +331,8 @@
TIMESTAMP( "CFeatMgrServer::LoadPluginsL - ListImplementationsL start: " )
REComSession::ListImplementationsL( KFeatureInfoPluginInterfaceUid,
+ resolverParams,
#ifndef EXTENDED_FEATURE_MANAGER_TEST
- resolverParams,
-
KRomOnlyResolverUid,
#endif
implInfoArray);
--- a/featuremgmt/featuremgr/test/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -83,6 +83,7 @@
//iby files for the test components
featmgr_techview_test.iby /epoc32/rom/include/featmgr_techview_test.iby
+featmgr_techview_rtest.iby /epoc32/rom/include/featmgr_techview_rtest.iby
featmgr_textshell_test.iby /epoc32/rom/include/featmgr_textshell_test.iby
../tef/tef_efm_configured/group/efm_configured_testserver.iby /epoc32/rom/include/efm_configured_testserver.iby
../tef/tef_efm_normal/group/efm_normal_testserver.iby /epoc32/rom/include/efm_normal_testserver.iby
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/featuremgmt/featuremgr/test/group/featmgr_techview_rtest.iby Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,22 @@
+// Copyright (c) 2010 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:
+//
+
+#ifndef __FEATMGR_TECHVIEW_RTEST_IBY__
+#define __FEATMGR_TECHVIEW_RTEST_IBY__
+
+file=ABI_DIR\BUILD_DIR\t_fmgrbackupresponse.exe test\t_fmgrbackupresponse.exe
+file=ABI_DIR\BUILD_DIR\t_fmgrrestoreresponse.exe test\t_fmgrrestoreresponse.exe
+
+#endif // __FEATMGR_TECHVIEW_RTEST_IBY__
--- a/featuremgmt/featuremgr/test/group/featmgr_techview_test.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/group/featmgr_techview_test.iby Tue Aug 31 16:57:14 2010 +0300
@@ -12,7 +12,7 @@
//
// Description:
// For all Techview tests (TEF + RTest).
-//
+//
#ifndef __FEATMGR_TEST_IBY__
#define __FEATMGR_TEST_IBY__
--- a/featuremgmt/featuremgr/test/helper/test_plugins/data/102836F3.rss Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/helper/test_plugins/data/102836F3.rss Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -35,8 +35,8 @@
{
implementation_uid = 0x102836F4;
version_no = 1;
- display_name = "";
- default_data = "";
+ display_name = "efmtestplugin";
+ default_data = "efmtestplugin";
opaque_data = "";
//rom-only resolving is disabled for test projects to allow run-time plugin addition and removal
rom_only = 0;
--- a/featuremgmt/featuremgr/test/helper/test_plugins/data/102836F5.rss Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/helper/test_plugins/data/102836F5.rss Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -35,8 +35,8 @@
{
implementation_uid = 0x102836F6;
version_no = 1;
- display_name = "";
- default_data = "";
+ display_name = "efmtestplugin";
+ default_data = "efmtestplugin";
opaque_data = "";
//rom-only resolving is disabled for test projects to allow run-time plugin addition and removal
rom_only = 0;
--- a/featuremgmt/featuremgr/test/helper/test_plugins/data/102836F7.rss Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/helper/test_plugins/data/102836F7.rss Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -35,8 +35,8 @@
{
implementation_uid = 0x102836F8;
version_no = 1;
- display_name = "";
- default_data = "";
+ display_name = "efmtestplugin";
+ default_data = "efmtestplugin";
opaque_data = "";
//rom-only resolving is disabled for test projects to allow run-time plugin addition and removal
rom_only = 0;
--- a/featuremgmt/featuremgr/test/helper/test_plugins/data/102836F9.rss Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/helper/test_plugins/data/102836F9.rss Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -35,8 +35,8 @@
{
implementation_uid = 0x102836FA;
version_no = 1;
- display_name = "";
- default_data = "";
+ display_name = "efmtestplugin";
+ default_data = "efmtestplugin";
opaque_data = "";
//rom-only resolving is disabled for test projects to allow run-time plugin addition and removal
rom_only = 0;
--- a/featuremgmt/featuremgr/test/helper/test_plugins/data/102836FB.rss Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/helper/test_plugins/data/102836FB.rss Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -35,8 +35,8 @@
{
implementation_uid = 0x102836FC;
version_no = 1;
- display_name = "";
- default_data = "";
+ display_name = "efmtestplugin";
+ default_data = "efmtestplugin";
opaque_data = "";
//rom-only resolving is disabled for test projects to allow run-time plugin addition and removal
rom_only = 0;
--- a/featuremgmt/featuremgr/test/helper/test_plugins/data/102836FD.rss Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/helper/test_plugins/data/102836FD.rss Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -35,8 +35,8 @@
{
implementation_uid = 0x102836FE;
version_no = 1;
- display_name = "";
- default_data = "";
+ display_name = "efmtestplugin";
+ default_data = "efmtestplugin";
opaque_data = "";
//rom-only resolving is disabled for test projects to allow run-time plugin addition and removal
rom_only = 0;
--- a/featuremgmt/featuremgr/test/helper/test_plugins/data/102836FF.rss Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/helper/test_plugins/data/102836FF.rss Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -35,8 +35,8 @@
{
implementation_uid = 0x10283700;
version_no = 1;
- display_name = "";
- default_data = "";
+ display_name = "efmtestplugin";
+ default_data = "efmtestplugin";
opaque_data = "";
//rom-only resolving is disabled for test projects to allow run-time plugin addition and removal
rom_only = 0;
--- a/featuremgmt/featuremgr/test/helper/test_plugins/data/10283707.rss Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/helper/test_plugins/data/10283707.rss Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -35,8 +35,8 @@
{
implementation_uid = 0x10283708;
version_no = 1;
- display_name = "";
- default_data = "";
+ display_name = "efmtestplugin";
+ default_data = "efmtestplugin";
opaque_data = "";
//rom-only resolving is disabled for test projects to allow run-time plugin addition and removal
rom_only = 0;
--- a/featuremgmt/featuremgr/test/rtest/group/t_fmgrstartup.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/rtest/group/t_fmgrstartup.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,6 +15,7 @@
TARGET t_fmgrstartup.exe
TARGETTYPE exe
+UID 0x10205054 0x10205054
MACRO EXTENDED_FEATURE_MANAGER_TEST
MACRO FEATURE_MANAGER_STARTUP_TEST
--- a/featuremgmt/featuremgr/test/rtest/src/t_fmgrapi.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/rtest/src/t_fmgrapi.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -28,6 +28,8 @@
///////////////////////////////////////////////////////////////////////////////////////
static RTest TheTest(_L("t_fmgrapi"));
+TUid SupportedFeature = KConnectivity; //Defaulted to KConnectivity, but we will re-assign it in FeatureTestPreparation().
+TUid SupportedFeature2 = KSip; //Defaulted to KSip, but we will re-assign it in FeatureTestPreparation().
///////////////////////////////////////////////////////////////////////////////////////
@@ -284,24 +286,24 @@
{
TBool rc = CFeatureDiscovery::IsFeatureSupportedL(KInvalidFeatureId1);
TEST(!rc);
- rc = CFeatureDiscovery::IsFeatureSupportedL(KLocationManagement.iUid);
+ rc = CFeatureDiscovery::IsFeatureSupportedL(SupportedFeature.iUid);
TEST(rc);
rc = CFeatureDiscovery::IsFeatureSupportedL(KInvalidFeatureUid1);
TEST(!rc);
- rc = CFeatureDiscovery::IsFeatureSupportedL(KLocationManagement);
+ rc = CFeatureDiscovery::IsFeatureSupportedL(SupportedFeature);
TEST(rc);
CFeatureDiscovery* fdiscovery = CFeatureDiscovery::NewLC();
rc = fdiscovery->IsSupported(KInvalidFeatureId1);
TEST(!rc);
- rc = fdiscovery->IsSupported(KLocationManagement.iUid);
+ rc = fdiscovery->IsSupported(SupportedFeature.iUid);
TEST(rc);
rc = fdiscovery->IsSupported(KInvalidFeatureUid1);
TEST(!rc);
- rc = fdiscovery->IsSupported(KLocationManagement);
+ rc = fdiscovery->IsSupported(SupportedFeature);
TEST(rc);
CleanupStack::PopAndDestroy(fdiscovery);
@@ -317,11 +319,11 @@
//////////////////////////////////////////////////////////
//A test with a set: one valid and one invalid feature
TFeatureSet fset;
- TInt err = fset.Append(KConnectivity);
+ TInt err = fset.Append(SupportedFeature);
TEST2(err, KErrNone);
err = fset.Append(KInvalidFeatureUid1);
TEST2(err, KErrNone);
- TBool rc = fset.IsFeatureSupported(KConnectivity);
+ TBool rc = fset.IsFeatureSupported(SupportedFeature);
TEST(!rc);
rc = fset.IsFeatureSupported(KInvalidFeatureUid1);
TEST(!rc);
@@ -334,7 +336,7 @@
err = fdiscovery->FeaturesSupported(fset);
}
TEST2(err, KErrNone);
- rc = fset.IsFeatureSupported(KConnectivity);
+ rc = fset.IsFeatureSupported(SupportedFeature);
TEST(rc);
rc = fset.IsFeatureSupported(KInvalidFeatureUid1);
TEST(!rc);
@@ -343,7 +345,7 @@
//////////////////////////////////////////////////////////
//A test with an empty set
TFeatureSet fset2;
- rc = fset2.IsFeatureSupported(KConnectivity);
+ rc = fset2.IsFeatureSupported(SupportedFeature);
TEST(!rc);
rc = fset2.IsFeatureSupported(KInvalidFeatureUid1);
TEST(!rc);
@@ -356,7 +358,7 @@
err = fdiscovery->FeaturesSupported(fset2);
}
TEST2(err, KErrArgument);
- rc = fset2.IsFeatureSupported(KConnectivity);
+ rc = fset2.IsFeatureSupported(SupportedFeature);
TEST(!rc);
rc = fset2.IsFeatureSupported(KInvalidFeatureUid1);
TEST(!rc);
@@ -365,9 +367,9 @@
//////////////////////////////////////////////////////////
//A test with a set: two valid features
TFeatureSet fset3;
- err = fset3.Append(KConnectivity);
+ err = fset3.Append(SupportedFeature);
TEST2(err, KErrNone);
- err = fset3.Append(KSip);
+ err = fset3.Append(SupportedFeature2);
TEST2(err, KErrNone);
if(aStaticMethodsUsed)
{
@@ -378,9 +380,9 @@
err = fdiscovery->FeaturesSupported(fset3);
}
TEST2(err, KErrNone);
- rc = fset3.IsFeatureSupported(KConnectivity);
+ rc = fset3.IsFeatureSupported(SupportedFeature);
TEST(rc);
- rc = fset3.IsFeatureSupported(KSip);
+ rc = fset3.IsFeatureSupported(SupportedFeature2);
TEST(rc);
rc = fset3.AreAllFeaturesSupported();
TEST(rc);
@@ -402,8 +404,31 @@
DoFeatureDiscoveryTest2L(EFalse);
}
+void FeatureTestPreparation()
+ {
+ RFeatureControl ctrl;
+ TInt err = ctrl.Open();
+ TEST2(err, KErrNone);
+ /////////////////////////////////////////////////////////////
+ RFeatureUidArray farray;
+ TheTest.Printf(_L("Getting supported feature for CFeatureDiscovery test\r\n"));
+ err = ctrl.ListSupportedFeatures(farray);
+ if (err == KErrNone && farray.Count() > 1)
+ {
+ SupportedFeature = farray[0]; //Take the first supported value
+ SupportedFeature2 = farray[1]; //Take the first supported value
+ }
+ else
+ {
+ TheTest.Printf(_L("Warning: Failed to get supported feature for testing. CFeatureDiscovery tests are going to fail\r\n"));
+ }
+ farray.Close();
+ ctrl.Close();
+ }
+
void DoTestsL()
{
+ FeatureTestPreparation(); //Preparation for the test.
TheTest.Start(_L("@SYMTestCaseID:PDS-EFM-CT-4059 FeatureManager::FeatureSupported() test"));
FeatureSupportedTestL();
TheTest.Next(_L("@SYMTestCaseID:PDS-EFM-CT-4060 RFeatureControl tests-1"));
--- a/featuremgmt/featuremgr/test/rtest/src/t_fmgrbackupresponse.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/rtest/src/t_fmgrbackupresponse.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -126,6 +126,11 @@
TRequestStatus testStatus;
CleanupClosePushL( testThread );
+ //Needs to ensure server is started before simulating backup operation
+ RFeatureControl rfc;
+ TTEST2( rfc.Connect(), KErrNone ); //This will start the server if not already started
+ rfc.Close();
+
simulate->Simulate_CheckRegFileL();
// Simulate a backup
--- a/featuremgmt/featuremgr/test/rtest/src/t_fmgrrestoreresponse.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/rtest/src/t_fmgrrestoreresponse.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -126,6 +126,11 @@
TRequestStatus testStatus;
CleanupClosePushL( testThread );
+ //Needs to ensure server is started before simulating backup operation
+ RFeatureControl rfc;
+ TTEST2( rfc.Connect(), KErrNone ); //This will start the server if not already started
+ rfc.Close();
+
simulate->Simulate_CheckRegFileL();
// Simulate a restore
--- a/featuremgmt/featuremgr/test/rtest/src/t_fmgrstartup.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/rtest/src/t_fmgrstartup.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -26,6 +26,7 @@
static const TInt KBurstRate = 20;
#endif
+void DestroyTestEnv();
///////////////////////////////////////////////////////////////////////////////////////
static RTest TheTest(_L("t_fmgrstartup"));
@@ -37,24 +38,6 @@
#endif
///////////////////////////////////////////////////////////////////////////////////////
-
-//Deletes all created test files.
-void DestroyTestEnv()
- {
- //KFeaturesDir is defined only if EXTENDED_FEATURE_MANAGER_TEST is defined
-#ifdef EXTENDED_FEATURE_MANAGER_TEST
- RFs fs;
- TInt err = fs.Connect();
- if(err == KErrNone)
- {
- (void)fs.Delete(KFeaturesFile);
- }
- fs.Close();
-#endif
- }
-
-///////////////////////////////////////////////////////////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////
//Test macros and functions
void Check1(TInt aValue, TInt aLine)
{
@@ -78,6 +61,45 @@
#define TEST2(aValue, aExpected) ::Check2(aValue, aExpected, __LINE__)
///////////////////////////////////////////////////////////////////////////////////////
+void CreateTestEnv()
+ {
+ //KFeaturesDir is defined only if EXTENDED_FEATURE_MANAGER_TEST is defined
+#ifdef EXTENDED_FEATURE_MANAGER_TEST
+ RFs fs;
+ TInt err = fs.Connect();
+ TEST2(err, KErrNone);
+
+ err = fs.MkDir(KFeaturesDir);
+ TEST (err == KErrNone || err == KErrAlreadyExists);
+
+ (void)fs.Delete(KFeaturesFile);
+ err = BaflUtils::CopyFile(fs, KZOrgFeaturesFile, KFeaturesDir);
+ TEST2 (err, KErrNone);
+ err = fs.SetAtt(KFeaturesFile, KEntryAttNormal, KEntryAttReadOnly);
+ TEST2 (err, KErrNone);
+ fs.Close();
+#endif
+ }
+
+//Deletes all created test files.
+void DestroyTestEnv()
+ {
+ //KFeaturesDir is defined only if EXTENDED_FEATURE_MANAGER_TEST is defined
+#ifdef EXTENDED_FEATURE_MANAGER_TEST
+ RFs fs;
+ TInt err = fs.Connect();
+ if(err == KErrNone)
+ {
+ err = fs.Delete(KFeaturesFile);
+ if (err != KErrNone)
+ {
+ RDebug::Print(_L("Warning: Clean test enviroment failed with error %d"), err);
+ }
+ }
+ fs.Close();
+#endif
+ }
+///////////////////////////////////////////////////////////////////////////////////////
static void MarkHandles()
{
@@ -193,24 +215,6 @@
TheTest.Printf(_L("\r\n===File I/O error simulation test succeeded on iteration %d===\r\n"), cnt);
}
-void CreateTestEnv()
- {
- //KFeaturesDir is defined only if EXTENDED_FEATURE_MANAGER_TEST is defined
-#ifdef EXTENDED_FEATURE_MANAGER_TEST
- RFs fs;
- TInt err = fs.Connect();
- TEST2(err, KErrNone);
-
- err = fs.MkDir(KFeaturesDir);
- TEST (err == KErrNone || err == KErrAlreadyExists);
-
- (void)fs.Delete(KFeaturesFile);
- err = BaflUtils::CopyFile(fs, KZOrgFeaturesFile, KFeaturesDir);
- TEST2 (err, KErrNone);
-
- fs.Close();
-#endif
- }
void DoTestsL()
{
--- a/featuremgmt/featuremgr/test/tef/tef_efm_configured/src/characterisation_steps.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/tef/tef_efm_configured/src/characterisation_steps.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -27,22 +27,16 @@
#include "characterisation_steps.h"
#include "efm_teststepbase.h"
+
+TBool SkipPerformanceTest = EFalse;
+const TInt KPlatSimUid = 0x20029a73; //0x20029a73 will be changed soon once PlatSim get its own uid.
+
// This is the base class for some of our characterisation tests.
// Creates an RFeatureControl object, finds out what the fast counter
// frequency is and gets the timeout for this test.
TVerdict CCharacteriseBaseStep :: doTestStepPreambleL()
{
- // First find out the granularity of the system clock..
- HAL::Get(HALData::EFastCounterFrequency, icountfreq);
- INFO_PRINTF2(_L("Counts per sec=%d"), icountfreq);
- icountperusec = icountfreq/1000000.0;
- INFO_PRINTF2(_L("Counts per usec=%f"), icountperusec);
- TInt err = icontrol.Open();
- TESTDIAGNOSTICERROR(err==KErrNone,
- _L("RFeatureControl::Open failed: error = %d"), err);
- if(err) { return TestStepResult(); }
- CleanupClosePushL(icontrol);
// Get the timeout from the .ini file. The name of the timeout entry
// varies depending on what type of build we have.
@@ -68,6 +62,10 @@
case HAL::EMachineUid_NE1_TB:
timeoutini.Append(_L("_NE1"));
break;
+ case KPlatSimUid:
+ ERR_PRINTF1(_L("Not running performance test in PlatSim"));
+ SkipPerformanceTest = ETrue; //Skip performance test on PlatSim
+ break;
//add any new hardware IDs here
default:
break;
@@ -78,21 +76,37 @@
#else
timeoutini.Append(_L("_UREL"));
#endif
-
- // Get the timeout, which is measured in microseconds.
- if( !GetIntFromConfig(ConfigSection(), timeoutini, itimeout ) )
- {
- ERR_PRINTF2(_L("Can't find '%S' in .ini file"),
- &timeoutini );
- CleanupStack::PopAndDestroy(&icontrol);
- SetTestStepResult(EFail);
- return TestStepResult();
- }
+ if (!SkipPerformanceTest)
+ {
+ // First find out the granularity of the system clock..
+ HAL::Get(HALData::EFastCounterFrequency, icountfreq);
+ INFO_PRINTF2(_L("Counts per sec=%d"), icountfreq);
+ icountperusec = icountfreq/1000000.0;
+ INFO_PRINTF2(_L("Counts per usec=%f"), icountperusec);
+ TInt err = icontrol.Open();
+ TESTDIAGNOSTICERROR(err==KErrNone,
+ _L("RFeatureControl::Open failed: error = %d"), err);
+ if(err) { return TestStepResult(); }
+ CleanupClosePushL(icontrol);
+ // Get the timeout, which is measured in microseconds.
+ if( !GetIntFromConfig(ConfigSection(), timeoutini, itimeout ) )
+ {
+ ERR_PRINTF2(_L("Can't find '%S' in .ini file"),
+ &timeoutini );
+ CleanupStack::PopAndDestroy(&icontrol);
+ SetTestStepResult(EFail);
+ return TestStepResult();
+ }
+ }
return TestStepResult();
}
TVerdict CCharacteriseBaseStep :: doTestStepPostambleL()
{
+ if (SkipPerformanceTest)
+ {
+ return TestStepResult();
+ }
CleanupStack::PopAndDestroy(&icontrol);
return TestStepResult();
}
@@ -104,6 +118,10 @@
TVerdict CCharacteriseSupportedStep::doTestStepL()
{
+ if (SkipPerformanceTest)
+ {
+ return TestStepResult();
+ }
// The base class 'CCharacteriseBaseStep' has already opened the
// RFeatureControl object and read in the timeout number.
@@ -171,6 +189,10 @@
TVerdict CCharacteriseSupportedArrayStep::doTestStepL()
{
+ if (SkipPerformanceTest)
+ {
+ return TestStepResult();
+ }
// Find out how many features we're going to attempt to read..
TInt nfeats, minuid, expsup;
if(!GetIntFromConfig(ConfigSection(), _L("NumFeaturesToRead"), nfeats) ||
--- a/featuremgmt/featuremgr/test/tef/tef_efm_normal/src/component_test_steps.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/tef/tef_efm_normal/src/component_test_steps.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -161,7 +161,8 @@
{
TThreadId id = RThread().Id();
TUid uid = {id.Id()};
- uid.iUid += 500;
+ uid.iUid += 0x1001000;
+
// Create the thread info instance that would hold the results for the tests below
TThreadTestInfo info;
info.iId = uid.iUid;
@@ -509,9 +510,7 @@
*/
// Locals for the test scenarios
- RApaLsSession ls;
RProcess process;
- CApaCommandLine* cmdLine;
TBitFlags32 flags( 0 );
flags.Set( EFeatureSupported);
flags.Set( EFeatureModifiable );
@@ -534,14 +533,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// This delay is used to allow P&S to complete the initial setting of the
// KSAUidSoftwareInstallKeyValue property to ESASwisInstall before we proceed with
@@ -564,17 +556,17 @@
err = control.AddFeature(entry3);
TESTDIAGNOSTICERROR(err==KErrNone,
_L("RFeatureControl::AddFeature expects KErrNone for KNewUid3; returned value is = %d"),err);
-
+
// Enable feature
- err = control.EnableFeature(KNewUid1);
- TESTDIAGNOSTICERROR(err==KErrNone,
- _L("RFeatureControl::EnableFeature expects KErrNone for KNewUid1; returned value is = %d"),err);
-
- // Disable feature
- err = control.DisableFeature(KNewUid1);
- TESTDIAGNOSTICERROR(err==KErrNone,
- _L("RFeatureControl::DisableFeature expects KErrNone for KNewUid1; returned value is = %d"),err);
-
+ err = control.EnableFeature(KNewUid1);
+ TESTDIAGNOSTICERROR(err==KErrNone,
+ _L("RFeatureControl::EnableFeature expects KErrNone for KNewUid1; returned value is = %d"),err);
+
+ // Disable feature
+ err = control.DisableFeature(KNewUid1);
+ TESTDIAGNOSTICERROR(err==KErrNone,
+ _L("RFeatureControl::DisableFeature expects KErrNone for KNewUid1; returned value is = %d"),err);
+
// Set features
err = control.SetFeature(KNewUid1, ETrue, KChangeData);
TESTDIAGNOSTICERROR(err==KErrNone,
@@ -675,14 +667,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -732,14 +717,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -788,14 +766,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -854,14 +825,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -920,14 +884,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -970,14 +927,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -1023,14 +973,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -1150,14 +1093,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -1207,14 +1143,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -1248,14 +1177,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -1314,14 +1236,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -1385,14 +1300,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -1427,14 +1335,7 @@
// Starting helping exe
_LIT(KHelpingExePath, "helping_exe.exe");
err = process.Create(KHelpingExePath, _L("1"));
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KHelpingExePath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Wait for helping_exe to finish
User::After(600000);
@@ -1518,14 +1419,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -1552,14 +1446,7 @@
// Starting helping exe which is going to call SWIEnd (passing 2 as a parameter to indicate this)
_LIT(KHelpingExePath, "helping_exe.exe");
err = process.Create(KHelpingExePath, _L("2"));
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KHelpingExePath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
User::After(500000);
@@ -1612,14 +1499,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(process);
process.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
// Allow P&S to complete initialising
User::After(200000);
@@ -1736,6 +1616,63 @@
// Wait before starting the next test
User::After(100000);
+ ////////////////////////////////////////////////////////////////////////////////////////////
+ // SCENARIO 18: Successful installation and features manipulation (Enable/Disable without modifying data)
+ // Add Feature with user data -> P&S install -> SWIStart -> Enable/Disable Feature ->
+ // -> SWIEnd -> P&S success -> No change to user data
+ ////////////////////////////////////////////////////////////////////////////////////////////
+ INFO_PRINTF1(_L("SCENARIO 18: Successful installation and Enable or Disable feature should not modify userdata"));
+ // Launching dummyswi.exe
+ err = process.Create(KDummySWIPath, _L("1")); // 1 = install success
+ TESTDIAGNOSTICERROR(err==KErrNone,
+ _L("RProcess::Create expects KErrNone, returned value is = %d"),err);
+ if( err==KErrNone )
+ {
+ process.Resume();
+
+ // Allow P&S to complete initialising
+ User::After(200000);
+
+ err = control.Open();
+ TESTDIAGNOSTICERROR(err==KErrNone, _L("RFeatureControl::Open failed, returned value is = %d"),err);
+
+ err = control.AddFeature(entry1);
+ TESTDIAGNOSTICERROR(err==KErrNone, _L("RFeatureControl::AddFeature expects KErrNone for KNewUid1; returned value is = %d"),err);
+
+ err = control.SWIStart();
+ TESTDIAGNOSTICERROR(err==KErrNone, _L("RFeatureControl::SWIStart expects KErrNone; returned value is = %d"),err);
+
+ // Enable feature
+ err = control.EnableFeature(KNewUid1);
+ TESTDIAGNOSTICERROR(err==KErrNone, _L("RFeatureControl::EnableFeature expects KErrNone for KNewUid1; returned value is = %d"),err);
+
+ // Disable feature
+ err = control.DisableFeature(KNewUid1);
+ TESTDIAGNOSTICERROR(err==KErrNone, _L("RFeatureControl::EnableFeature expects KErrNone for KNewUid1; returned value is = %d"),err);
+
+ err = control.SWIEnd();
+ TESTDIAGNOSTICERROR(err==KErrNone, _L("RFeatureControl::SWIEnd expects KErrNone; returned value is = %d"),err);
+
+ // Delay until the P&S property is set to ESASwisStatusSuccess in dummyswi.exe to indicate successful installation
+ User::After(1500000);
+
+ err = control.FeatureSupported(query1);
+ TESTDIAGNOSTICERROR(err==KErrNone, _L("TFeatureEntry::FeatureData expects 0 for KNewUid1; returned value is = %d"),err);
+ TESTDIAGNOSTICERROR(query1.FeatureData()==KDefaultData1, _L("TFeatureEntry::FeatureData expects non-zero for KNewUid1; returned value is = %d"), err);
+
+ // Delete KNewUid1
+ err = control.DeleteFeature(KNewUid1);
+ TESTDIAGNOSTICERROR(err==KErrNone, _L("RFeatureControl::DeleteFeature expects KErrNone for KNewUid1; returned value is = %d"),err);
+
+ query1 = TFeatureEntry(KNewUid1);
+
+ control.Close();
+
+ }
+ process.Close();
+ // Wait before starting the next test
+ User::After(100000);
+
return TestStepResult();
}
--- a/featuremgmt/featuremgr/test/tef/tef_efm_normal/src/featurecontrol_test_steps.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/tef/tef_efm_normal/src/featurecontrol_test_steps.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -174,7 +174,7 @@
_L("RFeatureControl::Open failed: error = %d"),err);
// Fetch status for "unknown" feature
- TFeatureEntry emptyEntry;
+ TFeatureEntry emptyEntry(TUid::Uid(0x1000005));
TInt supported = control.FeatureSupported( emptyEntry );
TESTDIAGNOSTICERROR(supported == KErrNotFound,
_L("RFeatureControl::FeatureSupported - KErrNotFound expected for unknown feature; returned value is %d"),supported);
--- a/featuremgmt/featuremgr/test/tef/tef_efm_unit/src/efm_unit_teststeps.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featuremgr/test/tef/tef_efm_unit/src/efm_unit_teststeps.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -435,16 +435,7 @@
_L("RProcess::Create expects KErrNone, returned value is = %d"),err);
if( err==KErrNone )
{
- RApaLsSession ls;
- CApaCommandLine* cmdLine;
- User::LeaveIfError(ls.Connect());
- CleanupClosePushL(ls);
- cmdLine = CApaCommandLine::NewLC();
- cmdLine->SetExecutableNameL(KDummySWIPath);
- cmdLine->SetProcessEnvironmentL(iSWIProcess);
- iSWIProcess.Resume();
- CleanupStack::PopAndDestroy(2);
- cmdLine = NULL;
+ iSWIProcess.Resume();
}
// Install the Active Scheduler. We need this for the SWIListener Active Object on the server to
--- a/featuremgmt/featureregistry/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/featuremgmt/featureregistry/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -17,9 +17,9 @@
DEFAULT
PRJ_EXPORTS
-../inc/featreg.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(featreg.h)
-../inc/featreg.inl SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(featreg.inl)
-../inc/featregpan.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(featregpan.h)
+../inc/featreg.h OS_LAYER_PLATFORM_EXPORT_PATH(featreg.h)
+../inc/featreg.inl OS_LAYER_PLATFORM_EXPORT_PATH(featreg.inl)
+../inc/featregpan.h OS_LAYER_PLATFORM_EXPORT_PATH(featregpan.h)
./featreg.iby /epoc32/rom/include/featreg.iby
PRJ_MMPFILES
--- a/loggingservices/eventlogger/LogServ/inc/LogServOperationBase.h Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/LogServ/inc/LogServOperationBase.h Tue Aug 31 16:57:14 2010 +0300
@@ -72,6 +72,7 @@
inline TLogOperationType Type() const;
inline TLogServSessionId SessionId();
static TUint QueueOffset();
+ inline void SetMessageCompletion(const TBool aMessageCompletion);
protected:
inline RMessage2& Message();
@@ -84,6 +85,7 @@
TLogClientServerData iClientServerData;
TLogServSessionId iSessionId;
TSglQueLink iServerLink;
+ TBool iMessageCompletion;
};
--- a/loggingservices/eventlogger/LogServ/inc/LogServOperationBase.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/LogServ/inc/LogServOperationBase.inl Tue Aug 31 16:57:14 2010 +0300
@@ -31,7 +31,7 @@
inline TBool CLogServOperationBase::HaveMessagePointer() const
{
- return (iMessage != RMessage2());
+ return (!iMessage.IsNull());
}
inline void CLogServOperationBase::ClearMessagePointer()
@@ -74,4 +74,9 @@
return iClientServerData;
}
+inline void CLogServOperationBase::SetMessageCompletion(const TBool aMessageCompletion)
+ {
+ iMessageCompletion = aMessageCompletion;
+ }
+
#endif
--- a/loggingservices/eventlogger/LogServ/src/LOGADD.CPP Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/LogServ/src/LOGADD.CPP Tue Aug 31 16:57:14 2010 +0300
@@ -480,7 +480,7 @@
//Sometimes, after a sequence of OpenContactsL()/CloseContacts() calls the Contacts server crashes
//and OpenContactsL() leaves with error -15. In order to avoid that the following delay has been added.
//(something related to Contacts server state machine)
- User::After(100);
+ User::After(1000);
// Attempt to open DB
TRAPD(err,iContactPlugin->OpenContactsL());
if(KErrNone!=err)
--- a/loggingservices/eventlogger/LogServ/src/LogServOperationBase.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/LogServ/src/LogServOperationBase.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -29,7 +29,8 @@
iPackage(aPackage),
iMessage(aMessage),
iClientServerData(aClientServerData),
- iSessionId(aSessionId)
+ iSessionId(aSessionId),
+ iMessageCompletion(ETrue)
{
// Queue this operations
OperationManager().OMOperationQueueAdd(*this);
@@ -63,8 +64,12 @@
//
void CLogServOperationBase::Complete(TInt aCompletionCode)
{
- __ASSERT_ALWAYS(iMessage != RMessage2(), Panic(ELogNoOutstandingAsyncRequest));
- iMessage.Complete(aCompletionCode);
+ __ASSERT_ALWAYS(! iMessage.IsNull(), Panic(ELogNoOutstandingAsyncRequest));
+
+ if (iMessageCompletion)
+ {
+ iMessage.Complete(aCompletionCode);
+ }
// Unnecessary?
iMessage = RMessage2();
--- a/loggingservices/eventlogger/LogServ/src/LogServOperationQueue.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/LogServ/src/LogServOperationQueue.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -133,9 +133,14 @@
// This should complete the request with KErrCancel causing RunL to leave
// RunError completes the request and removes the operation from the pending queue
iTaskInterface.TaskCancelCurrent();
+
//
- if (!aCompleteRequest)
- iCurrentOperation->ClearMessagePointer();
+ // Do not complete the message when the operation completes
+ //
+ if (!aCompleteRequest)
+ {
+ iCurrentOperation->SetMessageCompletion(aCompleteRequest);
+ }
}
else
{
--- a/loggingservices/eventlogger/LogServ/src/LogServResourceInterpreter.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/LogServ/src/LogServResourceInterpreter.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -133,7 +133,8 @@
// Check the entry exists on this drive (e.g. if we are running the log server
// from RAM, then default to the ROM if no RSC on the current drive exists).
TEntry fsEntry;
- if (iFsSession.Entry(fileName, fsEntry) == KErrNotFound)
+ TInt err = iFsSession.Entry(fileName, fsEntry);
+ if ( err == KErrNotFound || err == KErrPathNotFound )
{
// Switch to ROM (we might already have been launching from the ROM,
// in which case this will have no effect anyway).
--- a/loggingservices/eventlogger/LogServ/src/logservsession.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/LogServ/src/logservsession.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -59,7 +59,8 @@
{
LOGTEXT3("CLogServSession::~CLogServSession() - client logging off: %S, %d", &iClientThreadName, iSessionId);
- iOperationManager.OMCancel(iSessionId, ETrue);
+ // Set second parameter to not complete the message, otherwise if the client has died a KERN-EXEC 44 will be generated.
+ iOperationManager.OMCancel(iSessionId, EFalse);
delete iPackage;
delete iNotify;
--- a/loggingservices/eventlogger/LogWrap/inc/LOGWRAPLIMITS.H Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/LogWrap/inc/LOGWRAPLIMITS.H Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
/**
String lengths
-@publishedPartner
+@publishedAll
@released
*/
const TInt KLogMaxRemotePartyLength = 64;
@@ -34,7 +34,7 @@
/**
Limits
-@publishedPartner
+@publishedAll
@released
*/
--- a/loggingservices/eventlogger/Rom/logeng.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/Rom/logeng.iby Tue Aug 31 16:57:14 2010 +0300
@@ -23,16 +23,16 @@
REM The Log Engine
#ifndef NO_LOG_ENGINE_IN_ROM
-file=ABI_DIR\BUILD_DIR\LogWrap.dll System\Libs\LogWrap.dll
-file=ABI_DIR\BUILD_DIR\LogCli.dll System\Libs\LogCli.dll
-file=ABI_DIR\BUILD_DIR\LogCntModel.dll System\Libs\LogCntModel.dll
-file=ABI_DIR\BUILD_DIR\LogServ.exe System\Programs\LogServ.exe
+file=ABI_DIR\BUILD_DIR\logwrap.dll System\Libs\LogWrap.dll
+file=ABI_DIR\BUILD_DIR\logcli.dll System\Libs\LogCli.dll
+file=ABI_DIR\BUILD_DIR\logcntmodel.dll System\Libs\LogCntModel.dll
+file=ABI_DIR\BUILD_DIR\logserv.exe System\Programs\LogServ.exe
data=ZPRIVATE\101f401d\backup_registration.xml private\101f401d\backup_registration.xml
#include "logeng.hby"
#else
-file=ABI_DIR\BUILD_DIR\LogStub.dll System\Libs\LogWrap.dll
+file=ABI_DIR\BUILD_DIR\logstub.dll System\Libs\LogWrap.dll
#endif
#endif
--- a/loggingservices/eventlogger/group/BLD.INF Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/group/BLD.INF Tue Aug 31 16:57:14 2010 +0300
@@ -21,29 +21,29 @@
PRJ_EXPORTS
-../LogWrap/inc/LOGWRAP.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logwrap.h)
-../LogWrap/inc/LOGWRAPCONST.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logwrapconst.h)
-../LogWrap/inc/LOGWRAPLIMITS.H SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(logwraplimits.h)
-../LogWrap/inc/LOGWRAP.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logwrap.inl)
-../LogWrap/inc/LOGWRAP.HRH /epoc32/include/logwrap.hrh
-../LogWrap/inc/LOGFILTERANDEVENTCONSTANTS.HRH /epoc32/include/logfilterandeventconstants.hrh
-../LogWrap/inc/LOGENG.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logeng.h)
-../LogWrap/inc/LOGENGDURATIONS.H SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(logengdurations.h)
-../LogWrap/inc/LOGENGEVENTS.H SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(logengevents.h)
-../LogWrap/inc/LOGSMSPDUDATA.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logsmspdudata.h)
-../LogCli/inc/LOGCLI.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logcli.h)
-../LogCli/inc/LOGCLI.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logcli.inl)
-../LogCli/inc/LOGVIEW.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logview.h)
-../LogCli/inc/LOGVIEW.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logview.inl)
-../LogCli/inc/LogViewChangeObserver.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logviewchangeobserver.h)
-../LogCli/inc/LogClientChangeObserver.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(logclientchangeobserver.h)
+../LogWrap/inc/LOGWRAP.H OS_LAYER_PUBLIC_EXPORT_PATH(logwrap.h)
+../LogWrap/inc/LOGWRAPCONST.H OS_LAYER_PUBLIC_EXPORT_PATH(logwrapconst.h)
+../LogWrap/inc/LOGWRAPLIMITS.H OS_LAYER_PUBLIC_EXPORT_PATH(logwraplimits.h)
+../LogWrap/inc/LOGWRAP.INL OS_LAYER_PUBLIC_EXPORT_PATH(logwrap.inl)
+../LogWrap/inc/LOGWRAP.HRH OS_LAYER_PUBLIC_EXPORT_PATH(logwrap.hrh)
+../LogWrap/inc/LOGFILTERANDEVENTCONSTANTS.HRH OS_LAYER_PUBLIC_EXPORT_PATH(logfilterandeventconstants.hrh)
+../LogWrap/inc/LOGENG.H OS_LAYER_PUBLIC_EXPORT_PATH(logeng.h)
+../LogWrap/inc/LOGENGDURATIONS.H OS_LAYER_PLATFORM_EXPORT_PATH(logengdurations.h)
+../LogWrap/inc/LOGENGEVENTS.H OS_LAYER_PLATFORM_EXPORT_PATH(logengevents.h)
+../LogWrap/inc/LOGSMSPDUDATA.H OS_LAYER_PUBLIC_EXPORT_PATH(logsmspdudata.h)
+../LogCli/inc/LOGCLI.H OS_LAYER_PUBLIC_EXPORT_PATH(logcli.h)
+../LogCli/inc/LOGCLI.INL OS_LAYER_PUBLIC_EXPORT_PATH(logcli.inl)
+../LogCli/inc/LOGVIEW.H OS_LAYER_PUBLIC_EXPORT_PATH(logview.h)
+../LogCli/inc/LOGVIEW.INL OS_LAYER_PUBLIC_EXPORT_PATH(logview.inl)
+../LogCli/inc/LogViewChangeObserver.h OS_LAYER_PUBLIC_EXPORT_PATH(logviewchangeobserver.h)
+../LogCli/inc/LogClientChangeObserver.h OS_LAYER_PUBLIC_EXPORT_PATH(logclientchangeobserver.h)
../Rom/logeng.iby /epoc32/rom/include/logeng.iby
../Rom/logeng.hby /epoc32/rom/include/logeng.hby
-../logcntmodel/inc/logcntmodel.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(logcntmodel.h)
-../logcntmodel/inc/logcntdef.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(logcntdef.h)
+../logcntmodel/inc/logcntmodel.h OS_LAYER_PLATFORM_EXPORT_PATH(logcntmodel.h)
+../logcntmodel/inc/logcntdef.h OS_LAYER_PLATFORM_EXPORT_PATH(logcntdef.h)
backup_registration.xml z:/private/101f401d/backup_registration.xml
--- a/loggingservices/eventlogger/logcntmodel/inc/logcntmodel.h Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/logcntmodel/inc/logcntmodel.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
--- a/loggingservices/eventlogger/test/inc/t_logutil.h Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/inc/t_logutil.h Tue Aug 31 16:57:14 2010 +0300
@@ -17,9 +17,6 @@
#include <e32test.h>
-//Define "TheTest" variable in the cpp test file
-extern RTest TheTest;
-
void LogTestBoolExpr(TBool aRes, const TText* aFile, TInt aLine, TBool aPrintThreadName = EFalse);
void LogCheck(TInt aValue, TInt aExpected, const TText* aFile, TInt aLine, TBool aPrintThreadName = EFalse);
void LogCheckU(TUint aValue, TUint aExpected, const TText* aFile, TInt aLine, TBool aPrintThreadName = EFalse);
--- a/loggingservices/eventlogger/test/inc/t_logutil2.h Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/inc/t_logutil2.h Tue Aug 31 16:57:14 2010 +0300
@@ -82,7 +82,7 @@
GLREF_D RFile theLog;
GLREF_D RLogTestSession theLogServ;
-#define __FILE_FAILNEXT(X) theFs.SetErrorCondition(KErrGeneral, X)
+#define __FILE_FAILNEXT(err, iteration) theFs.SetErrorCondition(err, iteration)
#define __FILE_RESET theFs.SetErrorCondition(KErrNone, 0)
#if defined(_UNICODE)
--- a/loggingservices/eventlogger/test/src/t_logapi.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/src/t_logapi.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -780,17 +780,24 @@
_LIT(KExecutableFileName, "t_logapi_helper.exe");
_LIT(KCommandParameters, "c:\\private\\10202be9\\;c:\\private\\10202be9\\101f401d.txt;3");
RProcess process;
+ TRequestStatus processWaitStatus;
TInt r = process.Create(KExecutableFileName, KCommandParameters);
+ TEST(r == KErrNone);
+ process.Logon(processWaitStatus);
process.Resume();
- process.Close();
- User::After(1000);
+ User::WaitForRequest(processWaitStatus);
+ TEST(processWaitStatus.Int() == KErrNone);
+ process.Close();
//copy the repository file to the folder 10202be9
_LIT(KCommandParameters1, "z:\\test\\101f401d_TEST.txt;c:\\private\\10202be9\\101f401d.txt;0");
r = process.Create(KExecutableFileName, KCommandParameters1);
+ TEST(r == KErrNone);
+ process.Logon(processWaitStatus);
process.Resume();
- process.Close();
- User::After(1000);
+ User::WaitForRequest(processWaitStatus);
+ TEST(processWaitStatus.Int() == KErrNone);
+ process.Close();
TestUtils::DeleteDatabaseL();
@@ -830,9 +837,13 @@
//delete the repository file c:\\private\\10202be9\\101f401d.txt.
_LIT(KCommandParameters2, "c:\\private\\10202be9\\101f401d.txt;private\\10202be9\101f401d.txt;2");
r = process.Create(KExecutableFileName, KCommandParameters2);
+ TEST(r == KErrNone);
+ process.Logon(processWaitStatus);
process.Resume();
- process.Close();
- User::After(1000);
+ User::WaitForRequest(processWaitStatus);
+ TEST(processWaitStatus.Int() == KErrNone);
+ process.Close();
+
theLog.Write(_L8("Deleting the Log engine database... \n"));
TestUtils::DeleteDatabaseL();
TheTest.Next(_L("Delay of 2 min, the necessary time to central repository to unload its cache... "));
--- a/loggingservices/eventlogger/test/src/t_logbadclient.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/src/t_logbadclient.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -213,6 +213,50 @@
return KErrNone;
}
+//////////////////////////////////////////////////////////////////////////////////////////////////
+//////////////////////////////////////////////////////////////////////////////////////////////////
+
+//Thread function to detect a crash in the server.
+//The server should run for the duration of the test.
+// return KErrAbort: If failure to start server
+// return KErrServerTerminated: If server process is terminated
+
+TInt ServerWatcherFunc(TAny* /*aData*/)
+ {
+ __UHEAP_MARK;
+
+ _LIT(KLogEngServerName,"LogServ*");
+
+ TInt err;
+
+ // Start the server if not already running
+ RLogSession sess;
+ err = sess.Connect();
+ if (err != KErrNone)
+ return KErrAbort;
+ sess.Close();
+
+ TFindProcess findProcess(KLogEngServerName);
+ TFullName result;
+ if ( findProcess.Next(result) != KErrNone )
+ return KErrAbort;
+
+ RProcess server;
+ if( server.Open(findProcess, EOwnerProcess) != KErrNone)
+ return KErrAbort;
+
+ TRequestStatus status;
+ server.Logon(status);
+ User::WaitForRequest(status);
+
+ server.Close();
+
+ __UHEAP_MARKEND;
+
+ return KErrServerTerminated;
+ }
+
+
/**
@SYMTestCaseID PDS-LOGENG-UT-4045
@SYMTestCaseDesc In a loop, where the loop iterations are less than KTestIterCount (5000 at the moment),
@@ -227,6 +271,13 @@
*/
void BadClientTest()
{
+ // Start a thread to watch the server process
+ RThread serverWatcher;
+ TInt err = serverWatcher.Create(_L("ServerWatcher"), &ServerWatcherFunc, 0x2000, 0x1000, 0x10000, NULL, EOwnerProcess);
+ TRequestStatus serverStatus;
+ serverWatcher.Logon(serverStatus);
+ serverWatcher.Resume();
+
TThreadData* p = new TThreadData;
TEST(p != NULL);
TThreadData& data = *p;
@@ -243,7 +294,7 @@
User::After(200000);
_LIT(KTestThreadName, "TLBCThr");
RThread thread;
- TInt err = thread.Create(KTestThreadName, &ThreadFunc1, 0x2000, 0x1000, 0x10000, &data, EOwnerProcess);
+ err = thread.Create(KTestThreadName, &ThreadFunc1, 0x2000, 0x1000, 0x10000, &data, EOwnerProcess);
if(err == KErrAlreadyExists)
{
TheTest.Printf(_L("##Iteration %d. Function %d. Thread \"%S\" already exists!\r\n"), data.iIteration, data.iFunction, &KTestThreadName);
@@ -274,7 +325,15 @@
thread.Logon(status);
TEST2(status.Int(), KRequestPending);
thread.Resume();
- User::WaitForRequest(status);
+ User::WaitForRequest(status, serverStatus);
+
+ // If the Server has crashed then we must fail
+ if (serverStatus != KRequestPending)
+ {
+ TheTest.Printf(_L("##Iteration=%d, Function=%d, Status1=%d, Status2=%d\r\n"), data.iIteration, data.iFunction, status.Int(), serverStatus.Int());
+ break;
+ }
+
TExitType exitType = thread.ExitType();
TInt exitReason = thread.ExitReason();
thread.Close();
@@ -310,6 +369,13 @@
}
}//for
delete p;
+
+
+ // Check to see if the server crashed and not detected by client
+ TEST(serverStatus.Int() == KRequestPending);
+ serverWatcher.Kill(KErrCancel);
+ serverWatcher.Close();
+
}
/**
--- a/loggingservices/eventlogger/test/src/t_logcompat.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/src/t_logcompat.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -684,6 +684,7 @@
void doTestsL()
{
+ TestUtils::Initialize(_L("t_logcompat"));
TheTest.Start(_L("The LogEng compatibility test cases are compiled only when SYMBIAN_ENABLE_EVENTLOGGER_DUALSIM macro is defined!"));
}
--- a/loggingservices/eventlogger/test/src/t_logfile.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/src/t_logfile.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -198,7 +198,9 @@
while(!finished)
{
- if(failCount == 4)
+ TheTest.Printf(_L("%d\r\n"), failCount);
+
+ if(failCount > 8)
{
TRAP(error, client = CLogClient::NewL(theFs));
TEST2(error, KErrNone);
@@ -206,8 +208,8 @@
finished = ETrue;
continue;
}
-
- __FILE_FAILNEXT(++failCount);
+
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TRAP(error, client = CLogClient::NewL(theFs));
@@ -220,13 +222,13 @@
}
else
{
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
TestUtils::DeleteDatabaseL();
}
}
delete client;
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -258,8 +260,7 @@
while(!finished)
{
error = KErrNone;
-
- if(failCount == 4)
+ if(failCount == 8)
{
aClient.AddEventType(*type, active->iStatus);
active->StartL();
@@ -268,9 +269,11 @@
finished = ETrue;
continue;
}
+
+ TheTest.Printf(_L("%d \r"), failCount);
+
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
- __FILE_FAILNEXT(++failCount);
-
aClient.AddEventType(*type, active->iStatus);
active->StartL();
@@ -283,7 +286,7 @@
__FILE_RESET;
- if (error == KErrGeneral)
+ if (error == KErrNoMemory)
{
active->StartL();
aClient.GetEventType(*type, active->iStatus);
@@ -301,7 +304,7 @@
TEST2(active->iStatus.Int(), KErrAlreadyExists);
CleanupStack::PopAndDestroy(2); // active, type
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -329,7 +332,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
aClient.GetEventType(*type, active->iStatus);
@@ -340,7 +344,7 @@
finished = ETrue;
else
{
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
TEST(type->Description() == KNullDesC);
}
@@ -352,7 +356,7 @@
TEST(type->LoggingEnabled());
CleanupStack::PopAndDestroy(2); // active, type
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -386,7 +390,7 @@
type->SetDescription(KTestEventDesc2);
type->SetLoggingEnabled(EFalse);
- if(failCount == 3)
+ if(failCount == 8)
{
aClient.ChangeEventType(*type, active->iStatus);
active->StartL();
@@ -396,7 +400,8 @@
continue;
}
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
aClient.ChangeEventType(*type, active->iStatus);
@@ -410,7 +415,7 @@
__FILE_RESET;
- if (error == KErrGeneral)
+ if (error == KErrNoMemory)
{
active->StartL();
aClient.GetEventType(*type, active->iStatus);
@@ -436,7 +441,7 @@
TEST(type->LoggingEnabled() == EFalse);
CleanupStack::PopAndDestroy(2); // type, active
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -467,7 +472,7 @@
{
error = KErrNone;
- if(failCount == 3)
+ if(failCount == 8)
{
aClient.DeleteEventType(KTestEventUid, active->iStatus);
active->StartL();
@@ -477,7 +482,8 @@
continue;
}
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
aClient.DeleteEventType(KTestEventUid, active->iStatus);
@@ -491,7 +497,7 @@
__FILE_RESET;
- if (error == KErrGeneral)
+ if (error == KErrNoMemory)
{
active->StartL();
aClient.GetEventType(*type, active->iStatus);
@@ -508,7 +514,7 @@
TEST2(active->iStatus.Int(), KErrNotFound);
CleanupStack::PopAndDestroy(2); // type, active
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -568,7 +574,7 @@
{
error = KErrNone;
- if(failCount == 3)
+ if(failCount == 8)
{
aClient.AddEvent(*event, active->iStatus);
active->StartL();
@@ -578,7 +584,8 @@
continue;
}
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
aClient.AddEvent(*event, active->iStatus);
active->StartL();
@@ -591,9 +598,8 @@
__FILE_RESET;
- if (error == KErrGeneral)
+ if (error == KErrNoMemory)
{
- TEST2(error, KErrGeneral);
event->SetId(0);
active->StartL();
@@ -617,7 +623,7 @@
TEST2(active->iStatus.Int(), KErrNone);
CleanupStack::PopAndDestroy(3); // event, active, type
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -646,7 +652,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
aClient.GetEvent(*event, active->iStatus);
active->StartL();
@@ -655,7 +662,7 @@
if (active->iStatus == KErrNone)
finished = ETrue;
else
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
__FILE_RESET;
}
@@ -676,7 +683,7 @@
TEST(event->Data() == KTestData1);
CleanupStack::PopAndDestroy(2); // event, active
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -722,7 +729,7 @@
event->SetLink(KTestLink2);
event->SetDataL(KTestData2);
- if(failCount == 3)
+ if(failCount == 14)
{
aClient.ChangeEvent(*event, active->iStatus);
active->StartL();
@@ -732,7 +739,8 @@
continue;
}
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
aClient.ChangeEvent(*event, active->iStatus);
@@ -745,13 +753,13 @@
__FILE_RESET;
- if (error == KErrGeneral)
+ if (error == KErrNoMemory)
{
active->StartL();
aClient.GetEvent(*event, active->iStatus);
CActiveScheduler::Start();
if (active->iStatus != KErrNone)
- TheTest.Printf(_L("error code:%d failcount:%d\n"),active->iStatus.Int(),failCount);
+ TheTest.Printf(_L("\nerror code:%d failcount:%d\n"),active->iStatus.Int(),failCount);
TEST2(active->iStatus.Int(), KErrNone);
TEST(event->Id() == 0);
@@ -794,7 +802,7 @@
TEST(event->Data() == KTestData2);
CleanupStack::PopAndDestroy(2); // event, active
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -826,7 +834,7 @@
{
error = KErrNone;
- if(failCount == 6)
+ if(failCount == 10)
{
aClient.DeleteEvent(0, active->iStatus);
active->StartL();
@@ -836,7 +844,8 @@
continue;
}
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
aClient.DeleteEvent(0, active->iStatus);
@@ -850,7 +859,7 @@
__FILE_RESET;
- if (error == KErrGeneral)
+ if (error == KErrNoMemory)
{
active->StartL();
aClient.GetEvent(*event, active->iStatus);
@@ -867,7 +876,7 @@
TEST2(active->iStatus.Int(), KErrNotFound);
CleanupStack::PopAndDestroy(2); // event, active
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -897,7 +906,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
aClient.GetConfig(config, active->iStatus);
active->StartL();
@@ -906,7 +916,7 @@
if (active->iStatus == KErrNone)
finished = ETrue;
else
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
__FILE_RESET;
}
@@ -916,7 +926,7 @@
TEST(config.iMaxRecentLogSize > 0);
CleanupStack::PopAndDestroy(); // active
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -956,7 +966,7 @@
config.iMaxRecentLogSize = KTestMaxRecentLogSize;
config.iMaxEventAge = KTestMaxEventAge;
- if(failCount == 4)
+ if(failCount == 11)
{
aClient.ChangeConfig(config, active->iStatus);
active->StartL();
@@ -966,7 +976,8 @@
continue;
}
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
aClient.ChangeConfig(config, active->iStatus);
@@ -980,7 +991,7 @@
__FILE_RESET;
- if (error == KErrGeneral)
+ if (error == KErrNoMemory)
{
active->StartL();
aClient.GetConfig(config, active->iStatus);
@@ -1000,7 +1011,7 @@
TEST(config.iMaxEventAge == KTestMaxEventAge);
CleanupStack::PopAndDestroy(); // active
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -1024,7 +1035,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
error = aClient.GetString(str, R_LOG_DIR_IN);
@@ -1037,11 +1049,11 @@
}
else
{
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
TEST(str.Length() == 0);
}
}
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
@@ -1144,7 +1156,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
#ifdef SYMBIAN_ENABLE_EVENTLOGGER_DUALSIM
if(aUseSimId)
@@ -1165,7 +1178,7 @@
if (active->iStatus == KErrNone)
finished = ETrue;
else
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
active->StartL();
@@ -1206,7 +1219,7 @@
TEST2(active->iStatus.Int(), KErrNotFound);
CleanupStack::PopAndDestroy(5); // event4, event3, event2, event1, active
- TheTest.Printf(_L("The test has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
void doTestsL()
@@ -1216,7 +1229,7 @@
TheTest.Start(_L("Construction + create db"));
TestUtils::DeleteDatabaseL();
TestConstructionL(); // Creates database
- TheTest.Next(_L("Construction + open db"));
+ TheTest.Next(_L("Construction + open db"));
TestConstructionL(); // Opens existing database
TestUtils::DeleteDatabaseL();
theLog.Write(_L8("Test 1 OK\n"));
--- a/loggingservices/eventlogger/test/src/t_logutil.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/src/t_logutil.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -14,6 +14,9 @@
//
#include "t_logutil.h"
+//Define "TheTest" variable used in the test cpp files
+extern RTest TheTest;
+
TPtrC FileName(const TText* aFile)
{
TPtrC p(aFile);
--- a/loggingservices/eventlogger/test/src/t_logutil2.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/src/t_logutil2.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -16,6 +16,9 @@
#include <bautils.h>
#include "t_logutil2.h"
+//Define "TheTest" variable used in the test cpp files
+extern RTest TheTest;
+
_LIT(KHelperExeName, "t_LogHiCapHelper.exe");
//======================================================================================================
@@ -889,10 +892,6 @@
static void Cleanup(void*)
{
TRAP_IGNORE(TestUtils::DeleteDatabaseL());
- _LIT(KCntModelFileName, "c:\\system\\data\\CntModel.ini");
- ::DeleteDataFile(KCntModelFileName);
- _LIT(KContactsFileName, "c:\\system\\data\\Contacts.cdb");
- ::DeleteDataFile(KContactsFileName);
::DeleteDataFile(theLogName);
}
--- a/loggingservices/eventlogger/test/src/t_logviewfail2.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/src/t_logviewfail2.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -65,7 +65,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->SetFilterL(*filter, active->iStatus));
@@ -86,25 +87,25 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
}
- TheTest.Printf(_L("Test-1 has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-1 has succeeded at iteration %d\n"), failCount);
list->AppendL(filter);
CleanupStack::Pop(); // filter
@@ -120,7 +121,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->SetFilterL(*list, active->iStatus));
@@ -141,20 +143,20 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
@@ -163,7 +165,7 @@
list->ResetAndDestroy();
CleanupStack::PopAndDestroy(4); // list, view, event, active
- TheTest.Printf(_L("Test-2 has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-2 has succeeded at iteration %d\n"), failCount);
}
/**
@@ -206,7 +208,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->SetRecentListL(KLogRecentIncomingCalls, active->iStatus));
@@ -225,25 +228,25 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
}
- TheTest.Printf(_L("Test-1 has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-1 has succeeded at iteration %d\n"), failCount);
CLogFilterList* list = new(ELeave)CLogFilterList;
CleanupStack::PushL(list);
@@ -257,7 +260,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->SetRecentListL(KLogRecentIncomingCalls, *filter, active->iStatus));
@@ -276,25 +280,25 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
}
- TheTest.Printf(_L("Test-2 has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-2 has succeeded at iteration %d\n"), failCount);
list->AppendL(filter);
CleanupStack::Pop(); // filter
@@ -310,7 +314,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->SetRecentListL(KLogRecentIncomingCalls, *list, active->iStatus));
@@ -329,20 +334,20 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
@@ -351,7 +356,7 @@
list->ResetAndDestroy();
CleanupStack::PopAndDestroy(4); // list, view, event, active
- TheTest.Printf(_L("Test-3 has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-3 has succeeded at iteration %d\n"), failCount);
}
/**
@@ -409,7 +414,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->DuplicatesL(*duplicate, active->iStatus));
@@ -428,25 +434,25 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
}
- TheTest.Printf(_L("Test-1 has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-1 has succeeded at iteration %d\n"), failCount);
CLogFilterList* list = new(ELeave)CLogFilterList;
CleanupStack::PushL(list);
@@ -460,7 +466,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->DuplicatesL(*duplicate, *filter, active->iStatus));
@@ -479,25 +486,25 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
}
- TheTest.Printf(_L("Test-2 has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-2 has succeeded at iteration %d\n"), failCount);
list->AppendL(filter);
CleanupStack::Pop(); // filter
@@ -513,7 +520,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->DuplicatesL(*duplicate, *list, active->iStatus));
@@ -532,20 +540,20 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
@@ -554,7 +562,7 @@
list->ResetAndDestroy();
CleanupStack::PopAndDestroy(5); // list, duplicate, view, event, active
- TheTest.Printf(_L("Test-3 has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-3 has succeeded at iteration %d\n"), failCount);
}
/**
@@ -601,7 +609,8 @@
TEST(view->CountL() > 1);
event->CopyL(view->Event());
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->NextL(active->iStatus));
@@ -620,25 +629,25 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
}
- TheTest.Printf(_L("Test-1 (\"View Next\") has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-1 (\"View Next\") has succeeded at iteration %d\n"), failCount);
failCount = 0;
finished = EFalse;
@@ -658,7 +667,8 @@
event->CopyL(view->Event());
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->PreviousL(active->iStatus));
@@ -677,25 +687,25 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
}
- TheTest.Printf(_L("Test-2 (\"View Previous\") has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-2 (\"View Previous\") has succeeded at iteration %d\n"), failCount);
failCount = 0;
finished = EFalse;
@@ -715,7 +725,8 @@
event->CopyL(view->Event());
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->FirstL(active->iStatus));
@@ -734,25 +745,25 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
}
- TheTest.Printf(_L("Test-3 (\"View First\") has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-3 (\"View First\") has succeeded at iteration %d\n"), failCount);
failCount = 0;
finished = EFalse;
@@ -772,7 +783,8 @@
event->CopyL(view->Event());
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TBool result = EFalse;
TRAP(error, result = view->LastL(active->iStatus));
@@ -791,20 +803,20 @@
}
else
{
- if(active->iStatus.Int() != KErrGeneral)
+ if(active->iStatus.Int() != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
- TEST2(active->iStatus.Int(), KErrGeneral);
+ TEST2(active->iStatus.Int(), KErrNoMemory);
}
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
@@ -812,7 +824,7 @@
CleanupStack::PopAndDestroy(4); // filter, view, event, active
- TheTest.Printf(_L("Test-4 (\"View Last\") has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nTest-4 (\"View Last\") has succeeded at iteration %d\n"), failCount);
}
/**
@@ -856,7 +868,8 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TInt result = 0;
TRAP(error, result = view->CountL());
@@ -868,11 +881,11 @@
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
__FILE_RESET;
@@ -880,7 +893,7 @@
CleanupStack::PopAndDestroy(4); // filter, view, event, active
- TheTest.Printf(_L("The test (\"View Count\") has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test (\"View Count\") has succeeded at iteration %d\n"), failCount);
}
/**
@@ -943,14 +956,9 @@
while(!finished)
{
- // This failCount value causes DBMS to return KErrCorrupt. Apparently this
- // can't actually occur in real life, so we skip this value.
- if (failCount == 9)
- {
- failCount++;
- }
- __FILE_FAILNEXT(++failCount);
-
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
+
TRAP(error, view->RemoveL(view->Event().Id()));
__FILE_RESET;
@@ -964,7 +972,7 @@
CActiveScheduler::Start();
if(active->iStatus.Int() != KErrNone)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
TEST2(active->iStatus.Int(), KErrNone);
@@ -972,16 +980,24 @@
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
+ }
+ // This failCount value causes DBMS to return KErrCorrupt. Apparently this
+ // can't actually occur in real life, so we skip this value.
+ if (failCount > 9)
+ {
+ finished = ETrue;
+ TRAP(error, view->RemoveL(view->Event().Id()));
+ TEST2(error, KErrNone);
}
}
CleanupStack::PopAndDestroy(3); // view, event, active
- TheTest.Printf(_L("The test (\"View Remove\") has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test (\"View Remove\") has succeeded at iteration %d\n"), failCount);
}
/**
@@ -1055,14 +1071,15 @@
while(!finished)
{
- __FILE_FAILNEXT(++failCount);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
- if(failCount == 7)
+ if(failCount == 17)
{
__FILE_RESET;
break;
}
-
+
TRAP(error, duplicate->RemoveL(duplicate->Event().Id()));
__FILE_RESET;
@@ -1076,7 +1093,7 @@
CActiveScheduler::Start();
if(active->iStatus.Int() != KErrNone)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, active->iStatus.Int());
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, active->iStatus.Int());
}
TEST2(active->iStatus.Int(), KErrNone);
@@ -1084,16 +1101,16 @@
}
else
{
- if(error != KErrGeneral)
+ if(error != KErrNoMemory)
{
- TheTest.Printf(_L("Iter.step: %d, error %d\n"), failCount, error);
+ TheTest.Printf(_L("\r\nIter.step: %d, error %d\n"), failCount, error);
}
- TEST2(error, KErrGeneral);
+ TEST2(error, KErrNoMemory);
}
}
CleanupStack::PopAndDestroy(4); // duplicate, view, event, active
- TheTest.Printf(_L("The test (\"View Remove Duplicates\") has succeeded at iteration %d\n"), failCount);
+ TheTest.Printf(_L("\r\nThe test (\"View Remove Duplicates\") has succeeded at iteration %d\n"), failCount);
}
void doTestsL()
--- a/loggingservices/eventlogger/test/src/t_logwrap.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/src/t_logwrap.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -277,7 +277,8 @@
while(!finished)
{
- __FILE_FAILNEXT(failCount++);
+ TheTest.Printf(_L("%d \r"), failCount);
+ __FILE_FAILNEXT(KErrNoMemory, failCount++);
TRAP(error, wrapper = CLogWrapper::NewL(theFs));
@@ -291,8 +292,11 @@
delete wrapper;
}
else
- TEST2(error, KErrGeneral);
+ {
+ TEST2(error, KErrNoMemory);
+ }
}
+ TheTest.Printf(_L("\r\nThe test has succeeded at iteration %d\n"), failCount);
}
/**
--- a/loggingservices/eventlogger/test/tef/group/logengteftests.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/eventlogger/test/tef/group/logengteftests.iby Tue Aug 31 16:57:14 2010 +0300
@@ -19,14 +19,6 @@
#include <testexecute.iby>
#include <burtestserver.iby>
-#include <connectivity_securebackupengine.iby>
-// the backup engine is dependant on all of these:
-#include <swi.iby>
-#include <certman.iby>
-#include <filetokens.iby>
-#include <httpcore.iby>
-#include <tls.iby>
-#include <ResponseMsg.iby>
file=ABI_DIR\BUILD_DIR\teflogengbur.exe sys\bin\teflogengbur.exe
--- a/loggingservices/filelogger/TSRC/T_LOG.CPP Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/filelogger/TSRC/T_LOG.CPP Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 1997-2010 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"
@@ -64,40 +64,15 @@
LOCAL_C TInt DeleteFolder(const TDesC& aFolder)
{
-
- TUint temp;
- _LIT(KLogDir,"c:\\Logs\\");
- TInt ret=fs.Att(KLogDir,temp);
- if (ret==KErrPathNotFound)
- return KErrNone;
- else
- {
- TInt exists=fs.Att(aFolder,temp);
- if (exists==KErrPathNotFound)
- return KErrNone;
-
- if (exists!=KErrNotFound)
- {
- TFileName file1=aFolder;
- file1.Append(KTestLogFileName1);
- ret=fs.Delete(file1);
- if (ret!=KErrNone && ret!=KErrNotFound)
- return ret;
- TFileName file2=aFolder;
- file2.Append(KTestLogFileName1);
- ret=fs.Delete(file2);
- if (ret!=KErrNone && ret!=KErrNotFound)
- return ret;
- }
-
- CFileMan* fileman=NULL;
- TRAP(ret,fileman=CFileMan::NewL(fs));
- TFileName folder;
- folder.Copy(aFolder.Left(aFolder.Length()-1));
- ret=fileman->RmDir(folder);
- delete fileman;
- return ret;
- }
+ CFileMan* fileman=NULL;
+ TRAPD(ret,fileman=CFileMan::NewL(fs));
+ ret=fileman->RmDir(aFolder);
+ delete fileman;
+ if (ret==KErrPathNotFound || ret==KErrNotFound)
+ {
+ return KErrNone;
+ }
+ return ret;
}
LOCAL_C void CreateFolderL(const TDesC& aFolder)
--- a/loggingservices/filelogger/group/BLD.INF Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/filelogger/group/BLD.INF Tue Aug 31 16:57:14 2010 +0300
@@ -23,8 +23,8 @@
PRJ_EXPORTS
-../INC/FLOGGER.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(flogger.h)
-../INC/FLOGGER.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(flogger.inl)
+../INC/FLOGGER.H OS_LAYER_PUBLIC_EXPORT_PATH(flogger.h)
+../INC/FLOGGER.INL OS_LAYER_PUBLIC_EXPORT_PATH(flogger.inl)
../group/flogger.iby /epoc32/rom/include/flogger.iby
--- a/loggingservices/rfilelogger/Logger/Group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/rfilelogger/Logger/Group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -16,10 +16,10 @@
#include "../te_RFileLogger/group/bld.inf"
PRJ_EXPORTS
-../inc/RFileLogger.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(test/rfilelogger.h)
-../inc/RFileLoggermacro.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(test/rfileloggermacro.h)
-../Group/RFilelogger.iby /epoc32/rom/include/rfilelogger.iby
+../inc/RFileLogger.h OS_LAYER_PLATFORM_EXPORT_PATH(test/rfilelogger.h)
+../inc/RFileLoggermacro.h OS_LAYER_PLATFORM_EXPORT_PATH(test/rfileloggermacro.h)
+RFilelogger.iby /epoc32/rom/include/rfilelogger.iby
+
PRJ_MMPFILES
RFileLoggerServer.mmp
RFileloggerclient.mmp
-
--- a/loggingservices/rfilelogger/Logger/Src/Client.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/rfilelogger/Logger/Src/Client.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -288,7 +288,8 @@
}
/*----------------- End of Maintaince warning section --------------------------*/
- TRAPD(err,WriteL(ptr));
+ TRAP_IGNORE(WriteL(ptr));
+
delete buffer;
}
@@ -305,7 +306,7 @@
TPtr8 ptr(buffer->Des());
AddTime(ptr);
ptr.Append(aLogBuffer);
- TRAPD(err,WriteL(ptr));
+ TRAP_IGNORE(WriteL(ptr));
CleanupStack::PopAndDestroy(buffer);
}
--- a/loggingservices/rfilelogger/Logger/Src/Main.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/rfilelogger/Logger/Src/Main.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -69,7 +69,7 @@
{
return KErrNoMemory;
}
- TRAPD(err,MainL());
+ TRAP_IGNORE(MainL());
delete cleanup;
__UHEAP_MARKEND;
return KErrNone;
--- a/loggingservices/rfilelogger/Logger/Src/Server.Cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/rfilelogger/Logger/Src/Server.Cpp Tue Aug 31 16:57:14 2010 +0300
@@ -382,27 +382,28 @@
aCount[0]=0;
TInt posI(0);
-// retrive log message:
+ // retrive log message:
// Retrive common part of log message:
- for(TInt i = 1; i<6; i++)
+ TInt i=0;
+ for(i=1; i<6; i++)
{
SearchBuf.Set(aPtr.Mid(posI));
aCount[i]=SearchBuf.Find(KSeperation8)+posI;
posI=aCount[i]+3;
if(aCount[i]<aCount[i-1])
- {
- delete pBuf1;
- return; // wrong format string from client
- }
+ {
+ delete pBuf1;
+ return; // wrong format string from client
+ }
}
// seperating common log message and extra log fields will be easy for future maintaince.
TLogField8* alogField = new TLogField8[6]; // the common part of log message for both
// with and without extra log fields
if(!alogField)
- {
- delete pBuf1;
- return; // no memory
- }
+ {
+ delete pBuf1;
+ return; // no memory
+ }
TLogField8* extralogField=NULL; // only applied to extra log fields
@@ -416,7 +417,7 @@
alogField[5].iLogTag8.Copy(_L8("TEXT"));
alogField[0].iLogValue8.Copy(aPtr.Mid(aCount[0],aCount[1]-aCount[0]));
- for(TInt i=1; i<5; i++)
+ for(i=1; i<5; i++)
{
alogField[i].iLogValue8.Copy(aPtr.Mid(aCount[i]+3,aCount[i+1]-aCount[i]-3));
}
@@ -428,22 +429,23 @@
alogField[5].iLogValue8.Copy(aPtr.Mid(aCount[5]+3,aDes.Length()-aCount[5]-5));
}
else
- {
+ {
alogField[5].iLogValue8.Copy(aPtr.Mid(aCount[5]+3,aCount[6]-aCount[5]-5));
posI=aCount[6]+45; //45 is from the length of long string and a tab
SearchBuf.Set(aPtr.Mid(posI));
aCount[7]=SearchBuf.Find(_L8("\r\n"))+posI;
TLex8 lex(aPtr.Mid(posI,aCount[7]-posI)); // get the length
TInt err=lex.Val(alength);
- if (err) alength=0; // ignor the extra log fields. Let the log go
+ if (err)
+ alength=0; // ignor the extra log fields. Let the log go
// Retrive the extra log fields
extralogField = new TLogField8[alength];
if(!extralogField)
- {
- delete pBuf1;
- return; // no memory
- }
+ {
+ delete pBuf1;
+ return; // no memory
+ }
for(TInt i=0; i<alength; i++)
{
aCount[6]=aCount[7]+2;
@@ -455,65 +457,63 @@
aCount[7]=SearchBuf.Find(_L8("\r\n"))+aCount[6];
extralogField[i].iLogValue8.Copy(aPtr.Mid(aCount[6],aCount[7]-aCount[6]));
}
- }
-
- // Start to organize an XML format:
- TInt afileSize;
- _LIT(KLogMutex, "LoggingServerMutex");
- RMutex mutex;
- TInt r = mutex.CreateGlobal(KLogMutex);
- if(r==KErrAlreadyExists)
- r = mutex.OpenGlobal(KLogMutex);
-
- if(!r) mutex.Wait(); // if still failed, let logging go
- //without bother the mutex
-
- iLogFile.Size(afileSize);
- if(afileSize<12) // 12 is from charters of "\r\n</LOGFILE>"
- //It shoud happened once at the beginning of the file
- // such as overwrite mode
- {
- afileSize=12; // used for lock position
- alogbuf.Copy(KxmlHeader);
- }
- alogbuf.Append(_L8("\r\n<MESSAGE>\r\n"));
- for(TInt i=0; i<6; i++)
- {
- alogbuf.Append(_L8(" <"));
- alogbuf.Append(alogField[i].iLogTag8);
- alogbuf.Append(_L8(">"));
- alogbuf.Append(alogField[i].iLogValue8);
- alogbuf.Append(_L8("</"));
- alogbuf.Append(alogField[i].iLogTag8);
- alogbuf.Append(_L8(">\r\n"));
- }
- for(TInt i=0; i<alength; i++)
- {
- alogbuf.Append(_L8(" <"));
- alogbuf.Append(extralogField[i].iLogTag8);
- alogbuf.Append(_L8(">"));
- alogbuf.Append(extralogField[i].iLogValue8);
- alogbuf.Append(_L8("</"));
- alogbuf.Append(extralogField[i].iLogTag8);
- alogbuf.Append(_L8(">\r\n"));
- }
-
- alogbuf.Append(_L8("</MESSAGE>"));
- alogbuf.Append(_L8("\r\n</LOGFILE>"));
-
- iLogFile.Write(afileSize-12, alogbuf,iStatus);
-
-
- if(!r)
- {
- mutex.Signal();
- mutex.Close();
- }
-
- if(extralogField) delete[] extralogField;
+ }
+ // Start to organize an XML format:
+ TInt afileSize;
+ _LIT(KLogMutex, "LoggingServerMutex");
+ RMutex mutex;
+ TInt r = mutex.CreateGlobal(KLogMutex);
+ if(r==KErrAlreadyExists)
+ r = mutex.OpenGlobal(KLogMutex);
+
+ if(!r)
+ mutex.Wait(); // If still failed, let logging go without bother the mutex.
+ iLogFile.Size(afileSize);
+ if(afileSize<12) // 12 is from charters of "\r\n</LOGFILE>"
+ //It shoud happened once at the beginning of the file
+ // such as overwrite mode
+ {
+ afileSize=12; // used for lock position
+ alogbuf.Copy(KxmlHeader);
+ }
+ alogbuf.Append(_L8("\r\n<MESSAGE>\r\n"));
+ for(TInt i=0; i<6; i++)
+ {
+ alogbuf.Append(_L8(" <"));
+ alogbuf.Append(alogField[i].iLogTag8);
+ alogbuf.Append(_L8(">"));
+ alogbuf.Append(alogField[i].iLogValue8);
+ alogbuf.Append(_L8("</"));
+ alogbuf.Append(alogField[i].iLogTag8);
+ alogbuf.Append(_L8(">\r\n"));
+ }
+ for(TInt i=0; i<alength; i++)
+ {
+ alogbuf.Append(_L8(" <"));
+ alogbuf.Append(extralogField[i].iLogTag8);
+ alogbuf.Append(_L8(">"));
+ alogbuf.Append(extralogField[i].iLogValue8);
+ alogbuf.Append(_L8("</"));
+ alogbuf.Append(extralogField[i].iLogTag8);
+ alogbuf.Append(_L8(">\r\n"));
+ }
+
+ alogbuf.Append(_L8("</MESSAGE>"));
+ alogbuf.Append(_L8("\r\n</LOGFILE>"));
+
+ iLogFile.Write(afileSize-12, alogbuf,iStatus);
+
+ if(!r)
+ {
+ mutex.Signal();
+ mutex.Close();
+ }
+
+ if(extralogField)
+ delete[] extralogField;
+
delete[] alogField;
delete pBuf1;
-
}
void CLogFileControl::WriteTxt(const TDesC8 &aDes)
--- a/loggingservices/rfilelogger/Logger/te_RFileLogger/group/Te_RFileLoggersuite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/rfilelogger/Logger/te_RFileLogger/group/Te_RFileLoggersuite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -13,31 +13,22 @@
// Description:
//
- TARGET Te_RFileLoggerSuite.exe
- TARGETTYPE exe
- UID 0x1000007A 0x102089CD
-
-//Please add any change under here
-SOURCEPATH ..\src
-SOURCE Te_RFileLoggerSuiteServer.cpp
-SOURCE Te_RFileLoggerSuiteStepBase.cpp
-SOURCE addfield_logStep.cpp
-SOURCE conn_closeStep.cpp
-
+TARGET te_rfileloggersuite.exe
+TARGETTYPE exe
+UID 0x1000007A 0x102089CD
-USERINCLUDE ..\src
-
-SYSTEMINCLUDE \epoc32\include
-SYSTEMINCLUDE \epoc32\include\test
-
-//Please add your system include under here.
+SOURCEPATH ../src
+SOURCE Te_RFileLoggerSuiteServer.cpp
+SOURCE Te_RFileLoggerSuiteStepBase.cpp
+SOURCE addfield_logStep.cpp
+SOURCE conn_closeStep.cpp
-LIBRARY euser.lib
-LIBRARY testexecuteutils.lib
-LIBRARY testexecutelogclient.lib
+USERINCLUDE ../src
+OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-//Please add your libraries under here.
-LIBRARY RFileLoggerclient.lib
-
+LIBRARY euser.lib
+LIBRARY testexecuteutils.lib
+LIBRARY testexecutelogclient.lib
+LIBRARY rfileloggerclient.lib
CAPABILITY ALL -Tcb
--- a/loggingservices/rfilelogger/Logger/te_RFileLogger/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/rfilelogger/Logger/te_RFileLogger/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -14,19 +14,10 @@
//
PRJ_TESTEXPORTS
-../scripts/te_RFileLoggerSuite.script /epoc32/release/wins/udeb/z/testdata/scripts/te_rfileloggersuite.script
-../scripts/te_RFileLoggerSuite.script /epoc32/release/wins/urel/z/testdata/scripts/te_rfileloggersuite.script
-../scripts/te_RFileLoggerSuite.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_rfileloggersuite.script
-../scripts/te_RFileLoggerSuite.script /epoc32/release/winscw/urel/z/testdata/scripts/te_rfileloggersuite.script
+../scripts/te_RFileLoggerSuite.script z:/testdata/scripts/te_rfileloggersuite.script
+../testdata/te_RFileLoggersuite.ini z:/testdata/configs/te_rfileloggersuite.ini
-../testdata/te_RFileLoggersuite.ini /epoc32/release/wins/udeb/z/testdata/configs/te_rfileloggersuite.ini
-../testdata/te_RFileLoggersuite.ini /epoc32/release/wins/urel/z/testdata/configs/te_rfileloggersuite.ini
-../testdata/te_RFileLoggersuite.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_rfileloggersuite.ini
-../testdata/te_RFileLoggersuite.ini /epoc32/release/winscw/urel/z/testdata/configs/te_rfileloggersuite.ini
-
-
-./te_RFileLoggersuite.iby /epoc32/rom/include/te_rfileloggersuite.iby
-
+te_RFileLoggersuite.iby /epoc32/rom/include/te_rfileloggersuite.iby
PRJ_TESTMMPFILES
-Te_RFileLoggersuite.mmp
+Te_RFileLoggersuite.mmp manual
--- a/loggingservices/rfilelogger/Logger/te_RFileLogger/group/te_RFileLoggersuite.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/rfilelogger/Logger/te_RFileLogger/group/te_RFileLoggersuite.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2009-2010 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"
@@ -20,8 +20,8 @@
#include <testexecute.iby>
-file=ABI_DIR\DEBUG_DIR\Te_RFileLoggerSuite.exe System\bin\te_RFileLoggerSuite.exe
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TestData\configs\te_RFileLoggerSuite.ini TestData\configs\te_RFileLoggerSuite.ini
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TestData\scripts\te_RFileLoggerSuite.script TestData\Scripts\te_RFileLoggerSuite.Script
+file=ABI_DIR\DEBUG_DIR\te_rfileloggersuite.exe system\bin\te_rfileloggersuite.exe
+data=DATAZ_\testdata\configs\te_rfileloggersuite.ini testdata\configs\te_rfileloggersuite.ini
+data=DATAZ_\testdata\scripts\te_rfileloggersuite.script testdata\Scripts\te_rfileloggersuite.script
-#endif
+#endif // __TE_RFILELOGGER_SUITE_IBY__
--- a/loggingservices/rfilelogger/Logger/te_RFileLogger/src/Te_RFileLoggerSuiteServer.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/rfilelogger/Logger/te_RFileLogger/src/Te_RFileLoggerSuiteServer.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -90,7 +90,7 @@
{
return KErrNoMemory;
}
- TRAPD(err,MainL());
+ TRAP_IGNORE(MainL());
delete cleanup;
__UHEAP_MARKEND;
return KErrNone;
--- a/loggingservices/rfilelogger/Logger/te_RFileLogger/src/addfield_logStep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/loggingservices/rfilelogger/Logger/te_RFileLogger/src/addfield_logStep.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,6 @@
#include "addfield_logStep.h"
#include "Te_RFileLoggerSuiteDefs.h"
-_LIT(K16BitText,"This is a short line of 16 Bit Text");
_LIT(K16BitFormatText,"logger string int = %d, string = %S");
_LIT(K16BitString,"The String16");
--- a/package_definition.xml Thu Aug 19 11:36:21 2010 +0300
+++ b/package_definition.xml Tue Aug 31 16:57:14 2010 +0300
@@ -13,7 +13,7 @@
<component id="eventlogger" name="Event Logger" introduced="6.0" purpose="optional">
<unit bldFile="loggingservices/eventlogger/group" mrp="loggingservices/eventlogger/group/syslibs_logeng.mrp"/>
</component>
- <component id="filelogger" name="File Logger" introduced="ER5" purpose="optional">
+ <component id="filelogger" name="File Logger" introduced="ER5" deprecated="^3" purpose="optional">
<unit bldFile="loggingservices/filelogger/group" mrp="loggingservices/filelogger/group/comms-infras_flogger.mrp"/>
</component>
<component id="rfilelogger" name="RFile Logger" deprecated="^3" introduced="9.1" purpose="development">
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/package_map.xml Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,1 @@
+<PackageMap root="sf" layer="os"/>
--- a/persistentstorage/centralrepository/cenrepnotifierhandler/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/cenrepnotifierhandler/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -20,7 +20,7 @@
PRJ_EXPORTS
-../inc/cenrepnotifyhandler.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(cenrepnotifyhandler.h)
+../inc/cenrepnotifyhandler.h OS_LAYER_PUBLIC_EXPORT_PATH(cenrepnotifyhandler.h)
../rom/cenrepnotifierhandler.iby /epoc32/rom/include/cenrepnotifierhandler.iby
PRJ_MMPFILES
--- a/persistentstorage/centralrepository/cenrepnotifierhandler/rom/cenrepnotifierhandler.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/cenrepnotifierhandler/rom/cenrepnotifierhandler.iby Tue Aug 31 16:57:14 2010 +0300
@@ -18,7 +18,7 @@
#define __CENREPNOTIFHANDLER_IBY__
//file content
-file=ABI_DIR\BUILD_DIR\CENREPNOTIFHANDLER.DLL System\Libs\CENREPNOTIFHANDLER.DLL
+file=ABI_DIR\BUILD_DIR\cenrepnotifhandler.dll System\Libs\CENREPNOTIFHANDLER.DLL
#endif
--- a/persistentstorage/centralrepository/cenrepsrv/backup.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/cenrepsrv/backup.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -385,6 +385,15 @@
}
+void CRepositoryBackupClient::RestoreRepositoryAndListL(TUid repositoryUid, CDirectFileStore* store, TStreamId settingsStreamId, TStreamId deletedSettingsStreamId, TInt& repIndex)
+ {
+ // Add the restored repository to the restored repositories list.
+ // Pass its changed-keys list to further restoring functions to add entries for post-restoration notification.
+ repIndex = AddRestoredRepositoryL(repositoryUid);
+ iRepository->RestoreRepositoryContentsL(*store, settingsStreamId, deletedSettingsStreamId, *iRestoredRepositoriesArray[repIndex]);
+ iRepository->CommitChangesL();
+ }
+
//
// CRepositoryBackupClient::RestoreCompleteL
@@ -420,7 +429,6 @@
}
-
// Get the root stream and attempt to read a backup file header from it
TStreamId rootStreamId = store->Root() ;
RStoreReadStream rootStream ;
@@ -462,8 +470,8 @@
// Iterate through index and attempt restore of each repository stream
// we find in it.
- restoreStreamIndex->Reset() ;
- TUid repositoryUid ;
+ restoreStreamIndex->Reset();
+ TUid repositoryUid;
TStreamId settingsStreamId(KNullStreamIdValue);
TStreamId deletedSettingsStreamId(KNullStreamIdValue);
TStreamId installedSettingsStreamId(KNullStreamIdValue);
@@ -472,12 +480,10 @@
{
iRepository->OpenL(repositoryUid, *iNotifier, EFalse);
iRepository->FailAllTransactions();
- // Add the restored repository to the restored repositories list.
- // Pass its changed-keys list to further restoring functions to add entries for post-restoration notification.
- TInt repIndex = AddRestoredRepositoryL(repositoryUid);
- iRepository->RestoreRepositoryContentsL(*store, settingsStreamId, deletedSettingsStreamId, *iRestoredRepositoriesArray[repIndex]);
- iRepository->CommitChangesL();
+ TInt repIndex;
+ TRAPD(err, RestoreRepositoryAndListL(repositoryUid, store, settingsStreamId, deletedSettingsStreamId, repIndex));
iRepository->Close();
+ User::LeaveIfError(err);
// If the backup contains an installed repository containing default values for the settings, read them in
if (installedSettingsStreamId != KNullStreamId)
{
--- a/persistentstorage/centralrepository/cenrepsrv/backup.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/cenrepsrv/backup.h Tue Aug 31 16:57:14 2010 +0300
@@ -170,6 +170,8 @@
TUint GetDataChecksum(TDriveNumber aDrive);
void CompleteOwnerIdLookupTableL();
+ void RestoreRepositoryAndListL(TUid repositoryUid, CDirectFileStore* store, TStreamId settingsStreamId, TStreamId deletedSettingsStreamId,TInt& repIndex);
+
private:
// Usual active object stuff
void RunL() ;
--- a/persistentstorage/centralrepository/cenrepsrv/install.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/cenrepsrv/install.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 1997-2010 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 1997-2009 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"
@@ -227,110 +227,116 @@
// Find added or updated entries
ReadInstallDirL(iCurrentInstallDirEntries);
- TInt newCount=iCurrentInstallDirEntries.Count();
- TInt currentCount=iInstallEntryArray.Count();
- TInt i;
- TInt r;
- TInt operation;
-
- // If both counts are 0, we shouldn't have been notified, just return
- if( (newCount==0) && (currentCount==0))
- return;
-
- if(aStartup)
- {
- operation=ESASwisNone;
- }
- else
- {
- operation=iSWIOperation;
- }
-
// We don't want cache activity during SWI operations
TServerResources::iCacheManager->DisableCache();
- if( newCount==0) // currentCount > 0, newCount = 0
- { // All installed files have been deleted
- // Handle deletes of all files
- for(i=0;i<currentCount;i++)
- {
- iInstallEntryArray[i]->HandleFileDeleteL(operation);
- }
- // Free memory of elements
- iInstallEntryArray.ResetAndDestroy();
- }
- else
- {
- if( currentCount==0) // currentCount = 0, newCount > 0
- { // All new files need to be handled
- for(i=0;i<newCount;i++)
- {
- CInstallEntry* newEntry=iCurrentInstallDirEntries[i];
- newEntry->HandleFileCreateL(operation);
- }
- }
- else // currentCount > 0, newCount > 0
- {
- // Find added and modified entries by going through new entries and
- // looking for them in current array
- for(i=0;i<newCount;i++)
- {
- CInstallEntry* newEntry=iCurrentInstallDirEntries[i];
- r=iInstallEntryArray.Find( newEntry, MatchEntries);
- // If we find new entry in current array, check modification date
- if(r>=KErrNone)
- {
- CInstallEntry* currentEntry=iInstallEntryArray[r];
- if( newEntry->Modified() > currentEntry->Modified())
- {
- // Deal with newly installed file, note use newEntry
- // so we use new timestamp
- newEntry->HandleFileUpdateL(operation);
- }
- }
- else if(r==KErrNotFound) // File has been added
- {
- // Handle add
- newEntry->HandleFileCreateL(operation);
- // Don't leave on KErrNotFound
- r=KErrNone;
- }
- User::LeaveIfError(r);
- }
-
- // Find deleted entries by going through current entries and looking for them
- // in new array
- for(i=0;i<currentCount;i++)
- {
- CInstallEntry* currentEntry=iInstallEntryArray[i];
- r=iCurrentInstallDirEntries.Find( currentEntry, MatchEntries);
- // If we don't find current entry in new array, it's been deleted
- if(r==KErrNotFound)
- {
- // Deal with uninstalls
- currentEntry->HandleFileDeleteL(operation);
- // Don't leave on KErrNotFound
- r=KErrNone;
- }
- User::LeaveIfError(r);
- }
- }
-
- // Clear out old list
- iInstallEntryArray.ResetAndDestroy();
-
- // Re-read directory - if any files were corrupt they have been deleted
- // during the merge, so we need to re-read in case this has occurred
- ReadInstallDirL(iInstallEntryArray);
- }
-
- SaveInstallDirL();
- iCurrentInstallDirEntries.ResetAndDestroy();
+ TRAPD(err, HandleFileChangesL(aStartup));
// SWI operations finished, enable cache
- TServerResources::iCacheManager->EnableCache();
+ TServerResources::iCacheManager->EnableCache();
+ User::LeaveIfError(err);
}
+void CCentRepSWIWatcher::HandleFileChangesL(TBool aStartup)
+ {
+ TInt newCount=iCurrentInstallDirEntries.Count();
+ TInt currentCount=iInstallEntryArray.Count();
+ TInt i;
+ TInt r;
+ TInt operation;
+
+ // If both counts are 0, we shouldn't have been notified, just return
+ if( (newCount==0) && (currentCount==0))
+ return;
+
+ if(aStartup)
+ {
+ operation=ESASwisNone;
+ }
+ else
+ {
+ operation=iSWIOperation;
+ }
+
+ if( newCount==0) // currentCount > 0, newCount = 0
+ { // All installed files have been deleted
+ // Handle deletes of all files
+ for(i=0;i<currentCount;i++)
+ {
+ iInstallEntryArray[i]->HandleFileDeleteL(operation);
+ }
+ // Free memory of elements
+ iInstallEntryArray.ResetAndDestroy();
+ }
+ else
+ {
+ if( currentCount==0) // currentCount = 0, newCount > 0
+ { // All new files need to be handled
+ for(i=0;i<newCount;i++)
+ {
+ CInstallEntry* newEntry=iCurrentInstallDirEntries[i];
+ newEntry->HandleFileCreateL(operation);
+ }
+ }
+ else // currentCount > 0, newCount > 0
+ {
+ // Find added and modified entries by going through new entries and
+ // looking for them in current array
+ for(i=0;i<newCount;i++)
+ {
+ CInstallEntry* newEntry=iCurrentInstallDirEntries[i];
+ r=iInstallEntryArray.Find( newEntry, MatchEntries);
+ // If we find new entry in current array, check modification date
+ if(r>=KErrNone)
+ {
+ CInstallEntry* currentEntry=iInstallEntryArray[r];
+ if( newEntry->Modified() > currentEntry->Modified())
+ {
+ // Deal with newly installed file, note use newEntry
+ // so we use new timestamp
+ newEntry->HandleFileUpdateL(operation);
+ }
+ }
+ else if(r==KErrNotFound) // File has been added
+ {
+ // Handle add
+ newEntry->HandleFileCreateL(operation);
+ // Don't leave on KErrNotFound
+ r=KErrNone;
+ }
+ User::LeaveIfError(r);
+ }
+
+ // Find deleted entries by going through current entries and looking for them
+ // in new array
+ for(i=0;i<currentCount;i++)
+ {
+ CInstallEntry* currentEntry=iInstallEntryArray[i];
+ r=iCurrentInstallDirEntries.Find( currentEntry, MatchEntries);
+ // If we don't find current entry in new array, it's been deleted
+ if(r==KErrNotFound)
+ {
+ // Deal with uninstalls
+ currentEntry->HandleFileDeleteL(operation);
+ // Don't leave on KErrNotFound
+ r=KErrNone;
+ }
+ User::LeaveIfError(r);
+ }
+ }
+
+ // Clear out old list
+ iInstallEntryArray.ResetAndDestroy();
+
+ // Re-read directory - if any files were corrupt they have been deleted
+ // during the merge, so we need to re-read in case this has occurred
+ ReadInstallDirL(iInstallEntryArray);
+ }
+
+ SaveInstallDirL();
+ iCurrentInstallDirEntries.ResetAndDestroy();
+ }
+
CInstallEntry::CInstallEntry() :
iUid(KNullUid),
iModified(0),
--- a/persistentstorage/centralrepository/cenrepsrv/install.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/cenrepsrv/install.h Tue Aug 31 16:57:14 2010 +0300
@@ -60,7 +60,7 @@
void Start();
~CCentRepSWIWatcher();
void HandleSWIEventL(TInt swiProperty);
- void FindChangedEntriesL(TBool aStartup=EFalse);
+ void FindChangedEntriesL(TBool aStartup=EFalse);
//From CActive
protected:
void RunL();
@@ -72,11 +72,11 @@
void ConstructL();
void ReadInstallDirL(RPointerArray<CInstallEntry>& aEntryArray);
-
void SaveInstallDirL();
void GetInstallDirL();
void ReadAndInternalizeInstallDirL(const TDesC& aInstallDirFilePath);
+ void HandleFileChangesL(TBool aStartup);
static TBool MatchEntries(const CInstallEntry &aSource, const CInstallEntry &aTarget);
--- a/persistentstorage/centralrepository/cenrepsrv/obsrvr_noc.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/cenrepsrv/obsrvr_noc.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -704,29 +704,23 @@
TInt biggestBlock;
TInt firstAvail = myHeap.Available(biggestBlock);
- aRepository = CSharedRepository::NewL(aUid);
+ TRAPD(err, aRepository = CSharedRepository::NewL(aUid));
#ifdef CACHE_OOM_TESTABILITY
- if ((aRepository==NULL)&&!iTrapOOMOnOpen)
+ if ((err!=KErrNone)&&!iTrapOOMOnOpen)
{
- User::Leave(KErrNoMemory);
+ User::Leave(err);
}
#endif
- if ((aRepository==NULL)&&TServerResources::iCacheManager->Enabled())
+ if ((err!=KErrNone)&&TServerResources::iCacheManager->Enabled())
{
// If cache enabled, try recovery by releasing the cache
TServerResources::iCacheManager->FlushCache(EFalse);
// retry
aRepository = CSharedRepository::NewL(aUid);
+ err = KErrNone;
}
- // If still no memory, return error
- if (aRepository==NULL)
- {
- User::Leave(KErrNoMemory);
- }
- else // successfully created the object, so push it into the cleanup stack
- {
- CleanupStack::PushL(aRepository);
- }
+ User::LeaveIfError(err);
+ CleanupStack::PushL(aRepository);
// Now that we have enough memory for the object and constructed it properly
// we try to load it. We trap all errors, either from leaving functions or error code
--- a/persistentstorage/centralrepository/cenrepsrv/srvrepos_noc.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/cenrepsrv/srvrepos_noc.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -32,12 +32,25 @@
{
iNotifier = &aObserver;
- iRepository = TServerResources::iObserver->AccessL(aUid, aFailIfNotFound);
+ TServerResources::iObserver->iObservers.ReserveL(1);
+
+ TServerResources::iObserver->AddSharedRepositoryInfoL(aUid);
+
+ TRAPD( err, iRepository = TServerResources::iObserver->AccessL(aUid, aFailIfNotFound) );
+
//store uid
- iUid = aUid;
-
- TServerResources::iObserver->AddObserverL(aUid, this);
- TServerResources::iObserver->AddSharedRepositoryInfoL(aUid);
+ iUid = aUid;
+
+ if (err == KErrNone)
+ {
+ TRAP( err, TServerResources::iObserver->AddObserverL(aUid, this) );
+ }
+
+ if (err != KErrNone)
+ {
+ TServerResources::iObserver->RemoveSharedRepositoryInfo(aUid);
+ User::Leave(err);
+ }
}
void CServerRepository::Close()
@@ -398,6 +411,7 @@
{
if(err == KErrNoMemory)
{
+ repository->Close();
User::LeaveNoMemory();
}
else
@@ -652,21 +666,27 @@
// Create install rep for merging
CSharedRepository *installRep = 0;
- TServerResources::iObserver->LoadRepositoryLC(aUid, ETrue, installRep, CIniFileIn::EInstallOnly);
+ TRAPD( err, TServerResources::iObserver->LoadRepositoryLC(aUid, ETrue, installRep, CIniFileIn::EInstallOnly); CleanupStack::Pop(installRep) );
- // Perform merge
- iRepository->HandleUpdateMergeL(aModified, *installRep);
-
- CleanupStack::PopAndDestroy(installRep);
- Close();
+ if (err == KErrNone)
+ {
+ // Perform merge
+ TRAP( err, iRepository->HandleUpdateMergeL(aModified, *installRep) );
+ }
+ if (installRep!=NULL)
+ {
+ delete installRep;
+ }
+ Close();
+ User::LeaveIfError(err);
}
else // No ROM or persists
{
// Create install rep for persisting
OpenL(aUid, aNotifier);
-
- iRepository->CommitChangesL();
- Close();
+ TRAPD(err, iRepository->CommitChangesL());
+ Close();
+ User::LeaveIfError(err);
}
}
@@ -698,13 +718,19 @@
// Create ROM rep for merging
CSharedRepository *romRep = 0;
- TServerResources::iObserver->LoadRepositoryLC(aUid, ETrue, romRep, CIniFileIn::ERomOnly);
+ TRAPD( err, TServerResources::iObserver->LoadRepositoryLC(aUid, ETrue, romRep, CIniFileIn::ERomOnly); CleanupStack::Pop(romRep) );
- // Perform merge
- iRepository->HandleDeleteMergeL(*romRep);
-
- CleanupStack::PopAndDestroy(romRep);
+ if (err == KErrNone)
+ {
+ // Perform merge
+ TRAP( err, iRepository->HandleDeleteMergeL(*romRep) );
+ }
+ if (romRep!=NULL)
+ {
+ delete romRep;
+ }
Close();
+ User::LeaveIfError(err);
}
else // No ROM file, this is a complete uninstall
{
@@ -988,24 +1014,24 @@
iRepository = NULL;
}
-TInt CServerRepository::CheckAccessPolicyBeforeMoving(const TClientRequest& aMessage, const TServerSetting& aSourceSetting,
- TUint32 aSourceKey, const TServerSetting& aTargetSetting, TUint32 aTargetKey, TUint32& aErrorKey)
+TInt CServerRepository::CheckAccessPolicyBeforeMoving(const TClientRequest& aMessage, const TServerSetting* aSourceSetting,
+ TUint32 aSourceKey, const TServerSetting* aTargetSetting, TUint32 aTargetKey, TUint32& aErrorKey)
{
TInt error = KErrNone;
- if (&aTargetSetting && !aTargetSetting.IsDeleted())
+ if (aTargetSetting && !aTargetSetting->IsDeleted())
{
error=KErrAlreadyExists;
aErrorKey=aTargetKey;
}
- if (!aMessage.CheckPolicy(GetReadAccessPolicy(aSourceSetting),
+ if (!aMessage.CheckPolicy(GetReadAccessPolicy(*aSourceSetting),
__PLATSEC_DIAGNOSTIC_STRING("CenRep: CServerRepository::MoveL - Attempt made to read a setting")))
{
error = KErrPermissionDenied;
aErrorKey = aSourceKey;
}
- else if (!aMessage.CheckPolicy(GetWriteAccessPolicy(aSourceSetting),
+ else if (!aMessage.CheckPolicy(GetWriteAccessPolicy(*aSourceSetting),
__PLATSEC_DIAGNOSTIC_STRING("CenRep: CServerRepository::MoveL - Attempt made to delete a setting")))
{
error = KErrPermissionDenied;
@@ -1014,7 +1040,7 @@
else if (error == KErrAlreadyExists)
{
// set error to KErrPermissionDenied in preference to KErrAlreadyExists
- if (!aMessage.CheckPolicy(GetWriteAccessPolicy(aTargetSetting),
+ if (!aMessage.CheckPolicy(GetWriteAccessPolicy(*aTargetSetting),
__PLATSEC_DIAGNOSTIC_STRING("CenRep: CServerRepository::MoveL - Attempt made to create a setting")))
{
error = KErrPermissionDenied;
--- a/persistentstorage/centralrepository/cenrepsrv/srvrepos_noc.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/cenrepsrv/srvrepos_noc.h Tue Aug 31 16:57:14 2010 +0300
@@ -107,8 +107,8 @@
TInt CheckPermissions(RSettingPointerArray& aSettings, const TClientRequest& aMessage, const char* aDiagnostic,TBool aReadPolicy,TUint32& aErrId);
- TInt CheckAccessPolicyBeforeMoving(const TClientRequest& aMessage, const TServerSetting& aSourceSetting, TUint32 aSourceKey,
- const TServerSetting& aTargetSetting, TUint32 aTargetKey, TUint32& aErrorKey);
+ TInt CheckAccessPolicyBeforeMoving(const TClientRequest& aMessage, const TServerSetting* aSourceSetting, TUint32 aSourceKey,
+ const TServerSetting* aTargetSetting, TUint32 aTargetKey, TUint32& aErrorKey);
TInt CheckMovePermissions(const RSettingPointerArray& aSourceSettings,const TClientRequest& aMessage,TUint aSourceToTarget,TUint32& aErrorKey)
{
@@ -121,7 +121,7 @@
TUint32 targetKey = sourceKey ^ aSourceToTarget;
TServerSetting* targetSetting = GetSetting(targetKey);
- error = CheckAccessPolicyBeforeMoving(aMessage, *sourceSetting, sourceKey, *targetSetting, targetKey, aErrorKey);
+ error = CheckAccessPolicyBeforeMoving(aMessage, sourceSetting, sourceKey, targetSetting, targetKey, aErrorKey);
}
return error;
}
--- a/persistentstorage/centralrepository/group/CenRepFotaTvRTests.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/CenRepFotaTvRTests.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -28,8 +28,10 @@
// centrep techview test files
#ifdef SYMBIAN_BAFL_SYSUTIL
-file=ABI_DIR\BUILD_DIR\t_cenrep_fota_hw_setup.exe test\t_cenrep_fota_hw_setup.exe
-file=ABI_DIR\BUILD_DIR\t_cenrep_fota_hw_tests.exe test\t_cenrep_fota_hw_tests.exe
+ #ifdef CENTREP_MW_TESTS
+ file=ABI_DIR\BUILD_DIR\t_cenrep_fota_hw_setup.exe test\t_cenrep_fota_hw_setup.exe
+ file=ABI_DIR\BUILD_DIR\t_cenrep_fota_hw_tests.exe test\t_cenrep_fota_hw_tests.exe
+ #endif // CENTREP_MW_TESTS
#endif
#ifdef SYMBIAN_BAFL_SYSUTIL
--- a/persistentstorage/centralrepository/group/CentralRepositoryTechviewFlashPerformance.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/CentralRepositoryTechviewFlashPerformance.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -24,7 +24,9 @@
// centrep techview test files
#ifdef SYMBIAN_BAFL_SYSUTIL
// cenrep test exes
-file=ABI_DIR\BUILD_DIR\t_cenrep_fota_perf1.exe test\t_cenrep_fota_perf1.exe
+#ifdef CENTREP_MW_TESTS
+ file=ABI_DIR\BUILD_DIR\t_cenrep_fota_perf1.exe test\t_cenrep_fota_perf1.exe
+#endif // CENTREP_MW_TESTS
file=ABI_DIR\BUILD_DIR\t_cenrep_fota_perf2.exe test\t_cenrep_fota_perf2.exe
#ifndef __CENTRALREPOSITORYTECHVIEWRTESTS_IBY__
--- a/persistentstorage/centralrepository/group/CentralRepositoryTechviewRTests.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/CentralRepositoryTechviewRTests.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -19,13 +19,19 @@
REM Central Repository Tests that require Techview.
#ifdef SYMBIAN_BAFL_SYSUTIL
- #include <swicertstoredat.iby>
+ #ifdef CENTREP_MW_TESTS
+ #include <swicertstoredat.iby>
+ #endif // CENTREP_MW_TESTS
#endif // SYMBIAN_BAFL_SYSUTIL
-file=ABI_DIR\BUILD_DIR\t_cenrep_back_rest_defect.exe test\t_cenrep_back_rest_defect.exe
-
+#ifdef CENTREP_MW_TESTS
+ file=ABI_DIR\BUILD_DIR\t_cenrep_back_rest_defect.exe test\t_cenrep_back_rest_defect.exe
+#endif // CENTREP_MW_TESTS
+
#ifdef SYMBIAN_BAFL_SYSUTIL
- file=ABI_DIR\BUILD_DIR\t_cenrep_fotaut.exe test\t_cenrep_fotaut.exe
+ #ifdef CENTREP_MW_TESTS
+ file=ABI_DIR\BUILD_DIR\t_cenrep_fotaut.exe test\t_cenrep_fotaut.exe
+ #endif // CENTREP_MW_TESTS
#endif // SYMBIAN_BAFL_SYSUTIL
#ifndef __CENTREPTESTDATA_IBY__
--- a/persistentstorage/centralrepository/group/CentralRepositoryTests.bat Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/CentralRepositoryTests.bat Tue Aug 31 16:57:14 2010 +0300
@@ -1,5 +1,4 @@
-@rem
-@rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+@rem Copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies).
@rem All rights reserved.
@rem This component and the accompanying materials are made available
@rem under the terms of "Eclipse Public License v1.0"
@@ -12,18 +11,21 @@
@rem Contributors:
@rem
@rem Description:
-@rem
+@rem Batch file to run all the Central Repository textshell RTests.
+t_centrep_notifier_handler.exe
+t_cenrep_cache.exe
+t_cenrep_perf.exe
t_cenrep.exe
-t_cenrep_perf.exe
-t_cenrep_rfs.exe
t_cenreptrans.exe
t_cenrep_platsec.exe
t_cenrep_preq752.exe
t_cenrep_transactions.exe
t_cenrep_defects.exe
+t_cenrep_meta.exe
+t_cenrep_rfs.exe
t_cenrep_back_rest.exe
t_cenrep_back_rest_delete.exe
t_oomcenrepsrv.exe
-t_cenrep_cache.exe
-t_cenrep_preq2112.exe
\ No newline at end of file
+t_cenrep_preq2112u.exe
+t_cenrep_preq2112.exe
--- a/persistentstorage/centralrepository/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2004-2010 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"
@@ -14,14 +14,14 @@
//
PRJ_EXPORTS
-../include/centralrepository.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(centralrepository.h)
+../include/centralrepository.h OS_LAYER_PUBLIC_EXPORT_PATH(centralrepository.h)
#ifndef SYMBIAN_ENABLE_SPLIT_HEADERS
-#ifdef SYMBIAN_OLD_EXPORT_LOCATION
-../include/centralrepositoryinternal.h /epoc32/include/centralrepositoryinternal.h
+ #ifdef SYMBIAN_OLD_EXPORT_LOCATION
+ ../include/centralrepositoryinternal.h /epoc32/include/centralrepositoryinternal.h
+ #endif
#endif
-#endif
-centralrepository.iby /epoc32/rom/include/centralrepository.iby
-backup_registration.xml z:/private/10202be9/backup_registration.xml
+centralrepository.iby /epoc32/rom/include/centralrepository.iby
+backup_registration.xml z:/private/10202be9/backup_registration.xml
PRJ_MMPFILES
@@ -32,12 +32,40 @@
#endif // WINS
#ifdef SYMBIAN_CENREPNOTIFIERHANDLER
- //Core OS extension
+ // Core OS extension
#include "../cenrepnotifierhandler/group/bld.inf"
#endif // SYMBIAN_CENREPNOTIFIERHANDLER
PRJ_TESTEXPORTS
+// Stub sis file required by various tests.
+
+//define PDS_FULL_UI_TEST in the rom build command for Full S60 UI build
+#if defined(__SERIES60_) && defined(PDS_FULL_UI_TEST)
+../test/testexecute/SWI/data/rnd_sis/centrepswiteststub.sis z:/system/install/centrepswiteststub.sis
+#else
+../test/testexecute/SWI/data/techview_sis/centrepswiteststub.sis z:/system/install/centrepswiteststub.sis
+#endif //__SERIES60_
+
+CentralRepositoryTests.bat /epoc32/data/z/system/test/centralrepositorytests.bat
+centrepswiteststub.iby /epoc32/rom/include/centrepswiteststub.iby
+CentralRepositoryTests.iby /epoc32/rom/include/centralrepositorytests.iby
+CentralRepositoryTechviewRTests.iby /epoc32/rom/include/centralrepositorytechviewrtests.iby
+centreptesthelper.iby /epoc32/rom/include/centreptesthelper.iby
+centreptestdata.iby /epoc32/rom/include/centreptestdata.iby
+
+// For pccenrep tests.
+../pccenrep/include/centralrepository.h OS_LAYER_PLATFORM_EXPORT_PATH(x86tool/centralrepository.h)
+
+../test/testexecute/SWI/data/certstore/swicertstore.dat z:/resource/versions/swicertstore.dat
+
+#ifdef SYMBIAN_BAFL_SYSUTIL
+ //CenRepFotaTvRTests.iby and CentralRepositoryTechviewFlashPerformance.iby are manual tests only.
+ CenRepFotaTvRTests.iby /epoc32/rom/include/cenrepfotatvrtests.iby
+ CentralRepositoryTechviewFlashPerformance.iby /epoc32/rom/include/centralrepositorytechviewflashperformance.iby
+ ../test/t_cenrep_runtxtshellflashtests.bat /epoc32/data/z/system/test/t_cenrep_runtxtshellflashtests.bat
+ ../test/t_cenrep_runtvflashtests.bat /epoc32/data/z/system/test/t_cenrep_runtvflashtests.bat
+#endif // SYMBIAN_BAFL_SYSUTIL
../test/00000100.crb z:/private/10202be9/00000100.crb
../test/00000005.cra z:/private/10202be9/00000005.cra
@@ -148,14 +176,23 @@
../test/sw.txt z:/resource/versions/sw.txt
../test/00000003.txt z:/private/102081e4/00000003.txt
../test/00112273.txt z:/private/10202be9/00112273.txt
-../test/RF1.sis z:/private/10202be9/rf1.sis
-../test/RF2.sis z:/private/10202be9/rf2.sis
-../test/RF3.sis z:/private/10202be9/rf3.sis
-../test/RF4.sis z:/private/10202be9/rf4.sis
-../test/testexecute/SWI/data/certstore/swicertstore.dat z:/resource/versions/swicertstore.dat
+
+//define PDS_FULL_UI_TEST in the rom build command for Full S60 UI build
+#if defined(__SERIES60_) && defined(PDS_FULL_UI_TEST)
+../test/rnd_RF1.sis z:/private/10202be9/rf1.sis
+../test/rnd_RF2.sis z:/private/10202be9/rf2.sis
+../test/rnd_RF3.sis z:/private/10202be9/rf3.sis
+../test/rnd_RF4.sis z:/private/10202be9/rf4.sis
+#else
+../test/techview_RF1.sis z:/private/10202be9/rf1.sis
+../test/techview_RF2.sis z:/private/10202be9/rf2.sis
+../test/techview_RF3.sis z:/private/10202be9/rf3.sis
+../test/techview_RF4.sis z:/private/10202be9/rf4.sis
+#endif //__SERIES60_
#ifdef SYMBIAN_CENTREP_SUPPORT_MULTIROFS
// Multi Rofs testing
+centreptestdata_multirofs.iby /epoc32/rom/include/centreptestdata_multirofs.iby
../test/multirofs/testrepository/aaaa0000.txt z:/private/10202be9/aaaa0000.txt
../test/multirofs/testrepository/aaaa0000.txt{01-00} z:/private/10202be9/aaaa0000.txt[01-00]
../test/multirofs/testrepository/bbbb0000.txt z:/private/10202be9/bbbb0000.txt
@@ -1400,34 +1437,8 @@
../test/multirofs/2112_test_keyspaces/102869bc.cre{01-00} z:/private/10202be9/102869bc.cre[01-00]
../test/multirofs/2112_test_keyspaces/102869bd.cre{01-00} z:/private/10202be9/102869bd.cre[01-00]
../test/multirofs/2112_test_keyspaces/102869be.cre{01-00} z:/private/10202be9/102869be.cre[01-00]
-
#endif // SYMBIAN_CENTREP_SUPPORT_MULTIROFS
-// Stub sis file required by various tests.
-../test/testexecute/SWI/data/centrepswiteststub.SIS /epoc32/release/winscw/urel/z/system/install/centrepswiteststub.sis
-../test/testexecute/SWI/data/centrepswiteststub.SIS /epoc32/release/winscw/udeb/z/system/install/centrepswiteststub.sis
-
-CentralRepositoryTests.bat /epoc32/data/z/system/test/centralrepositorytests.bat
-centrepswiteststub.iby /epoc32/rom/include/centrepswiteststub.iby
-CentralRepositoryTests.iby /epoc32/rom/include/centralrepositorytests.iby
-CentralRepositoryTechviewRTests.iby /epoc32/rom/include/centralrepositorytechviewrtests.iby
-centreptesthelper.iby /epoc32/rom/include/centreptesthelper.iby
-centreptestdata.iby /epoc32/rom/include/centreptestdata.iby
-#ifdef SYMBIAN_CENTREP_SUPPORT_MULTIROFS
- centreptestdata_multirofs.iby /epoc32/rom/include/centreptestdata_multirofs.iby
-#endif // SYMBIAN_CENTREP_SUPPORT_MULTIROFS
-
-#ifdef SYMBIAN_BAFL_SYSUTIL
- //CenRepFotaTvRTests.iby and CentralRepositoryTechviewFlashPerformance.iby are manual tests only.
- CenRepFotaTvRTests.iby /epoc32/rom/include/cenrepfotatvrtests.iby
- CentralRepositoryTechviewFlashPerformance.iby /epoc32/rom/include/centralrepositorytechviewflashperformance.iby
- ../test/t_cenrep_runtxtshellflashtests.bat /epoc32/data/z/system/test/t_cenrep_runtxtshellflashtests.bat
- ../test/t_cenrep_runtvflashtests.bat /epoc32/data/z/system/test/t_cenrep_runtvflashtests.bat
-#endif // SYMBIAN_BAFL_SYSUTIL
-
-// for pccenrep tests
-../pccenrep/include/centralrepository.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(x86tool/centralrepository.h)
-
PRJ_TESTMMPFILES
t_cenrep_helper.mmp support
@@ -1442,26 +1453,38 @@
t_cenrep_meta.mmp
t_cenrep_rfs.mmp
t_cenrep_back_rest.mmp
-t_cenrep_back_rest_defect.mmp manual
+#ifdef CENTREP_MW_TESTS
+ t_cenrep_back_rest_defect.mmp manual
+#endif // CENTREP_MW_TESTS
t_cenrep_back_rest_delete.mmp
t_oomcenrepsrv.mmp
t_processkillprocess.mmp support
#ifdef SYMBIAN_BAFL_SYSUTIL
- t_cenrep_fota_tvem1.mmp manual
- t_cenrep_fota_tvem2.mmp manual
- t_cenrep_fota_tvem3.mmp manual
- t_cenrep_fota_txtem1.mmp manual
- t_cenrep_fota_txtem2.mmp manual
- t_cenrep_fotaUT.mmp manual
+ #ifdef CENTREP_MW_TESTS
+ t_cenrep_fota_tvem1.mmp manual
+ #endif // CENTREP_MW_TESTS
+
+ t_cenrep_fota_tvem2.mmp manual
- #ifdef __CENTREP_SERVER_PERFTEST__
- t_cenrep_fota_perf1.mmp manual
- t_cenrep_fota_perf2.mmp manual
- #endif // __CENTREP_SERVER_PERFTEST__
+ #ifdef CENTREP_MW_TESTS
+ t_cenrep_fota_tvem3.mmp manual
+ t_cenrep_fota_txtem1.mmp manual
+ t_cenrep_fota_txtem2.mmp manual
+ t_cenrep_fotaUT.mmp manual
+ #endif // CENTREP_MW_TESTS
- t_cenrep_fota_hw_setup.mmp manual
- t_cenrep_fota_hw_tests.mmp manual
+ #ifdef __CENTREP_SERVER_PERFTEST__
+ #ifdef CENTREP_MW_TESTS
+ t_cenrep_fota_perf1.mmp manual
+ #endif // CENTREP_MW_TESTS
+ t_cenrep_fota_perf2.mmp manual
+ #endif // __CENTREP_SERVER_PERFTEST__
+
+ #ifdef CENTREP_MW_TESTS
+ t_cenrep_fota_hw_setup.mmp manual
+ t_cenrep_fota_hw_tests.mmp manual
+ #endif // CENTREP_MW_TESTS
#endif // SYMBIAN_BAFL_SYSUTIL
--- a/persistentstorage/centralrepository/group/centralrepository.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/centralrepository.iby Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
#include <bsul.iby>
-data=ZPRIVATE\10202BE9\backup_registration.xml PRIVATE\10202BE9\backup_registration.xml
+data=ZPRIVATE\10202be9\backup_registration.xml PRIVATE\10202BE9\backup_registration.xml
#ifdef SYMBIAN_CENREPNOTIFIERHANDLER
//Core OS extension
--- a/persistentstorage/centralrepository/group/centrepswiteststub.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/centrepswiteststub.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -16,6 +16,6 @@
#ifndef __CENTREPSWITESTSTUB_IBY__
#define __CENTREPSWITESTSTUB_IBY__
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\System\Install\centrepswiteststub.sis System\Install\centrepswiteststub.sis
+data=DATAZ_\system\install\centrepswiteststub.sis system\install\centrepswiteststub.sis
#endif // __CENTREPSWITESTSTUB_IBY__
--- a/persistentstorage/centralrepository/group/centreptestdata.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/centreptestdata.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -104,6 +104,12 @@
#ifndef __CENTRALREPOSITORYTECHVIEWRTESTS_IBY__
data=DATAZ_\PRIVATE\10202BE9\babababa.txt PRIVATE\10202BE9\babababa.txt
+#ifdef SYMBIAN_CENTREP_SUPPORT_MULTIROFS
+ #ifdef PDS_TEST_MULTIROFS
+ // Emulated multirofs regression testing.
+ data=DATAZ_\private\10202be9\babababa.txt private\10202be9\babababa.txt[01-00]
+ #endif // PDS_TEST_MULTIROFS
+#endif // SYMBIAN_CENTREP_SUPPORT_MULTIROFS
#ifdef SYMBIAN_BAFL_SYSUTIL
#include <centrepswiteststub.iby>
data=DATAZ_\PRIVATE\10202BE9\10033333.txt PRIVATE\10202BE9\10033333.txt
@@ -119,13 +125,24 @@
data=DATAZ_\PRIVATE\10202BE9\10043337.txt PRIVATE\10202BE9\10043337.txt
data=DATAZ_\PRIVATE\10202BE9\10043338.txt PRIVATE\10202BE9\10043338.txt
data=DATAZ_\PRIVATE\10202BE9\10033333_modified.cre PRIVATE\10202BE9\10033333_modified.cre
+data=DATAZ_\private\10202be9\cabacaba.txt private\10202be9\cabacaba.txt
+data=DATAZ_\private\10202be9\cadacada.txt private\10202be9\cadacada.txt
+#ifdef SYMBIAN_CENTREP_SUPPORT_MULTIROFS
+ #ifdef PDS_TEST_MULTIROFS
+ //Emulated multirofs regression testing
+ data=DATAZ_\private\10202be9\10033333.txt private\10202be9\10033333.txt[01-00]
+ data=DATAZ_\private\10202be9\10043336.txt private\10202be9\10043336.txt[01-00]
+ data=DATAZ_\private\10202be9\10043337.txt private\10202be9\10043337.txt[01-00]
+ data=DATAZ_\private\10202be9\10043338.txt private\10202be9\10043338.txt[01-00]
+ #endif // PDS_TEST_MULTIROFS
+#endif // SYMBIAN_CENTREP_SUPPORT_MULTIROFS
#ifndef __TE_SYSUTILTEFTESTS_IBY__
data=DATAZ_\RESOURCE\versions\sw.txt RESOURCE\versions\sw.txt
-#endif
+#endif // __TE_SYSUTILTEFTESTS_IBY__
data=DATAZ_\PRIVATE\10202BE9\sw_modified.txt PRIVATE\10202BE9\sw_modified.txt
data=DATAZ_\PRIVATE\10202BE9\sw_modified1.txt PRIVATE\10202BE9\sw_modified1.txt
data=DATAZ_\PRIVATE\10202BE9\RF1.sis PRIVATE\10202BE9\RF1.sis
data=DATAZ_\PRIVATE\10202BE9\RF4.sis PRIVATE\10202BE9\RF4.sis
-#endif
-#endif
+#endif // SYMBIAN_BAFL_SYSUTIL
+#endif // __CENTRALREPOSITORYTECHVIEWRTESTS_IBY__
#endif //__CENTREPTESTDATA_IBY__
--- a/persistentstorage/centralrepository/group/t_cenrep_back_rest.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/t_cenrep_back_rest.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -28,7 +28,7 @@
target t_cenrep_back_rest.exe
targettype exe
-MW_LAYER_SYSTEMINCLUDE_SYMBIAN
+OS_LAYER_SYSTEMINCLUDE_SYMBIAN
OS_LAYER_LIBC_SYSTEMINCLUDE
USERINCLUDE ../cenrepsrv ../common/inc
--- a/persistentstorage/centralrepository/group/t_cenrep_back_rest_delete.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/t_cenrep_back_rest_delete.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -25,7 +25,7 @@
target t_cenrep_back_rest_delete.exe
targettype exe
-MW_LAYER_SYSTEMINCLUDE_SYMBIAN
+OS_LAYER_SYSTEMINCLUDE_SYMBIAN
OS_LAYER_LIBC_SYSTEMINCLUDE
USERINCLUDE ../cenrepsrv ../common/inc
--- a/persistentstorage/centralrepository/group/t_cenrep_defects.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/t_cenrep_defects.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2004-2010 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"
@@ -21,7 +21,7 @@
target t_cenrep_defects.exe
targettype exe
-MW_LAYER_SYSTEMINCLUDE_SYMBIAN
+OS_LAYER_SYSTEMINCLUDE_SYMBIAN
USERINCLUDE ../cenrepsrv
USERINCLUDE ../common/inc
--- a/persistentstorage/centralrepository/group/t_cenrep_fota_perf2.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/group/t_cenrep_fota_perf2.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -21,7 +21,7 @@
target t_cenrep_fota_perf2.exe
targettype exe
-MW_LAYER_SYSTEMINCLUDE_SYMBIAN
+OS_LAYER_SYSTEMINCLUDE_SYMBIAN
USERINCLUDE ../cenrepsrv
USERINCLUDE ../common/inc
--- a/persistentstorage/centralrepository/pccenrep/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/pccenrep/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -18,7 +18,7 @@
PRJ_EXPORTS
-../include/centralrepository.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(x86tool/centralrepository.h)
+../include/centralrepository.h OS_LAYER_PLATFORM_EXPORT_PATH(x86tool/centralrepository.h)
PRJ_TESTEXPORTS
Binary file persistentstorage/centralrepository/test/RF1.sis has changed
Binary file persistentstorage/centralrepository/test/RF2.sis has changed
Binary file persistentstorage/centralrepository/test/RF3.sis has changed
Binary file persistentstorage/centralrepository/test/RF4.sis has changed
--- a/persistentstorage/centralrepository/test/doflashsis.bat Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/doflashsis.bat Tue Aug 31 16:57:14 2010 +0300
@@ -19,13 +19,21 @@
rem Make and sign the RF1 package.
makesis RF1.pkg
-signsis -S RF1.sis RF1.sis testexecute\SWI\data\certstore\centreproot.pem testexecute\SWI\data\certstore\centreproot.key
+makesis RF2.pkg
+makesis RF3.pkg
+makesis RF4.pkg
-makesis RF2.pkg
-signsis -S RF2.sis RF2.sis testexecute\SWI\data\certstore\centreproot.pem testexecute\SWI\data\certstore\centreproot.key
+signsis -S RF1.sis techview_RF1.sis testexecute\SWI\data\certstore\centreproot.pem testexecute\SWI\data\certstore\centreproot.key
+signsis -S RF2.sis techview_RF2.sis testexecute\SWI\data\certstore\centreproot.pem testexecute\SWI\data\certstore\centreproot.key
+signsis -S RF3.sis techview_RF3.sis testexecute\SWI\data\certstore\centreproot.pem testexecute\SWI\data\certstore\centreproot.key
+signsis -S RF4.sis techview_RF4.sis testexecute\SWI\data\certstore\centreproot.pem testexecute\SWI\data\certstore\centreproot.key
-makesis RF3.pkg
-signsis -S RF3.sis RF3.sis testexecute\SWI\data\certstore\centreproot.pem testexecute\SWI\data\certstore\centreproot.key
+signsis -S RF1.sis rnd_RF1.sis testexecute\SWI\data\certstore\Nokia_RnDCert_02.der testexecute\SWI\data\certstore\Nokia_RnDCert_02.key
+signsis -S RF2.sis rnd_RF2.sis testexecute\SWI\data\certstore\Nokia_RnDCert_02.der testexecute\SWI\data\certstore\Nokia_RnDCert_02.key
+signsis -S RF3.sis rnd_RF3.sis testexecute\SWI\data\certstore\Nokia_RnDCert_02.der testexecute\SWI\data\certstore\Nokia_RnDCert_02.key
+signsis -S RF4.sis rnd_RF4.sis testexecute\SWI\data\certstore\Nokia_RnDCert_02.der testexecute\SWI\data\certstore\Nokia_RnDCert_02.key
-makesis RF4.pkg
-signsis -S RF4.sis RF4.sis testexecute\SWI\data\certstore\centreproot.pem testexecute\SWI\data\certstore\centreproot.key
+del /f RF1.sis
+del /f RF2.sis
+del /f RF3.sis
+del /f RF4.sis
--- a/persistentstorage/centralrepository/test/multirofs/group/t_cenrep_preq2112.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/multirofs/group/t_cenrep_preq2112.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -22,7 +22,7 @@
UID 0 0x1020FFFF
-MW_LAYER_SYSTEMINCLUDE_SYMBIAN
+OS_LAYER_SYSTEMINCLUDE_SYMBIAN
USERINCLUDE ../../../cenrepsrv
USERINCLUDE ../../../common/inc
--- a/persistentstorage/centralrepository/test/multirofs/group/t_cenrep_preq2112perf.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/multirofs/group/t_cenrep_preq2112perf.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -22,7 +22,7 @@
target t_cenrep_preq2112perf.exe
targettype exe
-MW_LAYER_SYSTEMINCLUDE_SYMBIAN
+OS_LAYER_SYSTEMINCLUDE_SYMBIAN
USERINCLUDE ../../../cenrepsrv
USERINCLUDE ../../../common/inc
--- a/persistentstorage/centralrepository/test/multirofs/group/t_cenrep_preq2112u.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/multirofs/group/t_cenrep_preq2112u.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -19,7 +19,7 @@
target t_cenrep_preq2112u.exe
targettype exe
-MW_LAYER_SYSTEMINCLUDE_SYMBIAN
+OS_LAYER_SYSTEMINCLUDE_SYMBIAN
USERINCLUDE ../../../cenrepsrv
USERINCLUDE ../../../common/inc
Binary file persistentstorage/centralrepository/test/rnd_RF1.sis has changed
Binary file persistentstorage/centralrepository/test/rnd_RF2.sis has changed
Binary file persistentstorage/centralrepository/test/rnd_RF3.sis has changed
Binary file persistentstorage/centralrepository/test/rnd_RF4.sis has changed
--- a/persistentstorage/centralrepository/test/t_cenrep_back_rest.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/t_cenrep_back_rest.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -13,13 +13,9 @@
// Description:
//
-//#include <centralrepository.h>
#include <e32test.h>
#include <f32file.h>
#include <badesca.h>
-#include <connect/sbdefs.h>
-#include <connect/sbeclient.h>
-
#include "srvrepos_noc.h"
#include "srvres.h"
#include "cachemgr.h"
--- a/persistentstorage/centralrepository/test/t_cenrep_back_rest_delete.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/t_cenrep_back_rest_delete.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -17,9 +17,6 @@
#include <e32test.h>
#include <f32file.h>
#include <badesca.h>
-#include <connect/sbdefs.h>
-#include <connect/sbeclient.h>
-
#include "srvrepos_noc.h"
#include "srvres.h"
#include "cachemgr.h"
--- a/persistentstorage/centralrepository/test/t_cenrep_rfs.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/t_cenrep_rfs.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -73,6 +73,17 @@
#define TEST(arg) ::CheckL((arg), __LINE__)
#define TEST2(aValue, aExpected) ::CheckL(aValue, aExpected, __LINE__)
+// This function kills the C32exe.exe process. This commsdat process will
+// interfere with the test if not killed. In a nutshell, some of the test cases
+// will kill and then wait for 2 seconds and restart the centrep server
+// with --SoftReset option. During that 2 seconds wait sometimes C32exe.exe
+// will use centrep API, thus starting the server normally without --SoftReset.
+LOCAL_C void KillC32Exe()
+ {
+ _LIT( KC32ServerName, "c32exe");
+ KillProcess(KC32ServerName); // Don't need to check the return code, it always return KErrNone anyway.
+ User::After(KGeneralDelay);
+ }
//This function restores the state of the files required for this test
//Existing files are deleted and then the required files are copied
@@ -622,6 +633,7 @@
{
TheTest.Start(_L(" @SYMTestCaseID:SYSLIB-CENTRALREPOSITORY-CT-0497-0001 Restore Factory Settings tests "));
CleanupCDriveL();
+ KillC32Exe(); //Need to kill C32Exe as it is interfering with the test.
RestoreFactorySettingsTestL();
PDEF105203();
RFSRomOnlyL();
Binary file persistentstorage/centralrepository/test/techview_RF1.sis has changed
Binary file persistentstorage/centralrepository/test/techview_RF2.sis has changed
Binary file persistentstorage/centralrepository/test/techview_RF3.sis has changed
Binary file persistentstorage/centralrepository/test/techview_RF4.sis has changed
--- a/persistentstorage/centralrepository/test/testexecute/BUR/group/Te_centrep_BURsuite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/testexecute/BUR/group/Te_centrep_BURsuite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -32,15 +32,11 @@
USERINCLUDE ../src
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-//SYSTEMINCLUDE /epoc32/include/test
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib
-
-//LIBRARY efsrv.lib
LIBRARY centralrepository.lib
-//LIBRARY bafl.lib
CAPABILITY ALL -Tcb
--- a/persistentstorage/centralrepository/test/testexecute/BUR/group/te_centrep_burobserversuite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/testexecute/BUR/group/te_centrep_burobserversuite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -29,15 +29,11 @@
USERINCLUDE ../src
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-//SYSTEMINCLUDE /epoc32/include/test
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib
-
-//LIBRARY efsrv.lib
LIBRARY centralrepository.lib
-//LIBRARY bafl.lib
CAPABILITY ALL -Tcb
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/APPXs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/APPY1s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/APPY2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/APPYs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP12s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP14s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP2.SIS has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP22s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP23s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP3.SIS has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP3s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP41s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP4s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KP62s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KPS14s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KPS4s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KPS64s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KS12s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KS14s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KS2.SIS has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KS22s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KS2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KS3s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KS41s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KS4s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KS51s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KS62s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KSDs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KSY1s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KSY2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/KSYs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/centrepswiteststub.SIS has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/certstore/Nokia_RnDCert_02.der has changed
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/centralrepository/test/testexecute/SWI/data/certstore/Nokia_RnDCert_02.key Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,15 @@
+-----BEGIN RSA PRIVATE KEY-----
+MIICXQIBAAKBgQC/TDP7KKIaf5+uW4OD2iVZuUMC2a+SeQTjf6srlKcOm+CpPNXn
+uLNm/8fdEnyOIuRXPRKmqhs1n0JkxEGHynELWMTuKXbQx9SRAGUXzyneGn+IJNnO
+vOKHWgKCouX2hfI8rtkdqJpqmO460gGsMgw+lsbeyWyW9lnfLxq+ZC7sqQIDAQAB
+AoGBALmUWZE8GBaQ3P4u9WUCSd3DJkkrmXIFSULSZeH/chlwCwDjbbhArHothVzo
+REE3hEFFlERvHbplZ+mNouzy7boduvgUzbksGrbGMLJ2qO1GzWWVwV+GzOWKd3ss
+/98Gwoy5R8pjnkqUE2wP1iJFw0FjvUTKcYv/z6t3LLJ0CsoBAkEA+c7ixvsviQ3J
+s0INytCKU2bf8fqFQJi1VI82ukxNsujGTQ9upVSjuvqPvWyDvvTdrUBHqO+3qPut
+sEh01Q8aiQJBAMQKDJPVRu4ud3mwUfEavzL5EjqwG1k9VCNGYsT4FwtrHcxu1oP/
+pk6M3rIZukqomoEEnHWPMwhrK3fhBqi0OSECQQDr40VXege4FnH5OI2Hj4afHMyp
+VdQQXGMWFyopnzXblFz0lXb43cTCIiorR9XcMqNFHybLypkWE5o+lRzlt55pAkBQ
+P/zeF5Sts//cpL0mgdh7OVKpC6ZmZaCnwAx2rUhhuDu+kDDoYCLoTOps5fNI1LRK
+1GRoC3LMo3Jr5IYhUYWBAkBpCpN6k4JU/mszq98EojHerQNxk8sPqvQKUzTutohT
+1gLX9yepGayB/TtT2EEJDkWOlnTy/dvN6W3vzbJYz97x
+-----END RSA PRIVATE KEY-----
--- a/persistentstorage/centralrepository/test/testexecute/SWI/data/dosis.bat Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/testexecute/SWI/data/dosis.bat Tue Aug 31 16:57:14 2010 +0300
@@ -1,6 +1,6 @@
@echo off
rem
-rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+rem Copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies).
rem All rights reserved.
rem This component and the accompanying materials are made available
rem under the terms of "Eclipse Public License v1.0"
@@ -15,120 +15,126 @@
rem Description:
rem
@echo on
+
+@if not exist "%1" md "%1"
+@if not exist "%1" goto :InvalidFolder
+@if not exist "%2" goto :MissingCert
+@if not exist "%3" goto :MissingKey
+
rem The stub..
makesis -s centrepswiteststub.pkg
rem Make and sign the KS12 package. This modifies the KS1.2 keyspace, which
rem is a user mod on the ROM keyspace K1.
-makesis KS12.pkg
-signsis -S KS12.sis KS12s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KS12.pkg KS12.sis
+signsis -S KS12.sis KS12s.sis %2 %3
rem Make and sign the KS14 package.
-makesis KS14.pkg
-signsis -S KS14.sis KS14s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KS14.pkg KS14.sis
+signsis -S KS14.sis KS14s.sis %2 %3
rem Make and sign the KS2 package. This creates the KS2 keyspace, which
rem is new.
-makesis KS2.pkg
-signsis -S KS2.sis KS2s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KS2.pkg KS2.sis
+signsis -S KS2.sis KS2s.sis %2 %3
rem Make and sign the KS22 package. This creates the KS22 keyspace, which
rem upgrades KS21 (user modified KS2).
-makesis KS22.pkg
-signsis -S KS22.sis KS22s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KS22.pkg KS22.sis
+signsis -S KS22.sis KS22s.sis %2 %3
rem Make and sign the KS3 package. This package will fail to install
rem because the referenced keyspace file is not in the ROM stub.
-makesis KS3.pkg
-signsis -S KS3.sis KS3s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KS3.pkg KS3.sis
+signsis -S KS3.sis KS3s.sis %2 %3
rem Make and sign the KS4 package. This keyspace contains various capabilities
rem which we'll test don't change on a further install.
-makesis KS4.pkg
-signsis -S KS4.sis KS4s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KS4.pkg KS4.sis
+signsis -S KS4.sis KS4s.sis %2 %3
rem Installs on top of the above, you might think the capabilities in the
rem above would be lost, but no - they are persisted before the caps in this
rem package can splat them.
-makesis KS41.pkg
-signsis -S KS41.sis KS41s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KS41.pkg KS41.sis
+signsis -S KS41.sis KS41s.sis %2 %3
rem Make and sign the KP4 package. This keyspace contains various capabilities
rem which we'll test don't change on a further install.
-makesis KP4.pkg
-signsis -S KP4.sis KP4s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KP4.pkg KP4.sis
+signsis -S KP4.sis KP4s.sis %2 %3
rem Installs on top of the above, you might think the capabilities in the
rem above would be lost, but no - they are persisted before the caps in this
rem package can splat them.
-makesis KP41.pkg
-signsis -S KP41.sis KP41s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KP41.pkg KP41.sis
+signsis -S KP41.sis KP41s.sis %2 %3
rem SP filenull for uninstalling KP4.
-makesis KPS4.pkg
-signsis -S KPS4.sis KPS4s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KPS4.pkg KPS4.sis
+signsis -S KPS4.sis KPS4s.sis %2 %3
rem Installs on top of the ROM (51551554)
-makesis KS51.pkg
-signsis -S KS51.sis KS51s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KS51.pkg KS51.sis
+signsis -S KS51.sis KS51s.sis %2 %3
rem Make and sign the KP2 package. This creates the KP2 keyspace, which
rem is new.
-makesis KP2.pkg
-signsis -S KP2.sis KP2s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KP2.pkg KP2.sis
+signsis -S KP2.sis KP2s.sis %2 %3
rem Make and sign the KP22 package. This creates the KP22 keyspace, which
rem upgrades KP21 (user modified KP2).
-makesis KP22.pkg
-signsis -S KP22.sis KP22s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KP22.pkg KP22.sis
+signsis -S KP22.sis KP22s.sis %2 %3
rem Make and sign the KP23 package.
-makesis KP23.pkg
-signsis -S KP23.sis KP23s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KP23.pkg KP23.sis
+signsis -S KP23.sis KP23s.sis %2 %3
rem Make and sign the KP12 package.
-makesis KP12.pkg
-signsis -S KP12.sis KP12s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KP12.pkg KP12.sis
+signsis -S KP12.sis KP12s.sis %2 %3
rem Make and sign the KP14 package.
-makesis KP14.pkg
-signsis -S KP14.sis KP14s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KP14.pkg KP14.sis
+signsis -S KP14.sis KP14s.sis %2 %3
rem Make and sign the KPS14 standard patch, this SP is installed with a
rem file-null so the 51551551 keyspace file can be removed.
-makesis KPS14.pkg
-signsis -S KPS14.sis KPS14s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KPS14.pkg KPS14.sis
+signsis -S KPS14.sis KPS14s.sis %2 %3
rem Make and sign the KP3 package. This package will fail to install
rem because the referenced keyspace file is not in the ROM stub.
-makesis KP3.pkg
-signsis -S KP3.sis KP3s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KP3.pkg KP3.sis
+signsis -S KP3.sis KP3s.sis %2 %3
rem Make and sign the KP62 package.
-makesis KP62.pkg
-signsis -S KP62.sis KP62s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KP62.pkg KP62.sis
+signsis -S KP62.sis KP62s.sis %2 %3
rem Make and sign the KP62 package.
-makesis KS62.pkg
-signsis -S KS62.sis KS62s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KS62.pkg KS62.sis
+signsis -S KS62.sis KS62s.sis %2 %3
rem Make and sign the KPS64 package.
-makesis KPS64.pkg
-signsis -S KPS64.sis KPS64s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KPS64.pkg KPS64.sis
+signsis -S KPS64.sis KPS64s.sis %2 %3
rem Make and sign the KSX package. This is the embedded sis that goes in AppX.sis
-makesis KSX.pkg
-signsis -S KSX.sis KSXs.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KSX.pkg KSX.sis
+signsis -S KSX.sis KSXs.sis %2 %3
rem Make the AppX package for the application. This is the sis which contains the
rem embedded sis that has the application repository as a Centrep patch. This sis
rem is self-signed and conditonally installs the exe file depending on the environment
-makesis APPX.pkg
+makesis APPX.pkg APPX.sis
signsis -S APPX.sis APPXs.sis certstore\appx.cer certstore\appx.key
rem Make and sign the KSD package. This contains the corrupt KSD keyspace.
-makesis KSD.pkg
-signsis -S KSD.sis KSDs.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KSD.pkg KSD.sis
+signsis -S KSD.sis KSDs.sis %2 %3
rem Make the AppY,1,2 packages for the application. These sis files contain the
rem embedded sis that has the application repository as a Centrep patch. This sis
@@ -138,33 +144,48 @@
rem The following packages are used for the APP-SP test
rem Make and sign the KSY package. This is the embedded PU sis that goes in AppY.sis
-makesis KSY.pkg
-signsis -S KSY.sis KSYs.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KSY.pkg KSY.sis
+signsis -S KSY.sis KSYs.sis %2 %3
rem Make and sign the APPY package. This package will install an APP exe
rem a keyspace in an embedded PU package and an SP package to be used for the uninstall
-makesis APPY.pkg
+makesis APPY.pkg APPY.sis
signsis -S APPY.sis APPYs.sis certstore\appx.cer certstore\appx.key
rem Make and sign the KSY1 package. This is the embedded PU sis that goes in AppY1.sis
-makesis KSY1.pkg
-signsis -S KSY1.sis KSY1s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KSY1.pkg KSY1.sis
+signsis -S KSY1.sis KSY1s.sis %2 %3
rem Make and sign the APPY1 package. This package will install the APP exe
rem a new version of the keyspace in an embedded PU package and an SP package
rem to be used for the uninstall
-makesis APPY1.pkg
+makesis APPY1.pkg APPY1.sis
signsis -S APPY1.sis APPY1s.sis certstore\appx.cer certstore\appx.key
rem Make and sign the KSY2 package. This is the embedded PU sis that goes in AppY2.sis
-makesis KSY2.pkg
-signsis -S KSY2.sis KSY2s.sis certstore\centreproot.pem certstore\centreproot.key
+makesis KSY2.pkg KSY2.sis
+signsis -S KSY2.sis KSY2s.sis %2 %3
rem Make and sign the APPY2 package. This package will install the APP exe
rem a new version of the keyspace in an embedded PU package and an SP package
rem to be used for the uninstall
-makesis APPY2.pkg
+makesis APPY2.pkg APPY2.sis
signsis -S APPY2.sis APPY2s.sis certstore\appx.cer certstore\appx.key
+echo f | XCOPY /fry *.sis %1\
+del /f *.sis
+@goto :EOF
+
+:InvalidFolder
+@echo ERROR: Can't create folder %1
+@goto :EOF
+
+:MissingCert
+@echo ERROR: Missing certificate %2
+@goto :EOF
+
+:MissingKey
+@echo ERROR: Missing certificate key %3
+@goto :EOF
\ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/centralrepository/test/testexecute/SWI/data/logfile.txt Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,267 @@
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem The stub..
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis -s centrepswiteststub.pkg
+Processing centrepswiteststub.pkg...
+Created centrepswiteststub.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KS12 package. This modifies the KS1.2 keyspace, which
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem is a user mod on the ROM keyspace K1.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KS12.pkg
+Processing KS12.pkg...
+Created KS12.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KS12.sis KS12s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KS14 package.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KS14.pkg
+Processing KS14.pkg...
+Created KS14.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KS14.sis KS14s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KS2 package. This creates the KS2 keyspace, which
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem is new.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KS2.pkg
+Processing KS2.pkg...
+Created KS2.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KS2.sis KS2s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KS22 package. This creates the KS22 keyspace, which
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem upgrades KS21 (user modified KS2).
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KS22.pkg
+Processing KS22.pkg...
+Created KS22.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KS22.sis KS22s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KS3 package. This package will fail to install
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem because the referenced keyspace file is not in the ROM stub.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KS3.pkg
+Processing KS3.pkg...
+Created KS3.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KS3.sis KS3s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KS4 package. This keyspace contains various capabilities
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem which we'll test don't change on a further install.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KS4.pkg
+Processing KS4.pkg...
+Created KS4.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KS4.sis KS4s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Installs on top of the above, you might think the capabilities in the
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem above would be lost, but no - they are persisted before the caps in this
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem package can splat them.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KS41.pkg
+Processing KS41.pkg...
+Created KS41.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KS41.sis KS41s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KP4 package. This keyspace contains various capabilities
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem which we'll test don't change on a further install.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KP4.pkg
+Processing KP4.pkg...
+Created KP4.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KP4.sis KP4s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Installs on top of the above, you might think the capabilities in the
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem above would be lost, but no - they are persisted before the caps in this
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem package can splat them.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KP41.pkg
+Processing KP41.pkg...
+Created KP41.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KP41.sis KP41s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem SP filenull for uninstalling KP4.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KPS4.pkg
+Processing KPS4.pkg...
+Created KPS4.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KPS4.sis KPS4s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Installs on top of the ROM (51551554)
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KS51.pkg
+Processing KS51.pkg...
+Created KS51.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KS51.sis KS51s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KP2 package. This creates the KP2 keyspace, which
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem is new.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KP2.pkg
+Processing KP2.pkg...
+Created KP2.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KP2.sis KP2s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KP22 package. This creates the KP22 keyspace, which
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem upgrades KP21 (user modified KP2).
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KP22.pkg
+Processing KP22.pkg...
+Created KP22.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KP22.sis KP22s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KP23 package.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KP23.pkg
+Processing KP23.pkg...
+Created KP23.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KP23.sis KP23s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KP12 package.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KP12.pkg
+Processing KP12.pkg...
+Created KP12.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KP12.sis KP12s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KP14 package.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KP14.pkg
+Processing KP14.pkg...
+Created KP14.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KP14.sis KP14s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KPS14 standard patch, this SP is installed with a
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem file-null so the 51551551 keyspace file can be removed.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KPS14.pkg
+Processing KPS14.pkg...
+Created KPS14.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KPS14.sis KPS14s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KP3 package. This package will fail to install
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem because the referenced keyspace file is not in the ROM stub.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KP3.pkg
+Processing KP3.pkg...
+Created KP3.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KP3.sis KP3s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KP62 package.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KP62.pkg
+Processing KP62.pkg...
+Created KP62.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KP62.sis KP62s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KP62 package.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KS62.pkg
+Processing KS62.pkg...
+Created KS62.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KS62.sis KS62s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KPS64 package.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KPS64.pkg
+Processing KPS64.pkg...
+Created KPS64.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KPS64.sis KPS64s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KSX package. This is the embedded sis that goes in AppX.sis
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KSX.pkg
+Processing KSX.pkg...
+Created KSX.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KSX.sis KSXs.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make the AppX package for the application. This is the sis which contains the
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem embedded sis that has the application repository as a Centrep patch. This sis
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem is self-signed and conditonally installs the exe file depending on the environment
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis APPX.pkg
+Processing APPX.pkg...
+Created APPX.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S APPX.sis APPXs.sis certstore\appx.cer certstore\appx.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KSD package. This contains the corrupt KSD keyspace.
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KSD.pkg
+Processing KSD.pkg...
+Created KSD.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KSD.sis KSDs.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make the AppY,1,2 packages for the application. These sis files contain the
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem embedded sis that has the application repository as a Centrep patch. This sis
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem is self-signed and conditonally installs the exe file depending on the environment
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem These SIS files are used to test a standard installation
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem The following packages are used for the APP-SP test
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KSY package. This is the embedded PU sis that goes in AppY.sis
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KSY.pkg
+Processing KSY.pkg...
+Created KSY.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KSY.sis KSYs.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the APPY package. This package will install an APP exe
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem a keyspace in an embedded PU package and an SP package to be used for the uninstall
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis APPY.pkg
+Processing APPY.pkg...
+Created APPY.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S APPY.sis APPYs.sis certstore\appx.cer certstore\appx.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KSY1 package. This is the embedded PU sis that goes in AppY1.sis
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KSY1.pkg
+Processing KSY1.pkg...
+Created KSY1.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KSY1.sis KSY1s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the APPY1 package. This package will install the APP exe
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem a new version of the keyspace in an embedded PU package and an SP package
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem to be used for the uninstall
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis APPY1.pkg
+Processing APPY1.pkg...
+Created APPY1.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S APPY1.sis APPY1s.sis certstore\appx.cer certstore\appx.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the KSY2 package. This is the embedded PU sis that goes in AppY2.sis
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis KSY2.pkg
+Processing KSY2.pkg...
+Created KSY2.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S KSY2.sis KSY2s.sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem Make and sign the APPY2 package. This package will install the APP exe
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem a new version of the keyspace in an embedded PU package and an SP package
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] rem to be used for the uninstall
+
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] makesis APPY2.pkg
+Processing APPY2.pkg...
+Created APPY2.sis.
+Y:\persistentdata\persistentstorage\centralrepository\test\testexecute\SWI\data> [EPOC] signsis -S APPY2.sis APPY2s.sis certstore\appx.cer certstore\appx.key
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_dosis.bat Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,19 @@
+@echo off
+rem
+rem Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+rem All rights reserved.
+rem This component and the accompanying materials are made available
+rem under the terms of "Eclipse Public License v1.0"
+rem which accompanies this distribution, and is available
+rem at the URL "http://www.eclipse.org/legal/epl-v10.html".
+rem
+rem Initial Contributors:
+rem Nokia Corporation - initial contribution.
+rem
+rem Contributors:
+rem
+rem Description:
+rem
+@echo on
+
+dosis rnd_sis certstore\Nokia_RnDCert_02.der certstore\Nokia_RnDCert_02.key
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/APPX.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/APPXs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/APPY.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/APPY1.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/APPY1s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/APPY2.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/APPY2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/APPYs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP12.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP12s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP14.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP14s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP2.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP22.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP22s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP23.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP23s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP3.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP3s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP4.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP41.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP41s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP4s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP62.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KP62s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KPS14.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KPS14s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KPS4.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KPS4s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KPS64.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KPS64s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS12.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS12s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS14.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS14s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS2.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS22.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS22s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS3.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS3s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS4.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS41.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS41s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS4s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS51.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS51s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS62.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KS62s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KSD.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KSDs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KSX.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KSXs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KSY.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KSY1.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KSY1s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KSY2.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KSY2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/KSYs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/rnd_sis/centrepswiteststub.sis has changed
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/centralrepository/test/testexecute/SWI/data/techview_dosis.bat Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,19 @@
+@echo off
+rem
+rem Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+rem All rights reserved.
+rem This component and the accompanying materials are made available
+rem under the terms of "Eclipse Public License v1.0"
+rem which accompanies this distribution, and is available
+rem at the URL "http://www.eclipse.org/legal/epl-v10.html".
+rem
+rem Initial Contributors:
+rem Nokia Corporation - initial contribution.
+rem
+rem Contributors:
+rem
+rem Description:
+rem
+@echo on
+
+dosis techview_sis certstore\centreproot.pem certstore\centreproot.key
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/APPX.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/APPXs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/APPY.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/APPY1.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/APPY1s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/APPY2.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/APPY2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/APPYs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP12.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP12s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP14.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP14s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP2.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP22.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP22s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP23.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP23s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP3.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP3s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP4.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP41.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP41s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP4s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP62.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KP62s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KPS14.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KPS14s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KPS4.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KPS4s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KPS64.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KPS64s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS12.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS12s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS14.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS14s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS2.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS22.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS22s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS3.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS3s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS4.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS41.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS41s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS4s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS51.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS51s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS62.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KS62s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KSD.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KSDs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KSX.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KSXs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KSY.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KSY1.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KSY1s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KSY2.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KSY2s.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/KSYs.sis has changed
Binary file persistentstorage/centralrepository/test/testexecute/SWI/data/techview_sis/centrepswiteststub.sis has changed
--- a/persistentstorage/centralrepository/test/testexecute/SWI/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/testexecute/SWI/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -65,50 +65,91 @@
../data/certstore/swicertstore.dat z:/resource/swicertstore.dat
./swicertstoredat.iby /epoc32/rom/include/swicertstoredat.iby
+
+//define PDS_FULL_UI_TEST in the rom build command for Full S60 UI build
+#if defined(__SERIES60_) && defined(PDS_FULL_UI_TEST)
+
// SP tests...
-../data/KS12s.sis z:/tef_centralrepository/ks12s.sis
-../data/KS14s.sis z:/tef_centralrepository/ks14s.sis
-../data/KS2s.sis z:/tef_centralrepository/ks2s.sis
-../data/KS22s.sis z:/tef_centralrepository/ks22s.sis
-../data/KS3s.sis z:/tef_centralrepository/ks3s.sis
-../data/KS4s.sis z:/tef_centralrepository/ks4s.sis
-../data/KS41s.sis z:/tef_centralrepository/ks41s.sis
-../data/KS51s.sis z:/tef_centralrepository/ks51s.sis
-../data/KS62s.sis z:/tef_centralrepository/ks62s.sis
+../data/rnd_sis/KS12s.sis z:/tef_centralrepository/ks12s.sis
+../data/rnd_sis/KS14s.sis z:/tef_centralrepository/ks14s.sis
+../data/rnd_sis/KS2s.sis z:/tef_centralrepository/ks2s.sis
+../data/rnd_sis/KS22s.sis z:/tef_centralrepository/ks22s.sis
+../data/rnd_sis/KS3s.sis z:/tef_centralrepository/ks3s.sis
+../data/rnd_sis/KS4s.sis z:/tef_centralrepository/ks4s.sis
+../data/rnd_sis/KS41s.sis z:/tef_centralrepository/ks41s.sis
+../data/rnd_sis/KS51s.sis z:/tef_centralrepository/ks51s.sis
+../data/rnd_sis/KS62s.sis z:/tef_centralrepository/ks62s.sis
// PU tests...
-../data/KP12s.sis z:/tef_centralrepository/kp12s.sis
-../data/KP14s.sis z:/tef_centralrepository/kp14s.sis
-../data/KPS14s.sis z:/tef_centralrepository/kps14s.sis
-../data/KP2s.sis z:/tef_centralrepository/kp2s.sis
-../data/KP22s.sis z:/tef_centralrepository/kp22s.sis
-../data/KP23s.sis z:/tef_centralrepository/kp23s.sis
-../data/KP3s.sis z:/tef_centralrepository/kp3s.sis
-../data/KP4s.sis z:/tef_centralrepository/kp4s.sis
-../data/KP41s.sis z:/tef_centralrepository/kp41s.sis
-../data/KPS4s.sis z:/tef_centralrepository/kps4s.sis
-../data/KP62s.sis z:/tef_centralrepository/kp62s.sis
-../data/KPS64s.sis z:/tef_centralrepository/kps64s.sis
+../data/rnd_sis/KP12s.sis z:/tef_centralrepository/kp12s.sis
+../data/rnd_sis/KP14s.sis z:/tef_centralrepository/kp14s.sis
+../data/rnd_sis/KPS14s.sis z:/tef_centralrepository/kps14s.sis
+../data/rnd_sis/KP2s.sis z:/tef_centralrepository/kp2s.sis
+../data/rnd_sis/KP22s.sis z:/tef_centralrepository/kp22s.sis
+../data/rnd_sis/KP23s.sis z:/tef_centralrepository/kp23s.sis
+../data/rnd_sis/KP3s.sis z:/tef_centralrepository/kp3s.sis
+../data/rnd_sis/KP4s.sis z:/tef_centralrepository/kp4s.sis
+../data/rnd_sis/KP41s.sis z:/tef_centralrepository/kp41s.sis
+../data/rnd_sis/KPS4s.sis z:/tef_centralrepository/kps4s.sis
+../data/rnd_sis/KP62s.sis z:/tef_centralrepository/kp62s.sis
+../data/rnd_sis/KPS64s.sis z:/tef_centralrepository/kps64s.sis
// SWI-BUR tests...
-../data/APPXs.sis z:/tef_centralrepository/appxs.sis
+../data/rnd_sis/APPXs.sis z:/tef_centralrepository/appxs.sis
// SWI-APP tests
-../data/APPYs.sis z:/tef_centralrepository/appys.sis
-
-../data/KSYs.sis z:/tef_centralrepository/ksys.sis
-
-../data/APPY1s.sis z:/tef_centralrepository/appy1s.sis
-
-../data/KSY1s.sis z:/tef_centralrepository/ksy1s.sis
-
-../data/APPY2s.sis z:/tef_centralrepository/appy2s.sis
-
-../data/KSY2s.sis z:/tef_centralrepository/ksy2s.sis
-
+../data/rnd_sis/APPYs.sis z:/tef_centralrepository/appys.sis
+../data/rnd_sis/KSYs.sis z:/tef_centralrepository/ksys.sis
+../data/rnd_sis/APPY1s.sis z:/tef_centralrepository/appy1s.sis
+../data/rnd_sis/KSY1s.sis z:/tef_centralrepository/ksy1s.sis
+../data/rnd_sis/APPY2s.sis z:/tef_centralrepository/appy2s.sis
+../data/rnd_sis/KSY2s.sis z:/tef_centralrepository/ksy2s.sis
// SWI defect tests...
-../data/KSDs.sis z:/tef_centralrepository/ksds.sis
+../data/rnd_sis/KSDs.sis z:/tef_centralrepository/ksds.sis
+
+#else
+
+// SP tests...
+../data/techview_sis/KS12s.sis z:/tef_centralrepository/ks12s.sis
+../data/techview_sis/KS14s.sis z:/tef_centralrepository/ks14s.sis
+../data/techview_sis/KS2s.sis z:/tef_centralrepository/ks2s.sis
+../data/techview_sis/KS22s.sis z:/tef_centralrepository/ks22s.sis
+../data/techview_sis/KS3s.sis z:/tef_centralrepository/ks3s.sis
+../data/techview_sis/KS4s.sis z:/tef_centralrepository/ks4s.sis
+../data/techview_sis/KS41s.sis z:/tef_centralrepository/ks41s.sis
+../data/techview_sis/KS51s.sis z:/tef_centralrepository/ks51s.sis
+../data/techview_sis/KS62s.sis z:/tef_centralrepository/ks62s.sis
+
+// PU tests...
+../data/techview_sis/KP12s.sis z:/tef_centralrepository/kp12s.sis
+../data/techview_sis/KP14s.sis z:/tef_centralrepository/kp14s.sis
+../data/techview_sis/KPS14s.sis z:/tef_centralrepository/kps14s.sis
+../data/techview_sis/KP2s.sis z:/tef_centralrepository/kp2s.sis
+../data/techview_sis/KP22s.sis z:/tef_centralrepository/kp22s.sis
+../data/techview_sis/KP23s.sis z:/tef_centralrepository/kp23s.sis
+../data/techview_sis/KP3s.sis z:/tef_centralrepository/kp3s.sis
+../data/techview_sis/KP4s.sis z:/tef_centralrepository/kp4s.sis
+../data/techview_sis/KP41s.sis z:/tef_centralrepository/kp41s.sis
+../data/techview_sis/KPS4s.sis z:/tef_centralrepository/kps4s.sis
+../data/techview_sis/KP62s.sis z:/tef_centralrepository/kp62s.sis
+../data/techview_sis/KPS64s.sis z:/tef_centralrepository/kps64s.sis
+
+// SWI-BUR tests...
+../data/techview_sis/APPXs.sis z:/tef_centralrepository/appxs.sis
+
+// SWI-APP tests
+../data/techview_sis/APPYs.sis z:/tef_centralrepository/appys.sis
+../data/techview_sis/KSYs.sis z:/tef_centralrepository/ksys.sis
+../data/techview_sis/APPY1s.sis z:/tef_centralrepository/appy1s.sis
+../data/techview_sis/KSY1s.sis z:/tef_centralrepository/ksy1s.sis
+../data/techview_sis/APPY2s.sis z:/tef_centralrepository/appy2s.sis
+../data/techview_sis/KSY2s.sis z:/tef_centralrepository/ksy2s.sis
+
+// SWI defect tests...
+../data/techview_sis/KSDs.sis z:/tef_centralrepository/ksds.sis
+
+#endif //__SERIES60_
PRJ_TESTMMPFILES
// TestExecute test binaries
--- a/persistentstorage/centralrepository/test/testexecute/group/TEF_CentralRepository.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/testexecute/group/TEF_CentralRepository.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2009-2010 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"
@@ -23,7 +23,9 @@
//
// Note also that all these tests are techview tests.
-#include <te_centrep_BURsuite.iby>
-#include <te_centrep_SWIsuite.iby>
-
+#ifdef CENTREP_MW_TESTS
+ #include <te_centrep_BURsuite.iby>
+ #include <te_centrep_SWIsuite.iby>
+#endif // CENTREP_MW_TESTS
+
#endif // __TEF_CentralRepository_IBY__
--- a/persistentstorage/centralrepository/test/testexecute/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/centralrepository/test/testexecute/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -14,16 +14,11 @@
//
-
-#include "../performance/group/bld.inf"
#include "../convtool/group/bld.inf"
-#include "../SWI/group/bld.inf"
-#include "../BUR/group/bld.inf"
+#ifdef CENTREP_MW_TESTS
+ #include "../SWI/group/bld.inf"
+ #include "../BUR/group/bld.inf"
+#endif // CENTREP_MW_TESTS
PRJ_TESTEXPORTS
-
-
-../group/TEF_CentralRepository.iby /epoc32/rom/include/tef_centralrepository.iby
-
-
-
+../group/TEF_CentralRepository.iby /epoc32/rom/include/tef_centralrepository.iby
--- a/persistentstorage/centralrepository/test/testexecute/performance/bwins/CentRepPerfTestU.DEF Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,3 +0,0 @@
-EXPORTS
- ?NewServer@@YAHXZ @ 1 NONAME ; int NewServer(void)
-
--- a/persistentstorage/centralrepository/test/testexecute/performance/config/perf.ini Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
-[boottest]
-TestMode=1
-
-[timingtest1]
-TestMode=0
-Output=ResultSet1
-
-[timingtest2]
-TestMode=0
-Output=ResultSet2
-
-[Shared]
-shared_data_num = 2
-shared_name_1 = ResultSet1
-shared_name_2 = ResultSet2
\ No newline at end of file
--- a/persistentstorage/centralrepository/test/testexecute/performance/group/TE_CentRepPerfTest.iby Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,33 +0,0 @@
-/*
-* Copyright (c) 2009 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:
-*
-*/
-#ifndef __TE_CENTREP_PERFTEST_IBY__
-#define __TE_CENTREP_PERFTEST_IBY__
-
-#include <testexecute.iby>
-
-// centrep test dlls
-#include <centreptesthelper.iby>
-
-// centrep test data
-#include <centreptestdata.iby>
-
-file=ABI_DIR\BUILD_DIR\CentRepPerfTest.exe System\bin\CentRepPerfTest.exe
-
-data=DATAZ_\TEF_CentralRepository\perf.ini TEF_CentralRepository\perf.ini
-data=DATAZ_\TEF_CentralRepository\TE_PerfTest.script TEF_CentralRepository\TE_PerfTest.Script
-
-#endif //__TE_CENTREP_PERFTEST_IBY__
--- a/persistentstorage/centralrepository/test/testexecute/performance/group/TE_CentRepPerfTest.mmp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,50 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-TARGET centrepperftest.exe
-CAPABILITY AllFiles ReadUserData WriteUserData
-TARGETTYPE exe
-UID 0x1000007A 0x1027431A
-
-SMPSAFE
-
-SOURCEPATH ../src
-SOURCE TE_PerfTestUtilities.cpp
-SOURCE TE_PerfTestCompareStep.cpp
-SOURCE TE_PerfTestCacheStepBase.cpp
-SOURCE TE_PerfTestCacheEnabledStep.cpp
-SOURCE TE_PerfTestCacheDisabledStep.cpp
-SOURCE TE_PerfTestStep.cpp
-SOURCE TE_MemTestStep.cpp
-SOURCE TE_FindPerfTestStep.cpp
-SOURCE TE_PerfTestServer.cpp
-SOURCE TE_DefectTestStep.cpp
-SOURCE TE_PerfTestClientOpenStep.cpp
-SOURCE TE_NotifyMemTestStep.cpp
-
-USERINCLUDE ../inc
-USERINCLUDE ../../../../cenrepsrv
-USERINCLUDE ../../../../common/inc
-USERINCLUDE ../../../../include
-USERINCLUDE ../../../../test
-OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-
-LIBRARY euser.lib
-LIBRARY testexecuteutils.lib
-LIBRARY testexecutelogclient.lib
-LIBRARY hal.lib
-LIBRARY centralrepository.lib
-LIBRARY t_cenrep_helper.lib bafl.lib efsrv.lib
-
--- a/persistentstorage/centralrepository/test/testexecute/performance/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,24 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-PRJ_TESTMMPFILES
-
-TE_CentRepPerfTest.mmp manual
-
-PRJ_TESTEXPORTS
-../scripts/TE_PerfTest.script z:/tef_centralrepository/te_perftest.script
-../config/perf.ini z:/tef_centralrepository/perf.ini
-
-TE_CentRepPerfTest.iby /epoc32/rom/include/te_centrepperftest.iby
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_DefectTestStep.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,38 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#ifndef __TE_DEFECTTESTSTEP_H__
-#define __TE_DEFECTTESTSTEP_H__
-
-#include <test/testexecutestepbase.h>
-
-_LIT(KPerfTestDefectStepDEF057491, "CentRepDefectTest057491");
-_LIT(KPerfTestDefectStepDEF059633, "CentRepDefectTest059633");
-
-class CPerfTestDefectStep057491 : public CTestStep
- {
-public:
- CPerfTestDefectStep057491();
- virtual TVerdict doTestStepL(void);
- };
-
-class CPerfTestDefectStep059633 : public CTestStep
- {
-public:
- CPerfTestDefectStep059633();
- virtual TVerdict doTestStepL(void);
- };
-
-#endif // __TE_DEFECTTESTSTEP_H__
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_FindPerfTestStep.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,32 +0,0 @@
-// Copyright (c) 2005-2009 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:
-// TE_MemTestStep.h
-//
-//
-
-#ifndef __TE_FINDPERFTESTSTEP_H__
-#define __TE_FINDPERFTESTSTEP_H__
-
-#include <test/testexecutestepbase.h>
-
-_LIT(KFindPerfTestName, "CentRepFindPerfTest");
-
-class CFindPerfTestStep : public CTestStep
- {
-public:
- CFindPerfTestStep();
- virtual TVerdict doTestStepL(void);
- };
-
-#endif // __TE_FINDPERFTESTSTEP_H__
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_MemTestStep.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,55 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#ifndef __TE_MEMTESTSTEP_H__
-#define __TE_MEMTESTSTEP_H__
-
-#include <test/testexecutestepbase.h>
-
-_LIT(KMemTestName, "CentRepMemTestLogger");
-
-#ifdef __CENTREP_SERVER_MEMTEST__
-// Class for storing initial and final heap size readings for specific
-// location and identifier
-class TMemTestResult
- {
-public:
- inline TMemTestResult(TInt32 aLocation, TInt32 aIdentifier, TBool aIsComplete)
- : iLocation(aLocation), iIdentifier(aIdentifier), iIsComplete(aIsComplete) { }
- //location where the memory reading is done
- TInt32 iLocation;
- //identifier of the memory reading (e.g. repository id, 10th reading etc)
- TInt32 iIdentifier;
- //whether both initial and final heap size readings are valid
- TBool iIsComplete;
- //heap size before the operation starts
- TInt32 iInitHeapSize;
- //heap size after the operation ends
- TInt32 iFinalHeapSize;
- };
-#endif //__CENTREP_SERVER_MEMTEST__
-
-class CMemTestStep : public CTestStep
- {
-public:
- CMemTestStep();
- virtual TVerdict doTestStepL(void);
-protected:
-#ifdef __CENTREP_SERVER_MEMTEST__
- virtual void ProcessMemTestResults(TAny* aRawData, TInt32 aRawCount, RArray<TMemTestResult>& aMemTestResults);
-#endif //__CENTREP_SERVER_MEMTEST__
- };
-
-#endif // __TE_MEMTESTSTEP_H__
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_NotifyMemTestStep.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,44 +0,0 @@
-/**
-* Copyright (c) 2006-2009 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:
-* This file define all the common values thoughout your test project
-*
-*
-*/
-
-
-
-/**
- @file
-*/
-#ifndef __TE_NOTIFYMEMTESTSTEP_H__
-#define __TE_NOTIFYMEMTESTSTEP_H__
-
-#include <test/testexecutestepbase.h>
-#include "TE_MemTestStep.h"
-
-_LIT(KNotifyMemTestStep, "NotifyMemTestStep");
-
-class CNotifyMemTestStep : public CMemTestStep
- {
-public:
- inline CNotifyMemTestStep(){SetTestStepName(KNotifyMemTestStep);};
- virtual TVerdict doTestStepL(void);
-protected:
-#ifdef __CENTREP_SERVER_MEMTEST__
- virtual void ProcessMemTestResults(TAny* aRawData, TInt32 aRawCount, RArray<TMemTestResult>& aMemTestResults);
-#endif //__CENTREP_SERVER_MEMTEST__
- };
-
-#endif //__TE_NOTIFYMEMTESTSTEP_H__
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_PerfTestCacheDisabledStep.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,36 +0,0 @@
-// Copyright (c) 2005-2009 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:
-// TE_PerfTestCacheEnabledStep.h
-//
-//
-
-#ifndef __TE_PERFTESTCACHEDISABLEDSTEP_H__
-#define __TE_PERFTESTCACHEDISABLEDSTEP_H__
-
-#include "TE_PerfTestCacheStepBase.h"
-
-//--------------------------------
-// class CPerfTestCacheDisabledStep
-//--------------------------------
-
-_LIT(KPerfTestCacheDisabledStep, "PerfTestCacheDisabledStep");
-
-class CPerfTestCacheDisabledStep : public CPerfTestCacheStepBase
- {
-public:
- CPerfTestCacheDisabledStep();
- virtual TVerdict doTestStepL(void);
- };
-
-#endif
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_PerfTestCacheEnabledStep.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,33 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#ifndef __TE_PERFTESTCACHEENABLEDSTEP_H__
-#define __TE_PERFTESTCACHEENABLEDSTEP_H__
-
-#include "TE_PerfTestCacheStepBase.h"
-
-//--------------------------------
-// class CPerfTestCacheEnabledStep
-//--------------------------------
-_LIT(KPerfTestCacheEnabledStep, "PerfTestCacheEnabledStep");
-
-class CPerfTestCacheEnabledStep : public CPerfTestCacheStepBase
- {
-public:
- CPerfTestCacheEnabledStep();
- virtual TVerdict doTestStepL(void);
- };
-
-#endif
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_PerfTestCacheStepBase.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,37 +0,0 @@
-/**
-* Copyright (c) 2005-2009 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:
-* This file define all the common values thoughout your test project
-*
-*
-*/
-
-
-
-/**
- @file
-*/
-#ifndef __TE_PERFTESTCACHESTEPBASE_H__
-#define __TE_PERFTESTCACHESTEPBASE_H__
-
-#include <test/testexecutestepbase.h>
-
-class CPerfTestCacheStepBase : public CTestStep
- {
-public:
- CPerfTestCacheStepBase() {};
- void CommonTestStepL(void);
- };
-
-#endif //__TE_PERFTESTCACHESTEPBASE_H__
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_PerfTestClientOpenStep.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,34 +0,0 @@
-// Copyright (c) 2006-2009 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:
-//
-
-#ifndef __TE_PERFTESTCLIENTOPENSTEP_H__
-#define __TE_PERFTESTCLIENTOPENSTEP_H__
-
-#include <test/testexecutestepbase.h>
-
-//--------------------------------
-// class CPerfTestClientOpenStep
-//--------------------------------
-
-_LIT(KPerfTestClientOpenName, "PerfTestClientOpenStep");
-
-class CPerfTestClientOpenStep : public CTestStep
- {
-public:
- CPerfTestClientOpenStep();
- virtual TVerdict doTestStepL(void);
- };
-
-#endif //__TE_PERFTESTCLIENTOPENSTEP_H__
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_PerfTestCompareStep.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,45 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#ifndef __TE_PERFTESTCOMPARESTEP_H__
-#define __TE_PERFTESTCOMPARESTEP_H__
-
-#include "TE_PerfTestCacheStepBase.h"
-
-//--------------------------------
-// class CPerfTestCompareStep
-//--------------------------------
-_LIT(KPerfTestCompareStep, "PerfTestCompareStep");
-
-class CPerfTestCompareStep : public CTestStep
- {
-public:
- CPerfTestCompareStep();
- virtual TVerdict doTestStepL(void);
-
-protected:
- class TSummary
- {
- public:
- TBuf<20> iName;
- TUint iUseCount;
- TUint32 iSumElapsedTicks;
- };
- void ReadResults(RArray<TSummary> &aArray, TBuf<KMaxFileName> &aString);
- RArray<TSummary> iResults1;
- RArray<TSummary> iResults2;
- };
-
-#endif
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_PerfTestServer.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,26 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#ifndef __TE_PERFTESTSERVER_H__
-#define __TE_PERFTESTSERVER_H__
-#include <test/testexecuteserverbase.h>
-
-class CPerfTestServer : public CTestServer
- {
-public:
- static CPerfTestServer* NewL();
- virtual CTestStep* CreateTestStep(const TDesC& aStepName);
- };
-#endif
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_PerfTestStep.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,90 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#ifndef __TE_PERFTESTSTEP_H__
-#define __TE_PERFTESTSTEP_H__
-
-#include <e32std.h>
-#include <test/testexecutestepbase.h>
-
-class TRepStatistics
- {
-public:
-#ifdef __WINS__
- #ifdef _DEBUG
- enum { KTicks2LoadFromCache = 70 }; // emulator UDEB
- #else
- enum { KTicks2LoadFromCache = 40 }; // emulator UREL
- #endif
-#else
- #ifdef _DEBUG
- enum { KTicks2LoadFromCache = 90 }; // armv5 UDEB
- #else
- enum { KTicks2LoadFromCache = 60 }; // armv5 UREL
- #endif
-#endif
-
- inline TRepStatistics();
- inline TRepStatistics(const TRepStatistics& aRepStatistics);
- inline TRepStatistics(TUint32 aRepUid, TUint32 aLoadTicks);
- inline TBool MatchUid(TUint32 aRepUid) const;
- void AddData(TUint32 aElapsedTicks);
-
- TUint32 iRepUid;
- TUint iUseCount; // how many times the rep is open
- TUint32 iSumLoadTicks;
- TUint iCacheMisses; // how many times rep need to be reloaded
- };
-
-//-----------------------------------------------
-
-class TIpcStatistics
- {
-public:
- inline TIpcStatistics();
- void AddData(TUint32 aElapsedTicks);
-
- TUint iUseCount;
- TUint32 iSumElapsedTicks;
- };
-
-//-----------------------------------------------
-
-_LIT(KGetPerfTestResults, "GetPerfTestResults");
-_LIT(KIniTestMode, "TestMode");
-_LIT(KResultsSection, "Output");
-
-class CPerfTestStep : public CTestStep
- {
-public:
- enum TTestModes
- {
- ETiming,
- EBoot
- };
-
- inline CPerfTestStep(){SetTestStepName(KGetPerfTestResults);};
- virtual TVerdict doTestStepL(void);
-
-private:
- void ConvertTickToSecAndMilli(TUint32 aTick, TUint& aSec, TUint& aMilliSec);
-
-private:
- TInt iTickFreq;
- };
-
-#include "TE_PerfTestStep.inl"
-
-#endif
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_PerfTestStep.inl Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,47 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-// class TRepStatistics
-inline TRepStatistics::TRepStatistics()
- : iRepUid(0), iUseCount(0), iSumLoadTicks(0), iCacheMisses(0)
- {
- }
-
-inline TRepStatistics::TRepStatistics(const TRepStatistics& aRepStatistics)
- {
- iRepUid = aRepStatistics.iRepUid;
- iUseCount = aRepStatistics.iUseCount;
- iSumLoadTicks = aRepStatistics.iSumLoadTicks;
- iCacheMisses = aRepStatistics.iCacheMisses;
- }
-
-inline TRepStatistics::TRepStatistics(TUint32 aRepUid, TUint32 aLoadTicks)
- : iRepUid(aRepUid), iUseCount(1), iSumLoadTicks(aLoadTicks), iCacheMisses(0)
- {
- }
-
-inline TBool TRepStatistics::MatchUid(TUint32 aRepUid) const
- {
- return iRepUid == aRepUid;
- }
-
-//-------------------------------------
-// class TIpcStatistics
-
-inline TIpcStatistics::TIpcStatistics()
- : iUseCount(0), iSumElapsedTicks(0)
- {
- }
-
--- a/persistentstorage/centralrepository/test/testexecute/performance/inc/TE_PerfTestUtilities.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,42 +0,0 @@
-// Copyright (c) 2006-2009 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:
-// TE_MemTestFileOpenStep.h
-//
-//
-
-#ifndef __TE_PERFTESTUTILITIES_H__
-#define __TE_PERFTESTUTILITIES_H__
-
-#include <e32base.h>
-
-//Utility function that converts fast counter result to milliseconds in real
-TReal FastCountToMillisecondsInReal(TInt aFastCount);
-
-//Utility function that converts fast counter result to microseconds in real
-TReal FastCountToMicrosecondsInReal(TInt aFastCount);
-
-//Utility function that converts fast counter result to milliseconds in int
-TUint64 FastCountToMillisecondsInInt(TInt aFastCount);
-
-//Utility function that converts fast counter result to microseconds in int
-TUint64 FastCountToMicrosecondsInInt(TInt aFastCount);
-
-//Utility function that measures the free ram size in bytes
-TInt FreeRamSize();
-
-//Utility function to cleanup cache
-void CleanupRepositoryCache();
-
-#endif //__TE_PERFTESTUTILITIES_H__
-
--- a/persistentstorage/centralrepository/test/testexecute/performance/scripts/TE_PerfTest.script Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,152 +0,0 @@
-// Copyright (c) 2006-2009 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:
-//
-
-//! @file
-//! @SYMTestSuiteName PDS-TEF-CENTREP-PERFORMANCE
-//! @SYMScriptTestEnvironment TEF
-//! @internalComponent
-//! @test
-
-PRINT CentralRepository TEF Performance Tests
-
-LOAD_SUITE CentRepPerfTest
-
-//Delay to make sure that boot has completed.
-DELAY 60000
-
-START_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1424
-//! @SYMTestCaseID SYSLIBS-CENTRALREPOSITORY-PT-1424
-//! @SYMTestCaseDesc Measure CPU time usage by CentralRepositorySrv during boot
-//! @SYMTestPriority Critical
-//! @SYMTestActions Retrieve performance data collected by CentRep server, analyze, and
-//! print out a summary of the performance data.
-//! @SYMTestExpectedResults This test always passes. Engineers working on CentRep
-//! improvement will run this suite before and after submission to gage actual
-//! savings in CPU time.
-//! @SYMPREQ PREQ1192
-//! @SYMTestStatus Defined
-RUN_TEST_STEP 300 CentRepPerfTest GetPerfTestResults z:\TEF_CentralRepository\perf.ini boottest
-
-END_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1424
-
-START_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1425
-//! @SYMTestCaseID SYSLIBS-CENTRALREPOSITORY-PT-1425
-//! @SYMTestCaseDesc Measure Heap usage by CentralRepositorySrv repositories during boot
-//! @SYMTestPriority Critical
-//! @SYMTestActions Retrieve performance data collected by CentRep server, analyze, and
-//! print out a summary.
-//! @SYMTestExpectedResults This test always passes. Engineers working on CentRep
-//! improvement will run this suite before and after submission to gauge actual
-//! savings in RAM usage of repositories.
-//! @SYMPREQ PREQ1192
-//! @SYMTestStatus Defined
-RUN_TEST_STEP 300 CentRepPerfTest CentRepMemTestLogger
-
-END_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1425
-
-START_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1459
-//! @SYMTestCaseID SYSLIBS-CENTRALREPOSITORY-PT-1459
-//! @SYMTestCaseDesc Measure CPU time used by CentRep client and server for Find~L API.
-//! @SYMTestPriority Critical
-//! @SYMTestActions Call Find~L API and measure the time it takes for completion then
-//! report the summary.
-//! @SYMTestExpectedResults This test always passes. Engineers working on CentRep
-//! improvement will run this suite before and after submission to gauge actual
-//! savings in CPU time.
-//! @SYMPREQ PREQ1192
-//! @SYMTestStatus Defined
-RUN_TEST_STEP 300 CentRepPerfTest CentRepFindPerfTest
-END_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1459
-
-START_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1423 //CachePerformance
-SHARED_DATA z:\TEF_CentralRepository\perf.ini Shared
-//! @SYMTestCaseID SYSLIBS-CENTRALREPOSITORY-PT-1423
-//! @SYMTestCaseDesc Measure cached repository access time in CentralRepository
-//! @SYMTestPriority High
-//! @SYMTestActions Bring up server, connect, access repositories, retrieve performance
-//! data, analyze, and print out a summary of the performance data.
-//! @SYMTestExpectedResults This test always passes. Engineers working on CentRep
-//! improvement will run this suite before and after submission to gage actual
-//! savings in CPU time.
-//! @SYMPREQ PREQ1192
-//! @SYMTestStatus Defined
-
- RUN_TEST_STEP 1200 CentRepPerfTest PerfTestCacheEnabledStep
- PRINT --- Performance data for repository access with Caching ENABLED ---
- RUN_TEST_STEP 300 CentRepPerfTest GetPerfTestResults z:\TEF_CentralRepository\perf.ini timingtest1
- RUN_TEST_STEP 1200 CentRepPerfTest PerfTestCacheDisabledStep
- PRINT --- Performance data for repository access with Caching DISABLED ---
- RUN_TEST_STEP 300 CentRepPerfTest GetPerfTestResults z:\TEF_CentralRepository\perf.ini timingtest2
- RUN_TEST_STEP 300 CentRepPerfTest PerfTestCompareStep z:\TEF_CentralRepository\perf.ini Shared
-END_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1423 //CachePerformance
-
-START_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1482
-//! @SYMTestCaseID SYSLIBS-CENTRALREPOSITORY-PT-1482
-//! @SYMTestCaseDesc Central repository persists operation performance could be improved
-//! @SYMTestPriority High
-//! @SYMTestActions Calculate Average time to open large repository from ROM file, average time to open
-//! large repository from persists file and average time to write large repository to persists file.
-//! @SYMTestExpectedResults This test always passes.
-//! @SYMDEF DEF057491
-//! @SYMTestStatus Defined
-RUN_TEST_STEP 300 CentRepPerfTest CentRepDefectTest057491
-END_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1482
-
-
-START_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1483
-//! @SYMTestCaseID SYSLIBS-CENTRALREPOSITORY-PT-1483
-//! @SYMTestCaseDesc Central Repository adds 11s to 9.1 NAND boot time
-//! @SYMTestPriority High
-//! @SYMTestActions Calculate time to open text based rep from ROM, time to open binary rep from ROM,
-//! average time to open text based rep from ROM, average time to open binary rep from ROM,
-//! compare results and prove that opening .ini is slower than opening .cre files
-//! @SYMTestExpectedResults This test always passes.
-//! @SYMDEF DEF059633
-//! @SYMTestStatus Defined
-RUN_TEST_STEP 300 CentRepPerfTest CentRepDefectTest059633
-
-END_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1483
-
-
-START_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1657
-//! @SYMTestCaseID SYSLIBS-CENTRALREPOSITORY-PT-1657
-//! @SYMTestCaseDesc Measure the time to open/close multiple repositories from a single thread
-//! @SYMTestPriority High
-//! @SYMTestActions Measure CPU time, open n repositories, measure CPU time, report the time it
-//! takes to open all repositories. Measure CPU time, close n repositories, measure
-//! CPU time, report the time it takes to close all repositories. Repeat all of
-//! the steps for n=1..5
-//! @SYMTestExpectedResults This test always passes. Engineers working on CentRep improvements
-//! will run this suite before and after submission to gauge actual savings
-//! in CPU time.
-//! @SYMPREQ PREQ1228
-//! @SYMTestStatus Defined
-RUN_TEST_STEP 300 CentRepPerfTest PerfTestClientOpenStep
-END_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1657
-
-START_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1658 //Notify-OnlyRAM
-//! @SYMTestCaseID SYSLIBS-CENTRALREPOSITORY-PT-1658
-//! @SYMTestCaseDesc Notify-only client optimization RAM usage test
-//! @SYMTestPriority High
-//! @SYMTestActions Retrieve memory usage data collected by CentRep server, analyze, and
-//! print out a summary during certain stages of the lifetime of session objects.
-//! @SYMTestExpectedResults This test always pass. Engineers working on CentRep
-//! improvement will run this suite before and after submission to gauge actual
-//! savings in RAM usage of repositories.
-//! @SYMPREQ PREQ1228
-//! @SYMTestStatus Defined
-
- RUN_TEST_STEP 300 CentRepPerfTest NotifyMemTestStep
-END_TESTCASE SYSLIBS-CENTRALREPOSITORY-PT-1658 //Notify-OnlyRAM
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_DefectTestStep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,287 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#include "TE_DefectTestStep.h"
-#include "TE_PerfTestUtilities.h"
-#include <centralrepository.h>
-#include "t_cenrep_helper.h"
-#include "srvdefs.h"
-#include "srvreqs.h"
-#include <bautils.h>
-#include "cachemgr.h"
-
-#ifdef __CENTREP_SERVER_CACHETEST__
-
-const TUid KUidLargeRepository = { 0xCCCCCC01 };
-const TUid KUidRep1 = { 0x00000100 };
-const TUid KUidLargeCreRepository = { 0xCCCCCC02 };
-
-const TUint32 KNewInt = 1000;
-const TInt KIntValue = 1234;
-
-const TInt KNumOfAttempts = 10;
-
-_LIT(KZRep1File, "z:\\private\\10202BE9\\00000100.txt");
-_LIT(KCRep1TxtFile, "c:\\private\\10202BE9\\persists\\00000100.txt");
-_LIT(KCRep1CreFile, "c:\\private\\10202BE9\\persists\\00000100.cre");
-#endif
-
-CPerfTestDefectStep057491::CPerfTestDefectStep057491()
- {
- SetTestStepName(KPerfTestDefectStepDEF057491);
- }
-
-TVerdict CPerfTestDefectStep057491::doTestStepL()
- {
-#ifndef __CENTREP_SERVER_CACHETEST__
- return EPass;
-#else
- SetTestStepResult(EFail);
-
- CRepository* rep;
- TInt64 totalRomMs=0;
- TInt64 totalCreMs=0;
- TInt64 totalRepWriteMs=0;
-
- TUint32 startFastCounter;
- TUint64 fastCounterromOpenMicroseconds;
- TUint64 fastCounterrepWriteMicroseconds;
- TUint64 fastCountercreOpenMicroseconds;
-
- // Flush and disable cache for this test
- TInt r;
- r = SetGetParameters(TIpcArgs(EDisableCache));
- TEST(r==KErrNone);
-
- // Time opening and writing repository
- for(TInt i=0; i<KNumOfAttempts;i++)
- {
- // Get start time for ROM file
- startFastCounter = User::FastCounter();
- User::LeaveIfNull(rep = CRepository::NewLC(KUidLargeRepository));
-
- // Get finish time for ROM file
- fastCounterromOpenMicroseconds = FastCountToMicrosecondsInInt(User::FastCounter() - startFastCounter);
- totalRomMs+=fastCounterromOpenMicroseconds;
- Logger().WriteFormat(_L("Time to open large repos from ROM file = %lu microseconds\n"), fastCounterromOpenMicroseconds);
-
- startFastCounter = User::FastCounter();
- TInt r = rep->Create(KNewInt, KIntValue);
- fastCounterrepWriteMicroseconds = FastCountToMicrosecondsInInt(User::FastCounter() - startFastCounter);
- totalRepWriteMs+=fastCounterrepWriteMicroseconds;
- Logger().WriteFormat(_L("Time to write large repos file = %lu microseconds\n"), fastCounterrepWriteMicroseconds);
-
- TEST(r==KErrNone);
-
- // Close repository
- CleanupStack::PopAndDestroy(rep);
-
- // Get start time and ticks for .cre file
- startFastCounter = User::FastCounter();
-
- // Open repository
- User::LeaveIfNull(rep = CRepository::NewLC(KUidLargeRepository));
-
- // Get finish time and ticks for .cre file
- fastCountercreOpenMicroseconds = FastCountToMicrosecondsInInt(User::FastCounter() - startFastCounter);
- totalCreMs+=fastCountercreOpenMicroseconds;
- Logger().WriteFormat(_L("Time to open large repos from persists file = %lu microseconds\n"), fastCountercreOpenMicroseconds);
-
-#if !defined(__WINS__) && !defined(__WINSCW__)
- TEST(fastCounterromOpenMicroseconds>fastCountercreOpenMicroseconds);
-#endif
- const TUint32 KIntKey1 = 8847616;
- const TInt KIntKey1Value = 1;
- const TUint32 KIntKey2 = 139068928;
- const TInt KIntKey2Value = 30;
- const TUint32 KIntKey3 = 2373975808UL;
- const TInt KIntKey3Value = -1920991488;
-
- // Test 3 random int key values from repository
- TInt keyValue;
- r=rep->Get(KIntKey1, keyValue);
- TEST(r == KErrNone);
- TEST(keyValue == KIntKey1Value);
-
- r=rep->Get(KIntKey2, keyValue);
- TEST(r == KErrNone);
- TEST(keyValue == KIntKey2Value);
-
- r=rep->Get(KIntKey3, keyValue);
- TEST(r == KErrNone);
- TEST(keyValue == KIntKey3Value);
-
- // Close repository
- CleanupStack::PopAndDestroy(rep);
-
- CleanupFileFromCDriveL(KUidLargeRepository);
- }
-
- Logger().WriteFormat(_L("Average time to open large repos from ROM file = %lu ms\n"), totalRomMs/KNumOfAttempts);
- Logger().WriteFormat(_L("Average time to open large repos from persists file = %lu ms\n"), totalCreMs/KNumOfAttempts);
- Logger().WriteFormat(_L("Average time to write large repos to persists file = %lu ms\n"), totalRepWriteMs/KNumOfAttempts);
-
- RFs fs;
- User::LeaveIfError(fs.Connect());
- CleanupClosePushL(fs);
- CFileMan* fm = CFileMan::NewL(fs);
- CleanupStack::PushL(fm);
- // Copy a repository txt file to the C:
- User::LeaveIfError(fm->Copy(KZRep1File, KCPersistsDir));
- // Reset read-only bit
- User::LeaveIfError(fm->Attribs(KCRep1TxtFile,0,KEntryAttReadOnly,TTime(0)));
- // Check it exists
- TEST( BaflUtils::FileExists (fs, KCRep1TxtFile));
-
- // Open repository
- User::LeaveIfNull(rep = CRepository::NewLC(KUidRep1));
-
- // Create a setting
- r = rep->Create(KNewInt, KIntValue);
- TEST(r == KErrNone);
-
- // Check persists file exists
- TEST(BaflUtils::FileExists (fs, KCRep1CreFile));
-
- // Check that .txt file is gone
- TEST(BaflUtils::FileExists (fs, KCRep1TxtFile) == EFalse);
-
- // Close the repository
- CleanupStack::PopAndDestroy(rep);
-
- CleanupStack::PopAndDestroy(2); // fm, fs
-
- CleanupFileFromCDriveL(KUidRep1);
-
- // Enable cache
- r = SetGetParameters(TIpcArgs(EEnableCache, KDefaultEvictionTimeout, KDefaultCacheSize));
- TEST(r==KErrNone);
-
- SetTestStepResult(EPass);
-
- return TestStepResult();
-#endif
- }
-
-CPerfTestDefectStep059633::CPerfTestDefectStep059633()
- {
- SetTestStepName(KPerfTestDefectStepDEF059633);
- }
-
-TVerdict CPerfTestDefectStep059633::doTestStepL()
- {
-#ifndef __CENTREP_SERVER_CACHETEST__
- return EPass;
-#else
- SetTestStepResult(EFail);
-
- // Flush and disable cache for this test
- TInt r;
- r = SetGetParameters(TIpcArgs(EDisableCache));
- TEST(r==KErrNone);
-
- CleanupFileFromCDriveL(KUidLargeRepository);
- CleanupFileFromCDriveL(KUidLargeCreRepository);
-
- CRepository* rep;
-
- TUint32 startFastCounter;
- TUint64 fastCountertimeToOpenLargeIniRep;
- TUint64 fastCountertimeToOpenLargeCreRep;
- TUint64 fastCountertimeToOpenXLargeInis;
- TUint64 fastCountertimeToOpenXLargeCres;
-
- //=========================================================================================
- //Single .ini - opening
- startFastCounter = User::FastCounter();
- User::LeaveIfNull(rep = CRepository::NewLC(KUidLargeRepository));
- fastCountertimeToOpenLargeIniRep = FastCountToMicrosecondsInInt(User::FastCounter() - startFastCounter);
- Logger().WriteFormat(_L("Time to open text based rep from ROM = %lu microseconds\n\n"), fastCountertimeToOpenLargeIniRep);
- CleanupStack::PopAndDestroy(rep);
-
- //=========================================================================================
- //KNumOfAttempts .ini
-
- startFastCounter = User::FastCounter();
- for (TInt i=0; i<KNumOfAttempts; i++)
- {
- User::LeaveIfNull(rep = CRepository::NewLC(KUidLargeRepository));
- CleanupStack::PopAndDestroy(rep);
- }
- fastCountertimeToOpenXLargeInis = FastCountToMicrosecondsInInt(User::FastCounter() - startFastCounter);
-
- //=========================================================================================
- //single .cre
- startFastCounter = User::FastCounter();
- User::LeaveIfNull(rep = CRepository::NewLC(KUidLargeCreRepository));
- fastCountertimeToOpenLargeCreRep = FastCountToMicrosecondsInInt(User::FastCounter() - startFastCounter);
- Logger().WriteFormat(_L("Time to open binary rep from ROM = %lu microseconds\n\n"), fastCountertimeToOpenLargeCreRep);
- CleanupStack::PopAndDestroy(rep);
-
- //=========================================================================================
- //KNumOfAttempts .cre
- startFastCounter = User::FastCounter();
- for (TInt j=0; j<KNumOfAttempts; j++)
- {
- User::LeaveIfNull(rep = CRepository::NewLC(KUidLargeCreRepository));
- CleanupStack::PopAndDestroy(rep);
- }
- fastCountertimeToOpenXLargeCres = FastCountToMicrosecondsInInt(User::FastCounter() - startFastCounter);
-
- //=========================================================================================
- //average
- TInt64 averageFastCounterTimeToOpenIni = fastCountertimeToOpenXLargeInis / KNumOfAttempts;
- Logger().WriteFormat(_L("Average time to open text based rep from ROM = %lu microseconds\n\n"), averageFastCounterTimeToOpenIni);
-
- TInt64 averageFastCounterTimeToOpenCre = fastCountertimeToOpenXLargeCres / KNumOfAttempts;
- Logger().WriteFormat(_L("Average time to open binary rep from ROM = %lu microseconds\n\n"), averageFastCounterTimeToOpenCre);
-
- //=========================================================================================
- //prove that opening .ini is slower than opening .cre files
- // (even though the difference is now much less after the performance
- // improvements of PREQ 1192, the test is now much more precise by using fastcounter)
-#if !defined(__WINS__) && !defined(__WINSCW__)
- TEST(fastCountertimeToOpenLargeIniRep > fastCountertimeToOpenLargeCreRep);
- TEST(fastCountertimeToOpenXLargeInis > fastCountertimeToOpenXLargeCres);
- TEST(averageFastCounterTimeToOpenIni > averageFastCounterTimeToOpenCre);
-#endif
-
- //==========================================================================================
- //benchmarks - open
- #if !defined(__WINS__) && !defined(__WINSCW__)
- #ifdef _DEBUG
- const TInt64 KOpenCreTime = 150000; //armv5 debug
- #else
- const TInt64 KOpenCreTime = 75000; //armv5 urel
- #endif
-
- TEST(averageFastCounterTimeToOpenCre < KOpenCreTime);
-
- #endif//!defined(__WINS__) && !defined(__WINSCW__)
-
- //========================================================================
-
- CleanupFileFromCDriveL(KUidLargeRepository);
- CleanupFileFromCDriveL(KUidLargeCreRepository);
-
- // Enable cache
- r = SetGetParameters(TIpcArgs(EEnableCache, KDefaultEvictionTimeout, KDefaultCacheSize));
- TEST(r==KErrNone);
-
- SetTestStepResult(EPass);
-
- return TestStepResult();
-#endif
- }
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_FindPerfTestStep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,103 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#include "TE_FindPerfTestStep.h"
-#include "TE_PerfTestUtilities.h"
-#include <centralrepository.h>
-#include "centralrepositoryinternal.h"
-#include <hal.h>
-#include <hal_data.h>
-
-using namespace NCentralRepositoryConstants;
-
-const TUid KUidFindPerfTestRepositorySmTxt = { 0x00000105 };
-
-CFindPerfTestStep::CFindPerfTestStep()
- {
- SetTestStepName(KFindPerfTestName);
- }
-
-// doTestStepL
-// This test fetches the memory data collected by
-// CentRep server, processes it and reports the result.
-TVerdict CFindPerfTestStep::doTestStepL()
- {
- SetTestStepResult(EFail);
-
- CRepository* repository = NULL;
- TRAPD(res, repository = CRepository::NewL(KUidFindPerfTestRepositorySmTxt));
- TESTL(res == KErrNone);
- TESTL(repository != NULL);
- CleanupStack::PushL(repository);
-
- //if the KCentRepFindBufSize has been increased to a value more then 16 then test
- //repository "KUidFindPerfTestRepositorySmTxt" needs to be updated otherwise this
- //test will start failing. In this case the repository should be updated to have
- //more entries.
- TESTL(KCentRepFindBufSize<=16);
-
- RArray<TUint32> foundIds;
- TUint32 accumulatedTicks = 0;
- for(TInt j=1; j<=KCentRepFindBufSize; j++)
- {
- accumulatedTicks = 0;
- for(TInt i=0; i<100; i++)
- {
- TInt r = KErrNone;
- TUint32 startTick = User::FastCounter();
- r = repository->FindEqL(0, 0, j, foundIds);
- TUint32 endTick = User::FastCounter();
-
- //check for errors
- TESTL(r == KErrNone);
- //check that number of found ids is as expected
- TESTL(foundIds.Count() == j);
-
- accumulatedTicks += endTick - startTick;
- }
-
- INFO_PRINTF3(_L("Total time spent to find settings of count %d is %f[ms]"), j, FastCountToMillisecondsInReal(accumulatedTicks));
- }
-
- //now run it one more time for settings of count more than KCentRepFindBufSize
- for(TInt j=1; j<=KCentRepFindBufSize; j++)
- {
- accumulatedTicks = 0;
- for(TInt i=0; i<100; i++)
- {
- TInt r = KErrNone;
- TUint32 startTick = User::FastCounter();
- r = repository->FindNeqL(0, 0, j, foundIds);
- TUint32 endTick = User::FastCounter();
-
- //check for errors
- TESTL(r == KErrNone);
- //check that number of found ids is as expected
- TESTL(foundIds.Count() > KCentRepFindBufSize);
-
- accumulatedTicks += endTick - startTick;
- }
-
- INFO_PRINTF3(_L("Total time spent to find settings of count %d is %f[ms]"), foundIds.Count(), FastCountToMillisecondsInReal(accumulatedTicks));
- }
-
- CleanupStack::PopAndDestroy(repository);
- repository = NULL;
-
- SetTestStepResult(EPass);
-
- return TestStepResult();
- }
-
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_MemTestStep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,157 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#include <centralrepository.h>
-#include "t_cenrep_helper.h"
-#include "srvPerf.h"
-#include "srvreqs.h"
-#include "TE_MemTestStep.h"
-
-#ifdef __CENTREP_SERVER_MEMTEST__
-// Method used for TIdentityRelation for TMemTestResult arrays
-TBool MatchMemTestResult(const TMemTestResult& aKey, const TMemTestResult& aIndexItem)
- {
- return aIndexItem.iLocation == aKey.iLocation &&
- aIndexItem.iIdentifier == aKey.iIdentifier &&
- aIndexItem.iIsComplete == aKey.iIsComplete;
- }
-
-void CMemTestStep::ProcessMemTestResults(TAny* aRawData, TInt32 aRawCount, RArray<TMemTestResult>& aMemTestResults)
- {
- ASSERT(aRawCount);
- ASSERT(aRawCount>=3);
-
- for(TInt i=0; i+2<aRawCount;)
- {
- TInt32 value1 = static_cast<TInt32*>(aRawData)[i++];
- TInt32 value2 = static_cast<TInt32*>(aRawData)[i++];
- TInt32 value3 = static_cast<TInt32*>(aRawData)[i++];
-
- if(value1 == KMagicMemTestOutOfBounds && value2 == KMagicMemTestOutOfBounds && value2 == KMagicMemTestOutOfBounds)
- {
- WARN_PRINTF1(_L("Memory test was not able to store all the requested values. Only the stored values will be reported."));
- }
- else
- {
- TMemTestResult result(value1, value2, EFalse);
- //look for not completed memTestResult that match the criteria
- TIdentityRelation<TMemTestResult> identity(MatchMemTestResult);
-
- TInt idx = aMemTestResults.Find(result, identity);
- if(idx == KErrNotFound)
- {
- result.iInitHeapSize = value3;
- aMemTestResults.Append(result);
- }
- else
- {
- TMemTestResult& foundResult = aMemTestResults[idx];
- foundResult.iFinalHeapSize = value3;
- foundResult.iIsComplete = ETrue;
- }
- }
- }
- }
-#endif //__CENTREP_SERVER_MEMTEST__
-
-CMemTestStep::CMemTestStep()
- {
- SetTestStepName(KMemTestName);
- }
-
-// doTestStepL
-// This test fetches the memory data collected by
-// CentRep server, processes it and reports the result.
-TVerdict CMemTestStep::doTestStepL()
- {
-#ifdef __CENTREP_SERVER_MEMTEST__
- SetTestStepResult(EFail);
- // Pause a few seconds to ensure startup sequence is finished.
-#ifdef __WINS__
- const TTimeIntervalMicroSeconds32 interval = 12000000;
-#else
- const TTimeIntervalMicroSeconds32 interval = 4000000;
-#endif
- User::After(interval);
-
- TAny* buf = User::AllocL((KMemBufMaxEntry) * sizeof(TInt32));
- CleanupStack::PushL(buf);
- TPtr8 pBuf(static_cast<TUint8*>(buf), (KMemBufMaxEntry) * sizeof(TInt32));
- TInt numEntries;
- TPckg<TInt> pNumEntries(numEntries);
- TInt error = SetGetParameters(TIpcArgs(EGetMemResults, &pNumEntries, &pBuf));
-
- if(error == KErrNone && numEntries > 0)
- {
- RArray<TMemTestResult> memTestResults;
-
- ProcessMemTestResults(buf, numEntries, memTestResults);
-
- TInt count = memTestResults.Count();
- for(TInt i=0; i<count; i++)
- {
- TMemTestResult& result = memTestResults[i];
- if(result.iIsComplete)
- {
- if(result.iLocation == EMemLcnRepositoryOpen)
- {
- Logger().WriteFormat(_L("Memory usage for repository [%08X]: %d"),
- result.iIdentifier,
- result.iFinalHeapSize - result.iInitHeapSize);
- }
- else if(result.iLocation == EMemLcnOnDemand)
- {
- Logger().WriteFormat(_L("Heap memory usage of Centrep server at step %d: %d"),
- result.iIdentifier,
- result.iFinalHeapSize);
- static TInt prevResult;
- switch (result.iIdentifier)
- {
- case 1: TESTL(result.iFinalHeapSize > prevResult); break;
- case 3: TESTL(result.iFinalHeapSize < prevResult); break;
- case 4: TESTL(result.iFinalHeapSize > prevResult); break;
- }
- prevResult = result.iFinalHeapSize;
- }
- else
- {
- Logger().WriteFormat(_L("Memory usage at location[%d] for identifier[%d]: %d"),
- result.iLocation,
- result.iIdentifier,
- result.iFinalHeapSize - result.iInitHeapSize);
- }
- }
- else
- {
- Logger().WriteFormat(_L("Incomplete memory reading at location[%d] for identifier[%d]"),
- result.iLocation,
- result.iIdentifier);
- }
- }
- }
-
- CleanupStack::PopAndDestroy();
-
- if(error == KErrNone)
- {
- SetTestStepResult(EPass);
- }
-#else
- WARN_PRINTF1(_L("Memory test macro __CENTREP_SERVER_MEMTEST__ is not defined. Test was not run."));
-#endif //__CENTREP_SERVER_MEMTEST__
-
- return TestStepResult();
- }
-
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_NotifyMemTestStep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,208 +0,0 @@
-// Copyright (c) 2006-2009 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:
-//
-
-#include "TE_NotifyMemTestStep.h"
-#include "TE_PerfTestUtilities.h"
-#include "t_cenrep_helper.h"
-#include <centralrepository.h>
-#include "srvreqs.h"
-#include "srvPerf.h"
-#include "srvdefs.h"
-#include "cachemgr.h"
-
-//--------------------------------
-// class CNotifyMemTestStep
-//--------------------------------
-
-#if defined(__CENTREP_SERVER_MEMTEST__)
-const TUid KUidTestRepository1 = { 0x00000001 };
-const TUid KUidCacheTestRepositorySmTxt = { 0x00000100 };
-const TUid KUidCacheTestRepositoryMedTxt = { 0x10057522 };
-const TUid KUidCacheTestRepositorySmCre = { 0x22222221 };
-const TUid KUidCacheTestRepositoryLrgCre = { 0xCCCCCC02 };
-
-const TInt KKey1 = 1;
-const TInt KKey2 = 0x201;
-const TInt KKey3 = 8585472;
-const TInt KKey4 = 22;
-#endif
-
-#ifdef __CENTREP_SERVER_MEMTEST__
-void CNotifyMemTestStep::ProcessMemTestResults(TAny* aRawData, TInt32 aRawCount, RArray<TMemTestResult>& aMemTestResults)
- {
- ASSERT(aRawCount);
- ASSERT(aRawCount>=3);
-
- for(TInt i=0; i+2<aRawCount;)
- {
- TInt32 value1 = static_cast<TInt32*>(aRawData)[i++];
- TInt32 value2 = static_cast<TInt32*>(aRawData)[i++];
- TInt32 value3 = static_cast<TInt32*>(aRawData)[i++];
-
- if(value1 == KMagicMemTestOutOfBounds && value2 == KMagicMemTestOutOfBounds && value2 == KMagicMemTestOutOfBounds)
- {
- WARN_PRINTF1(_L("Memory test was not able to store all the requested values. Only the stored values will be reported."));
- }
- else
- {
- TMemTestResult result(value1, value2, ETrue);
- if(result.iLocation == EMemLcnOnDemand)
- {
- result.iInitHeapSize = 0;
- result.iFinalHeapSize = value3;
- aMemTestResults.Append(result);
- }
- }
- }
- }
-#endif //__CENTREP_SERVER_MEMTEST__
-
-/**
-@SYMTestCaseID SYSLIBS-CENTRALREPOSITORY-PT-1658
-@SYMTestCaseDesc Notify-only client optimization RAM usage test
-@SYMTestPriority High
-@SYMTestActions Retrieve memory usage data collected by CentRep server, analyze, and
- print out a summary during certain stages of the lifetime of session objects.
-@SYMTestExpectedResults This test always pass. Engineers working on CentRep
- improvement will run this suite before and after submission to gauge actual
- savings in RAM usage of repositories.
-@SYMPREQ PREQ 1228 Symbian OS v9.3 System Quality: Performance, ROM and RAM targets
-*/
-TVerdict CNotifyMemTestStep::doTestStepL()
- {
-#if defined(__CENTREP_SERVER_MEMTEST__)
-
- SetTestStepResult(EFail);
-
- TInt testSteps = 0;
- TInt r;
-
- // Make sure cache is empty before we start
-#ifdef __CENTREP_SERVER_CACHETEST__
- r = SetGetParameters(TIpcArgs(EDisableCache));
- TESTL(r==KErrNone);
- r = SetGetParameters(TIpcArgs(EEnableCache, KDefaultEvictionTimeout, KDefaultCacheSize));
- TESTL(r==KErrNone);
-#else //__CENTREP_SERVER_CACHETEST__
- CleanupRepositoryCache();
-#endif //__CENTREP_SERVER_CACHETEST__
- //Reset RAM test data
- r = SetGetParameters(TIpcArgs(ERestartMemTests));
- TESTL(r==KErrNone);
-
- // Start of test
- Logger().WriteFormat(_L("Step %d, RAM at the beginning of test"),testSteps);
- r = SetGetParameters(TIpcArgs(ESingleMemTest, testSteps++));
- TESTL(r==KErrNone);
-
- CRepository* repository1;
- User::LeaveIfNull(repository1 = CRepository::NewLC(KUidTestRepository1));
- CRepository* repository2;
- User::LeaveIfNull(repository2 = CRepository::NewLC(KUidCacheTestRepositorySmTxt));
- CRepository* repository3;
- User::LeaveIfNull(repository3 = CRepository::NewLC(KUidCacheTestRepositoryMedTxt));
- CRepository* repository4;
- User::LeaveIfNull(repository4 = CRepository::NewLC(KUidCacheTestRepositorySmCre));
- CRepository* repository5;
- User::LeaveIfNull(repository5 = CRepository::NewLC(KUidCacheTestRepositoryLrgCre));
-
- // Reps automatically loaded by Init
- Logger().WriteFormat(_L("Step %d, RAM after sessions created"),testSteps);
- r = SetGetParameters(TIpcArgs(ESingleMemTest, testSteps++));
- TESTL(r==KErrNone);
-
- TInt i;
- r = repository1->Get(KKey1, i);
- TESTL(r==KErrNone);
- r = repository2->Get(KKey2, i);
- TESTL(r==KErrNone);
- r = repository3->Get(KKey4, i);
- TESTL(r==KErrNone);
- r = repository4->Get(KKey1, i);
- TESTL(r==KErrNone);
- r = repository5->Get(KKey3, i);
- TESTL(r==KErrNone);
-
- // Get's don't change memory usage because reps are already loaded/in cache
- Logger().WriteFormat(_L("Step %d, RAM after Get() calls"),testSteps);
- r = SetGetParameters(TIpcArgs(ESingleMemTest, testSteps++));
- TESTL(r==KErrNone);
-
-#ifdef __CENTREP_SERVER_CACHETEST__
- r = SetGetParameters(TIpcArgs(EDisableCache));
- TESTL(r==KErrNone);
- r = SetGetParameters(TIpcArgs(EEnableCache, KDefaultEvictionTimeout, KDefaultCacheSize));
- TESTL(r==KErrNone);
-#else //__CENTREP_SERVER_CACHETEST__
- CleanupRepositoryCache();
-#endif //__CENTREP_SERVER_CACHETEST__
-
- // Memory freed after reps are evicted
- Logger().WriteFormat(_L("Step %d, RAM after delaying for eviction"),testSteps);
- r = SetGetParameters(TIpcArgs(ESingleMemTest, testSteps++));
- TESTL(r==KErrNone);
-
- r = repository1->Get(KKey1, i);
- TESTL(r==KErrNone);
- r = repository2->Get(KKey2, i);
- TESTL(r==KErrNone);
- r = repository3->Get(KKey4, i);
- TESTL(r==KErrNone);
- r = repository4->Get(KKey1, i);
- TESTL(r==KErrNone);
- r = repository5->Get(KKey3, i);
- TESTL(r==KErrNone);
-
- // This time Get's trigger loads
- Logger().WriteFormat(_L("Step %d, RAM after Get() calls"),testSteps);
- r = SetGetParameters(TIpcArgs(ESingleMemTest, testSteps++));
- TESTL(r==KErrNone);
-
- CleanupStack::PopAndDestroy(5);
-
- // Closing sessions don't unload the reps because of coarse grained caching
- Logger().WriteFormat(_L("Step %d, RAM after sessions are closed"),testSteps);
- r = SetGetParameters(TIpcArgs(ESingleMemTest, testSteps++));
- TESTL(r==KErrNone);
-
-#ifdef __CENTREP_SERVER_CACHETEST__
- r = SetGetParameters(TIpcArgs(EDisableCache));
- TESTL(r==KErrNone);
- r = SetGetParameters(TIpcArgs(EEnableCache, KDefaultEvictionTimeout, KDefaultCacheSize));
- TESTL(r==KErrNone);
-#else //__CENTREP_SERVER_CACHETEST__
- CleanupRepositoryCache();
-#endif //__CENTREP_SERVER_CACHETEST__
-
- // Reps are unloaded by cache manager
- Logger().WriteFormat(_L("Step %d, RAM after delaying for eviction"),testSteps);
- r = SetGetParameters(TIpcArgs(ESingleMemTest, testSteps++));
- TESTL(r==KErrNone);
-
- // call inherited function to get the results
- SetTestStepResult(CMemTestStep::doTestStepL());
-
- return TestStepResult();
-#else // defined(__CENTREP_SERVER_MEMTEST__)
-
- _LIT(KWarnMemTestMacroOff, "Memory test macro __CENTREP_SERVER_MEMTEST__ is disabled. Test not run.");
- WARN_PRINTF1(KWarnMemTestMacroOff);
-
- return EPass;
-# endif // defined(__CENTREP_SERVER_MEMTEST__)
-
-
-
- }
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_PerfTestCacheDisabledStep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,51 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#include <centralrepository.h>
-#include "t_cenrep_helper.h"
-#include "srvreqs.h"
-#include "TE_PerfTestCacheDisabledStep.h"
-
-//---------------------------------
-// class CPerfTestCacheDisabledStep
-//---------------------------------
-
-CPerfTestCacheDisabledStep::CPerfTestCacheDisabledStep()
- {
- SetTestStepName(KPerfTestCacheDisabledStep);
- }
-
-// doTestStepL
-// Implement the pure virtual function.
-// This accesses a small and a large repository various times when cache is
-// enabled and disabled.
-TVerdict CPerfTestCacheDisabledStep::doTestStepL()
- {
-#ifndef __CENTREP_SERVER_CACHETEST__
- return EPass;
-#else
- SetTestStepResult(EFail);
-
- TInt r;
-
- r = SetGetParameters(TIpcArgs(EDisableCache));
- TESTL(r==KErrNone);
-
- CommonTestStepL();
-
- return TestStepResult();
-#endif
- }
-
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_PerfTestCacheEnabledStep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,55 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#include <centralrepository.h>
-#include "srvreqs.h"
-#include "srvdefs.h"
-#include "t_cenrep_helper.h"
-#include "TE_PerfTestCacheEnabledStep.h"
-#include "cachemgr.h"
-
-//--------------------------------
-// class CPerfTestCacheEnabledStep
-//--------------------------------
-
-CPerfTestCacheEnabledStep::CPerfTestCacheEnabledStep()
- {
- SetTestStepName(KPerfTestCacheEnabledStep);
- }
-
-// doTestStepL
-// Implement the pure virtual function.
-// This accesses a small and a large repository various times when cache is
-// enabled and disabled.
-TVerdict CPerfTestCacheEnabledStep::doTestStepL()
- {
-#ifndef __CENTREP_SERVER_CACHETEST__
- return EPass;
-#else
- SetTestStepResult(EFail);
-
- TInt r;
-
- r = SetGetParameters(TIpcArgs(EEnableCache, KDefaultEvictionTimeout, KDefaultCacheSize));
- // Shouldn't leave here if SetGetParameters is not supported (when running with old server)
-
- TEST(r==KErrNone);
-
- CommonTestStepL();
-
- return TestStepResult();
-#endif
- }
-
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_PerfTestCacheStepBase.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,85 +0,0 @@
-// Copyright (c) 2005-2009 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:
-// TE_PerfTestCacheEnabledStep.cpp
-//
-//
-
-#include "TE_PerfTestCacheStepBase.h"
-#include <centralrepository.h>
-#include "t_cenrep_helper.h"
-#include "srvreqs.h"
-
-//--------------------------------
-// class CPerfTestCacheStepBase
-//--------------------------------
-
-#if defined(__CENTREP_SERVER_CACHETEST__) && defined(__CENTREP_SERVER_PERFTEST__)
-const TUid KUidCacheTestRepositorySmTxt = { 0x00000002 };
-const TUid KUidCacheTestRepositoryLrgTxt = { 0xCCCCCC01 };
-const TUid KUidCacheTestRepositorySmCre = { 0x22222221 };
-const TUid KUidCacheTestRepositoryLrgCre = { 0xCCCCCC02 };
-#endif
-
-// CommonTestStepL
-// This function accesses a small and a large repository various times
-// when cache is enabled and disabled.
-void CPerfTestCacheStepBase::CommonTestStepL()
- {
- SetTestStepResult(EFail);
-
-#if defined(__CENTREP_SERVER_CACHETEST__) && defined(__CENTREP_SERVER_PERFTEST__)
- TInt r = SetGetParameters(TIpcArgs(ERestartPerfTests));
- TEST(r==KErrNone);
-
- CRepository* repository;
- TInt i;
- // Access small text rep 5 times in a row
- for(i=0; i<5; i++)
- {
- User::LeaveIfNull(repository = CRepository::NewL(KUidCacheTestRepositorySmTxt));
- delete repository;
- repository = NULL;
- User::After(200000); // delay 200ms before access
- }
-
- // Access large text rep 5 times in a row
- for(i=0; i<5; i++)
- {
- User::LeaveIfNull(repository = CRepository::NewL(KUidCacheTestRepositoryLrgTxt));
- delete repository;
- repository = NULL;
- User::After(200000); // delay 200ms before access
- }
-
- // Access small binary rep 20 times in a row
- for(i=0; i<20; i++)
- {
- User::LeaveIfNull(repository = CRepository::NewL(KUidCacheTestRepositorySmCre));
- delete repository;
- repository = NULL;
- User::After(200000); // delay 200ms before access
- }
-
- // Access large binary rep 20 times in a row
- for(i=0; i<20; i++)
- {
- User::LeaveIfNull(repository = CRepository::NewL(KUidCacheTestRepositoryLrgCre));
- delete repository;
- repository = NULL;
- User::After(200000); // delay 200ms before access
- }
- SetTestStepResult(EPass);
-
-#endif
- }
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_PerfTestClientOpenStep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,115 +0,0 @@
-// Copyright (c) 2006-2009 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:
-//
-
-#include "TE_PerfTestClientOpenStep.h"
-#include "TE_PerfTestUtilities.h"
-#include "t_cenrep_helper.h"
-#include "srvreqs.h"
-#include "srvdefs.h"
-#include <centralrepository.h>
-#include "cachemgr.h"
-
-#ifdef __CENTREP_SERVER_CACHETEST__
-
-const TInt KMaxRepositories = 5;
-const TInt KIterationCount = 100;
-const TUid KUidClientOpenTestRepositoryIds[KMaxRepositories] = { 0x00000106,
- 0x00000107,
- 0x00000108,
- 0x00000109,
- 0x0000010A };
-#endif //__CENTREP_SERVER_CACHETEST__
-
-CPerfTestClientOpenStep::CPerfTestClientOpenStep()
- {
- SetTestStepName(KPerfTestClientOpenName);
- }
-
-// doTestStepL
-// This test fetches the memory data collected by
-// CentRep server, processes it and reports the result.
-TVerdict CPerfTestClientOpenStep::doTestStepL()
- {
- SetTestStepResult(EFail);
-
-#ifndef __CENTREP_SERVER_CACHETEST__
- WARN_PRINTF1(_L("Test macro __CENTREP_SERVER_CACHETEST__ is not defined. Unable to disable cache. Test was not run."));
-#else
- CRepository* repositories[KMaxRepositories];
- TReal openResults[KMaxRepositories];
- TReal closeResults[KMaxRepositories];
- TInt res = KErrNone;
-
- //enable cache back.
- res = SetGetParameters(TIpcArgs(EDisableCache, KDefaultEvictionTimeout, KDefaultCacheSize));
- TESTL(res == KErrNone);
-
- for(TInt i=0; i<KMaxRepositories; i++)
- {
- openResults[i] = 0;
- closeResults[i] = 0;
- }
-
- for(TInt k=0; k<KIterationCount; k++)
- {
- //all of these operations are repeated for 100 times. Otherwise the measurement value
- //is too small to have an accurate value
- for(TInt i=0; i<KMaxRepositories; i++)
- {
- TUint32 startTick = 0;
- TUint32 endTick = 0;
-
- //open repositories and measure how long it takes to open them.
- for(TInt j=0; j<=i; j++)
- {
- startTick = User::FastCounter();
- TRAP(res, repositories[j] = CRepository::NewL(KUidClientOpenTestRepositoryIds[j]));
- endTick = User::FastCounter();
- openResults[i] += endTick - startTick;
-
- TESTL(res == KErrNone);
- TESTL(repositories[j] != NULL);
- CleanupStack::PushL(repositories[j]);
- }
-
- //close repositories in the reverse order, make sure cleanup stack is happy.
- for(TInt j=i; j>=0; j--)
- {
- startTick = User::FastCounter();
- CleanupStack::PopAndDestroy(repositories[j]);
- endTick = User::FastCounter();
- closeResults[i] += endTick - startTick;
-
- repositories[j] = NULL;
- }
- }
- }
-
- for(TInt i=0; i<KMaxRepositories; i++)
- {
- INFO_PRINTF4(_L("Total time spent to open %d times %d repositories is %f[ns]"), KIterationCount, i+1, FastCountToMicrosecondsInReal(openResults[i]));
- INFO_PRINTF4(_L("Total time spent to close %d times %d repositories is %f[ns]"), KIterationCount, i+1, FastCountToMicrosecondsInReal(closeResults[i]));
- }
-
- //enable cache back.
- res = SetGetParameters(TIpcArgs(EEnableCache, KDefaultEvictionTimeout, KDefaultCacheSize));
- TESTL(res == KErrNone);
-
-#endif
- SetTestStepResult(EPass);
-
- return TestStepResult();
- }
-
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_PerfTestCompareStep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,110 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#include "TE_PerfTestCompareStep.h"
-#include "t_cenrep_helper.h"
-#include <centralrepository.h>
-#include "srvreqs.h"
-#include "srvdefs.h"
-#include "cachemgr.h"
-
-//--------------------------------
-// class CPerfTestCompareStep
-//--------------------------------
-
-CPerfTestCompareStep::CPerfTestCompareStep()
- {
- SetTestStepName(KPerfTestCompareStep);
- }
-
-// doTestStepL
-// Implement the pure virtual function.
-// Comapre the results of previous timing tests
-TVerdict CPerfTestCompareStep::doTestStepL()
- {
-#ifndef __CENTREP_SERVER_CACHETEST__
- return EPass;
-#else
- SetTestStepResult(EFail);
-
- // To make sure future tests in this harness run under caching
- TInt r = SetGetParameters(TIpcArgs(EEnableCache, KDefaultEvictionTimeout, KDefaultCacheSize));
-
- TPtrC resultSection1;
- _LIT(KSharedName1, "shared_name_1");
- TInt bRet = GetStringFromConfig(ConfigSection(), KSharedName1, resultSection1);
- TESTL(bRet==1);
-
- TPtrC resultSection2;
- _LIT(KSharedName2, "shared_name_2");
- bRet = GetStringFromConfig(ConfigSection(), KSharedName2, resultSection2);
- TESTL(bRet==1);
-
- TBuf<KMaxFileName> sharedString;
-
- ReadSharedDataL(resultSection1, sharedString);
-
- ReadResults(iResults1, sharedString);
- sharedString.Zero();
- ReadSharedDataL(resultSection2, sharedString);
- ReadResults(iResults2, sharedString);
-
- TESTL(iResults1.Count()==iResults2.Count());
-
- for(TInt i=0; i<iResults1.Count(); i++)
- {
- TESTL(iResults1[i].iUseCount==iResults2[i].iUseCount);
-#if defined __WINS__ || defined __WINSCW__
- // This test is deactivated for emulator builds.
- // Emulator build runs produce inconsistent results when running this
- // test on ONB machines, probably because of uncontrolled CPU and disk
- // activity on the host system caused by previous build and test commands
-#else
- // Expect an increase in performance
- TESTL(iResults1[i].iSumElapsedTicks<iResults2[i].iSumElapsedTicks);
-#endif
- }
-
- SetTestStepResult(EPass);
-
- return TestStepResult();
-#endif //__CENTREP_SERVER_CACHETEST__
- }
-
-void CPerfTestCompareStep::ReadResults(RArray<TSummary>& aArray, TBuf<KMaxFileName>& aString)
- {
- TLex analyse(aString);
-
- TInt items;
- TSummary summary;
-
- for(TInt i=0; i<2; i++)
- {
- analyse.Val(items);
- analyse.SkipSpaceAndMark();
- for(TInt i=0;i<items;i++)
- {
- analyse.SkipCharacters();
- TPtrC token = analyse.MarkedToken();
- summary.iName.Copy(token);
- analyse.SkipSpaceAndMark();
- analyse.Val(summary.iUseCount);
- analyse.SkipSpaceAndMark();
- analyse.Val(summary.iSumElapsedTicks,EDecimal);
- analyse.SkipSpaceAndMark();
- aArray.Append(summary);
- }
- }
- }
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_PerfTestServer.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,122 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-#include "TE_PerfTestServer.h"
-#include "TE_PerfTestStep.h"
-#include "TE_MemTestStep.h"
-#include "TE_FindPerfTestStep.h"
-#include "TE_PerfTestCacheEnabledStep.h"
-#include "TE_PerfTestCacheDisabledStep.h"
-#include "TE_PerfTestCompareStep.h"
-#include "TE_DefectTestStep.h"
-#include "TE_PerfTestClientOpenStep.h"
-#include "TE_NotifyMemTestStep.h"
-
-_LIT(KServerName, "CentRepPerfTest");
-
-CPerfTestServer* CPerfTestServer::NewL()
- {
- CPerfTestServer* server = new (ELeave) CPerfTestServer();
- CleanupStack::PushL(server);
- // CServer base class call
- server->StartL(KServerName);
- CleanupStack::Pop(server);
- return server;
- }
-
-LOCAL_C void MainL()
- {
- // Leave the hooks in for platform security
-#if (defined __DATA_CAGING__)
- RProcess().DataCaging(RProcess::EDataCagingOn);
- RProcess().SecureApi(RProcess::ESecureApiOn);
-#endif
-
- CActiveScheduler* sched=NULL;
- sched=new(ELeave) CActiveScheduler;
- CActiveScheduler::Install(sched);
- CPerfTestServer* server = NULL;
- // Create the CTestServer derived server
- TRAPD(err,server = CPerfTestServer::NewL());
- if (KErrNone == err)
- {
- // Sync with the client and enter the active scheduler
- RProcess::Rendezvous(KErrNone);
- sched->Start();
- }
- delete server;
- delete sched;
- }
-
-GLDEF_C TInt E32Main()
- {
- CTrapCleanup* cleanup = CTrapCleanup::New();
- if(cleanup == NULL)
- {
- return KErrNoMemory;
- }
- TRAPD(err,MainL());
- delete cleanup;
- return err;
- }
-
-CTestStep* CPerfTestServer::CreateTestStep(const TDesC& aStepName)
- {
- CTestStep* testStep = NULL;
-
- if (aStepName == KGetPerfTestResults)
- {
- testStep = new CPerfTestStep();
- }
- else if (aStepName == KMemTestName)
- {
- testStep = new CMemTestStep();
- }
- else if (aStepName == KFindPerfTestName)
- {
- testStep = new CFindPerfTestStep();
- }
- else if (aStepName == KPerfTestCacheEnabledStep)
- {
- testStep = new CPerfTestCacheEnabledStep();
- }
- else if (aStepName == KPerfTestCacheDisabledStep)
- {
- testStep = new CPerfTestCacheDisabledStep();
- }
- else if (aStepName == KPerfTestCompareStep)
- {
- testStep = new CPerfTestCompareStep();
- }
- else if (aStepName == KPerfTestDefectStepDEF057491)
- {
- testStep = new CPerfTestDefectStep057491();
- }
- else if (aStepName == KPerfTestDefectStepDEF059633)
- {
- testStep = new CPerfTestDefectStep059633();
- }
- else if (aStepName == KPerfTestClientOpenName)
- {
- testStep = new CPerfTestClientOpenStep();
- }
- else if (aStepName == KNotifyMemTestStep)
- {
- testStep = new CNotifyMemTestStep();
- }
-
- return testStep;
- }
-
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_PerfTestStep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,432 +0,0 @@
-// Copyright (c) 2005-2009 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:
-//
-
-
-#include <e32std.h>
-#include <centralrepository.h>
-#include "t_cenrep_helper.h"
-#include <hal.h>
-#include <hal_data.h>
-#include "srvPerf.h"
-#include "srvreqs.h"
-#include "TE_PerfTestStep.h"
-
-#ifdef __CENTREP_SERVER_PERFTEST__
-
-// Function DecodeEventAndData
-// Extract the high 8-bit event Id and the low 24-bit data
-// from the 32 bit integer.
-//
-// param aEntry - the 32 bit integer to decode
-// param aEventId - return the EventId Id.
-// param aData - return the 24-bit data value
-inline
-void DecodeEventAndData(TUint32 aEntry, TUint& aEventId, TUint32& aData)
- {
- aEventId = (aEntry >> KEventIdShiftBits) & KEventIdMask;
- aData = aEntry & KDataMask;
- }
-
-// Function FindRepUid
-// Search for the given Repository UID in aArray.
-//
-// param aArray - the RArray containing a number of repositories.
-// param aRepUid - the rep UID to search for.
-// Return - if aRepUid is in the array, return its index in array,
-// else return KErrNotFound.
-TInt FindRepUid(const RArray<TRepStatistics>& aArray, TUint32 aRepUid)
- {
- for (TInt i = 0; i < aArray.Count(); i++)
- {
- if (aArray[i].MatchUid(aRepUid))
- return i;
- }
- return KErrNotFound;
- }
-
-// Function GetFuncCodeName
-// Map CentRep function code to string.
-//
-// param aFunc - the function code to map to string.
-// Return - textual representation of the function code.
-_LIT(KEInitialise, "Open");
-_LIT(KECreateInt, "ECreateInt");
-_LIT(KECreateReal, "ECreateReal");
-_LIT(KECreateString, "ECreateString");
-_LIT(KEDelete, "EDelete");
-_LIT(KEGetInt, "EGetInt");
-_LIT(KESetInt, "ESetInt");
-_LIT(KEGetReal, "EGetReal");
-_LIT(KESetReal, "ESetReal");
-_LIT(KEGetString, "EGetString");
-_LIT(KESetString, "ESetString");
-_LIT(KEFind, "EFind");
-_LIT(KEFindEqInt, "EFindEqInt");
-_LIT(KEFindEqReal, "EFindEqReal");
-_LIT(KEFindEqString, "EFindEqString");
-_LIT(KEFindNeqInt, "EFindNeqInt");
-_LIT(KEFindNeqReal, "EFindNeqReal");
-_LIT(KEFindNeqString, "EFindNeqString");
-_LIT(KEGetFindResult, "EGetFindResult");
-_LIT(KENotifyRequestCheck, "ENotifyRequestCheck");
-_LIT(KENotifyRequest, "ENotifyRequest");
-_LIT(KENotifyCancel, "ENotifyCancel");
-_LIT(KENotifyCancelAll, "ENotifyCancelAll");
-_LIT(KEGroupNotifyRequest, "EGroupNotifyRequest");
-_LIT(KEGroupNotifyCancel, "EGroupNotifyCancel");
-_LIT(KEReset, "EReset");
-_LIT(KEResetAll, "EResetAll");
-_LIT(KETransactionStart, "ETransactionStart");
-_LIT(KETransactionCommit, "ETransactionCommit");
-_LIT(KETransactionCancel, "ETransactionCancel");
-_LIT(KEMove, "EMove");
-_LIT(KETransactionState, "ETransactionState");
-_LIT(KETransactionFail, "ETransactionFail");
-_LIT(KEDeleteRange, "EDeleteRange");
-_LIT(KEGetSetParameters, "EGetSetParameters");
-_LIT(KEClose, "EClose");
-_LIT(KEEvict, "Evict");
-_LIT(KUnknownFunction, "UnknownCode");
-
-const TDesC* GetFuncCodeName(TUint aFunc)
- {
- switch (aFunc)
- {
- case EInitialise: return(&KEInitialise);
- case ECreateInt: return(&KECreateInt);
- case ECreateReal: return(&KECreateReal);
- case ECreateString: return(&KECreateString);
- case EDelete: return(&KEDelete);
- case EGetInt: return(&KEGetInt);
- case ESetInt: return(&KESetInt);
- case EGetReal: return(&KEGetReal);
- case ESetReal: return(&KESetReal);
- case EGetString: return(&KEGetString);
- case ESetString: return(&KESetString);
- case EFind: return(&KEFind);
- case EFindEqInt: return(&KEFindEqInt);
- case EFindEqReal: return(&KEFindEqReal);
- case EFindEqString: return(&KEFindEqString);
- case EFindNeqInt: return(&KEFindNeqInt);
- case EFindNeqReal: return(&KEFindNeqReal);
- case EFindNeqString: return(&KEFindNeqString);
- case EGetFindResult: return(&KEGetFindResult);
- case ENotifyRequestCheck: return(&KENotifyRequestCheck);
- case ENotifyRequest: return(&KENotifyRequest);
- case ENotifyCancel: return(&KENotifyCancel);
- case ENotifyCancelAll: return(&KENotifyCancelAll);
- case EGroupNotifyRequest: return(&KEGroupNotifyRequest);
- case EGroupNotifyCancel: return(&KEGroupNotifyCancel);
- case EReset: return(&KEReset);
- case EResetAll: return(&KEResetAll);
- case ETransactionStart: return(&KETransactionStart);
- case ETransactionCommit: return(&KETransactionCommit);
- case ETransactionCancel: return(&KETransactionCancel);
- case EMove: return(&KEMove);
- case ETransactionState: return(&KETransactionState);
- case ETransactionFail: return(&KETransactionFail);
- case EDeleteRange: return(&KEDeleteRange);
- case EGetSetParameters: return (&KEGetSetParameters);
- case EClose: return(&KEClose);
- case EEvict: return (&KEEvict);
- }
- return &KUnknownFunction;
- }
-#endif //__CENTREP_SERVER_PERFTEST__
-
-//--------------------
-// class CPerfTestStep
-//--------------------
-
-// doTestStepL
-// Implement the pure virtual function.
-// This test fetches the performance data collected by
-// CentRep server, sums the CPU time spent in servicing
-// each type of request and time spent in opening each
-// repository, and prints out the total.
-TVerdict CPerfTestStep::doTestStepL()
- {
-#ifdef __CENTREP_SERVER_PERFTEST__
-
- TBuf<KMaxFileName> sharedString;
-
- TPtrC resultSection;
- TInt testMode;
- TInt bRet;
- // get test mode from ini file
- bRet = GetIntFromConfig(ConfigSection(), KIniTestMode, testMode);
- TESTL(bRet==1);
-
- _LIT(KBlankLine, "\n");
- Logger().WriteFormat(KBlankLine);
-
- if (testMode == ETiming)
- {
- bRet = GetStringFromConfig(ConfigSection(), KResultsSection, resultSection);
- TESTL(bRet==1);
- }
-
- if (testMode == EBoot)
- {
- _LIT(KDoTestStepDisclaimer1, "For this test boot-up is considered to be finished when CommsDat repository is loaded 9 times.");
- Logger().WriteFormat(KDoTestStepDisclaimer1);
- _LIT(KDoTestStepDisclaimer2, "This is when the watcher thread is used to make re-attempts to connect to the network.");
- Logger().WriteFormat(KDoTestStepDisclaimer2);
- }
-
- // Setup IPC args to retreive performance data from server.
- TUint bufSize = KCentRepPerfTestArraySize * sizeof(TUint32);
- TAny* buf = User::AllocL(bufSize);
- TPtr8 bufDesc(static_cast<TUint8*>(buf), bufSize);
-
- TUint numValidEntries;
- TPckg<TUint> pckg(numValidEntries);
-
- TInt ret = SetGetParameters(TIpcArgs(EGetPerfResults, &bufDesc, &pckg));
- if (ret != KErrNone)
- {
- _LIT(KSetGetParamFailFmt, "Send msg err %d");
- ERR_PRINTF2(KSetGetParamFailFmt, ret);
- User::Free(buf);
- return EFail;
- }
-
- if (testMode == EBoot)
- {
- _LIT(KNumValidEntriesFmt, "Num Valid entries = %d");
- Logger().WriteFormat(KNumValidEntriesFmt, numValidEntries);
- }
-
- RArray<TUint32> perfData(sizeof(TUint32),static_cast<TUint32*>(buf),KCentRepPerfTestArraySize);
- CleanupClosePushL(perfData);
-
- // Need to find the tick frequency before using ConvertTickToSecAndMilli.
- HAL::Get(HALData::EFastCounterFrequency, iTickFreq);
-
- TUint sec;
- TUint milliSec;
-
- const TUint KNumIpcs = EEvict + 1;
- TIpcStatistics ipcStats[KNumIpcs];
- RArray<TRepStatistics> repStats;
- CleanupClosePushL(repStats);
- TUint32 totalElapsedTicks = 0;
- const TDesC* eventName;
-
- // Process the data
-
- // Performance data has 3 parts. First event ID and CPU tick
- // to service the request. 2nd & 3rd, if event is open/close/evict
- // the time of the event and repository UID.
- TInt i;
- for (i=0; i<numValidEntries && i<KCentRepPerfTestArraySize;)
- {
- TUint eventId;
- TUint32 ticksToServiceIpc;
- TUint32 repositoryUid;
-
- // This entry is elapsed ticks to service the request
- DecodeEventAndData(perfData[i++], eventId, ticksToServiceIpc);
- totalElapsedTicks += ticksToServiceIpc;
- ipcStats[eventId].AddData(ticksToServiceIpc);
-
- TBool repOpenCloseEvict = eventId == EInitialise || eventId == EClose || eventId == EEvict;
-
- if (repOpenCloseEvict)
- {
- TESTL(i < numValidEntries);
- TUint32 eventTime = perfData[i++];
-
- TESTL(i < numValidEntries);
- repositoryUid = perfData[i++];
-
- // Only rep open is stored in repStats array.
- // Close and evict go into the ipcStats.
- if (eventId == EInitialise)
- {
- TInt idx = FindRepUid(repStats, repositoryUid);
- if (idx == KErrNotFound)
- {
- repStats.Append(TRepStatistics(repositoryUid, ticksToServiceIpc));
- }
- else
- {
- repStats[idx].AddData(ticksToServiceIpc);
- }
- } // if eventId == EInitialise
-
- if (testMode == EBoot)
- {
- // Display the time that this event occur.
- eventName = GetFuncCodeName(eventId);
- ConvertTickToSecAndMilli(eventTime, sec, milliSec);
- _LIT(KRepOpenCloseFmt, "REP %X %S at %d.%03d");
- Logger().WriteFormat(KRepOpenCloseFmt, repositoryUid, eventName, sec, milliSec);
- }
- } // if repOpenCloseEvict
- } // for i
-
-
- // Display the IPC statistics
- Logger().WriteFormat(KBlankLine);
- Logger().WriteFormat(KBlankLine);
- _LIT(KIpcStatsFmt, "IPC Statistics:");
- Logger().WriteFormat(KIpcStatsFmt);
-
- TInt numIpcMsgs = 0;
- TInt numLogItems = 0;
- TBuf<50> keyName;
- _LIT(KIndividualIpcStat, "%S used %d times, sum of CPU time = %d ms");
- for (i = 0; i < KNumIpcs; i++)
- {
- if (ipcStats[i].iUseCount == 0)
- {
- continue;
- }
-
- numIpcMsgs += ipcStats[i].iUseCount;
- eventName = GetFuncCodeName(i);
- ConvertTickToSecAndMilli(ipcStats[i].iSumElapsedTicks, sec, milliSec);
- if (sec > 0)
- {
- milliSec += sec * 1000;
- }
- Logger().WriteFormat(KIndividualIpcStat, eventName, ipcStats[i].iUseCount, milliSec);
- if (testMode == ETiming)
- {
- sharedString.AppendFormat(_L(" %S %d %d"), eventName, ipcStats[i].iUseCount, milliSec);
- numLogItems++;
- }
- }
- if (testMode == ETiming)
- {
- TBuf<2> numofItems;
- numofItems.Num(numLogItems);
- sharedString.Insert(0, numofItems);
- WriteSharedDataL(resultSection, sharedString, ESetText);
- }
-
- // Display Repository statistics
- Logger().WriteFormat(KBlankLine);
- Logger().WriteFormat(KBlankLine);
- _LIT(KRepStatsFmt, "Repository Statistics:");
- Logger().WriteFormat(KRepStatsFmt);
-
- if (testMode == ETiming)
- {
- numLogItems = 0;
- sharedString.Copy(_L(" "));
- }
- _LIT(KIndividualRepStat, "%X used %d times, sum of load time %d ms");
- for (i = 0; i < repStats.Count(); i++)
- {
- ConvertTickToSecAndMilli(repStats[i].iSumLoadTicks, sec, milliSec);
- if (sec > 0)
- {
- milliSec += sec * 1000;
- }
- Logger().WriteFormat(KIndividualRepStat, repStats[i].iRepUid,
- repStats[i].iUseCount, milliSec);
- if (testMode == ETiming)
- {
- sharedString.AppendFormat(_L(" %08X %d %d"), repStats[i].iRepUid, repStats[i].iUseCount, milliSec);
- numLogItems++;
- }
- }
-
- if (testMode == ETiming)
- {
- TBuf<2> numofItems;
- numofItems.Num(numLogItems);
- sharedString.Insert(1, numofItems);
- WriteSharedDataL(resultSection, sharedString, EAppendText);
-
- Logger().WriteFormat(KBlankLine);
- }
-
- if (testMode == EBoot)
- {
- // show total CPU used by CentralRepository server.
- ConvertTickToSecAndMilli(totalElapsedTicks, sec, milliSec);
- if (sec > 0)
- {
- milliSec += sec * 1000;
- }
-
- Logger().WriteFormat(KBlankLine);
- Logger().WriteFormat(KBlankLine);
- _LIT(KTotalCpuFmt, "Total CPU time used by CentRepSrv: %d ms");
- Logger().WriteFormat(KTotalCpuFmt, milliSec);
-
- _LIT(KNoteAboutTotal, "The above does not include kernel processing time and client idle time for the %d IPC messages.\n");
- Logger().WriteFormat(KNoteAboutTotal, numIpcMsgs);
- }
-
- // Stop performance test data recording in the server
- TInt r = SetGetParameters(TIpcArgs(EStopPerfTests));
- TEST(r==KErrNone);
-
- CleanupStack::PopAndDestroy(); // repStats
- CleanupStack::PopAndDestroy(); // perfData
- return EPass;
-#else
- _LIT(KWarnTestMacroOff, "Performance test macro __CENTREP_SERVER_PERFTEST__ is disabled. Test not run.");
- WARN_PRINTF1(KWarnTestMacroOff);
- return EPass;
-#endif
- }
-
-// ConvertTickToSecAndMilli
-// Convert FastCounter ticks to seconds and milli-seconds.
-//
-// param aTick - ticks from User::FastCounter
-// param aSec - return number of seconds in aTick
-// param aMilliSec - return number of ms left behind after number of
-// seconds is subtracted from aTick.
-void CPerfTestStep::ConvertTickToSecAndMilli(TUint32 aTick, TUint& aSec, TUint& aMilliSec)
- {
- aSec = aTick / iTickFreq;
- aMilliSec = ((aTick - aSec * iTickFreq) * 1000 + (iTickFreq >> 1)) / iTickFreq;
- }
-
-//------------------------
-// class TRepStatistics
-//------------------------
-
-// AddData
-// Increment number of times this rep is open, sum of CPU used
-// to load it, and check cache miss.
-void TRepStatistics::AddData(TUint32 aElapsedTicks)
- {
- iSumLoadTicks += aElapsedTicks;
- iUseCount++;
- if (aElapsedTicks >= KTicks2LoadFromCache)
- {
- iCacheMisses++;
- }
- }
-
-//---------------------
-// class TIpcStatistics
-//---------------------
-
-// AddData
-// Increment number of times the IPC msg is received by server.
-// Sum time to service this type of request.
-void TIpcStatistics::AddData(TUint32 aElapsedTicks)
- {
- iUseCount++;
- iSumElapsedTicks += aElapsedTicks;
- }
--- a/persistentstorage/centralrepository/test/testexecute/performance/src/TE_PerfTestUtilities.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,59 +0,0 @@
-// Copyright (c) 2006-2009 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:
-//
-
-#include "TE_PerfTestUtilities.h"
-#include "srvdefs.h"
-#include <hal.h>
-#include <hal_data.h>
-
-TReal FastCountToMillisecondsInReal(TInt aFastCount)
- {
- TInt freqInHz;
- HAL::Get(HAL::EFastCounterFrequency, freqInHz);
- TReal freqInkHz = (TReal)freqInHz / 1000;
- return (TReal)aFastCount / freqInkHz;
- }
-
-TReal FastCountToMicrosecondsInReal(TInt aFastCount)
- {
- TInt freqInHz;
- HAL::Get(HAL::EFastCounterFrequency, freqInHz);
- TReal freqInkHz = (TReal)freqInHz / 1000000LL;
- return (TReal)aFastCount / freqInkHz;
- }
-
-TUint64 FastCountToMillisecondsInInt(TInt aFastCount)
- {
- TInt freqInHz;
- HAL::Get(HAL::EFastCounterFrequency, freqInHz);
- return (aFastCount*1000LL)/freqInHz;
- }
-
-TUint64 FastCountToMicrosecondsInInt(TInt aFastCount)
- {
- TInt freqInHz;
- HAL::Get(HAL::EFastCounterFrequency, freqInHz);
- return (aFastCount*1000000LL)/freqInHz;
- }
-
-TInt FreeRamSize()
- {
- TInt freeRamSize = 0;
-
- HAL::Get(HALData::EMemoryRAMFree, freeRamSize);
-
- return freeRamSize;
- }
-
--- a/persistentstorage/dbms/group/BLD.INF Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/dbms/group/BLD.INF Tue Aug 31 16:57:14 2010 +0300
@@ -25,9 +25,9 @@
PRJ_EXPORTS
-../inc/D32DBMS.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(d32dbms.h)
-../inc/D32DBMSCONSTANTS.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(d32dbmsconstants.h)
-../inc/D32DBMS.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(d32dbms.inl)
+../inc/D32DBMS.H OS_LAYER_PUBLIC_EXPORT_PATH(d32dbms.h)
+../inc/D32DBMSCONSTANTS.H OS_LAYER_PUBLIC_EXPORT_PATH(d32dbmsconstants.h)
+../inc/D32DBMS.INL OS_LAYER_PUBLIC_EXPORT_PATH(d32dbms.inl)
dbms.iby /epoc32/rom/include/dbms.iby
--- a/persistentstorage/dbms/pcdbms/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/dbms/pcdbms/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -15,9 +15,9 @@
PRJ_EXPORTS
-../inc/D32DBMS.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(x86tool/d32dbms.h)
-../inc/D32DBMSCONSTANTS.H SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(x86tool/d32dbmsconstants.h)
-../inc/D32DBMS.INL SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(x86tool/d32dbms.inl)
+../inc/D32DBMS.H OS_LAYER_PUBLIC_EXPORT_PATH(x86tool/d32dbms.h)
+../inc/D32DBMSCONSTANTS.H OS_LAYER_PLATFORM_EXPORT_PATH(x86tool/d32dbmsconstants.h)
+../inc/D32DBMS.INL OS_LAYER_PLATFORM_EXPORT_PATH(x86tool/d32dbms.inl)
PRJ_PLATFORMS
DEFAULT TOOLS2
--- a/persistentstorage/dbms/tdbms/t_dbbug.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/dbms/tdbms/t_dbbug.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -345,6 +345,7 @@
static const TDesC& Name();
private:
static void WaitForServerExit();
+ static void KillDbmsServer();
static TInt Thread(TAny*);
};
@@ -354,6 +355,41 @@
return KName;
}
+void Defect_COMBBAR_463J5D::KillDbmsServer()
+ {
+ _LIT(KDbmsServer,"edbsrv.exe");
+ TFullName name;
+ //RDebug::Print(_L("Find and kill \"%S\" process.\n"), &aProcessName);
+ TBuf<64> pattern(KDbmsServer);
+ TInt length = pattern.Length();
+ pattern += _L("*");
+ TFindProcess procFinder(pattern);
+
+ while (procFinder.Next(name) == KErrNone)
+ {
+ if (name.Length() > length)
+ {//If found name is a string containing aProcessName string.
+ TChar c(name[length]);
+ if (c.IsAlphaDigit() ||
+ c == TChar('_') ||
+ c == TChar('-'))
+ {
+ // If the found name is other valid application name
+ // starting with aProcessName string.
+ //RDebug::Print(_L(":: Process name: \"%S\".\n"), &name);
+ continue;
+ }
+ }
+ RProcess proc;
+ if (proc.Open(name) == KErrNone)
+ {
+ proc.Kill(0);
+ //RDebug::Print(_L("\"%S\" process killed.\n"), &name);
+ }
+ proc.Close();
+ }
+ }
+
void Defect_COMBBAR_463J5D::WaitForServerExit()
{
_LIT(KDbmsServer,"*!DBMS server");
@@ -392,8 +428,8 @@
void Defect_COMBBAR_463J5D::TestL()
{
test.Next(_L(" @SYMTestCaseID:SYSLIB-DBMS-CT-0584 "));
- Print(_S("Wait for the server to exit"));
- WaitForServerExit();
+ Print(_S("Kill the server if it has started"));
+ KillDbmsServer();
//
Print(_S("Create the launching threads"));
RThread t1,t2;
--- a/persistentstorage/dbms/tdbms/t_dbbug.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/dbms/tdbms/t_dbbug.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,7 +15,7 @@
target t_dbbug.exe
targettype exe
-
+capability All -Tcb
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
userinclude ../inc
--- a/persistentstorage/dbms/tdbms/t_dbperf2.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/dbms/tdbms/t_dbperf2.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -1292,49 +1292,53 @@
{
_LIT(KSpace, " ");
TheTest.Printf(_L("%*.*S%S\r\n"), aOffset, aOffset, &KSpace, &aPath);
- TFindFile findFile(TheFs);
+ TFindFile* findFile = new TFindFile(TheFs);//TFindFile has TParse data member.
+ //Since this function is called recoursively, on some platforms
+ //the test might crash - "stack overflow" problem.
+ TEST(findFile != NULL);
CDir* fileNameCol = NULL;
TBuf<8> fileNameMask;
fileNameMask.Copy(_L("*.*"));
- TInt err = findFile.FindWildByDir(fileNameMask, aPath, fileNameCol);
+ TInt err = findFile->FindWildByDir(fileNameMask, aPath, fileNameCol);
if(err == KErrNone)
{
do
{
- const TDesC& file = findFile.File();//"file" variable contains the drive and the path. the file name in "file" is invalid in this case.
+ const TDesC& file = findFile->File();//"file" variable contains the drive and the path. the file name in "file" is invalid in this case.
(void)TheParse.Set(file, NULL, NULL);
TPtrC driveName = TheParse.Drive();
- if(aPath.FindF(driveName) < 0)
- {
- goto cont;
- }
+ if(aPath.FindF(driveName) >= 0)
+ {
+ TInt cnt = fileNameCol->Count();
+ for(TInt i=0;i<cnt;++i)
+ {
+ const ::TEntry& entry = (*fileNameCol)[i];
+ if(!entry.IsDir())
+ {
+ TheTest.Printf(_L("%*.*S %S, size=%d\r\n"), aOffset, aOffset, &KSpace, &entry.iName, entry.iSize);
+ }
+ else
+ {
+ TFileName* path = new TFileName;//allocated in heap to prevent "stack overflow" prolem
+ TEST(path != NULL);
+ path->Copy(aPath);
+ path->Append(entry.iName);
+ path->Append(_L("\\"));
+ PrintDiskUsage(*path, aOffset + 4);
+ delete path;
+ }
+ }
+ } // if(aPath.FindF(driveName) >= 0)
- TInt cnt = fileNameCol->Count();
- for(TInt i=0;i<cnt;++i)
- {
- const ::TEntry& entry = (*fileNameCol)[i];
- if(!entry.IsDir())
- {
- TheTest.Printf(_L("%*.*S %S, size=%d\r\n"), aOffset, aOffset, &KSpace, &entry.iName, entry.iSize);
- }
- else
- {
- TBuf<100> path;
- path.Copy(aPath);
- path.Append(entry.iName);
- path.Append(_L("\\"));
- PrintDiskUsage(path, aOffset + 4);
- }
- }
-cont:
delete fileNameCol;
fileNameCol = NULL;
- } while((err = findFile.FindWild(fileNameCol)) == KErrNone);//Get the next set of files
+ } while((err = findFile->FindWild(fileNameCol)) == KErrNone);//Get the next set of files
}
else
{
TheTest.Printf(_L(" FindWildByDir() failed with err=%d\r\n"), err);
}
+ delete findFile;
}
void DoTestL()
@@ -1401,7 +1405,7 @@
DeleteFile(TheTestFileName);
TEST2(err, KErrNone);
- TheTest.Printf(_L("====================================================\r\n"));
+ TheTest.Printf(_L("====================== Disk usage ==================\r\n"));
PrintDiskUsage(_L("c:\\"));
TheTest.Printf(_L("====================================================\r\n"));
--- a/persistentstorage/dbms/tdbms/t_dbsrv.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/dbms/tdbms/t_dbsrv.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1257,6 +1257,39 @@
test(r==KErrNone);
}
+LOCAL_C void KillDbmsServer()
+ {
+ _LIT(KDbmsServer,"edbsrv.exe");
+ TFullName name;
+ TBuf<64> pattern(KDbmsServer);
+ TInt length = pattern.Length();
+ pattern += _L("*");
+ TFindProcess procFinder(pattern);
+
+ while (procFinder.Next(name) == KErrNone)
+ {
+ if (name.Length() > length)
+ {//If found name is a string containing aProcessName string.
+ TChar c(name[length]);
+ if (c.IsAlphaDigit() ||
+ c == TChar('_') ||
+ c == TChar('-'))
+ {
+ // If the found name is other valid application name
+ // starting with aProcessName string.
+ //RDebug::Print(_L(":: Process name: \"%S\".\n"), &name);
+ continue;
+ }
+ }
+ RProcess proc;
+ if (proc.Open(name) == KErrNone)
+ {
+ proc.Kill(0);
+ //RDebug::Print(_L("\"%S\" process killed.\n"), &name);
+ }
+ proc.Close();
+ }
+ }
void DoTests()
{
TVersionName n=RDbs::Version().Name();
@@ -1322,6 +1355,7 @@
setupTestDirectory();
DeleteTestFiles();
setupCleanup();
+ KillDbmsServer();
DoTests();
delete TheTrapCleanup;
DeleteTestFiles();
--- a/persistentstorage/dbms/tdbms/t_dbsrv.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/dbms/tdbms/t_dbsrv.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,7 +15,7 @@
target t_dbsrv.exe
targettype exe
-
+capability All -Tcb
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
userinclude ../inc
--- a/persistentstorage/dbms/tdbms/t_dbstress.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/dbms/tdbms/t_dbstress.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -467,7 +467,7 @@
for (TInt ii=0;;++ii)
{
TheTest.Printf(_L("Opening %d\r"),ii);
- TRAPD(r,store=CFileStore::OpenL(TheFs,KTestDatabase,EFileRead|EFileWrite));
+ TRAPD(r,store=CFileStore::OpenL(TheFs,KTestDatabase,EFileRead|EFileWrite|EFileWriteDirectIO));
if (r==KErrNone)
break;
TEST2(r, KErrInUse);
@@ -515,7 +515,7 @@
{
TheTest.Start(_L(" @SYMTestCaseID:SYSLIB-DBMS-CT-0636 Open store "));
CFileStore* store=NULL;
- TRAPD(r,store=CFileStore::OpenL(TheFs,KTestDatabase,EFileRead|EFileWrite));
+ TRAPD(r,store=CFileStore::OpenL(TheFs,KTestDatabase,EFileRead|EFileWrite|EFileWriteDirectIO));
TEST2 (r,KErrNone);
TheTest.Next(_L("Verify"));
NewCount=-1;
--- a/persistentstorage/dbms/tdbms/t_dbthrd.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/dbms/tdbms/t_dbthrd.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -113,7 +113,7 @@
User::LeaveIfError(iFs.Connect());
User::LeaveIfError(iFs.SetSessionPath(KTestDir));
User::LeaveIfError(iLog.Replace(iFs,KLogFile,EFileWrite|EFileStreamText));
- iStore=CFileStore::OpenL(iFs,KTestDatabase,EFileRead|EFileWrite);
+ iStore=CFileStore::OpenL(iFs,KTestDatabase,EFileRead|EFileWrite|EFileWriteDirectIO);
LogSize();
iData.OpenL(iStore,iStore->Root());
}
--- a/persistentstorage/dbms/ustor/US_FILE.CPP Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/dbms/ustor/US_FILE.CPP Tue Aug 31 16:57:14 2010 +0300
@@ -97,8 +97,8 @@
{
default:
__LEAVE(KErrNotSupported);
- case TDbFormat::ECreate:
- store=CPermanentFileStore::CreateL(iFs,aName,EFileRead|EFileWrite);
+ case TDbFormat::ECreate:
+ store=CPermanentFileStore::CreateL(iFs,aName,EFileRead|EFileWrite);
break;
case TDbFormat::EReplace:
store=CPermanentFileStore::ReplaceL(iFs,aName,EFileRead|EFileWrite);
--- a/persistentstorage/sql/GROUP/BLD.INF Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/BLD.INF Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
PRJ_EXPORTS
-../INC/SqlDb.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(sqldb.h)
+../INC/SqlDb.h OS_LAYER_PUBLIC_EXPORT_PATH(sqldb.h)
#ifndef SYMBIAN_ENABLE_SPLIT_HEADERS
#ifdef SYMBIAN_OLD_EXPORT_LOCATION
../INC/SqlResourceTester.h /epoc32/include/sqlresourcetester.h
--- a/persistentstorage/sql/GROUP/SqlDb.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/SqlDb.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -19,13 +19,6 @@
@file
*/
-//#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-#include <e32utrace.mmh>
-
-#ifdef SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-MACRO SQLDB_ENABLE_TRACE
-#endif
-
TARGET sqldb.dll
TARGETTYPE dll
@@ -35,12 +28,12 @@
OPTION CW -w noillpragmas
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
+USERINCLUDE ../traces_SqlDb
USERINCLUDE ../INC
USERINCLUDE ../SRC/Client
USERINCLUDE ../SRC/Client/IPC
USERINCLUDE ../SRC/Common
USERINCLUDE ../SRC/Common/IPC
-USERINCLUDE ../SRC/Common/Trace
USERINCLUDE ../SRC/Security
//SqlDb includes sqlite3.h header file for the error code macros defined there
#ifdef SYMBIAN_USE_SQLITE_VERSION_3_6_4
@@ -52,26 +45,30 @@
OS_LAYER_ESTLIB_SYSTEMINCLUDE
SOURCEPATH ../SRC/Client
-SOURCE SQLDatabase.cpp SqlDatabaseImpl.cpp SqlStatement.cpp SqlStatementImpl.cpp SqlStream.cpp
+SOURCE SQLDatabase.cpp
+SOURCE SqlDatabaseImpl.cpp
+SOURCE SqlStatement.cpp
+SOURCE SqlStatementImpl.cpp
+SOURCE SqlStream.cpp
SOURCE SqlBlob.cpp
+SOURCE SqlDbSession.cpp
+SOURCE SqlStmtSession.cpp
+SOURCE SqlResourceTest.cpp
+SOURCE SqlScalarFullSelect.cpp
+SOURCE SqlResourceProfiler.cpp
+
+SOURCEPATH ../SRC/Client/IPC
+SOURCE IPCBuf.cpp
SOURCEPATH ../SRC/Common
-SOURCE SqlUtil.cpp SqlBufFlat.cpp SqlBufIterator.cpp
-
-SOURCEPATH ../SRC/Client
-SOURCE SqlDbSession.cpp SqlStmtSession.cpp SqlResourceTest.cpp SqlScalarFullSelect.cpp SqlResourceProfiler.cpp
-SOURCEPATH ../SRC/Client/IPC
-SOURCE IPCBuf.cpp
-SOURCEPATH ../SRC/Common
+SOURCE SqlUtil.cpp
+SOURCE SqlBufFlat.cpp
+SOURCE SqlBufIterator.cpp
SOURCE SqlSrvStartup.cpp
SOURCEPATH ../SRC/Security
-SOURCE SqlSecurity.cpp SqlSecurityImpl.cpp
-
-#ifdef SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-SOURCEPATH ../SRC/Common/Trace
-SOURCE UTraceSql.cpp
-#endif
+SOURCE SqlSecurity.cpp
+SOURCE SqlSecurityImpl.cpp
LIBRARY euser.lib efsrv.lib estor.lib
--- a/persistentstorage/sql/GROUP/SqlSrv.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/SqlSrv.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -19,13 +19,6 @@
@file
*/
-//#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-#include <e32utrace.mmh>
-
-#ifdef SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-MACRO SQLSRV_ENABLE_TRACE
-#endif
-
TARGET sqlsrv.exe
TARGETTYPE exe
CAPABILITY ProtServ
@@ -50,10 +43,10 @@
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
OS_LAYER_ESTLIB_SYSTEMINCLUDE
+USERINCLUDE ../traces_SqlSrv
USERINCLUDE ../INC
USERINCLUDE ../SRC/Common
USERINCLUDE ../SRC/Common/IPC
-USERINCLUDE ../SRC/Common/Trace
USERINCLUDE ../SRC/Security
USERINCLUDE ../SRC/Server
USERINCLUDE ../SRC/Server/IPC
@@ -66,10 +59,23 @@
#endif
SOURCEPATH ../SRC/Server
-SOURCE SqlSrvMain.cpp SqlSrvSession.cpp SqlSrvDatabase.cpp SqlSrvStatement.cpp SqlSrvAuthorizer.cpp
-SOURCE SqlSrvUtil.cpp SqlSrvStrings.cpp SqlSrvStatementUtil.cpp SqlSrvCollation.cpp SqlSrvSecurityMap.cpp
-SOURCE SqlSrvFileData.cpp SqlSrvDriveSpace.cpp SqlSrvDbSysSettings.cpp SqlSrvConfig.cpp SqlSrvBlob.cpp
-SOURCE SqlSrvCheckStatement.cpp SqlSrvResourceProfiler.cpp
+SOURCE SqlSrvMain.cpp
+SOURCE SqlSrvSession.cpp
+SOURCE SqlSrvDatabase.cpp
+SOURCE SqlSrvStatement.cpp
+SOURCE SqlSrvAuthorizer.cpp
+SOURCE SqlSrvUtil.cpp
+SOURCE SqlSrvStrings.cpp
+SOURCE SqlSrvStatementUtil.cpp
+SOURCE SqlSrvCollation.cpp
+SOURCE SqlSrvSecurityMap.cpp
+SOURCE SqlSrvFileData.cpp
+SOURCE SqlSrvDriveSpace.cpp
+SOURCE SqlSrvDbSysSettings.cpp
+SOURCE SqlSrvConfig.cpp
+SOURCE SqlSrvBlob.cpp
+SOURCE SqlSrvCheckStatement.cpp
+SOURCE SqlSrvResourceProfiler.cpp
// for backup and restore
SOURCE SqlBur.cpp
@@ -77,18 +83,18 @@
SOURCE IPCStream.cpp
SOURCEPATH ../SRC/Common
-SOURCE SqlUtil.cpp SqlBufFlat.cpp SqlBufIterator.cpp
+SOURCE SqlUtil.cpp
+SOURCE SqlBufFlat.cpp
+SOURCE SqlBufIterator.cpp
SOURCEPATH ../SRC/Security
SOURCE SqlSecurityImpl.cpp
SOURCEPATH ../SRC/Server/Compact
-SOURCE SqlCompact.cpp SqlCompactEntry.cpp SqlCompactConn.cpp SqlCompactTimer.cpp
-
-#ifdef SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-SOURCEPATH ../SRC/Common/Trace
-SOURCE UTraceSql.cpp
-#endif
+SOURCE SqlCompact.cpp
+SOURCE SqlCompactEntry.cpp
+SOURCE SqlCompactConn.cpp
+SOURCE SqlCompactTimer.cpp
LIBRARY estlib.lib
LIBRARY euser.lib
--- a/persistentstorage/sql/GROUP/sqlite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/sqlite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -19,13 +19,8 @@
@file
*/
-//#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
#include "sqlite_macro.mmh"
-#ifdef SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-MACRO SQLITELIB_ENABLE_TRACE
-#endif
-
TARGET sqlite.lib
TARGETTYPE lib
@@ -68,9 +63,9 @@
//////////////////////////////////////////////////////////////////////////////////////////////////////////
-USERINCLUDE ../SRC/Common/Trace
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
OS_LAYER_ESTLIB_SYSTEMINCLUDE
+USERINCLUDE ../traces_sqlite
USERINCLUDE ../OsLayer
#ifdef SYMBIAN_USE_SQLITE_VERSION_3_6_4
@@ -195,8 +190,4 @@
SOURCEPATH ../OsLayer
SOURCE FileBuf64.cpp
SOURCE os_symbian.cpp
-
-#ifdef SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-SOURCEPATH ../SRC/Common/Trace
-SOURCE UTraceSql.cpp
-#endif
+SOURCE SqliteUtil.cpp
--- a/persistentstorage/sql/GROUP/sqltests.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/sqltests.iby Tue Aug 31 16:57:14 2010 +0300
@@ -23,12 +23,6 @@
#include <charconv.iby>
#include <sql.iby>
-//Include the following to enable the ulogger server and the client tool.
-//This is used to perform tracing using the UTF2
-
-//#include <uloggerclttool.iby>
-//#include <ulogger.iby>
-
data=DATAZ_\test\sqlTests.bat \test\sqltests.bat
data=DATAZ_\test\contacts_schema_to_vendors.sql \test\contacts_schema_to_vendors.sql
--- a/persistentstorage/sql/GROUP/t_sqlbur.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqlbur.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -20,7 +20,7 @@
USERINCLUDE .
USERINCLUDE ../SRC/Server
USERINCLUDE ../SRC/Common
-USERINCLUDE ../SRC/Common/Trace
+USERINCLUDE ../traces_SqlSrv
#ifdef SYMBIAN_USE_SQLITE_VERSION_3_6_4
USERINCLUDE ../SQLite364
#else
@@ -47,4 +47,4 @@
UID 0 0x10281e17
VENDORID 0x70000001
-SMPSAFE
\ No newline at end of file
+SMPSAFE
--- a/persistentstorage/sql/GROUP/t_sqlcompact2.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqlcompact2.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -13,7 +13,6 @@
// Description:
//
-#include <e32utrace.mmh>
#include "sqlite_macro.mmh"
TARGET t_sqlcompact2.exe
@@ -28,7 +27,7 @@
USERINCLUDE .
USERINCLUDE ../INC
USERINCLUDE ../SRC/Common
-USERINCLUDE ../SRC/Common/Trace
+USERINCLUDE ../traces_SqlSrv
USERINCLUDE ../SRC/Server/Compact
USERINCLUDE ../SRC/Server
USERINCLUDE ../OsLayer
--- a/persistentstorage/sql/GROUP/t_sqlcompact3.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqlcompact3.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -25,6 +25,7 @@
USERINCLUDE .
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
OS_LAYER_ESTLIB_SYSTEMINCLUDE
+USERINCLUDE ../traces_sqlite
USERINCLUDE ../OsLayer
#ifdef SYMBIAN_USE_SQLITE_VERSION_3_6_4
USERINCLUDE ../SQLite364
--- a/persistentstorage/sql/GROUP/t_sqlconfig.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqlconfig.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -20,7 +20,7 @@
USERINCLUDE .
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
USERINCLUDE ../SRC/Common
-USERINCLUDE ../SRC/Common/Trace
+USERINCLUDE ../traces_SqlSrv
USERINCLUDE ../SRC/Server
SOURCEPATH ../TEST
@@ -34,4 +34,4 @@
UID 0 0x1111C1C1
VENDORID 0x70000001
-SMPSAFE
\ No newline at end of file
+SMPSAFE
--- a/persistentstorage/sql/GROUP/t_sqlconfigfile.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqlconfigfile.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -21,7 +21,7 @@
USERINCLUDE ../INC
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
USERINCLUDE ../SRC/Common
-USERINCLUDE ../SRC/Common/Trace
+USERINCLUDE ../traces_SqlSrv
USERINCLUDE ../SRC/Server
SOURCEPATH ../TEST
--- a/persistentstorage/sql/GROUP/t_sqldbconfigfile.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqldbconfigfile.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -25,7 +25,8 @@
USERINCLUDE ../INC
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-SYSTEMINCLUDE /epoc32/include/libc
+OS_LAYER_ESTLIB_SYSTEMINCLUDE
+
USERINCLUDE ../OsLayer
#ifdef SYMBIAN_USE_SQLITE_VERSION_3_6_4
USERINCLUDE ../SQLite364
--- a/persistentstorage/sql/GROUP/t_sqldefect2.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqldefect2.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -35,4 +35,4 @@
VENDORID 0x70000001
-SMPSAFE
\ No newline at end of file
+SMPSAFE
--- a/persistentstorage/sql/GROUP/t_sqlfilebuf64.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqlfilebuf64.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -19,6 +19,7 @@
MACRO _SQLPROFILER
USERINCLUDE .
+USERINCLUDE ../traces_sqlite
USERINCLUDE ../OsLayer
#ifdef SYMBIAN_USE_SQLITE_VERSION_3_6_4
USERINCLUDE ../SQLite364
@@ -31,6 +32,7 @@
SOURCEPATH ../OsLayer
SOURCE FileBuf64.cpp
+SOURCE SqliteUtil.cpp
SOURCEPATH ../TEST
SOURCE t_sqlfilebuf64.cpp
--- a/persistentstorage/sql/GROUP/t_sqlgetfirststmt.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqlgetfirststmt.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -13,8 +13,6 @@
// Description:
//
-#include <e32utrace.mmh>
-
TARGET t_sqlgetfirststmt.exe
TARGETTYPE EXE
CAPABILITY None
@@ -29,8 +27,8 @@
USERINCLUDE .
USERINCLUDE ../INC
USERINCLUDE ../SRC/Common
-USERINCLUDE ../SRC/Common/Trace
-USERINCLUDE ../OsLayer
+USERINCLUDE ../traces_SqlSrv
+USERINCLUDE ../OsLayer
SOURCEPATH ../TEST
SOURCE t_sqlgetfirststmt.cpp
--- a/persistentstorage/sql/GROUP/t_sqloom5.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqloom5.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -12,7 +12,7 @@
//
// Description:
//
-
+#include <e32utrace.mmh>
TARGET t_sqloom5.exe
TARGETTYPE EXE
CAPABILITY ProtServ AllFiles
@@ -35,13 +35,15 @@
USERINCLUDE ../INC
USERINCLUDE ../SRC/Common
USERINCLUDE ../SRC/Common/IPC
-USERINCLUDE ../SRC/Common/Trace
USERINCLUDE ../SRC/Server
USERINCLUDE ../SRC/Server/Compact
USERINCLUDE ../SRC/Server/IPC
USERINCLUDE ../SRC/Security
USERINCLUDE ../SQLite
USERINCLUDE ../OsLayer
+USERINCLUDE ../traces_SqlDb
+USERINCLUDE ../traces_SqlSrv
+
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
OS_LAYER_ESTLIB_SYSTEMINCLUDE
--- a/persistentstorage/sql/GROUP/t_sqlperformance.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqlperformance.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -13,8 +13,6 @@
// Description:
//
-#include <e32utrace.mmh>
-
TARGET t_sqlperformance.exe
TARGETTYPE EXE
//"AllFiles" capability is needed because the test accesses the database files in the SQL server private data cage
@@ -28,7 +26,7 @@
USERINCLUDE .
USERINCLUDE ../INC
USERINCLUDE ../SRC/Common
-USERINCLUDE ../SRC/Common/Trace
+USERINCLUDE ../traces_SqlSrv
USERINCLUDE ../SRC/Server
USERINCLUDE ../OsLayer
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
--- a/persistentstorage/sql/GROUP/t_sqlsecurity6.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqlsecurity6.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -12,6 +12,7 @@
//
// Description:
//
+#include <e32utrace.mmh>
TARGET t_sqlsecurity6.exe
TARGETTYPE EXE
--- a/persistentstorage/sql/GROUP/t_sqlstartup.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/GROUP/t_sqlstartup.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -12,9 +12,9 @@
//
// Description:
//
-
-TARGET t_sqlstartup.exe
-TARGETTYPE EXE
+#include <e32utrace.mmh>
+TARGET t_sqlstartup.exe
+TARGETTYPE EXE
CAPABILITY ProtServ AllFiles
EPOCFIXEDPROCESS
@@ -25,58 +25,59 @@
EPOCHEAPSIZE 0x00020000 0x02000000
#endif
-EPOCSTACKSIZE 0x3000
+EPOCSTACKSIZE 0x3000
-UID 0 0x10281E17
+UID 0 0x10281E17
MACRO SQLSRV_STARTUP_TEST
-USERINCLUDE .
-USERINCLUDE ../INC
-USERINCLUDE ../SRC/Common
-USERINCLUDE ../SRC/Common/IPC
-USERINCLUDE ../SRC/Common/Trace
-USERINCLUDE ../SRC/Server
-USERINCLUDE ../SRC/Server/Compact
-USERINCLUDE ../SRC/Server/IPC
-USERINCLUDE ../SRC/Security
-USERINCLUDE ../SQLite
-USERINCLUDE ../OsLayer
+USERINCLUDE .
+USERINCLUDE ../INC
+USERINCLUDE ../traces_SqlDb
+USERINCLUDE ../traces_SqlSrv
+USERINCLUDE ../SRC/Common
+USERINCLUDE ../SRC/Common/IPC
+USERINCLUDE ../SRC/Server
+USERINCLUDE ../SRC/Server/Compact
+USERINCLUDE ../SRC/Server/IPC
+USERINCLUDE ../SRC/Security
+USERINCLUDE ../SQLite
+USERINCLUDE ../OsLayer
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
OS_LAYER_ESTLIB_SYSTEMINCLUDE
-SOURCEPATH ../TEST
-SOURCE t_sqlstartup.cpp
+SOURCEPATH ../TEST
+SOURCE t_sqlstartup.cpp
-SOURCEPATH ../SRC/Common
-SOURCE SqlBufFlat.cpp
-SOURCE SqlUtil.cpp
+SOURCEPATH ../SRC/Common
+SOURCE SqlBufFlat.cpp
+SOURCE SqlUtil.cpp
-SOURCEPATH ../SRC/Server
-SOURCE SqlBur.cpp
-SOURCE SqlSrvConfig.cpp
-SOURCE SqlSrvMain.cpp
-SOURCE SqlSrvDriveSpace.cpp
-SOURCE SqlSrvStrings.cpp
-SOURCE SqlSrvStatementUtil.cpp
-SOURCE SqlSrvSecurityMap.cpp
-SOURCE SqlSrvUtil.cpp
-SOURCE SqlSrvResourceProfiler.cpp
+SOURCEPATH ../SRC/Server
+SOURCE SqlBur.cpp
+SOURCE SqlSrvConfig.cpp
+SOURCE SqlSrvMain.cpp
+SOURCE SqlSrvDriveSpace.cpp
+SOURCE SqlSrvStrings.cpp
+SOURCE SqlSrvStatementUtil.cpp
+SOURCE SqlSrvSecurityMap.cpp
+SOURCE SqlSrvUtil.cpp
+SOURCE SqlSrvResourceProfiler.cpp
-SOURCEPATH ../SRC/Server/Compact
-SOURCE SqlCompact.cpp
-SOURCE SqlCompactConn.cpp
-SOURCE SqlCompactEntry.cpp
-SOURCE SqlCompactTimer.cpp
+SOURCEPATH ../SRC/Server/Compact
+SOURCE SqlCompact.cpp
+SOURCE SqlCompactConn.cpp
+SOURCE SqlCompactEntry.cpp
+SOURCE SqlCompactTimer.cpp
-LIBRARY estlib.lib
-LIBRARY hal.lib
-LIBRARY euser.lib
-LIBRARY efsrv.lib
-LIBRARY estor.lib
-LIBRARY abclient.lib
-STATICLIBRARY sqlite.lib
+LIBRARY estlib.lib
+LIBRARY hal.lib
+LIBRARY euser.lib
+LIBRARY efsrv.lib
+LIBRARY estor.lib
+LIBRARY abclient.lib
+STATICLIBRARY sqlite.lib
-VENDORID 0x70000001
+VENDORID 0x70000001
SMPSAFE
--- a/persistentstorage/sql/OsLayer/FileBuf64.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/OsLayer/FileBuf64.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -801,7 +801,7 @@
DoDiscard();
iReadAheadSize = RFileBuf64::KDefaultReadAheadSize;
iBase = static_cast <TUint8*> (User::Alloc(iCapacity));
- return iBase ? KErrNone : KErrNoMemory;
+ return iBase ? KErrNone : KErrNoMemory;
}
/**
--- a/persistentstorage/sql/OsLayer/FileBuf64.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/OsLayer/FileBuf64.h Tue Aug 31 16:57:14 2010 +0300
@@ -180,8 +180,8 @@
TInt iLength; //The length of the data currently held in the buffer.
//File related
TInt64 iFilePos; //The file position associated with the beginning of the buffer.
- TInt64 iFileSize; //The file size which is the logical end of file from the buffer's point of view.
- TInt64 iRealFileSize; //The real file size on disk.
+ TInt64 iFileSize; //The file size which is the nominal file length including the buffer contents.
+ TInt64 iRealFileSize; //The real file size in disk.
RFile64 iFile; //The file object.
//Read-ahead related
TBool iDirty; //The buffer contains pending data to be written to the file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/OsLayer/SqliteTraceDef.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,55 @@
+// Copyright (c) 2010 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:
+//
+#ifndef SQLITETRACEDEF_H
+#define SQLITETRACEDEF_H
+
+#include <e32def.h>
+#include "SqliteUtil.h"
+
+//////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_OS_TRACE_ENABLED
+ #define __SQLITETRACE_OSVAR(var) var
+ #define __SQLITETRACE_OSEXPR(expr) expr
+#else
+ #define __SQLITETRACE_OSVAR(var)
+ #define __SQLITETRACE_OSEXPR(expr)
+#endif
+
+//////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_RDEBUG_PRINT
+ #undef OstTrace0
+ #undef OstTrace1
+ #undef OstTraceExt1
+ #undef OstTraceExt2
+ #undef OstTraceExt3
+ #undef OstTraceExt4
+ #undef OstTraceExt5
+
+ void SqlitePrintf(TInt aGroupName, TInt aTraceName, const char* aFormat, ...);
+
+ #define OstTrace0 SqlitePrintf
+ #define OstTrace1 SqlitePrintf
+ #define OstTraceExt1 SqlitePrintf
+ #define OstTraceExt2 SqlitePrintf
+ #define OstTraceExt3 SqlitePrintf
+ #define OstTraceExt4 SqlitePrintf
+ #define OstTraceExt5 SqlitePrintf
+#endif//defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_RDEBUG_PRINT
+
+//////////////////////////////////////////////////////////////////////////////////////
+
+#endif//SQLITETRACEDEF_H
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/OsLayer/SqliteUtil.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,180 @@
+// Copyright (c) 2010 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:
+//
+#include <e32debug.h>
+#include "SqliteUtil.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqliteUtilTraces.h"
+#endif
+#include "SqliteTraceDef.h"
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#define UNUSED_ARG(arg) arg = arg
+#define UNUSED_DES(arg) arg
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_RDEBUG_PRINT
+
+/**
+This class has been added here to avoid the crashes when _SQLITE_RDEBUG_PRINT macro is defined but the
+data to be printed out is too big and cannot fit into the buffer with size KSqliteMaxPrnStrLen.
+@internalComponent
+*/
+class TSqliteDes16Overflow : public TDes16Overflow
+ {
+public:
+ virtual void Overflow(TDes16& /*aDes*/)
+ {
+ }
+ };
+
+//Replaces:
+// 1) "%lld" with "%ld"
+// 2) "%s" with "%S"
+//These are the differences in format specification between RDebig::Print and OST functions.
+//The new format spec length should be less or equal than the old format spec length.
+static void ReplaceFmtSpec(TDes& aFormat, const TDesC& aFmtSpec, const TDesC& aNewFmtSpec)
+ {
+ TInt fmtLength = aFormat.Length();
+ const TInt KDiff = aFmtSpec.Length() - aNewFmtSpec.Length();
+ TPtr ptr((TText*)aFormat.Ptr(), fmtLength, fmtLength);
+ TInt pos;
+ while((pos = ptr.Find(aFmtSpec)) >= 0)
+ {
+ ptr.Replace(pos, aFmtSpec.Length(), aNewFmtSpec);
+ fmtLength -= KDiff;
+ ptr.Set(ptr.MidTPtr(pos));
+ }
+ aFormat.SetLength(fmtLength);
+ }
+
+void SqlitePrintf(TInt /*aGroupName*/, TInt /*aTraceName*/, const char* aFormat, ...)
+ {
+ VA_LIST list;
+ VA_START(list, aFormat);
+ TBuf<128> format;
+ _LIT(KTraceIdent, "Sqlite;");
+ format.Copy(TPtrC8((const TUint8*)aFormat));
+ format.Insert(0, KTraceIdent);
+ format.Append(_L("\r\n"));
+ _LIT(KOstI64Fmt, "%lld");
+ _LIT(KDbgPrnI64Fmt, "%ld");
+ ReplaceFmtSpec(format, KOstI64Fmt, KDbgPrnI64Fmt);
+ _LIT(KOstDes8Fmt, "%s");
+ _LIT(KDbgPrnDesFmt, "%S");
+ ReplaceFmtSpec(format, KOstDes8Fmt, KDbgPrnDesFmt);
+ TBuf<KSqliteMaxPrnStrLen> buf;
+ TSqliteDes16Overflow overflowHandler;
+ buf.AppendFormatList(format, list, &overflowHandler);
+#ifdef _SQLITE_RDEBUG_PRINT
+ RDebug::RawPrint(buf);
+#endif
+ }
+
+const TDesC* SqliteDes8to16Ptr(const TDesC8& aDes)
+ {
+ const TInt KBufSize = 100;
+ static TBuf<KBufSize> buf;
+ TPtrC8 ptr(aDes.Ptr(), Min(aDes.Length(), buf.MaxLength()));
+ buf.Copy(ptr);
+ return &buf;
+ }
+
+#endif//defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_RDEBUG_PRINT
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+SQLite panic category.
+
+@internalComponent
+*/
+_LIT(KSqlitePanicCategory, "Sqlite");
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+Panics the caller with aPanicCode panic code.
+The call will terminate the thread where it is called from.
+
+@param aPanicCode Panic code.
+
+@internalComponent
+*/
+static void SqlitePanic(TSqlitePanic aPanicCode)
+ {
+ User::Panic(KSqlitePanicCategory, aPanicCode);
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+The function prints out a "SQLite" panic message to the console and panics the thread where it is called from.
+It gives a useful information about the found error together with the source file name and line number where
+it occurred.
+
+Note: this function will output information regarding the panic only if _SQLITE_PANIC_TRACE_ENABLED macro is defined
+
+@param aFile Source file name
+@param aLine Source line number
+@param aPanicCode Panic code
+@param aHandle Numeric value, uniquely identfying the leaving location (the "this" pointer for example)
+
+@return KErrNone
+
+@internalComponent
+*/
+TInt TSqliteUtil::Panic(const TText* aFile, TInt aLine, TInt aPanicCode, TUint aHandle)
+ {
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_PANIC_TRACE_ENABLED
+ TPtrC fname(FileName(aFile));
+ OstTraceExt5(TRACE_FATAL, TSQLUTIL_PANIC, "SQLite-Panic;0x%X;%S;%d;%S;%d", aHandle, __SQLITEPRNSTR(fname), aLine, __SQLITEPRNSTR(KSqlitePanicCategory), aPanicCode);
+#else
+ UNUSED_ARG(aFile);
+ UNUSED_ARG(aLine);
+ UNUSED_ARG(aHandle);
+#endif
+ ::SqlitePanic(static_cast <TSqlitePanic> (aPanicCode));
+ return KErrNone;
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_PANIC_TRACE_ENABLED
+
+/**
+The function creates and returns TPtrC object which points to aFile parameter.
+
+@param aFile File name
+@return TPtrC object pointing to aFile parameter.
+
+@internalComponent
+*/
+TPtrC TSqliteUtil::FileName(const TText* aFile)
+ {
+ TPtrC p(aFile);
+ TInt ix = p.LocateReverse('\\');
+ if(ix<0)
+ ix=p.LocateReverse('/');
+ if(ix>=0)
+ p.Set(p.Mid(1+ix));
+ return p;
+ }
+
+#endif //defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_PANIC_TRACE_ENABLED
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/OsLayer/SqliteUtil.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,143 @@
+// Copyright (c) 2010 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:
+//
+#ifndef SQLITEUTIL_H
+#define SQLITEUTIL_H
+
+#include <e32std.h>
+
+/**
+Panic codes - used by asserts in the OS porting layer and the file buffer.
+
+@see KPanicCategory
+
+@internalComponent
+*/
+enum TSqlitePanic
+ {
+ ESqliteOsPanicNullOsLayerDataPtr = 1,
+ ESqliteOsPanicInvalidWAmount = 2,
+ ESqliteOsPanicOffset64bit = 3,
+ ESqliteOsPanicInvalidOpType =11,
+ ESqliteOsPanicInvalidFhStr =12,
+ ESqliteOsPanicInvalidFhData =13,
+ ESqliteOsPanicInvalidArg =14,
+ ESqliteOsPanicInvalidRAmount =15,
+ ESqliteOsPanicOsLayerDataExists =16,
+ ESqliteOsPanicInvalidDrive =17,
+ ESqliteOsPanicInvalidSectorSize =18,
+ ESqliteOsPanicInternalError =19,
+ ESqliteOsPanicNullDbFilePtr =20,
+ ESqliteOsPanicFastCounterFreq =21,
+ //
+ EFBufPanicCapacity =101,
+ EFBufPanicNullBuf =102,
+ EFBufPanicBufLen =103,
+ EFBufPanicFilePos =104,
+ EFBufPanicFileSize =105,
+ EFBufPanicFileHandle =106,
+ EFBufPanicFsHandle =107,
+ EFBufPanicMsgHandle =108,
+ EFBufPanicMsgIndex =109,
+ EFBufPanicFileNameLen =110,
+ EFBufPanicNullThis =111,
+ EFBufPanicDirty =112,
+ EFBufPanicNextReadFilePos =113,
+ EFBufPanicNextReadFilePosHits =114,
+ EFBufPanicFileBlockSize =115,
+ EFBufPanicRwDataLength =116,
+ };
+
+////////////////////////////////////////////////////////////////////////////////////////////
+
+//All macros in this header will have a non-void definition only if the OST_TRACE_COMPILER_IN_USE macro
+//is defined.
+//In order to get the traces enabled, the OST_TRACE_COMPILER_IN_USE macro has to be defined in
+//OstTraceDefinitions.h file.
+//After that, the trace output can be redirected by defining _SQL_RDEBUG_PRINT or specific categories
+//of traces can be enabled/disabled.
+
+//Enable _SQLITE_RDEBUG_PRINT if you want to redirect the OS porting layer and file buffer tracing output via RDebug::Print()
+//#define _SQLITE_RDEBUG_PRINT
+
+//Enable _SQLITE_OS_TRACE_ENABLED if you get the OS porting layer traces compiled in the binary
+//#define _SQLITE_OS_TRACE_ENABLED
+
+//Enable _SQLITE_FBUF_TRACE_ENABLED if you get the file buffer traces compiled in the binary
+//#define _SQLITE_FBUF_TRACE_ENABLED
+
+#ifdef _DEBUG
+ //Enable _SQLITE_PANIC_TRACE_ENABLED if you want to get more detailed output regarding panics
+ //#define _SQLITE_PANIC_TRACE_ENABLED
+#endif
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+//Wrap every string (file name, file path, etc.) you want to trace, in a __SQLITEPRNSTR()/__SQLITEPRNSTR8() macro.
+//There is a difference how RDebug::Print() and OstTraceExt<n>() work.
+#if defined _SQLITE_RDEBUG_PRINT
+ const TInt KSqliteMaxPrnStrLen = 512;
+ #define __SQLITEPRNSTR(des) &des
+ const TDesC* SqliteDes8to16Ptr(const TDesC8& aDes);
+ #define __SQLITEPRNSTR8(des) SqliteDes8to16Ptr(des)
+#else
+ #define __SQLITEPRNSTR(des) des
+ #define __SQLITEPRNSTR8(des) des
+#endif
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+Set of useful functions to print diagnostic messages on the console when a panic occurs.
+
+@internalComponent
+*/
+class TSqliteUtil
+ {
+public:
+ static TInt Panic(const TText* aFile, TInt aLine, TInt aPanicCode, TUint aHandle);
+
+private:
+ static TPtrC FileName(const TText* aFile);
+
+ };
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#define __SQLITESTRING(str) _S(str)
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+//__SQLITEPANIC/__SQLITEPANIC2 macro is used for printing out additional information when panic occurs in SQLite OS porting layer and the file buffer:
+//source file name, line number, "this" pointer, panic category.
+#define __SQLITEPANIC(aPanicCode) TSqliteUtil::Panic(__SQLITESTRING(__FILE__), __LINE__, aPanicCode, (TUint)this)
+#define __SQLITEPANIC2(aPanicCode) TSqliteUtil::Panic(__SQLITESTRING(__FILE__), __LINE__, aPanicCode, 0)
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#ifdef _SQLITE_OS_TRACE_ENABLED
+ #define SQLITE_TRACE_OS(trace) trace
+#else
+ #define SQLITE_TRACE_OS(trace) do {} while(0)
+#endif
+
+#ifdef _SQLITE_FBUF_TRACE_ENABLED
+ #define SQLITE_TRACE_FBUF(trace) trace
+#else
+ #define SQLITE_TRACE_FBUF(trace) do {} while(0)
+#endif
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#endif //SQLITEUTIL_H
--- a/persistentstorage/sql/OsLayer/os_symbian.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/OsLayer/os_symbian.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -40,50 +40,21 @@
#include "SqliteSymbian.h"
#include "FileBuf64.h"
#include <e32math.h>
-#include "UTraceSql.h"
#ifdef _SQLPROFILER
#include <hal.h>
#include "../INC/SqlResourceProfiler.h"
#endif
+#include "SqliteUtil.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "os_symbianTraces.h"
+#endif
+#include "SqliteTraceDef.h"
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-/**
-Panic category - used by asserts in this file (the OS porting layer).
-
-@see TPanicCodes
-
-@internalComponent
-*/
-_LIT(KPanicCategory, "Sqlite");
-
-/**
-Panic codes - used by asserts in this file (the OS porting layer).
-
-@see KPanicCategory
-
-@internalComponent
-*/
-enum TPanicCodes
- {
- EPanicNullOsLayerDataPtr = 1,
- EPanicInvalidWAmount = 2,
- EPanicOffset64bit = 3,
- EPanicInvalidOpType =11,
- EPanicInvalidFhStr =12,
- EPanicInvalidFhData =13,
- EPanicInvalidArg =14,
- EPanicInvalidRAmount =15,
- EPanicOsLayerDataExists =16,
- EPanicInvalidDrive =17,
- EPanicInvalidSectorSize =18,
- EPanicInternalError =19,
- EPanicNullDbFilePtr =20,
- EPanicFastCounterFreq =21
- };
-
//The SQLite temp files willl be created in this subdir
_LIT(KTempFileDir, "temp");
@@ -424,7 +395,7 @@
fname.Copy(fn8);
}
// 0 1 2 3 4 5 6 7 8 9 10
- RDebug::Print(_L("[SQL-OS]¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬\"%X\"¬%c¬%S¬%d¬%d¬%ld¬%d¬%ld¬%ld¬%ld¬%S\r\n"),
+ RDebug::Print(_L("[SQL-OS]¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬¬\"%X\"¬%c¬%S¬%d¬%d¬%ld¬%d¬%ld¬%ld¬%ld¬%S\n"),
//[SQL-OS]
//Handle
//Time from start, microseconds
@@ -488,7 +459,7 @@
{
TInt ticksPerSec = 0;
TInt err = HAL::Get(HAL::EFastCounterFrequency, ticksPerSec);
- __ASSERT_ALWAYS(err == KErrNone, User::Panic(KPanicCategory, EPanicFastCounterFreq));
+ __ASSERT_ALWAYS(err == KErrNone, __SQLITEPANIC2(ESqliteOsPanicFastCounterFreq));
return ticksPerSec;
}
@@ -682,6 +653,47 @@
#endif//_SQLPROFILER
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+Os2SqliteErr() is called at the end of many of the interface functions of the OS porting layer (wherever it is appropriate -
+TFileIo and TVfs interfaces). The purpose of this function is to identify the "out of memory" and "disk is full" errors
+reported by the used Symbian OS APIs (aOsErr parameter) and report them to SQLite as SQLITE_FULL and SQLITE_NOMEM errors.
+The KErrEof error (TFileIo::Read() can return KErrEof) is reported to SQLite as SQLITE_IOERR_SHORT_READ. The rest of failures
+are reported as the error specified in aDefaultErr parameter.
+
+@param aOsErr Symbian OS error
+@param aDefaultErr The default SQLite error that should be used if the aOsErr parameter is not one of:
+ KErrNone, KErrEof, KErrNoMemory, KErrDiskFull
+@return SQLITE_OK, The OS porting layer function call has completed successfully,
+ SQLITE_IOERR_SHORT_READ, The amount of the data read is less than the requested amount,
+ SQLITE_IOERR_NOMEM, Out of memory,
+ SQLITE_FULL, The disk is full,
+ aDefaultErr, The rest of failures will be reported as aDefaultErr.
+*/
+static TInt Os2SqliteErr(TInt aOsErr, TInt aDefaultErr)
+ {
+ switch(aOsErr)
+ {
+ case KErrNone:
+ return SQLITE_OK;
+ case KErrEof:
+ return SQLITE_IOERR_SHORT_READ;
+ case KErrNoMemory:
+ return SQLITE_IOERR_NOMEM;
+ case KErrDiskFull:
+ return SQLITE_FULL;
+ default:
+#ifdef _DEBUG
+ RDebug::Print(_L("SQLite OS porting layer, Os2SqliteErr(), err=%d\n"), aOsErr);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, OS2SQLITEERR, "OS;0;Os2SqliteErr;aOsErr=%d", aOsErr));
+#endif
+ break;
+ }
+ return aDefaultErr;
+ }
+
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
///////////////////// COsLayerData class declaration //////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -847,8 +859,7 @@
static int Sleep(sqlite3_vfs* aVfs, int aMicrosec);
static int CurrentTime(sqlite3_vfs* aVfs, double* aNow);
static int GetLastError(sqlite3_vfs *sVfs, int aBufLen, char* aBuf);
- static TInt DoGetDeviceCharacteristicsAndSectorSize(TDbFile& aDbFile, TInt& aRecReadBufSize);
-
+ static TInt DoGetDeviceCharacteristicsAndSectorSize(TDbFile& aDbFile, TInt& aRecReadBufSize);
private:
static TInt DoOpenFromHandle(TDbFile& aDbFile, const RMessage2& aMsg, TBool aReadOnly);
static inline TInt DoGetVolumeIoParamInfo(RFs& aFs, TInt aDriveNo, TVolumeIOParamInfo& aVolumeInfo);
@@ -958,12 +969,14 @@
*/
/* static */ TInt COsLayerData::Create()
{
- __ASSERT_DEBUG(!COsLayerData::iOsLayerData, User::Panic(KPanicCategory, EPanicOsLayerDataExists));
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, COSLAYERDATA_CREATE_ENTRY, "OS-Entry;0;COsLayerData::Create"));
+ __ASSERT_DEBUG(!COsLayerData::iOsLayerData, __SQLITEPANIC2(ESqliteOsPanicOsLayerDataExists));
if(!COsLayerData::iOsLayerData)
{
COsLayerData::iOsLayerData = new COsLayerData;
if(!COsLayerData::iOsLayerData)
{
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, COSLAYERDATA_CREATE_EXIT1, "OS-Exit;0;COsLayerData::Create;err=KErrNoMemory"));
return KErrNoMemory;
}
TInt err = COsLayerData::iOsLayerData->DoCreate();
@@ -971,9 +984,11 @@
{
delete COsLayerData::iOsLayerData;
COsLayerData::iOsLayerData = NULL;
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, COSLAYERDATA_CREATE_EXIT2, "OS-Exit;0;COsLayerData::Create;err=%d", err));
return err;
}
}
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, COSLAYERDATA_CREATE_EXIT3, "OS-Exit;0;COsLayerData::Create;err=KErrNone"));
return KErrNone;
}
@@ -984,6 +999,7 @@
{
delete COsLayerData::iOsLayerData;
COsLayerData::iOsLayerData = NULL;
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, COSLAYERDATA_DESTROY, "OS;0;COsLayerData::Destroy"));
}
/**
@@ -993,7 +1009,7 @@
*/
/* static */ inline COsLayerData& COsLayerData::Instance()
{
- __ASSERT_DEBUG(COsLayerData::iOsLayerData != NULL, User::Panic(KPanicCategory, EPanicNullOsLayerDataPtr));
+ __ASSERT_DEBUG(COsLayerData::iOsLayerData != NULL, __SQLITEPANIC2(ESqliteOsPanicNullOsLayerDataPtr));
return *COsLayerData::iOsLayerData;
}
@@ -1067,7 +1083,7 @@
*/
inline void COsLayerData::RetrieveAndResetFhData(const RMessage2*& aMsg, TBool& aReadOnly)
{
- __ASSERT_DEBUG(iMessage != NULL, User::Panic(KPanicCategory, EPanicInvalidFhData));
+ __ASSERT_DEBUG(iMessage != NULL, __SQLITEPANIC(ESqliteOsPanicInvalidFhData));
aMsg = iMessage;
aReadOnly = iReadOnly;
iMessage = NULL;
@@ -1093,6 +1109,7 @@
*/
inline COsLayerData::~COsLayerData()
{
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, COSLAYERDATA_COSLAYERDATA2, "OS;0;COsLayerData::~COsLayerData;iFs.Handle()=0x%X", (TUint)iFs.Handle()));
__FS_CALL(EFsOpFsClose, 0);
iFs.Close();
}
@@ -1149,6 +1166,7 @@
{
return err;
}
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, COSLAYERDATA_DOCREATE, "OS;0;COsLayerData::DoCreate;iFs.Handle()=0x%X;sysDrive=%d;iSysPrivDir=%S", (TUint)iFs.Handle(), sysDrive, __SQLITEPRNSTR(iSysPrivDir)));
return KErrNone;
}
@@ -1198,6 +1216,7 @@
osErr = sqliteErr == SQLITE_NOMEM ? KErrNoMemory : KErrGeneral;
COsLayerData::Destroy();
}
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, SQLITE3SYMBIANLIBINIT, "OS;0;sqlite3SymbianLibInit;osErr=%d", osErr));
return osErr;
}
@@ -1217,6 +1236,7 @@
{
(void)sqlite3_shutdown();
COsLayerData::Destroy();
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, SQLITE3SYMBIANLIBFINALIZE, "OS;0;sqlite3SymbianLibFinalize"));
}
/**
@@ -1253,7 +1273,7 @@
{
wchar_t* dest = reinterpret_cast <wchar_t*> (const_cast <TUint16*> (aFileNameDestBuf.Ptr()));
TInt len = mbstowcs(dest, aFileName, aFileNameDestBuf.MaxLength());
- __ASSERT_DEBUG(len >= 0, User::Panic(KPanicCategory, EPanicInternalError));
+ __ASSERT_DEBUG(len >= 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
//If len == aFileNameDestBuf.MaxLength(), then the output buffer is too small.
if(len < aFileNameDestBuf.MaxLength())
{
@@ -1282,7 +1302,7 @@
char* dest = reinterpret_cast <char*> (const_cast <TUint8*> (aFileNameDestBuf.Ptr()));
const wchar_t* src = reinterpret_cast <const wchar_t*> (aFileName.Ptr());
TInt len = wcstombs(dest, src, aFileNameDestBuf.MaxLength());
- __ASSERT_DEBUG(len >= 0, User::Panic(KPanicCategory, EPanicInternalError));
+ __ASSERT_DEBUG(len >= 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
//If len == aFileNameDestBuf.MaxLength(), then the output buffer is too small.
if(len < aFileNameDestBuf.MaxLength())
{
@@ -1424,7 +1444,7 @@
static void FhExtractAndStore(TDes& aDbFileName)
{
TInt fhStartPos = aDbFileName.Locate(TChar(KFhSeparator));
- __ASSERT_DEBUG(fhStartPos == KFhMarkPos, User::Panic(KPanicCategory, EPanicInvalidFhStr));
+ __ASSERT_DEBUG(fhStartPos == KFhMarkPos, __SQLITEPANIC2(ESqliteOsPanicInvalidFhStr));
//If this file name string contains file handles
if(fhStartPos == KFhMarkPos)
{
@@ -1432,12 +1452,12 @@
TLex lex(aDbFileName.Mid(fhStartPos + KFhMsgAddrPos, KFhMsgAddrLen));
TUint32 addr;
TInt err = lex.Val(addr, EHex);
- __ASSERT_DEBUG(err == KErrNone, User::Panic(KPanicCategory, EPanicInvalidFhStr));
+ __ASSERT_DEBUG(err == KErrNone, __SQLITEPANIC2(ESqliteOsPanicInvalidFhStr));
if(err == KErrNone)
{
//Cast the address to RMessage2 pointer.
const RMessage2* msg = reinterpret_cast <const RMessage2*> (addr);
- __ASSERT_DEBUG(msg != NULL, User::Panic(KPanicCategory, EPanicInvalidFhStr));
+ __ASSERT_DEBUG(msg != NULL, __SQLITEPANIC2(ESqliteOsPanicInvalidFhStr));
if(msg)
{
//Store the data from aDbFileName in the single COsLayerData instance.
@@ -1469,6 +1489,7 @@
iIsJournal = EFalse;
#endif
pMethods = 0;
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TDBFILE_TDBFILE, "OS;0x%X;TDbFile::TDbFile", (TUint)this));
}
/**
@@ -1489,7 +1510,7 @@
*/
static inline TDbFile& DbFile(sqlite3_file* aDbFile)
{
- __ASSERT_DEBUG(aDbFile != 0, User::Panic(KPanicCategory, EPanicNullDbFilePtr));
+ __ASSERT_DEBUG(aDbFile != 0, __SQLITEPANIC2(ESqliteOsPanicNullDbFilePtr));
return *(static_cast <TDbFile*> (aDbFile));
}
@@ -1510,12 +1531,12 @@
*/
/* static */ int TFileIo::Close(sqlite3_file* aDbFile)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TFILEIO_CLOSE1, "OS;0x%X;TFileIo::Close", (TUint)&dbFile));
__OS_CALL(EOsFileClose, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileClose], ::OsCallProfile(dbFile.iIsJournal, EOsFileClose), 0, 0, aDbFile, 0);
__FS_CALL(EFsOpFileClose, 0);
- dbFile.iFileBuf.Close();
+ dbFile.iFileBuf.Close();
return SQLITE_OK;
}
@@ -1543,38 +1564,23 @@
*/
/* static */ int TFileIo::Read(sqlite3_file* aDbFile, void* aBuf, int aAmt, sqlite3_int64 aOffset)
{
- SQLUTRACE_PROFILER(aDbFile);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileRead, aAmt, aOffset));
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_READ_ENTRY, "OS-Entry;0x%X;TFileIo::Read;aAmt=%d;aOffset=%lld", (TUint)&dbFile, aAmt, aOffset));
__OS_CALL(EOsFileRead, 0, 0);
__COUNTER_INCR(TheSqlSrvProfilerFileRead);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileRead], ::OsCallProfile(dbFile.iIsJournal, EOsFileRead), aOffset, aAmt, aDbFile, 0);
TPtr8 ptr((TUint8*)aBuf, 0, aAmt);
TInt err = dbFile.iFileBuf.Read(aOffset, ptr);
TInt cnt = ptr.Length();
- TInt sqliteErr = SQLITE_IOERR_READ;
- switch(err)
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_IOERR_READ);
+ if(cnt != aAmt && (sqliteErr == SQLITE_OK || sqliteErr == SQLITE_IOERR_SHORT_READ))
{
- case KErrNone:
- sqliteErr = SQLITE_OK;
- if(cnt != aAmt)
- {
- Mem::FillZ(static_cast <TUint8*> (aBuf) + cnt, aAmt - cnt);
- sqliteErr = SQLITE_IOERR_SHORT_READ;
- err = KErrEof;
- }
- break;
- case KErrEof:
- Mem::FillZ(static_cast <TUint8*> (aBuf) + cnt, aAmt - cnt);
- sqliteErr = SQLITE_IOERR_SHORT_READ;
- break;
- case KErrNoMemory:
- sqliteErr = SQLITE_IOERR_NOMEM;
- break;
- default:
- break;
+ Mem::FillZ(static_cast <TUint8*> (aBuf) + cnt, aAmt - cnt);
+ err = KErrEof;
+ sqliteErr = SQLITE_IOERR_SHORT_READ;
}
COsLayerData::Instance().SetOsErrorCode(err);
+ SQLITE_TRACE_OS(OstTraceExt4(TRACE_INTERNALS, TFILEIO_READ_EXIT, "OS-Exit;0x%X;TFileIo::Read;cnt=%d;err=%d;sqliteErr=%d", (TUint)&dbFile, cnt, err, sqliteErr));
return sqliteErr;
}
@@ -1653,9 +1659,11 @@
*/
/* static */ int TFileIo::Write(sqlite3_file* aDbFile, const void* aData, int aAmt, sqlite3_int64 aOffset)
{
- SQLUTRACE_PROFILER(aDbFile);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileWrite, aAmt, aOffset));
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_WRITE_ENTRY, "OS-Entry;0x%X;TFileIo::Write;aAmt=%d;aOffset=%lld", (TUint)&dbFile, aAmt, aOffset));
+ __OS_CALL(EOsFileWrite, 0, 0);
+ __COUNTER_INCR(TheSqlSrvProfilerFileWrite);
+ __OSTIME_COUNTER(TheOsCallTicks[EOsFileWrite], ::OsCallProfile(dbFile.iIsJournal, EOsFileWrite), aOffset, aAmt, aDbFile, 0);
TInt err = KErrNone;
if(!dbFile.iIsFileCreated)
{//Create a temp file if it has not been created.
@@ -1664,35 +1672,34 @@
if(err != KErrNone)
{
COsLayerData::Instance().SetOsErrorCode(err);
- return err == KErrNoMemory ? SQLITE_IOERR_NOMEM : SQLITE_FULL;
+ return ::Os2SqliteErr(err, SQLITE_FULL);
}
+ err = KErrAccessDenied;
+ if(!dbFile.iReadOnly)
+ {
+ TPtrC8 ptr((const TUint8*)aData, aAmt);
+ err = dbFile.iFileBuf.Write(aOffset, ptr);
+ }
+ COsLayerData::Instance().SetOsErrorCode(err);
- __OS_CALL(EOsFileWrite, 0, 0);
- __COUNTER_INCR(TheSqlSrvProfilerFileWrite);
- __OSTIME_COUNTER(TheOsCallTicks[EOsFileWrite], ::OsCallProfile(dbFile.iIsJournal, EOsFileWrite), aOffset, aAmt, aDbFile, 0);
- err = KErrAccessDenied;
- if(!dbFile.iReadOnly)
- {
- TPtrC8 ptr((const TUint8*)aData, aAmt);
- err = dbFile.iFileBuf.Write(aOffset, ptr);
- }
- COsLayerData::Instance().SetOsErrorCode(err);
-
- const TInt KFreePageCountOffset = 36;//hard-coded constant. SQLite does not offer anything - a constant or #define.
- //The checks in the "if" bellow do:
- // - "err == KErrNone" - check the free page count only after a successful "write";
- // - "aOffset == 0" - check the free page count only if the write operation affects the system page (at aOffset = 0);
- // - "aAmt >= (KFreePageCountOffset + sizeof(int))" - check the free page count only if the amount of bytes to be written
- // is more than the offset of the free page counter (othewrise the free page counter is not affected
- // by this write operation);
- // - "dbFile.iFreePageCallback.IsValid()" - check the free page count only if there is a valid callback;
- if(err == KErrNone && aOffset == 0 && aAmt >= (KFreePageCountOffset + sizeof(int)) && dbFile.iFreePageCallback.IsValid())
- {
- const TUint8* ptr = static_cast <const TUint8*> (aData) + KFreePageCountOffset;
- TInt freePageCount = (ptr[0] << 24) | (ptr[1] << 16) | (ptr[2] << 8) | ptr[3];
- dbFile.iFreePageCallback.CheckAndCallback(freePageCount);
- }
- return err == KErrNone ? SQLITE_OK : (err == KErrNoMemory ? SQLITE_IOERR_NOMEM : SQLITE_FULL);
+ const TInt KFreePageCountOffset = 36;//hard-coded constant. SQLite does not offer anything - a constant or #define.
+ //The checks in the "if" bellow do:
+ // - "err == KErrNone" - check the free page count only after a successful "write";
+ // - "aOffset == 0" - check the free page count only if the write operation affects the system page (at aOffset = 0);
+ // - "aAmt >= (KFreePageCountOffset + sizeof(int))" - check the free page count only if the amount of bytes to be written
+ // is more than the offset of the free page counter (othewrise the free page counter is not affected
+ // by this write operation);
+ // - "dbFile.iFreePageCallback.IsValid()" - check the free page count only if there is a valid callback;
+ if(err == KErrNone && aOffset == 0 && aAmt >= (KFreePageCountOffset + sizeof(int)) && dbFile.iFreePageCallback.IsValid())
+ {
+ const TUint8* ptr = static_cast <const TUint8*> (aData) + KFreePageCountOffset;
+ TInt freePageCount = (ptr[0] << 24) | (ptr[1] << 16) | (ptr[2] << 8) | ptr[3];
+ dbFile.iFreePageCallback.CheckAndCallback(freePageCount);
+ }
+
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_FULL);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_WRITE_EXIT, "OS-Exit;0x%X;TFileIo::Write;err=%d;sqliteErr=%d", (TUint)&dbFile, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -1717,9 +1724,8 @@
*/
/* static */ int TFileIo::Truncate(sqlite3_file* aDbFile, sqlite3_int64 aLength)
{
- SQLUTRACE_PROFILER(aDbFile);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileTruncate, aLength));
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_TRUNCATE_ENTRY, "OS-Entry;0x%X;TFileIo::Truncate;aLength=%lld", (TUint)&dbFile, aLength));
__OS_CALL(EOsFileTruncate, 0, 0);
__COUNTER_INCR(TheSqlSrvProfilerFileSetSize);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileTruncate], ::OsCallProfile(dbFile.iIsJournal, EOsFileTruncate), aLength, 0, aDbFile, 0);
@@ -1731,7 +1737,9 @@
__FS_CALL(EFsOpFileSetSize, 0);
TInt err = dbFile.iFileBuf.SetSize(aLength);
COsLayerData::Instance().SetOsErrorCode(err);
- return err == KErrNone ? SQLITE_OK : (err == KErrNoMemory ? SQLITE_IOERR_NOMEM : SQLITE_IOERR);
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_IOERR);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_TRUNCATE_EXIT, "OS-Exit;0x%X;TFileIo::Truncate;err=%d;sqliteErr=%d", (TUint)&dbFile, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -1754,8 +1762,8 @@
*/
/* static */int TFileIo::Sync(sqlite3_file* aDbFile, int /* aFlags */)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TFILEIO_SYNC_ENTRY, "OS-Entry;0x%X;TFileIo::Sync", (TUint)&dbFile));
__OS_CALL(EOsFileSync, 0, 0);
__COUNTER_INCR(TheSqlSrvProfilerFileSync);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileSync], ::OsCallProfile(dbFile.iIsJournal, EOsFileSync), 0, 0, aDbFile, 0);
@@ -1767,7 +1775,9 @@
__FS_CALL(EFsOpFileSync, 0);
TInt err = dbFile.iFileBuf.Flush();
COsLayerData::Instance().SetOsErrorCode(err);
- return err == KErrNone ? SQLITE_OK : (err == KErrNoMemory ? SQLITE_IOERR_NOMEM : SQLITE_IOERR);
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_IOERR);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_SYNC_EXIT, "OS-Exit;0x%X;TFileIo::Sync;err=%d;sqliteErr=%d", (TUint)&dbFile, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -1790,18 +1800,16 @@
*/
/* static */ int TFileIo::FileSize(sqlite3_file* aDbFile, sqlite3_int64* aSize)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TFILEIO_FILESIZE_ENTRY, "OS-Entry;0x%X;TFileIo::FileSize", (TUint)&dbFile));
__OS_CALL(EOsFileFileSize, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileFileSize], ::OsCallProfile(dbFile.iIsJournal, EOsFileFileSize), 0, 0, aDbFile, 0);
__FS_CALL(EFsOpFileSize, 0);
TInt err = dbFile.iFileBuf.Size(*aSize);
COsLayerData::Instance().SetOsErrorCode(err);
- if(err == KErrNone)
- {
- return SQLITE_OK;
- }
- return err == KErrNoMemory ? SQLITE_IOERR_NOMEM : SQLITE_IOERR;
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_IOERR);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_FILESIZE_EXIT, "OS-Exit;0x%X;TFileIo::FileSize;err=%d;sqliteErr=%d", (TUint)&dbFile, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -1824,7 +1832,6 @@
*/
/* static */ int TFileIo::Lock(sqlite3_file* aDbFile, int aLockType)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
__OS_CALL(EOsFileLock, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileLock], ::OsCallProfile(dbFile.iIsJournal, EOsFileLock), aLockType, 0, aDbFile, 0);
@@ -1857,7 +1864,6 @@
*/
/* static */ int TFileIo::Unlock(sqlite3_file* aDbFile, int aLockType)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
__OS_CALL(EOsFileUnlock, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileUnlock], ::OsCallProfile(dbFile.iIsJournal, EOsFileUnlock), aLockType, 0, aDbFile, 0);
@@ -1886,7 +1892,6 @@
*/
/* static */ int TFileIo::CheckReservedLock(sqlite3_file* aDbFile, int *aResOut)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
__OS_CALL(EOsFileCheckReservedLock, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileCheckReservedLock], ::OsCallProfile(dbFile.iIsJournal, EOsFileCheckReservedLock), 0, 0, aDbFile, 0);
@@ -1921,9 +1926,8 @@
*/
/* static */ int TFileIo::FileControl(sqlite3_file* aDbFile, int aOp, void* aArg)
{
- SQLUTRACE_PROFILER(aDbFile);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileFileCtr, aOp));
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_FILECONTROL_ENTRY, "OS-Entry;0x%X;TFileIo::FileControl;aOp=%d", (TUint)&dbFile, aOp));
__OS_CALL(EOsFileFileControl, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileFileControl], ::OsCallProfile(dbFile.iIsJournal, EOsFileFileControl), aOp, 0, aDbFile, 0);
TInt err = KErrNone;
@@ -1951,7 +1955,9 @@
break;
}
COsLayerData::Instance().SetOsErrorCode(err);
- return err == KErrNone ? SQLITE_OK : SQLITE_ERROR;
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_ERROR);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_FILECONTROL_EXIT, "OS-Exit;0x%X;TFileIo::FileControl;err=%d;sqliteErr=%d", (TUint)&dbFile, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -1973,11 +1979,10 @@
*/
/* static */ int TFileIo::SectorSize(sqlite3_file* aDbFile)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
__OS_CALL(EOsFileSectorSize, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileSectorSize], ::OsCallProfile(dbFile.iIsJournal, EOsFileSectorSize), 0, 0, aDbFile, 0);
- __ASSERT_DEBUG(dbFile.iSectorSize > 0, User::Panic(KPanicCategory, EPanicInternalError));
+ __ASSERT_DEBUG(dbFile.iSectorSize > 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
if(dbFile.iSectorSize > 0)
{
return dbFile.iSectorSize;
@@ -2004,11 +2009,10 @@
*/
/* static */ int TFileIo::DeviceCharacteristics(sqlite3_file* aDbFile)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
__OS_CALL(EOsFileDeviceCharacteristics, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsFileDeviceCharacteristics], ::OsCallProfile(dbFile.iIsJournal, EOsFileDeviceCharacteristics), 0, 0, aDbFile, 0);
- __ASSERT_DEBUG(dbFile.iDeviceCharacteristics >= 0, User::Panic(KPanicCategory, EPanicInternalError));
+ __ASSERT_DEBUG(dbFile.iDeviceCharacteristics >= 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
if(dbFile.iDeviceCharacteristics >= 0)
{
return dbFile.iDeviceCharacteristics;
@@ -2065,7 +2069,9 @@
/* static */ inline TInt TVfs::DoGetVolumeIoParamInfo(RFs& aFs, TInt aDriveNo, TVolumeIOParamInfo& aVolumeInfo)
{
__FS_CALL(EFsOpFsVolumeIoParam, 0);
- return aFs.VolumeIOParam(aDriveNo, aVolumeInfo);
+ TInt err = aFs.VolumeIOParam(aDriveNo, aVolumeInfo);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TVFS_DOGETVOLUMEIOPARAMINFO, "OS;0;TVfs::DoGetVolumeIoParamInfo;aDriveNo=%d;err=%d", aDriveNo, err));
+ return err;
}
/**
@@ -2153,7 +2159,7 @@
sectorSize = aVolumeInfo.iBlockSize;
}
}
- __ASSERT_DEBUG(sectorSize > 0 && (sectorSize & (sectorSize - 1)) == 0, User::Panic(KPanicCategory, EPanicInternalError));
+ __ASSERT_DEBUG(sectorSize > 0 && (sectorSize & (sectorSize - 1)) == 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
return sectorSize;
}
@@ -2182,8 +2188,8 @@
*/
/* static */ TInt TVfs::DoGetDeviceCharacteristicsAndSectorSize(TDbFile& aDbFile, TInt& aRecReadBufSize)
{
- __ASSERT_DEBUG(aDbFile.iDeviceCharacteristics < 0, User::Panic(KPanicCategory, EPanicInternalError));
- __ASSERT_DEBUG(aDbFile.iSectorSize <= 0, User::Panic(KPanicCategory, EPanicInternalError));
+ __ASSERT_DEBUG(aDbFile.iDeviceCharacteristics < 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
+ __ASSERT_DEBUG(aDbFile.iSectorSize <= 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
TInt driveNo;
TDriveInfo driveInfo;
__FS_CALL(EFsOpFileDrive, 0);
@@ -2201,6 +2207,7 @@
aDbFile.iDeviceCharacteristics = TVfs::DoGetDeviceCharacteristics(driveInfo, volumeInfo);
aDbFile.iSectorSize = TVfs::DoGetSectorSize(driveInfo, volumeInfo);
aRecReadBufSize = volumeInfo.iRecReadBufSize;
+ SQLITE_TRACE_OS(OstTraceExt5(TRACE_INTERNALS, TVFS_DOGETGETDEVICECHARACTERISTICSANDSECTORSIZE, "OS;0x%X;TVfs::DoGetDeviceCharacteristicsAndSectorSize;driveNo=%d;sectorSize=%d;devCharact=0x%X;readBufSize=%d", (TUint)&aDbFile, driveNo, aDbFile.iSectorSize, (TUint)aDbFile.iDeviceCharacteristics, volumeInfo.iRecReadBufSize));
return KErrNone;
}
@@ -2256,8 +2263,10 @@
COsLayerData& osLayerData = COsLayerData::Instance();
aDbFile.iFileBuf.Close();
- (void) osLayerData.iFs.Delete(aFname);
+ __SQLITETRACE_OSEXPR(TInt err2 =) osLayerData.iFs.Delete(aFname);
+ SQLITE_TRACE_OS(OstTraceExt4(TRACE_INTERNALS, TVFS_DOFILESIZECORRUPTIONCHECK1, "OS;0x%X;TVfs::DoFileSizeCorruptionCheck;size=%lld;err=%d;deleteErr=%d", (TUint)&aDbFile, size, err, err2));
err = aDbFile.iFileBuf.Create(osLayerData.iFs, aFname, aFmode);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TVFS_DOFILESIZECORRUPTIONCHECK2, "OS;0x%X;TVfs::DoFileSizeCorruptionCheck;createErr=%d", (TUint)&aDbFile, err));
}
return err;
}
@@ -2295,101 +2304,95 @@
@see TDbFile
*/
/* static */ int TVfs::Open(sqlite3_vfs* aVfs, const char* aFileName, sqlite3_file* aDbFile, int aFlags, int* aOutFlags)
- {
- SQLUTRACE_PROFILER(aVfs);
- __OS_CALL(EOsVfsOpen, 0, 0);
- __OSTIME_COUNTER(TheOsCallTicks[EOsVfsOpen], ::OsCallProfile(EFalse, EOsVfsOpen), 0, 0, aDbFile, aFileName);
-
- COsLayerData& osLayerData = COsLayerData::Instance();
- TFhStrType fhStrType = ENotFhStr;
- new (aDbFile) TDbFile;
- TDbFile& dbFile = ::DbFile(aDbFile);
-
+ {
+ __OS_CALL(EOsVfsOpen, 0, 0);
+ __OSTIME_COUNTER(TheOsCallTicks[EOsVfsOpen], ::OsCallProfile(EFalse, EOsVfsOpen), 0, 0, aDbFile, aFileName);
+ COsLayerData& osLayerData = COsLayerData::Instance();
+ new (aDbFile) TDbFile;
+ TDbFile& dbFile = ::DbFile(aDbFile);
if(!aFileName)
{
//It is to create and open a temp file if aFileName is NULL. In this case,
//we will defer the file creation util it is needed.
-
dbFile.pMethods = &TheFileIoApi;
dbFile.iIsFileCreated = EFalse;
if(aOutFlags)
{
*aOutFlags = SQLITE_OPEN_READWRITE;
}
+ osLayerData.SetOsErrorCode(KErrNone);
return SQLITE_OK;
}
-
- TFileName fname;
+ TFileName fname;
if(!::ConvertToUnicode(aFileName, fname))
- {
+ {
osLayerData.SetOsErrorCode(KErrBadName);
return SQLITE_CANTOPEN;
- }
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileOpen, aDbFile, &fname));
- fhStrType = ::FhStringProps(aFileName);
- TInt err = KErrNone;
- TInt recReadBufSize = -1;
- if(fhStrType == EFhMainDbStr)
- {//Main db file, open from handle
- const RMessage2* msg;
- TBool readOnly;
- osLayerData.RetrieveAndResetFhData(msg, readOnly);
- err = msg != NULL ? TVfs::DoOpenFromHandle(dbFile, *msg, readOnly) : KErrGeneral;
- }
- else
- {
- if(fhStrType == EFhStr)
- {//Not the main db file. Remove invalid characters in the file name
- ::FhConvertToFileName(fname, osLayerData.iSysPrivDir);//If fname does not have a path, iSysPrivDir will be used
- }
- TInt fmode = EFileRead;
- if(aFlags & SQLITE_OPEN_READWRITE)
- {
- fmode |= EFileWrite;
- }
- if(aFlags & SQLITE_OPEN_EXCLUSIVE)
- {
- fmode |= EFileShareExclusive;
- }
- err = KErrAccessDenied;
- TInt prevErr = KErrNone;
- if(aFlags & SQLITE_OPEN_DELETEONCLOSE)
- {
- fmode |= EDeleteOnClose;
- }
- if(aFlags & SQLITE_OPEN_CREATE)
- {
- __FS_CALL(EFsOpFileCreate, 0);
- prevErr = err = dbFile.iFileBuf.Create(osLayerData.iFs, fname, fmode);
- }
- if(err != KErrNone && err != KErrNoMemory && err != KErrDiskFull)
- {
- __FS_CALL(EFsOpFileOpen, 0);
- err = dbFile.iFileBuf.Open(osLayerData.iFs, fname, fmode);
-
- if(err == KErrNone && (aFlags & KJournalFileTypeBitMask))
- {
- err = TVfs::DoFileSizeCorruptionCheck(dbFile, fname, fmode);
- }
- }
- if((err != KErrNone && err != KErrNoMemory && err != KErrDiskFull) && (aFlags & SQLITE_OPEN_READWRITE))
- {
- aFlags &= ~SQLITE_OPEN_READWRITE;
- aFlags |= SQLITE_OPEN_READONLY;
- fmode &= ~EFileWrite;
- __FS_CALL(EFsOpFileOpen, 0);
- err = dbFile.iFileBuf.Open(osLayerData.iFs, fname, fmode);
- }
- if(err != KErrNone && prevErr == KErrAccessDenied)
- {
- err = KErrAccessDenied;
- }
- }
- if(err == KErrNone)
- {
- err = TVfs::DoGetDeviceCharacteristicsAndSectorSize(dbFile, recReadBufSize);
- }
-
+ }
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TVFS_OPEN_ENTRY, "OS-Entry;0x%X;TVfs::Open;fname=%S;aFlags=0x%X", (TUint)&aDbFile, __SQLITEPRNSTR(fname), (TUint)aFlags));
+ TFhStrType fhStrType = aFileName ? ::FhStringProps(aFileName) : ENotFhStr;
+ TInt err = KErrNone;
+ if(fhStrType == EFhMainDbStr)
+ {//Main db file, open from handle
+ const RMessage2* msg;
+ TBool readOnly;
+ osLayerData.RetrieveAndResetFhData(msg, readOnly);
+ err = msg != NULL ? TVfs::DoOpenFromHandle(dbFile, *msg, readOnly) : KErrGeneral;
+ }
+ else
+ {
+ if(fhStrType == EFhStr)
+ {//Not the main db file. Remove invalid characters in the file name
+ ::FhConvertToFileName(fname, osLayerData.iSysPrivDir);//If fname does not have a path, iSysPrivDir will be used
+ }
+ TInt fmode = EFileRead;
+ if(aFlags & SQLITE_OPEN_READWRITE)
+ {
+ fmode |= EFileWrite;
+ }
+ if(aFlags & SQLITE_OPEN_EXCLUSIVE)
+ {
+ fmode |= EFileShareExclusive;
+ }
+ if(aFlags & SQLITE_OPEN_DELETEONCLOSE)
+ {
+ fmode |= EDeleteOnClose;
+ }
+ err = KErrAccessDenied;
+ TInt prevErr = KErrNone;
+ if(aFlags & SQLITE_OPEN_CREATE)
+ {
+ __FS_CALL(EFsOpFileCreate, 0);
+ prevErr = err = dbFile.iFileBuf.Create(osLayerData.iFs, fname, fmode);
+ }
+ if(err != KErrNone && err != KErrNoMemory && err != KErrDiskFull)
+ {
+ __FS_CALL(EFsOpFileOpen, 0);
+ err = dbFile.iFileBuf.Open(osLayerData.iFs, fname, fmode);
+
+ if(err == KErrNone && (aFlags & KJournalFileTypeBitMask))
+ {
+ err = TVfs::DoFileSizeCorruptionCheck(dbFile, fname, fmode);
+ }
+ }
+ if((err != KErrNone && err != KErrNoMemory && err != KErrDiskFull) && (aFlags & SQLITE_OPEN_READWRITE))
+ {
+ aFlags &= ~SQLITE_OPEN_READWRITE;
+ aFlags |= SQLITE_OPEN_READONLY;
+ fmode &= ~EFileWrite;
+ __FS_CALL(EFsOpFileOpen, 0);
+ err = dbFile.iFileBuf.Open(osLayerData.iFs, fname, fmode);
+ }
+ if(err != KErrNone && prevErr == KErrAccessDenied)
+ {
+ err = KErrAccessDenied;
+ }
+ }
+ TInt recReadBufSize = -1;
+ if(err == KErrNone)
+ {
+ err = TVfs::DoGetDeviceCharacteristicsAndSectorSize(dbFile, recReadBufSize);
+ }
osLayerData.SetOsErrorCode(err);
if(err != KErrNone)
{
@@ -2412,7 +2415,9 @@
#ifdef _SQLPROFILER
dbFile.iIsJournal = aFlags & KJournalFileTypeBitMask;
#endif
- return err == KErrNone ? SQLITE_OK : (err == KErrNoMemory ? SQLITE_IOERR_NOMEM : SQLITE_CANTOPEN);
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_CANTOPEN);
+ SQLITE_TRACE_OS(OstTraceExt4(TRACE_INTERNALS, TVFS_OPEN_EXIT, "OS-Exit;0x%X;TVfs::Open;outFlags=0x%X;err=%d;sqliteErr=%d", (TUint)&aDbFile, aOutFlags ? (TUint)*aOutFlags : 0, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -2435,7 +2440,6 @@
*/
/* static */ int TVfs::Delete(sqlite3_vfs* aVfs, const char* aFileName, int /*aSyncDir*/)
{
- SQLUTRACE_PROFILER(aVfs);
__OS_CALL(EOsVfsDelete, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsVfsDelete], ::OsCallProfile(EFalse, EOsVfsDelete), 0, 0, 0, aFileName);
COsLayerData& osLayerData = COsLayerData::Instance();
@@ -2443,13 +2447,15 @@
if(!::ConvertToUnicode(aFileName, fname))
{
osLayerData.SetOsErrorCode(KErrBadName);
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_DELETE1, "OS;0;TVfs::Delete;err=KErrBadName"));
return SQLITE_ERROR;
}
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileName, &fname));
+ SQLITE_TRACE_OS(OstTraceExt1(TRACE_INTERNALS, TVFS_DELETE_ENTRY, "OS-Entry;0;TVfs::Delete;fname=%S", __SQLITEPRNSTR(fname)));
TFhStrType fhStrType = FhStringProps(aFileName);
if(fhStrType == EFhMainDbStr)
{//Deleting files not in your own private data cage - not allowed!
osLayerData.SetOsErrorCode(KErrPermissionDenied);
+ SQLITE_TRACE_OS(OstTraceExt1(TRACE_INTERNALS, TVFS_DELETE2, "OS;0;TVfs::Delete;err=KErrPermissionDenied;fname=%S", __SQLITEPRNSTR(fname)));
return SQLITE_ERROR;
}
if(fhStrType == EFhStr)
@@ -2459,7 +2465,9 @@
__FS_CALL(EFsOpFileDelete, 0);
TInt err = osLayerData.iFs.Delete(fname);
osLayerData.SetOsErrorCode(err);
- return err == KErrNone ? SQLITE_OK : (err == KErrNoMemory ? SQLITE_IOERR_NOMEM : SQLITE_IOERR_DELETE);
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_IOERR_DELETE);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TVFS_DELETE_EXIT, "OS-Exit;0;TVfs::Delete;err=%d;sqliteErr=%d", err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -2483,7 +2491,6 @@
*/
/* static */ int TVfs::Access(sqlite3_vfs* aVfs, const char* aFileName, int aFlags, int* aResOut)
{
- SQLUTRACE_PROFILER(aVfs);
__OS_CALL(EOsVfsAccess, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsVfsAccess], ::OsCallProfile(EFalse, EOsVfsAccess), aFlags, 0, 0, aFileName);
COsLayerData& osLayerData = COsLayerData::Instance();
@@ -2491,9 +2498,10 @@
if(!::ConvertToUnicode(aFileName, fname))
{
osLayerData.SetOsErrorCode(KErrGeneral);
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_ACCESS1, "OS;0;TVfs::Access;err=KErrGeneral"));
return SQLITE_IOERR_ACCESS;
}
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileName, &fname));
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TVFS_ACCESS_ENTRY, "OS-Entry;0;TVfs::Access;fname=%S;aFlags=0x%X", __SQLITEPRNSTR(fname), (TUint)aFlags));
TFhStrType fhStrType = ::FhStringProps(aFileName);
if(fhStrType == EFhStr)
{
@@ -2506,11 +2514,13 @@
{
osLayerData.SetOsErrorCode(KErrNone);
*aResOut = 0;
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_ACCESS_EXIT1, "OS-Exit;0;TVfs::Access;Exists-NoFound"));
return SQLITE_OK;
}
if(err != KErrNone)
{
osLayerData.SetOsErrorCode(err);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TVFS_ACCESS_EXIT2, "OS-Exit;0;TVfs::Access;err=%d", err));
return err == KErrNoMemory ? SQLITE_IOERR_NOMEM : SQLITE_IOERR_ACCESS;
}
*aResOut = 0;
@@ -2529,6 +2539,7 @@
break;
}
osLayerData.SetOsErrorCode(KErrNone);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TVFS_ACCESS_EXIT3, "OS-Exit;0;TVfs::Access;aResOut=%d", *aResOut));
return SQLITE_OK;
}
@@ -2560,7 +2571,6 @@
*/
/* static */ int TVfs::FullPathName(sqlite3_vfs* aVfs, const char* aRelative, int aBufLen, char* aBuf)
{
- SQLUTRACE_PROFILER(aVfs);
__OS_CALL(EOsVfsFullPathName, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsVfsFullPathName], ::OsCallProfile(EFalse, EOsVfsFullPathName), aBufLen, 0, 0, aRelative);
COsLayerData& osLayerData = COsLayerData::Instance();
@@ -2569,9 +2579,10 @@
TBuf<KMaxFileName + 1> fname;
if(!::ConvertToUnicode(aRelative, fname))
{
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_FULLPATHNAME1, "OS;0;TVfs::FullPathName;err=SQLITE_ERROR"));
return SQLITE_ERROR;
}
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileName, &fname));
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TVFS_FULLPATHNAME_ENTRY, "OS-Entry;0;TVfs::FullPathName;fname=%S;aBufLen=%d", __SQLITEPRNSTR(fname), aBufLen));
//Zero-terminate the converted file name
fname.Append(TChar(0));
TParse parse;
@@ -2590,8 +2601,10 @@
if(!::ConvertFromUnicode(parse.FullName(), dest8))
{//Zero the stored fh data, because it has been initialized by the FhExtractAndStore(fname) call (couple of lines above)
osLayerData.StoreFhData(NULL, EFalse);
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_FULLPATHNAME_EXIT1, "OS-Exit;0;TVfs::FullPathName;err=SQLITE_ERROR"));
return SQLITE_ERROR;
}
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_FULLPATHNAME_EXIT2, "OS-Exit;0;TVfs::FullPathName;err=SQLITE_OK"));
return SQLITE_OK;
}
@@ -2607,7 +2620,6 @@
*/
/* static */ int TVfs::Randomness(sqlite3_vfs* aVfs, int aBufLen, char* aBuf)
{
- SQLUTRACE_PROFILER(aVfs);
__OS_CALL(EOsVfsRandomness, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsVfsRandomness], ::OsCallProfile(EFalse, EOsVfsRandomness), aBufLen, 0, 0, 0);
COsLayerData& osLayerData = COsLayerData::Instance();
@@ -2631,7 +2643,6 @@
*/
/* static */ int TVfs::Sleep(sqlite3_vfs* aVfs, int aMicrosec)
{
- SQLUTRACE_PROFILER(aVfs);
__OS_CALL(EOsVfsSleep, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsVfsSleep], ::OsCallProfile(EFalse, EOsVfsSleep), aMicrosec, 0, 0, 0);
User::AfterHighRes(TTimeIntervalMicroSeconds32(aMicrosec));
@@ -2651,7 +2662,6 @@
*/
/* static */ int TVfs::CurrentTime(sqlite3_vfs* aVfs, double* aNow)
{
- SQLUTRACE_PROFILER(aVfs);
__OS_CALL(EOsVfsCurrentTime, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsVfsCurrentTime], ::OsCallProfile(EFalse, EOsVfsCurrentTime), 0, 0, 0, 0);
TTime now;
@@ -2687,7 +2697,6 @@
*/
/* static */int TVfs::GetLastError(sqlite3_vfs* aVfs, int /*aBufLen*/, char* /*aBuf*/)
{
- SQLUTRACE_PROFILER(aVfs);
__OS_CALL(EOsVfsGetLastError, 0, 0);
__OSTIME_COUNTER(TheOsCallTicks[EOsVfsGetLastError], ::OsCallProfile(EFalse, EOsVfsGetLastError), 0, 0, 0, 0);
return 0;
@@ -2702,9 +2711,11 @@
Memory allocation routine.
+EXPORT_C required to match IMPORT_C in stdlib.h and avoid compiler warning
+
@internalComponent
*/
-extern "C" void* sqlite3SymbianMalloc(size_t aSize)
+extern "C" EXPORT_C void* sqlite3SymbianMalloc(size_t aSize)
{
__MEM_CALL(EMemOpAlloc, aSize, 0);
return Allocator().Alloc(aSize);
@@ -2715,9 +2726,11 @@
Memory reallocation routine.
+EXPORT_C required to match IMPORT_C in stdlib.h and avoid compiler warning
+
@internalComponent
*/
-extern "C" void* sqlite3SymbianRealloc(void* aPtr, size_t aSize)
+extern "C" EXPORT_C void* sqlite3SymbianRealloc(void* aPtr, size_t aSize)
{
#ifdef _SQLPROFILER
TInt size = Allocator().AllocLen(aPtr);
@@ -2731,9 +2744,11 @@
Memory free routine.
+EXPORT_C required to match IMPORT_C in stdlib.h and avoid compiler warning
+
@internalComponent
*/
-extern "C" void sqlite3SymbianFree(void* aPtr)
+extern "C" EXPORT_C void sqlite3SymbianFree(void* aPtr)
{
#ifdef _SQLPROFILER
TInt size = Allocator().AllocLen(aPtr);
--- a/persistentstorage/sql/SQLite/alter.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/alter.c Tue Aug 31 16:57:14 2010 +0300
@@ -46,7 +46,7 @@
unsigned char const *zTableName = sqlite3_value_text(argv[1]);
int token;
- Token tname;
+ Token tname = {0,0,0}; /* Initialized to placate warning */
unsigned char const *zCsr = zSql;
int len = 0;
char *zRet;
@@ -101,7 +101,7 @@
unsigned char const *zTableName = sqlite3_value_text(argv[1]);
int token;
- Token tname;
+ Token tname = {0,0,0}; /* Initialized to placate warning */
int dist = 3;
unsigned char const *zCsr = zSql;
int len = 0;
--- a/persistentstorage/sql/SQLite/btree.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/btree.c Tue Aug 31 16:57:14 2010 +0300
@@ -3021,7 +3021,7 @@
Pgno *pPgnoNext /* OUT: Next overflow page number */
){
Pgno next = 0;
- int rc;
+ int rc = SQLITE_OK; /* Initialized to placate warning */
assert( sqlite3_mutex_held(pBt->mutex) );
/* One of these must not be NULL. Otherwise, why call this function? */
--- a/persistentstorage/sql/SQLite/delete.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/delete.c Tue Aug 31 16:57:14 2010 +0300
@@ -143,10 +143,10 @@
int isView; /* True if attempting to delete from a view */
int triggers_exist = 0; /* True if any triggers exist */
#endif
- int iBeginAfterTrigger; /* Address of after trigger program */
- int iEndAfterTrigger; /* Exit of after trigger program */
- int iBeginBeforeTrigger; /* Address of before trigger program */
- int iEndBeforeTrigger; /* Exit of before trigger program */
+ int iBeginAfterTrigger = 0; /* Address of after trigger program */
+ int iEndAfterTrigger = 0; /* Exit of after trigger program */
+ int iBeginBeforeTrigger = 0; /* Address of before trigger program */
+ int iEndBeforeTrigger = 0; /* Exit of before trigger program */
u32 old_col_mask = 0; /* Mask of OLD.* columns in use */
sContext.pParse = 0;
--- a/persistentstorage/sql/SQLite/expr.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/expr.c Tue Aug 31 16:57:14 2010 +0300
@@ -2737,7 +2737,7 @@
Expr opCompare; /* The X==Ei expression */
Expr cacheX; /* Cached expression X */
Expr *pX; /* The X expression */
- Expr *pTest; /* X==Ei (form A) or just Ei (form B) */
+ Expr *pTest = 0; /* X==Ei (form A) or just Ei (form B) */
assert(pExpr->pList);
assert((pExpr->pList->nExpr % 2) == 0);
--- a/persistentstorage/sql/SQLite/func.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/func.c Tue Aug 31 16:57:14 2010 +0300
@@ -911,7 +911,7 @@
flags = SQLITE_PTR_TO_INT(sqlite3_user_data(context));
if( flags & 1 ){
while( nIn>0 ){
- int len;
+ int len = 0; /* Initialized to placate warning. */
for(i=0; i<nChar; i++){
len = aLen[i];
if( memcmp(zIn, azChar[i], len)==0 ) break;
@@ -923,7 +923,7 @@
}
if( flags & 2 ){
while( nIn>0 ){
- int len;
+ int len = 0; /* Initialized to placate warning. */
for(i=0; i<nChar; i++){
len = aLen[i];
if( len<=nIn && memcmp(&zIn[nIn-len],azChar[i],len)==0 ) break;
--- a/persistentstorage/sql/SQLite/insert.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/insert.c Tue Aug 31 16:57:14 2010 +0300
@@ -388,14 +388,14 @@
int appendFlag = 0; /* True if the insert is likely to be an append */
/* Register allocations */
- int regFromSelect; /* Base register for data coming from SELECT */
+ int regFromSelect = 0;/* Base register for data coming from SELECT */
int regAutoinc = 0; /* Register holding the AUTOINCREMENT counter */
int regRowCount = 0; /* Memory cell used for the row counter */
int regIns; /* Block of regs holding rowid+data being inserted */
int regRowid; /* registers holding insert rowid */
int regData; /* register holding first column to insert */
int regRecord; /* Holds the assemblied row record */
- int regEof; /* Register recording end of SELECT data */
+ int regEof = 0; /* Register recording end of SELECT data */
int *aRegIdx = 0; /* One register allocated to each index */
@@ -1095,7 +1095,8 @@
Vdbe *v;
int nCol;
int onError;
- int j1, j2, j3; /* Addresses of jump instructions */
+ int j1, j3; /* Addresses of jump instructions */
+ int j2 = 0; /* Initialized to placate warning */
int regData; /* Register containing first data column */
int iCur;
Index *pIdx;
--- a/persistentstorage/sql/SQLite/printf.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/printf.c Tue Aug 31 16:57:14 2010 +0300
@@ -247,7 +247,7 @@
char buf[etBUFSIZE]; /* Conversion buffer */
char prefix; /* Prefix character. "+" or "-" or " " or '\0'. */
etByte errorflag = 0; /* True if an error is encountered */
- etByte xtype; /* Conversion paradigm */
+ etByte xtype = 0; /* Conversion paradigm */
char *zExtra; /* Extra memory used for etTCLESCAPE conversions */
#ifndef SQLITE_OMIT_FLOATING_POINT
int exp, e2; /* exponent of real numbers */
--- a/persistentstorage/sql/SQLite/select.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/select.c Tue Aug 31 16:57:14 2010 +0300
@@ -2467,7 +2467,7 @@
int regOutA; /* Address register for the output-A subroutine */
int regOutB; /* Address register for the output-B subroutine */
int addrOutA; /* Address of the output-A subroutine */
- int addrOutB; /* Address of the output-B subroutine */
+ int addrOutB = 0; /* Address of the output-B subroutine */
int addrEofA; /* Address of the select-A-exhausted subroutine */
int addrEofB; /* Address of the select-B-exhausted subroutine */
int addrAltB; /* Address of the A<B subroutine */
@@ -2482,7 +2482,7 @@
int labelEnd; /* Label for the end of the overall SELECT stmt */
int j1; /* Jump instructions that get retargetted */
int op; /* One of TK_ALL, TK_UNION, TK_EXCEPT, TK_INTERSECT */
- KeyInfo *pKeyDup; /* Comparison information for duplicate removal */
+ KeyInfo *pKeyDup = 0; /* Comparison information for duplicate removal */
KeyInfo *pKeyMerge; /* Comparison information for merging rows */
sqlite3 *db; /* Database connection */
ExprList *pOrderBy; /* The ORDER BY clause */
--- a/persistentstorage/sql/SQLite/sqlite3.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/sqlite3.h Tue Aug 31 16:57:14 2010 +0300
@@ -698,6 +698,7 @@
** into an integer that the pArg argument points to. This capability
** is used during testing and only needs to be supported when SQLITE_TEST
** is defined.
+**
*/
#define SQLITE_FCNTL_LOCKSTATE 1
--- a/persistentstorage/sql/SQLite/update.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/update.c Tue Aug 31 16:57:14 2010 +0300
@@ -109,10 +109,10 @@
int isView; /* Trying to update a view */
int triggers_exist = 0; /* True if any row triggers exist */
#endif
- int iBeginAfterTrigger; /* Address of after trigger program */
- int iEndAfterTrigger; /* Exit of after trigger program */
- int iBeginBeforeTrigger; /* Address of before trigger program */
- int iEndBeforeTrigger; /* Exit of before trigger program */
+ int iBeginAfterTrigger = 0; /* Address of after trigger program */
+ int iEndAfterTrigger = 0; /* Exit of after trigger program */
+ int iBeginBeforeTrigger = 0; /* Address of before trigger program */
+ int iEndBeforeTrigger = 0; /* Exit of before trigger program */
u32 old_col_mask = 0; /* Mask of OLD.* columns in use */
u32 new_col_mask = 0; /* Mask of NEW.* columns in use */
--- a/persistentstorage/sql/SQLite/util.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/util.c Tue Aug 31 16:57:14 2010 +0300
@@ -546,6 +546,19 @@
}
/*
+** Bitmasks used by sqlite3GetVarint(). These precomputed constants
+** are defined here rather than simply putting the constant expressions
+** inline in order to work around bugs in the RVT compiler.
+**
+** SLOT_2_0 A mask for (0x7f<<14) | 0x7f
+**
+** SLOT_4_2_0 A mask for (0x7f<<28) | SLOT_2_0
+*/
+#define SLOT_2_0 0x001fc07f
+#define SLOT_4_2_0 0xf01fc07f
+
+
+/*
** Read a 64-bit variable-length integer from memory starting at p[0].
** Return the number of bytes read. The value is stored in *v.
*/
@@ -572,13 +585,17 @@
return 2;
}
+ /* Verify that constants are precomputed correctly */
+ assert( SLOT_2_0 == ((0x7f<<14) | (0x7f)) );
+ assert( SLOT_4_2_0 == ((0xf<<28) | (0x7f<<14) | (0x7f)) );
+
p++;
a = a<<14;
a |= *p;
/* a: p0<<14 | p2 (unmasked) */
if (!(a&0x80))
{
- a &= (0x7f<<14)|(0x7f);
+ a &= SLOT_2_0;
b &= 0x7f;
b = b<<7;
a |= b;
@@ -587,14 +604,14 @@
}
/* CSE1 from below */
- a &= (0x7f<<14)|(0x7f);
+ a &= SLOT_2_0;
p++;
b = b<<14;
b |= *p;
/* b: p1<<14 | p3 (unmasked) */
if (!(b&0x80))
{
- b &= (0x7f<<14)|(0x7f);
+ b &= SLOT_2_0;
/* moved CSE1 up */
/* a &= (0x7f<<14)|(0x7f); */
a = a<<7;
@@ -608,7 +625,7 @@
/* 1:save off p0<<21 | p1<<14 | p2<<7 | p3 (masked) */
/* moved CSE1 up */
/* a &= (0x7f<<14)|(0x7f); */
- b &= (0x7f<<14)|(0x7f);
+ b &= SLOT_2_0;
s = a;
/* s: p0<<14 | p2 (masked) */
@@ -641,7 +658,7 @@
{
/* we can skip this cause it was (effectively) done above in calc'ing s */
/* b &= (0x7f<<28)|(0x7f<<14)|(0x7f); */
- a &= (0x7f<<14)|(0x7f);
+ a &= SLOT_2_0;
a = a<<7;
a |= b;
s = s>>18;
@@ -655,8 +672,8 @@
/* a: p2<<28 | p4<<14 | p6 (unmasked) */
if (!(a&0x80))
{
- a &= (0x7f<<28)|(0x7f<<14)|(0x7f);
- b &= (0x7f<<14)|(0x7f);
+ a &= SLOT_4_2_0;
+ b &= SLOT_2_0;
b = b<<7;
a |= b;
s = s>>11;
@@ -665,14 +682,14 @@
}
/* CSE2 from below */
- a &= (0x7f<<14)|(0x7f);
+ a &= SLOT_2_0;
p++;
b = b<<14;
b |= *p;
/* b: p3<<28 | p5<<14 | p7 (unmasked) */
if (!(b&0x80))
{
- b &= (0x7f<<28)|(0x7f<<14)|(0x7f);
+ b &= SLOT_4_2_0;
/* moved CSE2 up */
/* a &= (0x7f<<14)|(0x7f); */
a = a<<7;
@@ -689,7 +706,7 @@
/* moved CSE2 up */
/* a &= (0x7f<<29)|(0x7f<<15)|(0xff); */
- b &= (0x7f<<14)|(0x7f);
+ b &= SLOT_2_0;
b = b<<8;
a |= b;
@@ -767,8 +784,8 @@
/* a: p0<<28 | p2<<14 | p4 (unmasked) */
if (!(a&0x80))
{
- a &= (0x7f<<28)|(0x7f<<14)|(0x7f);
- b &= (0x7f<<28)|(0x7f<<14)|(0x7f);
+ a &= SLOT_4_2_0;
+ b &= SLOT_4_2_0;
b = b<<7;
*v = a | b;
return 5;
--- a/persistentstorage/sql/SQLite/vdbe.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SQLite/vdbe.c Tue Aug 31 16:57:14 2010 +0300
@@ -543,8 +543,10 @@
int rc = SQLITE_OK; /* Value to return */
sqlite3 *db = p->db; /* The database */
u8 encoding = ENC(db); /* The database encoding */
- Mem *pIn1, *pIn2, *pIn3; /* Input operands */
- Mem *pOut; /* Output operand */
+ Mem *pIn1 = 0; /* Input operands */
+ Mem *pIn2 = 0; /* Input operands */
+ Mem *pIn3 = 0; /* Input operands */
+ Mem *pOut = 0; /* Output operand */
u8 opProperty;
int iCompare = 0; /* Result of last OP_Compare operation */
int *aPermute = 0; /* Permuation of columns for OP_Compare */
@@ -3532,7 +3534,7 @@
*/
case OP_Delete: {
int i = pOp->p1;
- i64 iKey;
+ i64 iKey = 0;
Cursor *pC;
assert( i>=0 && i<p->nCursor );
--- a/persistentstorage/sql/SRC/Client/IPC/IPCBuf.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/IPC/IPCBuf.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -15,8 +15,13 @@
#include <e32base.h>
#include "IPCBuf.h"
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlDbSession.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "IPCBufTraces.h"
+#endif
+#include "SqlTraceDef.h"
/**
Standard, phase-one HIpcBuf factory method.
@@ -75,6 +80,7 @@
TPckg<TIpcStreamBuf> pckg(iBuf);
aArgs.Set(2, &pckg);
__SQLLEAVE_IF_ERROR(iHandle = iSession.SendReceive(aFunction, aArgs));
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, HIPCBUF_CONSTRUCTL, "0x%X;HIpcBuf::ConstructL;iHandle=%d", (TUint)this, iHandle));
TUint8* base = iBuf.iData;
// if reading we already have one buffer-full of data
TInt avail = Max(0, Min(iBuf.iExt, KIpcBufSize));
@@ -100,6 +106,7 @@
*/
HIpcBuf::~HIpcBuf()
{
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, HIPCBUF_HIPCBUFL2, "0x%X;HIpcBuf::~HIpcBuf;iHandle=%d", (TUint)this, iHandle));
if(iHandle > 0) //iHandle is valid only when > 0.
{
(void)iSession.SendReceive(::MakeMsgCode(ESqlSrvStreamClose, ESqlSrvStreamHandle, iHandle));
@@ -116,7 +123,7 @@
{
return 0;
}
- __SQLASSERT(Avail(ERead) == 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(Avail(ERead) == 0, __SQLPANIC(ESqlPanicInternalError));
TUint8* base=iBuf.iData;
IpcWriteL(base,Lag(EWrite));
SetBuf(EWrite,base,base);
@@ -131,7 +138,7 @@
*/
void HIpcBuf::OverflowL()
{
- __SQLASSERT(Avail(EWrite) == 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(Avail(EWrite) == 0, __SQLPANIC(ESqlPanicInternalError));
TUint8* base = iBuf.iData;
MovePos(ERead, Lag(ERead));
@@ -168,9 +175,9 @@
*/
TInt HIpcBuf::DoReadL(TAny* aPtr, TInt aMaxLength)
{
- __SQLASSERT(aMaxLength > 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aMaxLength > 0, __SQLPANIC(ESqlPanicInternalError));
TInt avail = Avail(ERead);
- __SQLASSERT(avail >= 0 && Avail(EWrite) >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(avail >= 0 && Avail(EWrite) >= 0, __SQLPANIC(ESqlPanicInternalError));
if(avail > 0)
{
TInt len = Min(aMaxLength, avail);
@@ -181,7 +188,7 @@
if(aMaxLength == 0)
return len; // that's it
}
- __SQLASSERT(Avail(ERead) == 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(Avail(ERead) == 0, __SQLPANIC(ESqlPanicInternalError));
if(aMaxLength < iBuf.ESize)
return avail + TStreamBuf::DoReadL(aPtr, aMaxLength);
@@ -202,9 +209,9 @@
*/
void HIpcBuf::DoWriteL(const TAny* aPtr,TInt aLength)
{
- __SQLASSERT(aLength > 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aLength > 0, __SQLPANIC(ESqlPanicInternalError));
TInt avail = Avail(EWrite);
- __SQLASSERT(Avail(ERead) >= 0 && avail >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(Avail(ERead) >= 0 && avail >= 0, __SQLPANIC(ESqlPanicInternalError));
if(avail > 0)
{
TInt len = Min(aLength, avail);
@@ -215,7 +222,7 @@
aPtr = (TUint8*)aPtr + len;
}
- __SQLASSERT(Avail(EWrite) == 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(Avail(EWrite) == 0, __SQLPANIC(ESqlPanicInternalError));
if(aLength < iBuf.ESize)
TStreamBuf::DoWriteL(aPtr, aLength);
else
@@ -250,7 +257,7 @@
aOffset += Mark(EWrite);
break;
default:
- __SQLASSERT_ALWAYS(0, ESqlPanicStreamMarkInvalid);
+ __ASSERT_ALWAYS(0, __SQLPANIC(ESqlPanicStreamMarkInvalid));
break;
}
break;
@@ -258,7 +265,7 @@
aOffset += end;
break;
default:
- __SQLASSERT_ALWAYS(0, ESqlPanicStreamLocationInvalid);
+ __ASSERT_ALWAYS(0, __SQLPANIC(ESqlPanicStreamLocationInvalid));
break;
}
TInt r = KErrNone;
@@ -273,7 +280,7 @@
r = KErrEof;
}
- __SQLASSERT_ALWAYS(!(aMark & ~(ERead | EWrite)), ESqlPanicStreamMarkInvalid);
+ __ASSERT_ALWAYS(!(aMark & ~(ERead | EWrite)), __SQLPANIC(ESqlPanicStreamMarkInvalid));
if(aMark & ERead)
{
TInt lag = aOffset - Pos(ERead);
@@ -304,7 +311,7 @@
*/
TInt HIpcBuf::IpcReadL(TAny* aPtr, TInt aMaxLength)
{
- __SQLASSERT(aMaxLength >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aMaxLength >= 0, __SQLPANIC(ESqlPanicInternalError));
if(aMaxLength == 0)
return 0;
@@ -327,7 +334,7 @@
*/
void HIpcBuf::IpcWriteL(const TAny* aPtr, TInt aLength)
{
- __SQLASSERT(aLength >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aLength >= 0, __SQLPANIC(ESqlPanicInternalError));
if(aLength == 0)
return;
--- a/persistentstorage/sql/SRC/Client/SQLDatabase.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SQLDatabase.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -13,8 +13,13 @@
// Description:
//
-#include "SqlPanic.h" //ESqlPanicInvalidObj, ESqlPanicObjExists
+#include "SqlAssert.h" //ESqlPanicInvalidObj, ESqlPanicObjExists
#include "SqlDatabaseImpl.h" //CSqlDatabaseImpl
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlDatabaseTraces.h"
+#endif
+#include "SqlTraceDef.h"
/**
Gets the category of the return code value that is returned by
@@ -95,12 +100,11 @@
*/
EXPORT_C TInt RSqlDatabase::Create(const TDesC& aDbFileName, const TDesC8* aConfig)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aDbFileName));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(aConfig ? (void)UTF::Printf(UTF::TTraceContext(UTF::EInternals),
- KStrParam, 2, aConfig) : void(0));
-
+ __SQLTRACE_BORDEREXPR(TPtrC8 config(aConfig ? *aConfig : KNullDesC8));
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLDATABASE_CREATE_ENTRY, "Entry;0x%X;RSqlDatabase::Create;aDbFileName=%S;aConfig=%s", (TUint)this, __SQLPRNSTR(aDbFileName), __SQLPRNSTR8(config, des16prnbuf)));
TRAPD(err, iImpl = CSqlDatabaseImpl::NewL(ESqlSrvDbCreate, aDbFileName, NULL, aConfig));
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLDATABASE_CREATE_Exit, "Exit;0x%X;RSqlDatabase::Create;iImpl=0x%X;err=%d", (TUint)this, (TUint)iImpl, err));
return err;
}
@@ -146,13 +150,11 @@
EXPORT_C TInt RSqlDatabase::Create(const TDesC& aDbFileName,
const RSqlSecurityPolicy& aSecurityPolicy, const TDesC8* aConfig)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aDbFileName));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(aConfig ? (void)UTF::Printf(UTF::TTraceContext(UTF::EInternals),
- KStrParam, 2, aConfig) : void(0));
-
- TRAPD(err, iImpl = CSqlDatabaseImpl::NewL(ESqlSrvDbCreateSecure, aDbFileName,
- &aSecurityPolicy.Impl(), aConfig));
+ __SQLTRACE_BORDEREXPR(TPtrC8 config(aConfig ? *aConfig : KNullDesC8));
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt4(TRACE_BORDER, RSQLDATABASE_CREATE2_ENTRY, "Entry;0x%X;RSqlDatabase::Create;aDbFileName=%S;aSecurityPolicy=0x%X;aConfig=%s", (TUint)this, __SQLPRNSTR(aDbFileName), (TUint)&aSecurityPolicy, __SQLPRNSTR8(config, des16prnbuf)));
+ TRAPD(err, iImpl = CSqlDatabaseImpl::NewL(ESqlSrvDbCreateSecure, aDbFileName, &aSecurityPolicy.Impl(), aConfig));
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLDATABASE_CREATE2_Exit, "Exit;0x%X;RSqlDatabase::Create;iImpl=0x%X;err=%d", (TUint)this, (TUint)iImpl, err));
return err;
}
@@ -199,12 +201,11 @@
*/
EXPORT_C TInt RSqlDatabase::Open(const TDesC& aDbFileName, const TDesC8* aConfig)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aDbFileName));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(aConfig ? (void)UTF::Printf(UTF::TTraceContext(UTF::EInternals),
- KStrParam, 2, aConfig) : void(0));
-
+ __SQLTRACE_BORDEREXPR(TPtrC8 config(aConfig ? *aConfig : KNullDesC8));
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLDATABASE_OPEN_ENTRY, "Entry;0x%X;RSqlDatabase::Open;aDbFileName=%S;aConfig=%s", (TUint)this, __SQLPRNSTR(aDbFileName), __SQLPRNSTR8(config, des16prnbuf)));
TRAPD(err, iImpl = CSqlDatabaseImpl::NewL(ESqlSrvDbOpen, aDbFileName, NULL, aConfig));
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLDATABASE_OPEN_EXIT, "Exit;0x%X;RSqlDatabase::Open;iImpl=0x%X;err=%d", (TUint)this, (TUint)iImpl, err));
return err;
}
@@ -240,12 +241,11 @@
*/
EXPORT_C void RSqlDatabase::CreateL(const TDesC& aDbFileName, const TDesC8* aConfig)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aDbFileName));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(aConfig ? (void)UTF::Printf(UTF::TTraceContext(UTF::EInternals),
- KStrParam, 2, aConfig) : void(0));
-
+ __SQLTRACE_BORDEREXPR(TPtrC8 config(aConfig ? *aConfig : KNullDesC8));
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLDATABASE_CREATEL_ENTRY, "Entry;0x%X;RSqlDatabase::CreateL;aDbFileName=%S;aConfig=%s", (TUint)this, __SQLPRNSTR(aDbFileName), __SQLPRNSTR8(config, des16prnbuf)));
iImpl = CSqlDatabaseImpl::NewL(ESqlSrvDbCreate, aDbFileName, NULL, aConfig);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_CREATEL_EXIT, "Entry;0x%X;RSqlDatabase::CreateL;iImpl=0x%X", (TUint)this, (TUint)iImpl));
}
/**
@@ -288,13 +288,11 @@
EXPORT_C void RSqlDatabase::CreateL(const TDesC& aDbFileName,
const RSqlSecurityPolicy& aSecurityPolicy, const TDesC8* aConfig)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aDbFileName));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(aConfig ? (void)UTF::Printf(UTF::TTraceContext(UTF::EInternals),
- KStrParam, 2, aConfig) : void(0));
-
- iImpl = CSqlDatabaseImpl::NewL(ESqlSrvDbCreateSecure, aDbFileName,
- &aSecurityPolicy.Impl(), aConfig);
+ __SQLTRACE_BORDEREXPR(TPtrC8 config(aConfig ? *aConfig : KNullDesC8));
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt4(TRACE_BORDER, RSQLDATABASE_CREATEL2_ENTRY, "Entry;0x%X;RSqlDatabase::CreateL;aDbFileName=%S;aSecurityPolicy=0x%X;aConfig=%s", (TUint)this, __SQLPRNSTR(aDbFileName), (TUint)&aSecurityPolicy, __SQLPRNSTR8(config, des16prnbuf)));
+ iImpl = CSqlDatabaseImpl::NewL(ESqlSrvDbCreateSecure, aDbFileName, &aSecurityPolicy.Impl(), aConfig);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_CREATEL2_EXIT, "Exit;0x%X;RSqlDatabase::CreateL;iImpl=0x%X", (TUint)this, (TUint)iImpl));
}
/**
@@ -339,12 +337,10 @@
*/
EXPORT_C void RSqlDatabase::OpenL(const TDesC& aDbFileName, const TDesC8* aConfig)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aDbFileName));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(aConfig ? (void)UTF::Printf(UTF::TTraceContext(UTF::EInternals),
- KStrParam, 2, aConfig) : void(0));
-
+ __SQLTRACE_BORDEREXPR(TPtrC8 config(aConfig ? *aConfig : KNullDesC8));
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLDATABASE_OPENL_ENTRY, "Entry;0x%X;RSqlDatabase::OpenL;aDbFileName=%S;aConfig=%s", (TUint)this, __SQLPRNSTR(aDbFileName), __SQLPRNSTR(config)));
iImpl = CSqlDatabaseImpl::NewL(ESqlSrvDbOpen, aDbFileName, NULL, aConfig);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_OPENL_EXIT, "Exit;0x%X;RSqlDatabase::OpenL;iImpl=0x%X", (TUint)this, (TUint)iImpl));
}
/**
@@ -362,8 +358,9 @@
*/
EXPORT_C void RSqlDatabase::Close()
{
- SQLUTRACE_PROFILER(this);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_CLOSE_ENTRY, "Entry;0x%X;RSqlDatabase::Close;iImpl=0x%X", (TUint)this, (TUint)iImpl));
delete iImpl;
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_CLOSE_EXIT, "Exit;0x%X;RSqlDatabase::Close;iImpl=0x%X", (TUint)this, (TUint)iImpl));
iImpl = NULL;
}
@@ -408,10 +405,10 @@
*/
EXPORT_C TInt RSqlDatabase::Attach(const TDesC& aDbFileName, const TDesC& aDbName)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrStrParam16, &aDbFileName, &aDbName));
-
- return Impl().Attach(aDbFileName, aDbName);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLDATABASE_ATTACH_ENTRY, "Entry;0x%X;RSqlDatabase::Attach;aDbFileName=%S;aDbName=%S", (TUint)this, __SQLPRNSTR(aDbFileName), __SQLPRNSTR(aDbName)));
+ TInt err = Impl().Attach(aDbFileName, aDbName);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_ATTACH_EXIT, "Entry;0x%X;RSqlDatabase::Attach;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -429,10 +426,10 @@
*/
EXPORT_C TInt RSqlDatabase::Detach(const TDesC& aDbName)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aDbName));
-
- return Impl().Detach(aDbName);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_DETACH_ENTRY, "Entry;0x%X;RSqlDatabase::Detach;aDbName=%S", (TUint)this, __SQLPRNSTR(aDbName)));
+ TInt err = Impl().Detach(aDbName);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_DETACH_EXIT, "Exit;0x%X;RSqlDatabase::Detach;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -470,11 +467,10 @@
*/
EXPORT_C TInt RSqlDatabase::Copy(const TDesC& aSrcDbFileName, const TDesC& aDestDbFileName)
{
- SQLUTRACE_PROFILER(0);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrStrParam16,
- &aSrcDbFileName, &aDestDbFileName));
-
- return CSqlDatabaseImpl::Copy(aSrcDbFileName, aDestDbFileName);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_COPY_ENTRY, "Entry;0;RSqlDatabase::Copy;aSrcDbFileName=%S;aDestDbFileName=%S", __SQLPRNSTR(aSrcDbFileName), __SQLPRNSTR(aDestDbFileName)));
+ TInt err = CSqlDatabaseImpl::Copy(aSrcDbFileName, aDestDbFileName);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLDATABASE_COPY_EXIT, "Exit;0;RSqlDatabase::Copy;err=%d", err));
+ return err;
}
/**
@@ -504,10 +500,10 @@
*/
EXPORT_C TInt RSqlDatabase::Delete(const TDesC& aDbFileName)
{
- SQLUTRACE_PROFILER(0);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aDbFileName));
-
- return CSqlDatabaseImpl::Delete(aDbFileName);
+ SQL_TRACE_BORDER(OstTraceExt1(TRACE_BORDER, RSQLDATABASE_DELETE_ENTRY, "Entry;0;RSqlDatabase::Delete;aDbFileName=%S", __SQLPRNSTR(aDbFileName)));
+ TInt err = CSqlDatabaseImpl::Delete(aDbFileName);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLDATABASE_DELETE_EXIT, "Exit;0;RSqlDatabase::Delete;err=%d", err));
+ return err;
}
/**
@@ -527,10 +523,9 @@
*/
EXPORT_C TInt RSqlDatabase::GetSecurityPolicy(RSqlSecurityPolicy& aSecurityPolicy) const
{
- SQLUTRACE_PROFILER(this);
- TRAPD(err, CSqlSecurityPolicy* securityPolicy = Impl().CloneSecurityPolicyL();
- aSecurityPolicy.Set(*securityPolicy));
-
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_GETSECURITYPOLICY_ENTRY, "Entry;0x%X;RSqlDatabase::GetSecurityPolicy;aSecurityPolicy=0x%X", (TUint)this, (TUint)&aSecurityPolicy));
+ TRAPD(err, CSqlSecurityPolicy* securityPolicy = Impl().CloneSecurityPolicyL(); aSecurityPolicy.Set(*securityPolicy));
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_GETSECURITYPOLICY_EXIT, "Exit;0x%X;RSqlDatabase::GetSecurityPolicy;err=%d", (TUint)this, err));
return err;
}
@@ -550,9 +545,10 @@
*/
EXPORT_C void RSqlDatabase::GetSecurityPolicyL(RSqlSecurityPolicy& aSecurityPolicy) const
{
- SQLUTRACE_PROFILER(this);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_GETSECURITYPOLICYL_ENTRY, "Entry;0x%X;RSqlDatabase::GetSecurityPolicyL;aSecurityPolicy=0x%X", (TUint)this, (TUint)&aSecurityPolicy));
CSqlSecurityPolicy* securityPolicy = Impl().CloneSecurityPolicyL();
aSecurityPolicy.Set(*securityPolicy);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLDATABASE_GETSECURITYPOLICYL_EXIT, "Exit;0x%X;RSqlDatabase::GetSecurityPolicyL", (TUint)this));
}
/**
@@ -581,8 +577,10 @@
*/
EXPORT_C TInt RSqlDatabase::SetIsolationLevel(RSqlDatabase::TIsolationLevel aIsolationLevel)
{
- SQLUTRACE_PROFILER(this);
- return Impl().SetIsolationLevel(aIsolationLevel);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_SETISOLATIONLEVEL_ENTRY, "Entry;0x%X;RSqlDatabase::SetIsolationLevel;aIsolationLevel=%d", (TUint)this, aIsolationLevel));
+ TInt err = Impl().SetIsolationLevel(aIsolationLevel);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_SETISOLATIONLEVEL_EXIT, "Exit;0x%X;RSqlDatabase::SetIsolationLevel;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -632,10 +630,10 @@
*/
EXPORT_C TInt RSqlDatabase::Exec(const TDesC& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aSqlStmt));
-
- return Impl().Exec(aSqlStmt);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_EXEC16_ENTRY, "Entry;0x%X;RSqlDatabase::Exec16;aSqlStmt=%S", (TUint)this, __SQLPRNSTR(aSqlStmt)));
+ TInt err = Impl().Exec(aSqlStmt);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_EXEC16_EXIT, "Exit;0x%X;RSqlDatabase::Exec16;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -685,10 +683,11 @@
*/
EXPORT_C TInt RSqlDatabase::Exec(const TDesC8& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam, 1, &aSqlStmt));
-
- return Impl().Exec(aSqlStmt);
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_EXEC8_ENTRY, "Entry;0x%X;RSqlDatabase::Exec8;aSqlStmt=%s", (TUint)this, __SQLPRNSTR8(aSqlStmt, des16prnbuf)));
+ TInt err = Impl().Exec(aSqlStmt);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_EXEC8_EXIT, "Exit;0x%X;RSqlDatabase::Exec8;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -743,10 +742,9 @@
*/
EXPORT_C void RSqlDatabase::Exec(const TDesC& aSqlStmt, TRequestStatus& aStatus)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aSqlStmt));
-
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_EXECASYNC16_ENTRY, "Entry;0x%X;RSqlDatabase::ExecAsync16;aSqlStmt=%S", (TUint)this, __SQLPRNSTR(aSqlStmt)));
Impl().Exec(aSqlStmt, aStatus);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_EXECASYNC16_EXIT, "Exit;0x%X;RSqlDatabase::ExecAsync16;aStatus.Int()=%d", (TUint)this, aStatus.Int()));
}
/**
@@ -801,10 +799,10 @@
*/
EXPORT_C void RSqlDatabase::Exec(const TDesC8& aSqlStmt, TRequestStatus& aStatus)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam, 1, &aSqlStmt));
-
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_EXECASYNC8_ENTRY, "Entry;0x%X;RSqlDatabase::ExecAsync8;aSqlStmt=%s", (TUint)this, __SQLPRNSTR8(aSqlStmt, des16prnbuf)));
Impl().Exec(aSqlStmt, aStatus);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_EXECASYNC8_EXIT, "Exit;0x%X;RSqlDatabase::ExecAsync8;aStatus.Int()=%d", (TUint)this, aStatus.Int()));
}
/**
@@ -833,8 +831,9 @@
*/
EXPORT_C TPtrC RSqlDatabase::LastErrorMessage() const
{
- SQLUTRACE_PROFILER(0);
- return Impl().LastErrorMessage();
+ TPtrC msg(Impl().LastErrorMessage());
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_LASTERRORMESSAGE, "0x%X;RSqlDatabase::LastErrorMessage;msg=%S", (TUint)this, __SQLPRNSTR(msg)));
+ return msg;
}
/**
@@ -850,8 +849,10 @@
*/
EXPORT_C TInt64 RSqlDatabase::LastInsertedRowId() const
{
- SQLUTRACE_PROFILER(0);
- return Impl().LastInsertedRowId();
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLDATABASE_LASTINSERTEDROWID_ENTRY, "Entry;0x%X;RSqlDatabase::LastInsertedRowId", (TUint)this));
+ TInt64 rc = Impl().LastInsertedRowId();
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_LASTINSERTEDROWID_EXIT, "Exit;0x%X;RSqlDatabase::LastInsertedRowId;RowId=%lld", (TUint)this, rc));
+ return rc;
}
/**
@@ -863,8 +864,10 @@
*/
EXPORT_C TBool RSqlDatabase::InTransaction() const
{
- SQLUTRACE_PROFILER(0);
- return Impl().InTransaction();
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLDATABASE_INTRABSACTION_ENTRY, "Entry;0x%X;RSqlDatabase::InTransaction", (TUint)this));
+ TBool res = Impl().InTransaction();
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_INTRABSACTION_EXIT, "Exit;0x%X;RSqlDatabase::InTransaction;res=%d", (TUint)this, res));
+ return res;
}
/**
@@ -881,8 +884,10 @@
*/
EXPORT_C TInt RSqlDatabase::Size() const
{
- SQLUTRACE_PROFILER(0);
- return Impl().Size();
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLDATABASE_SIZE_ENTRY, "Entry;0x%X;RSqlDatabase::Size", (TUint)this));
+ TInt rc = Impl().Size();
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_SIZE_EXIT, "Exit;0x%X;RSqlDatabase::Size;rc=%d", (TUint)this, rc));
+ return rc;
}
/**
@@ -902,10 +907,10 @@
*/
EXPORT_C TInt RSqlDatabase::Size(RSqlDatabase::TSize& aSize, const TDesC& aDbName) const
{
- SQLUTRACE_PROFILER(0);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 2, &aDbName));
-
- return Impl().Size(aSize, aDbName);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_SIZE2_ENTRY, "Entry;0x%X;RSqlDatabase::Size-2;aDbName=%S", (TUint)this, __SQLPRNSTR(aDbName)));
+ TInt err = Impl().Size(aSize, aDbName);
+ SQL_TRACE_BORDER(OstTraceExt4(TRACE_BORDER, RSQLDATABASE_SIZE2_EXIT, "Exit;0x%X;RSqlDatabase::Size-2;err=%d;aSize.iSize=%lld;aSize.iFree=%lld", (TUint)this, err, aSize.iSize, aSize.iFree));
+ return err;
}
/**
@@ -940,10 +945,10 @@
*/
EXPORT_C TInt RSqlDatabase::Compact(TInt64 aSize, const TDesC& aDbName)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KSizeStrParam16, 1, aSize, 2, &aDbName));
-
- return Impl().Compact(aSize, aDbName);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLDATABASE_COMPACT_ENTRY, "Entry;0x%X;RSqlDatabase::Compact;aSize=%lld;aDbName=%S", (TUint)this, aSize, __SQLPRNSTR(aDbName)));
+ TInt rc = Impl().Compact(aSize, aDbName);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_COMPACT_EXIT, "Exit;0x%X;RSqlDatabase::Compact;rc=%d", (TUint)this, rc));
+ return rc;
}
/**
@@ -980,10 +985,9 @@
*/
EXPORT_C void RSqlDatabase::Compact(TInt64 aSize, TRequestStatus& aStatus, const TDesC& aDbName)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KSizeStrParam16, 1, aSize, 3, &aDbName));
-
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLDATABASE_COMPACTASYNC_ENTRY, "Entry;0x%X;RSqlDatabase::CompactAsync;aSize=%lld;aDbName=%S", (TUint)this, aSize, __SQLPRNSTR(aDbName)));
Impl().Compact(aSize, aDbName, aStatus);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_COMPACTASYNC_EXIT, "Exit;0x%X;RSqlDatabase::CompactAsync;aStatus.Int()=%d", (TUint)this, aStatus.Int()));
}
/**
@@ -1010,10 +1014,12 @@
*/
EXPORT_C TInt RSqlDatabase::ReserveDriveSpace(TInt aSize)
{
- SQLUTRACE_PROFILER(this);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_RESERVEDRIVESPACE_ENTRY, "Entry;0x%X;RSqlDatabase::ReserveDriveSpace;aSize=%d", (TUint)this, aSize));
//Usage of the IPC call arguments:
//Arg 0: [out] requested size
- return Impl().Session().SendReceive(ESqlSrvDbReserveDriveSpace, TIpcArgs(aSize));
+ TInt err = Impl().Session().SendReceive(ESqlSrvDbReserveDriveSpace, TIpcArgs(aSize));
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_RESERVEDRIVESPACE_EXIT, "Exit;0x%X;RSqlDatabase::ReserveDriveSpace;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -1025,8 +1031,9 @@
*/
EXPORT_C void RSqlDatabase::FreeReservedSpace()
{
- SQLUTRACE_PROFILER(this);
- Impl().Session().SendReceive(ESqlSrvDbFreeReservedSpace);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLDATABASE_FREERESERVEDSPACE_ENTRY, "Entry;0x%X;RSqlDatabase::FreeReservedSpace", (TUint)this));
+ __SQLTRACE_BORDERVAR(TInt err =) Impl().Session().SendReceive(ESqlSrvDbFreeReservedSpace);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_FREERESERVEDSPACE_EXIT, "Exit;0x%X;RSqlDatabase::FreeReservedSpace;err=%d", (TUint)this, err));
}
/**
@@ -1043,8 +1050,10 @@
*/
EXPORT_C TInt RSqlDatabase::GetReserveAccess()
{
- SQLUTRACE_PROFILER(this);
- return Impl().Session().SendReceive(ESqlSrvDbGetReserveAccess);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLDATABASE_GETRESERVEACCESS_ENTRY, "Exit;0x%X;RSqlDatabase::GetReserveAccess", (TUint)this));
+ TInt err = Impl().Session().SendReceive(ESqlSrvDbGetReserveAccess);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_GETRESERVEACCESS_EXIT, "Exit;0x%X;RSqlDatabase::GetReserveAccess;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -1056,8 +1065,9 @@
*/
EXPORT_C void RSqlDatabase::ReleaseReserveAccess()
{
- SQLUTRACE_PROFILER(this);
- Impl().Session().SendReceive(ESqlSrvDbReleaseReserveAccess);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLDATABASE_RELEASERESERVEACCESS_ENTRY, "Entry;0x%X;RSqlDatabase::ReleaseReserveAccess", (TUint)this));
+ __SQLTRACE_BORDERVAR(TInt err =) Impl().Session().SendReceive(ESqlSrvDbReleaseReserveAccess);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLDATABASE_RELEASERESERVEACCESS_EXIT, "Exit;0x%X;RSqlDatabase::ReleaseReserveAccess;err=%d", (TUint)this, err));
}
/**
@@ -1069,6 +1079,6 @@
*/
CSqlDatabaseImpl& RSqlDatabase::Impl() const
{
- __SQLASSERT_ALWAYS(iImpl != NULL, ESqlPanicInvalidObj);
+ __ASSERT_ALWAYS(iImpl != NULL, __SQLPANIC(ESqlPanicInvalidObj));
return *iImpl;
}
--- a/persistentstorage/sql/SRC/Client/SqlBlob.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlBlob.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -15,9 +15,14 @@
#include <s32mem.h>
#include "SqlDb.h"
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlDatabaseImpl.h"
#include "IPCBuf.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlBlobTraces.h"
+#endif
+#include "SqlTraceDef.h"
// The maximum time (100 milliseconds) that a block of data is allowed to take to be read/written by TSqlBlob.
// If the time taken is longer than this value then the next block size used will be less
@@ -103,7 +108,7 @@
// Update how much data is still to be read, and the buffer pointer
remainingDataSize -= blockSize;
- __SQLASSERT(remainingDataSize >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(remainingDataSize >= 0, __SQLPANIC2(ESqlPanicInternalError));
ptr.Set((TUint8*)(ptr.Ptr() + blockSize), 0, remainingDataSize);
}
aDestBuffer.SetLength(aBlobSize);
@@ -132,7 +137,7 @@
// Update how much data is still to be written
remainingDataSize -= blockSize;
- __SQLASSERT(remainingDataSize >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(remainingDataSize >= 0, __SQLPANIC2(ESqlPanicInternalError));
}
aStrm.CommitL();
}
@@ -171,7 +176,7 @@
TInt blobSize = strm.SizeL(); // size of the blob, in bytes
if(blobSize > aBuffer.MaxSize())
{
- __SQLLEAVE(KErrOverflow);
+ __SQLLEAVE2(KErrOverflow);
}
DoReadInBlocksL(strm, aBuffer, blobSize);
CleanupStack::PopAndDestroy(); // strm
@@ -192,7 +197,7 @@
TInt blobSize = strm.SizeL(); // size of the blob, in bytes
if(dataSize > blobSize)
{
- __SQLLEAVE(KErrEof);
+ __SQLLEAVE2(KErrEof);
}
if(dataSize > 0)
{
@@ -236,14 +241,12 @@
EXPORT_C void RSqlBlobReadStream::OpenL(RSqlDatabase& aDb, const TDesC& aTableName, const TDesC& aColumnName,
TInt64 aRowId, const TDesC& aDbName)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KRSqlBlobParam16, &aDb, &aTableName,
- &aColumnName, aRowId, &aDbName));
-
+ SQL_TRACE_BORDER(OstTraceExt5(TRACE_BORDER, RSQLBLOBREADSTREAM_OPENL_ENTRY, "Entry;0;RSqlBlobReadStream::OpenL;aDb=0x%X;aTableName=%S;aColumnName=%S;aDbName=%S;aRowId=%lld", (TUint)&aDb, __SQLPRNSTR(aTableName), __SQLPRNSTR(aColumnName), __SQLPRNSTR(aDbName), aRowId));
HBufC8* ipcPrmBuf = ::PrepareIpcParamBufLC(aTableName, aColumnName, aRowId, ETrue, aDbName);
MStreamBuf* strm = ::CreateIpcStreamL(aDb.Impl().Session(), ipcPrmBuf->Des());
Attach(strm);
CleanupStack::PopAndDestroy(ipcPrmBuf);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLBLOBREADSTREAM_OPENL_EXIT, "Exit;0x%x;RSqlBlobReadStream::OpenL;strm=0x%X", (TUint)this, (TUint)strm));
}
/**
@@ -259,11 +262,12 @@
*/
EXPORT_C TInt RSqlBlobReadStream::SizeL()
{
- SQLUTRACE_PROFILER(this);
-
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLBLOBREADSTREAM_SIZEL_ENTRY, "Entry;0x%X;RSqlBlobReadStream::SizeL;", (TUint)this));
MStreamBuf* src = Source();
- __SQLASSERT_ALWAYS(src != NULL, ESqlPanicInvalidObj);
- return src->SizeL();
+ __ASSERT_ALWAYS(src != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ TInt size = src->SizeL();
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLBLOBREADSTREAM_SIZEL_EXIT, "Exit;0x%X;RSqlBlobReadStream::SizeL;size=%d", (TUint)this, size));
+ return size;
}
/**
@@ -299,14 +303,12 @@
EXPORT_C void RSqlBlobWriteStream::OpenL(RSqlDatabase& aDb, const TDesC& aTableName, const TDesC& aColumnName,
TInt64 aRowId, const TDesC& aDbName)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KRSqlBlobParam16, &aDb, &aTableName,
- &aColumnName, aRowId, &aDbName));
-
+ SQL_TRACE_BORDER(OstTraceExt5(TRACE_BORDER, RSQLBLOBWRITESTREAM_OPENL_ENTRY, "Entry;0;RSqlBlobWriteStream::OpenL;aDb=0x%X;aTableName=%S;aColumnName=%S;aDbName=%S;aRowId=%lld", (TUint)&aDb, __SQLPRNSTR(aTableName), __SQLPRNSTR(aColumnName), __SQLPRNSTR(aDbName), aRowId));
HBufC8* ipcPrmBuf = ::PrepareIpcParamBufLC(aTableName, aColumnName, aRowId, EFalse, aDbName);
MStreamBuf* strm = ::CreateIpcStreamL(aDb.Impl().Session(), ipcPrmBuf->Des());
Attach(strm);
CleanupStack::PopAndDestroy(ipcPrmBuf);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLBLOBWRITESTREAM_OPENL_EXIT, "Exit;0x%x;RSqlBlobWriteStream::OpenL;strm=0x%X", (TUint)this, (TUint)strm));
}
/**
@@ -322,11 +324,12 @@
*/
EXPORT_C TInt RSqlBlobWriteStream::SizeL()
{
- SQLUTRACE_PROFILER(this);
-
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLBLOBWRITESTREAM_SIZEL_ENTRY, "Entry;0x%X;RSqlBlobWriteStream::SizeL;", (TUint)this));
MStreamBuf* sink = Sink();
- __SQLASSERT_ALWAYS(sink != NULL, ESqlPanicInvalidObj);
- return sink->SizeL();
+ __ASSERT_ALWAYS(sink != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ TInt size = sink->SizeL();
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLBLOBWRITESTREAM_SIZEL_EXIT, "Exit;0x%X;RSqlBlobWriteStream::SizeL;size=%d", (TUint)this, size));
+ return size;
}
/**
@@ -367,11 +370,10 @@
TInt64 aRowId,
const TDesC& aDbName)
{
- SQLUTRACE_PROFILER(0);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KRSqlBlobParam16, &aDb, &aTableName,
- &aColumnName, aRowId, &aDbName));
-
- return ReadLC(aDb, aTableName, aColumnName, aRowId, aDbName);
+ SQL_TRACE_BORDER(OstTraceExt5(TRACE_BORDER, TSQLBLOB_GETLC_ENTRY, "Entry;0;TSqlBlob::GetLC;aDb=0x%X;aTableName=%S;aColumnName=%S;aDbName=%S;aRowId=%lld", (TUint)&aDb, __SQLPRNSTR(aTableName), __SQLPRNSTR(aColumnName), __SQLPRNSTR(aDbName), aRowId));
+ HBufC8* res = ReadLC(aDb, aTableName, aColumnName, aRowId, aDbName);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLBLOB_GETLC_EXIT, "Exit;0;TSqlBlob::GetLC;res=0x%X;res->Size()=%d", (TUint)res, res->Des().Size()));
+ return res;
}
/**
@@ -412,11 +414,9 @@
TInt64 aRowId,
const TDesC& aDbName)
{
- SQLUTRACE_PROFILER(0);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KRSqlBlobParam16, &aDb, &aTableName,
- &aColumnName, aRowId, &aDbName));
-
+ SQL_TRACE_BORDER(OstTraceExt5(TRACE_BORDER, TSQLBLOB_GET_ENTRY, "Entry;0;TSqlBlob::Get;aDb=0x%X;aTableName=%S;aColumnName=%S;aDbName=%S;aRowId=%lld", (TUint)&aDb, __SQLPRNSTR(aTableName), __SQLPRNSTR(aColumnName), __SQLPRNSTR(aDbName), aRowId));
TRAPD(err, ReadL(aDb, aTableName, aColumnName, aBuffer, aRowId, aDbName));
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLBLOB_GET_EXIT, "Exit;0;TSqlBlob::Get;aBuffer.Ptr()=0x%X;aBuffer.Size()=%d", (TUint)aBuffer.Ptr(), aBuffer.Size()));
return err;
}
@@ -458,10 +458,9 @@
TInt64 aRowId,
const TDesC& aDbName)
{
- SQLUTRACE_PROFILER(0);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KRSqlBlobParam16, &aDb, &aTableName,
- &aColumnName, aRowId, &aDbName));
-
+ SQL_TRACE_BORDER(OstTraceExt5(TRACE_BORDER, TSQLBLOB_SET_ENTRY, "Entry;0;TSqlBlob::Set;aDb=0x%X;aTableName=%S;aColumnName=%S;aDbName=%S;aRowId=%lld", (TUint)&aDb, __SQLPRNSTR(aTableName), __SQLPRNSTR(aColumnName), __SQLPRNSTR(aDbName), aRowId));
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLBLOB_SET_ENTRYEXT, "EntryExt;0;TSqlBlob::Set;aData.Ptr=0x%X;aData.Size()=%d", (TUint)aData.Ptr(), aData.Size()));
WriteL(aDb, aTableName, aColumnName, aData, aRowId, aDbName);
+ SQL_TRACE_BORDER(OstTrace0(TRACE_BORDER, TSQLBLOB_SET_EXIT, "Exit;0;TSqlBlob::Set"));
}
--- a/persistentstorage/sql/SRC/Client/SqlDatabaseImpl.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlDatabaseImpl.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -171,7 +171,7 @@
TPtrC8 securityPolicyData;
if(aFunction == ESqlSrvDbCreateSecure)
{
- __SQLASSERT(aSecurityPolicy != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aSecurityPolicy != NULL, __SQLPANIC(ESqlPanicBadArgument));
const RSqlBufFlat& bufFlat = aSecurityPolicy->BufFlat();
securityPolicyData.Set(bufFlat.BufDes());
}
--- a/persistentstorage/sql/SRC/Client/SqlDbSession.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlDbSession.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -23,6 +23,11 @@
#include "SqlSrvStartup.h" //StartSqlServer()
#include "SqlResourceTest.h" //TSqlResourceTestData
#include "SqlSecurityImpl.h" //CSqlSecurityPolicy
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlDbSessionTraces.h"
+#endif
+#include "SqlTraceDef.h"
///////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////// TSqlFhCmdFunctor ///////////////////////////////////////////////
@@ -196,8 +201,8 @@
TPtr8 bufPtr = buf->Des();
RDesWriteStream out(bufPtr);
TRAPD(err, SerializeToStreamL(out));
- __SQLASSERT(err == KErrNone, ESqlPanicInternalError);//"Write to descriptor" streaming operatons can't fail
- TUint32 arg0 = (TUint32)bufPtr.Length() | (aReadOnly ? 0x80000000 : 0);
+ __ASSERT_DEBUG(err == KErrNone, __SQLPANIC(ESqlPanicInternalError));//"Write to descriptor" streaming operatons can't fail
+ TUint32 arg0 = (TUint32)bufPtr.Length() | (aReadOnly ? 0x80000000 : 0);
TIpcArgs ipcArgs(arg0, &bufPtr);
err = aDbFile.TransferToServer(ipcArgs, 2, 3);
if(err == KErrNone)
@@ -301,6 +306,7 @@
*/
TInt RSqlDbSession::Connect(TSqlSrvFunction aFunction, const TDesC& aDbFileName, const TDesC8& aSecurityPolicyData, const TDesC8* aConfig)
{
+ SQL_TRACE_SESSION(OstTraceExt2(TRACE_INTERNALS, RSQLDBSESSION_CONNECT_ENTRY, "Entry;0x%X;RSqlDbSession::Connect;aDbFileName=%S", (TUint)this, __SQLPRNSTR(aDbFileName)));
#ifdef SYSLIBS_TEST
const TInt KDefaultMsgBufLen = 4;
#else
@@ -358,6 +364,7 @@
{
Close();
}
+ SQL_TRACE_SESSION(OstTraceExt3(TRACE_INTERNALS, RSQLDBSESSION_CONNECT_EXIT, "Exit;0x%X;RSqlDbSession::Connect;err=%d;handle=0x%X", (TUint)this, err, (TUint)Handle()));
return err;
}
@@ -650,6 +657,7 @@
*/
void RSqlDbSession::Close()
{
+ SQL_TRACE_SESSION(OstTraceExt2(TRACE_INTERNALS, RSQLDBSESSION_CLOSE, "0x%X;RSqlDbSession::Close;handle=0x%X", (TUint)this, (TUint)Handle()));
if(Handle())
{
(void)SendReceive(ESqlSrvDbClose);
@@ -848,7 +856,7 @@
{
//coverity[DEADCODE]
//The ASSERT might be useful in catching future defect in this function
- __SQLASSERT(aConfig != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aConfig != NULL, __SQLPANIC(ESqlPanicInternalError));
arg3Ptr.Append(*aConfig);
}
ipcArgs.Set(3, &arg3Ptr);
--- a/persistentstorage/sql/SRC/Client/SqlDbSession.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlDbSession.h Tue Aug 31 16:57:14 2010 +0300
@@ -18,7 +18,6 @@
#include <sqldb.h> //RSqlDatabase::TIsolationLevel
#include "SqlUtil.h" //TSqlSrvFunction
-#include "UTraceSql.h"
//Forward declarations
struct sqlite3;
--- a/persistentstorage/sql/SRC/Client/SqlDbSession.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlDbSession.inl Tue Aug 31 16:57:14 2010 +0300
@@ -223,8 +223,6 @@
*/
inline TInt RSqlDbSession::SendReceive(TInt aFunction)
{
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(TPtrC8 funcStr = GetIPCFuncStr(aFunction));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EBorder), KDbMsgStr, &funcStr));
return RSessionBase::SendReceive(aFunction);
}
@@ -237,8 +235,6 @@
*/
inline void RSqlDbSession::SendReceive(TInt aFunction, TRequestStatus& aStatus)
{
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(TPtrC8 funcStr = GetIPCFuncStr(aFunction));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EBorder), KDbMsgStr, &funcStr));
RSessionBase::SendReceive(aFunction, aStatus);
}
@@ -252,8 +248,6 @@
*/
inline TInt RSqlDbSession::SendReceive(TInt aFunction, const TIpcArgs& aArgs)
{
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(TPtrC8 funcStr = GetIPCFuncStr(aFunction));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EBorder), KDbMsgStr, &funcStr));
return RSessionBase::SendReceive(aFunction, aArgs);
}
@@ -266,7 +260,5 @@
*/
inline void RSqlDbSession::SendReceive(TInt aFunction,const TIpcArgs& aArgs, TRequestStatus& aStatus)
{
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(TPtrC8 funcStr = GetIPCFuncStr(aFunction));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EBorder), KDbMsgStr, &funcStr));
RSessionBase::SendReceive(aFunction, aArgs, aStatus);
}
--- a/persistentstorage/sql/SRC/Client/SqlResourceProfiler.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlResourceProfiler.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -14,7 +14,7 @@
//
#include "SqlResourceProfiler.h"
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlDatabaseImpl.h"
--- a/persistentstorage/sql/SRC/Client/SqlResourceTest.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlResourceTest.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -15,7 +15,7 @@
#include <sqldb.h> //TSqlResourceTester
#include "SqlResourceTest.h" //TSqlResourceTestData
-#include "SqlPanic.h" //__SQLASSERT, ESqlPanicInternalError
+#include "SqlAssert.h" //ESqlPanicInternalError
#include "SqlDbSession.h" //RSqlDbSession
#include "SqlResourceTester.h" //TSqlResourceTester
@@ -102,7 +102,7 @@
*/
TInt TSqlResourceTestData::Set(TSqlSrvFunction aFunction, TInt aAllocFailType, TInt aRate)
{
- __SQLASSERT(!iRqPending, ESqlPanicMisuse);
+ __ASSERT_DEBUG(!iRqPending, __SQLPANIC(ESqlPanicMisuse));
if(iDbSession)
{
return iDbSession->SendReceive(aFunction, TIpcArgs(aAllocFailType, aRate));
--- a/persistentstorage/sql/SRC/Client/SqlScalarFullSelect.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlScalarFullSelect.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -13,8 +13,13 @@
// Description:
//
-#include "SqlPanic.h" //ESqlPanicInvalidObj, ESqlPanicObjExists
+#include "SqlAssert.h" //ESqlPanicInvalidObj, ESqlPanicObjExists
#include "SqlDatabaseImpl.h" //CSqlDatabaseImpl
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlScalarFullSelectTraces.h"
+#endif
+#include "SqlTraceDef.h"
/**
Returns a reference to the implementation object of RSqlDatabase - CSqlDatabaseImpl.
@@ -25,7 +30,7 @@
*/
inline CSqlDatabaseImpl& TSqlScalarFullSelectQuery::Impl() const
{
- __SQLASSERT_ALWAYS(iDatabaseImpl != NULL, ESqlPanicInvalidObj);
+ __ASSERT_ALWAYS(iDatabaseImpl != NULL, __SQLPANIC(ESqlPanicInvalidObj));
return *iDatabaseImpl;
}
@@ -46,6 +51,7 @@
EXPORT_C TSqlScalarFullSelectQuery::TSqlScalarFullSelectQuery(RSqlDatabase& aDatabase) :
iDatabaseImpl(&aDatabase.Impl())
{
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_TSQLSCALARFULLSELECTQUERY, "0x%X;TSqlScalarFullSelectQuery::TSqlScalarFullSelectQuery;aDatabase=0x%X;iDatabaseImpl=0x%X", (TUint)this, (TUint)&aDatabase, (TUint)iDatabaseImpl));
}
/**
@@ -56,8 +62,8 @@
*/
EXPORT_C void TSqlScalarFullSelectQuery::SetDatabase(RSqlDatabase& aDatabase)
{
- SQLUTRACE_PROFILER(this);
iDatabaseImpl = &aDatabase.Impl();
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SETDATABASE, "0x%X;TSqlScalarFullSelectQuery::SetDatabase;aDatabase=0x%X;iDatabaseImpl=0x%X", (TUint)this, (TUint)&aDatabase, (TUint)iDatabaseImpl));
}
/**
@@ -74,12 +80,11 @@
*/
EXPORT_C TInt TSqlScalarFullSelectQuery::SelectIntL(const TDesC& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aSqlStmt));
-
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTINTL_ENTRY16, "Entry;0x%X;TSqlScalarFullSelectQuery::SelectIntL-16;aSqlStmt=%S", (TUint)this, __SQLPRNSTR(aSqlStmt)));
TInt res;
TPtr8 ptr(reinterpret_cast <TUint8*> (&res), sizeof(res));
(void)Impl().ExecScalarFullSelectL(aSqlStmt, ESqlInt, ptr);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTINTL_EXIT16, "Exit;0x%X;TSqlScalarFullSelectQuery::SelectIntL-16;res=%d", (TUint)this, res));
return res;
}
@@ -97,12 +102,11 @@
*/
EXPORT_C TInt64 TSqlScalarFullSelectQuery::SelectInt64L(const TDesC& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aSqlStmt));
-
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTINT64L_ENTRY16, "Entry;0x%X;TSqlScalarFullSelectQuery::SelectInt64L-16;aSqlStmt=%S", (TUint)this, __SQLPRNSTR(aSqlStmt)));
TInt64 res;
TPtr8 ptr(reinterpret_cast <TUint8*> (&res), sizeof(res));
(void)Impl().ExecScalarFullSelectL(aSqlStmt, ESqlInt64, ptr);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTINT64L_EXIT16, "Exit;0x%X;TSqlScalarFullSelectQuery::SelectInt64L-16;res=%lld", (TUint)this, res));
return res;
}
@@ -120,12 +124,11 @@
*/
EXPORT_C TReal TSqlScalarFullSelectQuery::SelectRealL(const TDesC& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aSqlStmt));
-
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTREALL_ENTRY16, "Entry;0x%X;TSqlScalarFullSelectQuery::SelectRealL-16;aSqlStmt=%S", (TUint)this, __SQLPRNSTR(aSqlStmt)));
TReal res;
TPtr8 ptr(reinterpret_cast <TUint8*> (&res), sizeof(res));
(void)Impl().ExecScalarFullSelectL(aSqlStmt, ESqlReal, ptr);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTREALL_EXIT16, "Exit;0x%X;TSqlScalarFullSelectQuery::SelectRealL-16", (TUint)this));
return res;
}
@@ -149,13 +152,12 @@
*/
EXPORT_C TInt TSqlScalarFullSelectQuery::SelectTextL(const TDesC& aSqlStmt, TDes& aDest)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aSqlStmt));
-
+ SQL_TRACE_BORDER(OstTraceExt5(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTTEXTL_ENTRY16, "Entry;0x%X;TSqlScalarFullSelectQuery::SelectTextL-16;aSqlStmt=%S;aDest.Ptr()=0x%X;aDest.Size()=%d;aDest.MaxSize()=%d", (TUint)this, __SQLPRNSTR(aSqlStmt), (TUint)aDest.Ptr(), aDest.Size(), aDest.MaxSize()));
TPtr8 ptr(reinterpret_cast <TUint8*> (const_cast <TUint16*> (aDest.Ptr())), aDest.MaxLength() * sizeof(TUint16));
- TInt err = Impl().ExecScalarFullSelectL(aSqlStmt, ESqlText, ptr);
+ TInt rc = Impl().ExecScalarFullSelectL(aSqlStmt, ESqlText, ptr);
aDest.SetLength(ptr.Length() / sizeof(TUint16));
- return err;
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTTEXTL_EXIT16, "Exit;0x%X;TSqlScalarFullSelectQuery::SelectTextL-16;rc=%d", (TUint)this, rc));
+ return rc;
}
/**
@@ -178,10 +180,10 @@
*/
EXPORT_C TInt TSqlScalarFullSelectQuery::SelectBinaryL(const TDesC& aSqlStmt, TDes8& aDest)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aSqlStmt));
-
- return Impl().ExecScalarFullSelectL(aSqlStmt, ESqlBinary, aDest);
+ SQL_TRACE_BORDER(OstTraceExt5(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTBINARYL_ENTRY16, "Entry;0x%X;TSqlScalarFullSelectQuery::SelectBinaryL-16;aSqlStmt=%S;aDest.Ptr()=0x%X;aDest.Size()=%d;aDest.MaxSize()=%d", (TUint)this, __SQLPRNSTR(aSqlStmt), (TUint)aDest.Ptr(), aDest.Size(), aDest.MaxSize()));
+ TInt rc = Impl().ExecScalarFullSelectL(aSqlStmt, ESqlBinary, aDest);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTBINARYL_EXIT16, "Exit;0x%X;TSqlScalarFullSelectQuery::SelectBinaryL-16;rc=%d", (TUint)this, rc));
+ return rc;
}
/**
@@ -198,12 +200,12 @@
*/
EXPORT_C TInt TSqlScalarFullSelectQuery::SelectIntL(const TDesC8& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam, 1, &aSqlStmt));
-
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTINTL_ENTRY8, "Entry;0x%X;TSqlScalarFullSelectQuery::SelectIntL-8;aSqlStmt=%s", (TUint)this, __SQLPRNSTR8(aSqlStmt, des16prnbuf)));
TInt res;
TPtr8 ptr(reinterpret_cast <TUint8*> (&res), sizeof(res));
(void)Impl().ExecScalarFullSelectL(aSqlStmt, ESqlInt, ptr);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTINTL_EXIT8, "Exit;0x%X;TSqlScalarFullSelectQuery::SelectIntL-8;res=%d", (TUint)this, res));
return res;
}
@@ -221,12 +223,12 @@
*/
EXPORT_C TInt64 TSqlScalarFullSelectQuery::SelectInt64L(const TDesC8& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam, 1, &aSqlStmt));
-
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTINT64L_ENTRY8, "Entry;0x%X;TSqlScalarFullSelectQuery::SelectInt64L-8;aSqlStmt=%s", (TUint)this, __SQLPRNSTR8(aSqlStmt, des16prnbuf)));
TInt64 res;
TPtr8 ptr(reinterpret_cast <TUint8*> (&res), sizeof(res));
(void)Impl().ExecScalarFullSelectL(aSqlStmt, ESqlInt64, ptr);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTINT64L_EXIT8, "Exit;0x%X;TSqlScalarFullSelectQuery::SelectInt64L-8;res=%lld", (TUint)this, res));
return res;
}
@@ -244,12 +246,12 @@
*/
EXPORT_C TReal TSqlScalarFullSelectQuery::SelectRealL(const TDesC8& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam, 1, &aSqlStmt));
-
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTREALL_ENTRY8, "Entry;0x%X;TSqlScalarFullSelectQuery::SelectRealL-8;aSqlStmt=%s", (TUint)this, __SQLPRNSTR8(aSqlStmt, des16prnbuf)));
TReal res;
TPtr8 ptr(reinterpret_cast <TUint8*> (&res), sizeof(res));
(void)Impl().ExecScalarFullSelectL(aSqlStmt, ESqlReal, ptr);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTREALL_EXIT8, "Exit;0x%X;TSqlScalarFullSelectQuery::SelectRealL-8", (TUint)this));
return res;
}
@@ -273,13 +275,13 @@
*/
EXPORT_C TInt TSqlScalarFullSelectQuery::SelectTextL(const TDesC8& aSqlStmt, TDes& aDest)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam, 1, &aSqlStmt));
-
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt5(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTTEXTL_ENTRY8, "Entry;0x%X;TSqlScalarFullSelectQuery::SelectTextL-8;aSqlStmt=%s;aDest.Ptr()=0x%X;aDest.Size()=%d;aDest.MaxSize()=%d", (TUint)this, __SQLPRNSTR8(aSqlStmt, des16prnbuf), (TUint)aDest.Ptr(), aDest.Size(), aDest.MaxSize()));
TPtr8 ptr(reinterpret_cast <TUint8*> (const_cast <TUint16*> (aDest.Ptr())), aDest.MaxLength() * sizeof(TUint16));
- TInt err = Impl().ExecScalarFullSelectL(aSqlStmt, ESqlText, ptr);
+ TInt rc = Impl().ExecScalarFullSelectL(aSqlStmt, ESqlText, ptr);
aDest.SetLength(ptr.Length() / sizeof(TUint16));
- return err;
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTTEXTL_EXIT8, "Exit;0x%X;TSqlScalarFullSelectQuery::SelectTextL-8;rc=%d", (TUint)this, rc));
+ return rc;
}
/**
@@ -302,8 +304,9 @@
*/
EXPORT_C TInt TSqlScalarFullSelectQuery::SelectBinaryL(const TDesC8& aSqlStmt, TDes8& aDest)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam, 1, &aSqlStmt));
-
- return Impl().ExecScalarFullSelectL(aSqlStmt, ESqlBinary, aDest);
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt5(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTBINARYL_ENTRY8, "Entry;0x%X;TSqlScalarFullSelectQuery::SelectBinaryL-8;aSqlStmt=%s;aDest.Ptr()=0x%X;aDest.Size()=%d;aDest.MaxSize()=%d", (TUint)this, __SQLPRNSTR8(aSqlStmt, des16prnbuf), (TUint)aDest.Ptr(), aDest.Size(), aDest.MaxSize()));
+ TInt rc = Impl().ExecScalarFullSelectL(aSqlStmt, ESqlBinary, aDest);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, TSQLSCALARFULLSELECTQUERY_SELECTBINARYL_EXIT8, "Exit;0x%X;TSqlScalarFullSelectQuery::SelectBinaryL-8;rc=%d", (TUint)this, rc));
+ return rc;
}
--- a/persistentstorage/sql/SRC/Client/SqlStatement.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlStatement.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -14,6 +14,11 @@
//
#include "SqlStatementImpl.h" //CSqlStatementImpl
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlStatementTraces.h"
+#endif
+#include "SqlTraceDef.h"
/////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -79,10 +84,10 @@
*/
EXPORT_C TInt RSqlStatement::Prepare(RSqlDatabase& aDatabase, const TDesC& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexStrParam16, &aDatabase, &aSqlStmt));
-
- return CSqlStatementImpl::New(iImpl, aDatabase.Impl(), aSqlStmt);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLSTATEMENT_PREPARE16_ENTRY, "Entry;0x%X;RSqlStatement::Prepare16;aDatabase=0x%X;aSqlStmt=%S", (TUint)this, (TUint)&aDatabase, __SQLPRNSTR(aSqlStmt)));
+ TInt err = CSqlStatementImpl::New(iImpl, aDatabase.Impl(), aSqlStmt);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLSTATEMENT_PREPARE16_EXIT, "Exit;0x%X;RSqlStatement::Prepare16;iImpl=0x%X;err=%d", (TUint)this, (TUint)iImpl, err));
+ return err;
}
/**
@@ -138,11 +143,11 @@
*/
EXPORT_C TInt RSqlStatement::Prepare(RSqlDatabase& aDatabase, const TDesC8& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexStrParam,
- &aDatabase, &aSqlStmt));
-
- return CSqlStatementImpl::New(iImpl, aDatabase.Impl(), aSqlStmt);
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLSTATEMENT_PREPARE8_ENTRY, "Entry;0x%X;RSqlStatement::Prepare8;aDatabase=0x%X;aSqlStmt=%s", (TUint)this, (TUint)&aDatabase, __SQLPRNSTR8(aSqlStmt, des16prnbuf)));
+ TInt err = CSqlStatementImpl::New(iImpl, aDatabase.Impl(), aSqlStmt);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLSTATEMENT_PREPARE8_EXIT, "Exit;0x%X;RSqlStatement::Prepare8;iImpl=0x%X;err=%d", (TUint)this, (TUint)iImpl, err));
+ return err;
}
/**
@@ -196,11 +201,9 @@
*/
EXPORT_C void RSqlStatement::PrepareL(RSqlDatabase& aDatabase, const TDesC& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexStrParam16,
- &aDatabase, &aSqlStmt));
-
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLSTATEMENT_PREPARE16L_ENTRY, "Entry;0x%X;RSqlStatement::Prepare16L;aDatabase=0x%X;aSqlStmt=%S", (TUint)this, (TUint)&aDatabase, __SQLPRNSTR(aSqlStmt)));
__SQLLEAVE_IF_ERROR(Prepare(aDatabase, aSqlStmt));
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSTATEMENT_PREPARE16L_EXIT, "Exit;0x%X;RSqlStatement::Prepare16L;iImpl=0x%X", (TUint)this, (TUint)iImpl));
}
/**
@@ -255,11 +258,10 @@
*/
EXPORT_C void RSqlStatement::PrepareL(RSqlDatabase& aDatabase, const TDesC8& aSqlStmt)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexStrParam,
- &aDatabase, &aSqlStmt));
-
+ __SQLTRACE_BORDERVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLSTATEMENT_PREPARE8L_ENTRY, "Entry;0x%X;RSqlStatement::Prepare8L;aDatabase=0x%X;aSqlStmt=%s", (TUint)this, (TUint)&aDatabase, __SQLPRNSTR8(aSqlStmt, des16prnbuf)));
__SQLLEAVE_IF_ERROR(Prepare(aDatabase, aSqlStmt));
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSTATEMENT_PREPARE8L_EXIT, "Exit;0x%X;RSqlStatement::Prepare8L;iImpl=0x%X", (TUint)this, (TUint)iImpl));
}
@@ -274,8 +276,9 @@
*/
EXPORT_C void RSqlStatement::Close()
{
- SQLUTRACE_PROFILER(this);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSTATEMENT_CLOSE_ENTRY, "Entry;0x%X;RSqlStatement::Close;iImpl=0x%X", (TUint)this, (TUint)iImpl));
delete iImpl;
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSTATEMENT_CLOSE_EXIT, "Exit;0x%X;RSqlStatement::Close;iImpl=0x%X", (TUint)this, (TUint)iImpl));
iImpl = NULL;
}
@@ -288,7 +291,6 @@
*/
EXPORT_C TBool RSqlStatement::AtRow() const
{
- SQLUTRACE_PROFILER(this);
return Impl().AtRow();
}
@@ -352,8 +354,10 @@
*/
EXPORT_C TInt RSqlStatement::Reset()
{
- SQLUTRACE_PROFILER(this);
- return Impl().Reset();
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLSTATEMENT_RESET_ENTRY, "Entry;0x%X;RSqlStatement::Reset", (TUint)this));
+ TInt err = Impl().Reset();
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSTATEMENT_RESET_EXIT, "Exit;0x%X;RSqlStatement::Reset;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -412,8 +416,10 @@
*/
EXPORT_C TInt RSqlStatement::Exec()
{
- SQLUTRACE_PROFILER(this);
- return Impl().Exec();
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLSTATEMENT_EXEC_ENTRY, "Entry;0x%X;RSqlStatement::Exec", (TUint)this));
+ TInt err = Impl().Exec();
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSTATEMENT_EXEC_EXIT, "Exit;0x%X;RSqlStatement::Exec;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -463,8 +469,9 @@
*/
EXPORT_C void RSqlStatement::Exec(TRequestStatus& aStatus)
{
- SQLUTRACE_PROFILER(this);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLSTATEMENT_EXECASYNC_ENTRY, "Entry;0x%X;RSqlStatement::ExecAsync", (TUint)this));
Impl().Exec(aStatus);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSTATEMENT_EXECASYNC_EXIT, "Exit;0x%X;RSqlStatement::ExecAsync;aStatus.Int()=%d", (TUint)this, aStatus.Int()));
}
/**
@@ -513,8 +520,10 @@
*/
EXPORT_C TInt RSqlStatement::Next()
{
- SQLUTRACE_PROFILER(this);
- return Impl().Next();
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLSTATEMENT_NEXT_ENTRY, "Entry;0x%X;RSqlStatement::Next", (TUint)this));
+ TInt err = Impl().Next();
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSTATEMENT_NEXT_EXIT, "Exit;0x%X;RSqlStatement::Next;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -537,9 +546,6 @@
*/
EXPORT_C TInt RSqlStatement::ParameterIndex(const TDesC& aParameterName) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aParameterName));
-
return Impl().ParamIndex(aParameterName);
}
@@ -555,7 +561,6 @@
*/
EXPORT_C TInt RSqlStatement::ColumnCount() const
{
- SQLUTRACE_PROFILER(this);
return Impl().ColumnCount();
}
@@ -576,9 +581,6 @@
*/
EXPORT_C TInt RSqlStatement::ColumnIndex(const TDesC& aColumnName) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KStrParam16, 1, &aColumnName));
-
return Impl().ColumnIndex(aColumnName);
}
@@ -609,9 +611,6 @@
*/
EXPORT_C TSqlColumnType RSqlStatement::ColumnType(TInt aColumnIndex) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnType(aColumnIndex);
}
@@ -650,9 +649,6 @@
*/
EXPORT_C TInt RSqlStatement::DeclaredColumnType(TInt aColumnIndex, TSqlColumnType& aColumnType) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().DeclaredColumnType(aColumnIndex, aColumnType);
}
@@ -700,9 +696,6 @@
*/
EXPORT_C TInt RSqlStatement::ColumnSize(TInt aColumnIndex) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnSize(aColumnIndex);
}
@@ -733,9 +726,6 @@
*/
EXPORT_C TInt RSqlStatement::BindNull(TInt aParamIndex)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aParamIndex));
-
return Impl().BindNull(aParamIndex);
}
@@ -764,9 +754,6 @@
*/
EXPORT_C TInt RSqlStatement::BindInt(TInt aParamIndex, TInt aParamValue)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aParamIndex));
-
return Impl().BindInt(aParamIndex, aParamValue);
}
@@ -795,9 +782,6 @@
*/
EXPORT_C TInt RSqlStatement::BindInt64(TInt aParamIndex, TInt64 aParamValue)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aParamIndex));
-
return Impl().BindInt64(aParamIndex, aParamValue);
}
@@ -826,9 +810,6 @@
*/
EXPORT_C TInt RSqlStatement::BindReal(TInt aParamIndex, TReal aParamValue)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aParamIndex));
-
return Impl().BindReal(aParamIndex, aParamValue);
}
@@ -872,10 +853,6 @@
*/
EXPORT_C TInt RSqlStatement::BindText(TInt aParamIndex, const TDesC& aParamText)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntSizeParam,
- aParamIndex, aParamText.Length()));
-
return Impl().BindText(aParamIndex, aParamText);
}
@@ -917,10 +894,6 @@
*/
EXPORT_C TInt RSqlStatement::BindBinary(TInt aParamIndex, const TDesC8& aParamData)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntSizeParam,
- aParamIndex, aParamData.Length()));
-
return Impl().BindBinary(aParamIndex, aParamData);
}
@@ -969,10 +942,6 @@
*/
EXPORT_C TInt RSqlStatement::BindZeroBlob(TInt aParamIndex, TInt aBlobSize)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntSizeParam,
- aParamIndex, aBlobSize));
-
return Impl().BindZeroBlob(aParamIndex, aBlobSize);
}
@@ -1005,9 +974,6 @@
*/
EXPORT_C TBool RSqlStatement::IsNull(TInt aColumnIndex) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnType(aColumnIndex) == ESqlNull;
}
@@ -1035,9 +1001,6 @@
*/
EXPORT_C TInt RSqlStatement::ColumnInt(TInt aColumnIndex) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnInt(aColumnIndex);
}
@@ -1065,9 +1028,6 @@
*/
EXPORT_C TInt64 RSqlStatement::ColumnInt64(TInt aColumnIndex) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnInt64(aColumnIndex);
}
@@ -1095,9 +1055,6 @@
*/
EXPORT_C TReal RSqlStatement::ColumnReal(TInt aColumnIndex) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnReal(aColumnIndex);
}
@@ -1140,9 +1097,6 @@
*/
EXPORT_C TPtrC RSqlStatement::ColumnTextL(TInt aColumnIndex) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
TPtrC res;
__SQLLEAVE_IF_ERROR(Impl().ColumnText(aColumnIndex, res));
return res;
@@ -1184,9 +1138,6 @@
*/
EXPORT_C TInt RSqlStatement::ColumnText(TInt aColumnIndex, TPtrC& aPtr) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnText(aColumnIndex, aPtr);
}
@@ -1228,9 +1179,6 @@
*/
EXPORT_C TInt RSqlStatement::ColumnText(TInt aColumnIndex, TDes& aDest) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnText(aColumnIndex, aDest);
}
@@ -1273,9 +1221,6 @@
*/
EXPORT_C TPtrC8 RSqlStatement::ColumnBinaryL(TInt aColumnIndex) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
TPtrC8 res;
__SQLLEAVE_IF_ERROR(Impl().ColumnBinary(aColumnIndex, res));
return res;
@@ -1317,9 +1262,6 @@
*/
EXPORT_C TInt RSqlStatement::ColumnBinary(TInt aColumnIndex, TPtrC8& aPtr) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnBinary(aColumnIndex, aPtr);
}
@@ -1361,9 +1303,6 @@
*/
EXPORT_C TInt RSqlStatement::ColumnBinary(TInt aColumnIndex, TDes8& aDest) const
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnBinary(aColumnIndex, aDest);
}
@@ -1377,9 +1316,6 @@
*/
EXPORT_C TInt RSqlStatement::ColumnName(TInt aColumnIndex, TPtrC& aNameDest)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aColumnIndex));
-
return Impl().ColumnName(aColumnIndex, aNameDest);
}
@@ -1398,9 +1334,6 @@
*/
EXPORT_C TInt RSqlStatement::ParameterName(TInt aParameterIndex, TPtrC& aNameDest)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KIntParam, 1, aParameterIndex));
-
return Impl().ParameterName(aParameterIndex, aNameDest);
}
@@ -1440,6 +1373,6 @@
*/
CSqlStatementImpl& RSqlStatement::Impl() const
{
- __SQLASSERT_ALWAYS(iImpl != NULL, ESqlPanicInvalidObj);
+ __ASSERT_ALWAYS(iImpl != NULL, __SQLPANIC(ESqlPanicInvalidObj));
return *iImpl;
}
--- a/persistentstorage/sql/SRC/Client/SqlStatementImpl.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlStatementImpl.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -9,7 +9,7 @@
// Nokia Corporation - initial contribution.
//
// Contributors:
-// NTT DOCOMO, INC - Fix for Bug 1915 "SQL server panics when using long column type strings"
+// NTT DOCOMO, INC - Fix for defect 1915 "SQL server panics when using long column type strings"
//
// Description:
//
@@ -45,8 +45,8 @@
*/
TBool RSqlLongColumnColl::TData::Compare(const TInt* aIndex, const RSqlLongColumnColl::TData& aData)
{
- __SQLASSERT(aIndex != NULL, ESqlPanicBadArgument);
- __SQLASSERT(*aIndex >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aIndex != NULL, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(*aIndex >= 0, __SQLPANIC2(ESqlPanicBadArgument));
return *aIndex == aData.iIndex;
}
@@ -63,8 +63,8 @@
*/
TInt RSqlLongColumnColl::Append(RSqlLongColumnColl::TColumnReader& aReader, TInt aColumnIndex, TInt aColumnSize)
{
- __SQLASSERT(aColumnIndex >= 0, ESqlPanicBadArgument);
- __SQLASSERT(aColumnSize >= KSqlMaxDesLen, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aColumnIndex >= 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aColumnSize >= KSqlMaxDesLen, __SQLPANIC(ESqlPanicBadArgument));
LONGCOL_INVARIANT();
HBufC8* colBuf = HBufC8::New(aColumnSize);
if(!colBuf)
@@ -96,11 +96,11 @@
for(TInt i=iValues.Count()-1;i>=0;--i)
{
const RSqlLongColumnColl::TData& data = iValues[i];
- __SQLASSERT(data.iIndex >= 0, ESqlPanicInternalError);
- __SQLASSERT(data.iData != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(data.iIndex >= 0, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(data.iData != NULL, __SQLPANIC(ESqlPanicInternalError));
for(TInt j=i-1;j>=0;--j)
{
- __SQLASSERT(data.iIndex != iValues[j].iIndex, ESqlPanicInternalError);
+ __ASSERT_DEBUG(data.iIndex != iValues[j].iIndex, __SQLPANIC(ESqlPanicInternalError));
}
}
}
@@ -318,7 +318,7 @@
*/
TInt CSqlStatementImpl::BindNull(TInt aParamIndex)
{
- __SQLASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, ESqlPanicBadColumnIndex);
+ __ASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
iBound = EFalse;
iParamValBufIt.MoveTo(aParamIndex);
iParamValBufIt.SetNull();
@@ -334,7 +334,7 @@
*/
TInt CSqlStatementImpl::BindInt(TInt aParamIndex, TInt aParamValue)
{
- __SQLASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, ESqlPanicBadColumnIndex);
+ __ASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
iBound = EFalse;
iParamValBufIt.MoveTo(aParamIndex);
return iParamValBufIt.SetInt(aParamValue);
@@ -349,7 +349,7 @@
*/
TInt CSqlStatementImpl::BindInt64(TInt aParamIndex, TInt64 aParamValue)
{
- __SQLASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, ESqlPanicBadColumnIndex);
+ __ASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
iBound = EFalse;
iParamValBufIt.MoveTo(aParamIndex);
return iParamValBufIt.SetInt64(aParamValue);
@@ -364,7 +364,7 @@
*/
TInt CSqlStatementImpl::BindReal(TInt aParamIndex, TReal aParamValue)
{
- __SQLASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, ESqlPanicBadColumnIndex);
+ __ASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
iBound = EFalse;
iParamValBufIt.MoveTo(aParamIndex);
return iParamValBufIt.SetReal(aParamValue);
@@ -379,7 +379,7 @@
*/
TInt CSqlStatementImpl::BindText(TInt aParamIndex, const TDesC& aParamText)
{
- __SQLASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, ESqlPanicBadColumnIndex);
+ __ASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
iBound = EFalse;
iParamValBufIt.MoveTo(aParamIndex);
return iParamValBufIt.SetText(aParamText);
@@ -394,7 +394,7 @@
*/
TInt CSqlStatementImpl::BindBinary(TInt aParamIndex, const TDesC8& aParamData)
{
- __SQLASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, ESqlPanicBadColumnIndex);
+ __ASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
iBound = EFalse;
iParamValBufIt.MoveTo(aParamIndex);
return iParamValBufIt.SetBinary(aParamData);
@@ -409,7 +409,7 @@
*/
TInt CSqlStatementImpl::BindZeroBlob(TInt aParamIndex, TInt aBlobSize)
{
- __SQLASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, ESqlPanicBadColumnIndex);
+ __ASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
iBound = EFalse;
iParamValBufIt.MoveTo(aParamIndex);
return iParamValBufIt.SetZeroBlob(aBlobSize);
@@ -425,8 +425,8 @@
*/
TSqlColumnType CSqlStatementImpl::ColumnType(TInt aColumnIndex)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
- __SQLASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, ESqlPanicInvalidRow);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
+ __ASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, __SQLPANIC(ESqlPanicInvalidRow));
iColumnValBufIt.MoveTo(aColumnIndex);
return static_cast <TSqlColumnType> (iColumnValBufIt.Type());
}
@@ -447,7 +447,7 @@
*/
TInt CSqlStatementImpl::DeclaredColumnType(TInt aColumnIndex, TSqlColumnType& aColumnType)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
if(iDeclaredColumnTypes.Count() == 0) //initialise iDeclaredColumnTypes array if necessary
{
RSqlBufFlat declaredColumnTypeBuf;
@@ -506,10 +506,10 @@
colType = ESqlReal;
}
err = iDeclaredColumnTypes.Append(colType);
- __SQLASSERT(err == KErrNone, ESqlPanicInternalError);//memory for the array elements has been reserved already
+ __ASSERT_DEBUG(err == KErrNone, __SQLPANIC(ESqlPanicInternalError));//memory for the array elements has been reserved already
++colIdx;
} //end of - while(declColumnTypeBufIt.Next())
- __SQLASSERT(colIdx == iColumnCnt, ESqlPanicInternalError);
+ __ASSERT_DEBUG(colIdx == iColumnCnt, __SQLPANIC(ESqlPanicInternalError));
declaredColumnTypeBuf.Close();
} //end of - if(iDeclaredColumnTypes.Count() == 0 && iColumnCnt > 0)
aColumnType = iDeclaredColumnTypes[aColumnIndex];
@@ -526,8 +526,8 @@
*/
TInt CSqlStatementImpl::ColumnSize(TInt aColumnIndex)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
- __SQLASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, ESqlPanicInvalidRow);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
+ __ASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, __SQLPANIC(ESqlPanicInvalidRow));
iColumnValBufIt.MoveTo(aColumnIndex);
return iColumnValBufIt.Size();
}
@@ -542,10 +542,10 @@
*/
TInt CSqlStatementImpl::ColumnInt(TInt aColumnIndex)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
- __SQLASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, ESqlPanicInvalidRow);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
+ __ASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, __SQLPANIC(ESqlPanicInvalidRow));
iColumnValBufIt.MoveTo(aColumnIndex);
- __SQLASSERT(iColumnValBufIt.IsPresent(), ESqlPanicValueNotPresent);
+ __ASSERT_DEBUG(iColumnValBufIt.IsPresent(), __SQLPANIC(ESqlPanicValueNotPresent));
return iColumnValBufIt.Int();
}
@@ -559,10 +559,10 @@
*/
TInt64 CSqlStatementImpl::ColumnInt64(TInt aColumnIndex)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
- __SQLASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, ESqlPanicInvalidRow);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
+ __ASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, __SQLPANIC(ESqlPanicInvalidRow));
iColumnValBufIt.MoveTo(aColumnIndex);
- __SQLASSERT(iColumnValBufIt.IsPresent(), ESqlPanicValueNotPresent);
+ __ASSERT_DEBUG(iColumnValBufIt.IsPresent(), __SQLPANIC(ESqlPanicValueNotPresent));
return iColumnValBufIt.Int64();
}
@@ -576,10 +576,10 @@
*/
TReal CSqlStatementImpl::ColumnReal(TInt aColumnIndex)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
- __SQLASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, ESqlPanicInvalidRow);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
+ __ASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, __SQLPANIC(ESqlPanicInvalidRow));
iColumnValBufIt.MoveTo(aColumnIndex);
- __SQLASSERT(iColumnValBufIt.IsPresent(), ESqlPanicValueNotPresent);
+ __ASSERT_DEBUG(iColumnValBufIt.IsPresent(), __SQLPANIC(ESqlPanicValueNotPresent));
return iColumnValBufIt.Real();
}
@@ -597,8 +597,8 @@
*/
TInt CSqlStatementImpl::ColumnText(TInt aColumnIndex, TPtrC& aPtr)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
- __SQLASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, ESqlPanicInvalidRow);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
+ __ASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, __SQLPANIC(ESqlPanicInvalidRow));
iColumnValBufIt.MoveTo(aColumnIndex);
if(iColumnValBufIt.IsPresent())
{
@@ -644,8 +644,8 @@
*/
TInt CSqlStatementImpl::ColumnText(TInt aColumnIndex, TDes& aDest)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
- __SQLASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, ESqlPanicInvalidRow);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
+ __ASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, __SQLPANIC(ESqlPanicInvalidRow));
iColumnValBufIt.MoveTo(aColumnIndex);
TInt err = KErrNone;
//The text column value has not been transferred to the client side if its length is >= KSqlMaxDesLen characters.
@@ -697,8 +697,8 @@
*/
TInt CSqlStatementImpl::ColumnBinary(TInt aColumnIndex, TPtrC8& aPtr)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
- __SQLASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, ESqlPanicInvalidRow);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
+ __ASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, __SQLPANIC(ESqlPanicInvalidRow));
iColumnValBufIt.MoveTo(aColumnIndex);
if(iColumnValBufIt.IsPresent())
{
@@ -744,8 +744,8 @@
*/
TInt CSqlStatementImpl::ColumnBinary(TInt aColumnIndex, TDes8& aDest)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
- __SQLASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, ESqlPanicInvalidRow);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
+ __ASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, __SQLPANIC(ESqlPanicInvalidRow));
iColumnValBufIt.MoveTo(aColumnIndex);
TInt err = KErrNone;
//The binary column value has not been transferred to the client side if its length is >= KSqlMaxDesLen bytes.
--- a/persistentstorage/sql/SRC/Client/SqlStatementImpl.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlStatementImpl.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2010 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2009 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"
--- a/persistentstorage/sql/SRC/Client/SqlStatementImpl.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlStatementImpl.inl Tue Aug 31 16:57:14 2010 +0300
@@ -53,10 +53,10 @@
*/
inline TPtrC RSqlLongColumnColl::Text(TInt aColumnIndex) const
{
- __SQLASSERT(aColumnIndex >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aColumnIndex >= 0, __SQLPANIC(ESqlPanicBadArgument));
LONGCOL_INVARIANT();
TInt rc = FindValue(aColumnIndex);
- __SQLASSERT_ALWAYS(rc >= 0, ESqlPanicInternalError);
+ __ASSERT_ALWAYS(rc >= 0, __SQLPANIC(ESqlPanicInternalError));
TPtrC8 ptr(iValues[rc].iData->Des());
return TPtrC(reinterpret_cast <const TUint16*> (ptr.Ptr()), ptr.Length() / sizeof(TUint16));
}
@@ -70,10 +70,10 @@
*/
inline TPtrC8 RSqlLongColumnColl::Binary(TInt aColumnIndex) const
{
- __SQLASSERT(aColumnIndex >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aColumnIndex >= 0, __SQLPANIC(ESqlPanicBadArgument));
LONGCOL_INVARIANT();
TInt rc = FindValue(aColumnIndex);
- __SQLASSERT_ALWAYS(rc >= 0, ESqlPanicInternalError);
+ __ASSERT_ALWAYS(rc >= 0, __SQLPANIC(ESqlPanicInternalError));
return iValues[rc].iData->Des();
}
@@ -85,7 +85,7 @@
*/
inline TBool RSqlLongColumnColl::IsPresent(TInt aColumnIndex) const
{
- __SQLASSERT(aColumnIndex >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aColumnIndex >= 0, __SQLPANIC(ESqlPanicBadArgument));
LONGCOL_INVARIANT();
return FindValue(aColumnIndex) >= 0;
}
@@ -99,7 +99,7 @@
*/
inline TInt RSqlLongColumnColl::FindValue(TInt aColumnIndex) const
{
- __SQLASSERT(aColumnIndex >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aColumnIndex >= 0, __SQLPANIC(ESqlPanicBadArgument));
return iValues.Find(aColumnIndex, &RSqlLongColumnColl::TData::Compare);
}
@@ -113,8 +113,8 @@
iIndex(aIndex),
iData(aData)
{
- __SQLASSERT(aIndex >= 0, ESqlPanicBadArgument);
- __SQLASSERT(aData != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aIndex >= 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aData != NULL, __SQLPANIC(ESqlPanicBadArgument));
}
/////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -145,7 +145,7 @@
{
return err;
}
- __SQLASSERT(iColumnCnt >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iColumnCnt >= 0, __SQLPANIC(ESqlPanicInternalError));
err = iColumnValueBuf.SetCount(iColumnCnt);
if(err != KErrNone)
{
@@ -342,8 +342,8 @@
*/
inline MStreamBuf* CSqlStatementImpl::ColumnSourceL(TInt aColumnIndex)
{
- __SQLASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, ESqlPanicBadColumnIndex);
- __SQLASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, ESqlPanicInvalidRow);
+ __ASSERT_ALWAYS((TUint)aColumnIndex < (TUint)iColumnCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
+ __ASSERT_ALWAYS(iState == CSqlStatementImpl::EAtRow, __SQLPANIC(ESqlPanicInvalidRow));
iColumnValBufIt.MoveTo(aColumnIndex);
return iColumnValBufIt.IsPresent() ? iColumnValBufIt.StreamL() : iSqlStmtSession.ColumnSourceL(aColumnIndex);
}
@@ -369,7 +369,7 @@
*/
inline MStreamBuf* CSqlStatementImpl::ParamSinkL(TSqlSrvFunction aFunction, TInt aParamIndex)
{
- __SQLASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, ESqlPanicBadColumnIndex);
+ __ASSERT_ALWAYS((TUint)aParamIndex < (TUint)iParamCnt, __SQLPANIC(ESqlPanicBadColumnIndex));
return iSqlStmtSession.ParamSinkL(aFunction, aParamIndex);
}
--- a/persistentstorage/sql/SRC/Client/SqlStmtSession.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlStmtSession.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -16,6 +16,83 @@
#include <s32mem.h>
#include "SqlStmtSession.h" //RSqlStatementSession
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlStmtSessionTraces.h"
+#endif
+#include "SqlTraceDef.h"
+
+/**
+ Sends a request to the SQL server to prepare 16-bit aSqlStmt statement.
+
+ Usage of the IPC call arguments:
+ Arg 0: [in/out] data buffer for the column and parameter count.
+ Arg 1: [out] statement length in characters
+ Arg 2: [out] 16-bit statement
+
+ @param aDbSession A reference to RSqlDbSession instance.
+ @param aSqlStmt 16-bit SQL statement.
+ @param aColumnCount Output parameter. Statement column count.
+ @param aParamCount Output parameter. Statement parameter count.
+
+ @return KErrNoMemory, an out of memory condition has occured;
+ KErrArgument, bad argument, for example - the SQL string contains more than one SQL statements.
+ Note that the function may return some database specific errors categorised as
+ ESqlDbError or other system-wide error codes;
+ KErrNone The operation has completed successfully.
+
+ @panic SqlDb 7 In _DEBUG mode if the statement handle is 0.
+*/
+TInt RSqlStatementSession::Prepare(RSqlDbSession& aDbSession, const TDesC& aSqlStmt,
+ TInt& aColumnCount, TInt& aParamCount)
+ {
+ iDbSession = &aDbSession;
+ TSqlIpcData data;
+ TPckg<TSqlIpcData> pckg(data);
+ TUint stmtLen = aSqlStmt.Length();
+ iHandle = iDbSession->SendReceive(ESqlSrvStmtPrepare16, TIpcArgs(&pckg, stmtLen, &aSqlStmt));
+ __ASSERT_DEBUG(iHandle != 0, __SQLPANIC(ESqlPanicInternalError));
+ aColumnCount = static_cast <TInt> (data.iPrm1);
+ aParamCount = static_cast <TInt> (data.iPrm2);
+ SQL_TRACE_SESSION(OstTraceExt2(TRACE_INTERNALS, RSQLSTATEMENTSESSION_PREPARE16, "0x%X;RSqlStatementSession::Prepare-16;iHandle=%d", (TUint)this, iHandle));
+ return iHandle > 0 ? KErrNone : iHandle;
+ }
+
+/**
+Sends a request to the SQL server to prepare 8-bit aSqlStmt statement.
+
+Usage of the IPC call arguments:
+Arg 0: [in/out] data buffer for the column and parameter count.
+Arg 1: [out] statement length in characters
+Arg 2: [out] 8-bit statement
+
+@param aDbSession A reference to RSqlDbSession instance.
+@param aSqlStmt 8-bit SQL statement.
+@param aColumnCount Output parameter. Statement column count.
+@param aParamCount Output parameter. Statement parameter count.
+
+@return KErrNoMemory, an out of memory condition has occured;
+ KErrArgument, bad argument, for example - the SQL string contains more than one SQL statements.
+ Note that the function may return some database specific errors categorised as
+ ESqlDbError or other system-wide error codes;
+ KErrNone The operation has completed successfully.
+
+@panic SqlDb 7 In _DEBUG mode if the statement handle is 0.
+*/
+TInt RSqlStatementSession::Prepare(RSqlDbSession& aDbSession, const TDesC8& aSqlStmt,
+ TInt& aColumnCount, TInt& aParamCount)
+ {
+ iDbSession = &aDbSession;
+ TSqlIpcData data;
+ TPckg<TSqlIpcData> pckg(data);
+ TUint stmtLen = aSqlStmt.Length();
+ iHandle = iDbSession->SendReceive(ESqlSrvStmtPrepare8, TIpcArgs(&pckg, stmtLen, &aSqlStmt));
+ __ASSERT_DEBUG(iHandle != 0, __SQLPANIC(ESqlPanicInternalError));
+ aColumnCount = static_cast <TInt> (data.iPrm1);
+ aParamCount = static_cast <TInt> (data.iPrm2);
+ SQL_TRACE_SESSION(OstTraceExt2(TRACE_INTERNALS, RSQLSTATEMENTSESSION_PREPARE8, "0x%X;RSqlStatementSession::Prepare-8;iHandle=%d", (TUint)this, iHandle));
+ return iHandle > 0 ? KErrNone : iHandle;
+ }
/**
Sends a request to the server to close the statement handle.
@@ -23,6 +100,7 @@
*/
void RSqlStatementSession::Close()
{
+ SQL_TRACE_SESSION(OstTraceExt2(TRACE_INTERNALS, RSQLSTATEMENTSESSION_CLOSE, "0x%X;RSqlStatementSession::Close;iHandle=%d", (TUint)this, iHandle));
if(iDbSession && iHandle > 0)
{
(void)iDbSession->SendReceive(::MakeMsgCode(ESqlSrvStmtClose, ESqlSrvStatementHandle, iHandle));
--- a/persistentstorage/sql/SRC/Client/SqlStmtSession.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlStmtSession.h Tue Aug 31 16:57:14 2010 +0300
@@ -81,8 +81,8 @@
{
public:
inline RSqlStatementSession();
- inline TInt Prepare(RSqlDbSession& aDbSession, const TDesC& aSqlStmt, TInt& aColumnCount, TInt& aParamCount);
- inline TInt Prepare(RSqlDbSession& aDbSession, const TDesC8& aSqlStmt, TInt& aColumnCount, TInt& aParamCount);
+ TInt Prepare(RSqlDbSession& aDbSession, const TDesC& aSqlStmt, TInt& aColumnCount, TInt& aParamCount);
+ TInt Prepare(RSqlDbSession& aDbSession, const TDesC8& aSqlStmt, TInt& aColumnCount, TInt& aParamCount);
void Close();
inline TInt Reset();
--- a/persistentstorage/sql/SRC/Client/SqlStmtSession.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlStmtSession.inl Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -16,77 +16,6 @@
//
/**
-
- Sends a request to the SQL server to prepare 16-bit aSqlStmt statement.
-
- Usage of the IPC call arguments:
- Arg 0: [in/out] data buffer for the column and parameter count.
- Arg 1: [out] statement length in characters
- Arg 2: [out] 16-bit statement
-
- @param aDbSession A reference to RSqlDbSession instance.
- @param aSqlStmt 16-bit SQL statement.
- @param aColumnCount Output parameter. Statement column count.
- @param aParamCount Output parameter. Statement parameter count.
-
- @return KErrNoMemory, an out of memory condition has occured;
- KErrArgument, bad argument, for example - the SQL string contains more than one SQL statements.
- Note that the function may leave with some database specific errors categorised as
- ESqlDbError or other system-wide error codes;
- KErrNone The operation has completed successfully.
-
- @panic SqlDb 7 In _DEBUG mode if the statement handle is 0.
-*/
-inline TInt RSqlStatementSession::Prepare(RSqlDbSession& aDbSession, const TDesC& aSqlStmt,
- TInt& aColumnCount, TInt& aParamCount)
- {
- iDbSession = &aDbSession;
- TSqlIpcData data;
- TPckg<TSqlIpcData> pckg(data);
- TUint stmtLen = aSqlStmt.Length();
- iHandle = iDbSession->SendReceive(ESqlSrvStmtPrepare16, TIpcArgs(&pckg, stmtLen, &aSqlStmt));
- __SQLASSERT(iHandle != 0, ESqlPanicInternalError);
- aColumnCount = static_cast <TInt> (data.iPrm1);
- aParamCount = static_cast <TInt> (data.iPrm2);
- return iHandle > 0 ? KErrNone : iHandle;
- }
-
-/**
-Sends a request to the SQL server to prepare 8-bit aSqlStmt statement.
-
-Usage of the IPC call arguments:
-Arg 0: [in/out] data buffer for the column and parameter count.
-Arg 1: [out] statement length in characters
-Arg 2: [out] 8-bit statement
-
-@param aDbSession A reference to RSqlDbSession instance.
-@param aSqlStmt 8-bit SQL statement.
-@param aColumnCount Output parameter. Statement column count.
-@param aParamCount Output parameter. Statement parameter count.
-
-@return KErrNoMemory, an out of memory condition has occured;
- KErrArgument, bad argument, for example - the SQL string contains more than one SQL statements.
- Note that the function may leave with some database specific errors categorised as
- ESqlDbError or other system-wide error codes;
- KErrNone The operation has completed successfully.
-
-@panic SqlDb 7 In _DEBUG mode if the statement handle is 0.
-*/
-inline TInt RSqlStatementSession::Prepare(RSqlDbSession& aDbSession, const TDesC8& aSqlStmt,
- TInt& aColumnCount, TInt& aParamCount)
- {
- iDbSession = &aDbSession;
- TSqlIpcData data;
- TPckg<TSqlIpcData> pckg(data);
- TUint stmtLen = aSqlStmt.Length();
- iHandle = iDbSession->SendReceive(ESqlSrvStmtPrepare8, TIpcArgs(&pckg, stmtLen, &aSqlStmt));
- __SQLASSERT(iHandle != 0, ESqlPanicInternalError);
- aColumnCount = static_cast <TInt> (data.iPrm1);
- aParamCount = static_cast <TInt> (data.iPrm2);
- return iHandle > 0 ? KErrNone : iHandle;
- }
-
-/**
@panic SqlDb 2 In _DEBUG mode if the statement handle is 0 or the database session is NULL,
i.e. Prepare() has not yet been called on this RSqlStatementSession object.
@@ -94,7 +23,7 @@
*/
inline RSqlDbSession& RSqlStatementSession::DbSession() const
{
- __SQLASSERT(iHandle > 0 && iDbSession != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iHandle > 0 && iDbSession != NULL, __SQLPANIC(ESqlPanicInvalidObj));
return *iDbSession;
}
--- a/persistentstorage/sql/SRC/Client/SqlStream.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Client/SqlStream.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -15,6 +15,11 @@
#include <sqldb.h> //RSqlColumnReadStream, RSqlParamWriteStream
#include "SqlStatementImpl.h" //CSqlStatementImpl
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlStreamTraces.h"
+#endif
+#include "SqlTraceDef.h"
////////////////////////////////////////////////////////////////////////////////////////////////////
///////////////////// RSqlColumnReadStream ////////////////////////////////////
@@ -38,10 +43,9 @@
*/
EXPORT_C TInt RSqlColumnReadStream::ColumnText(RSqlStatement& aStmt, TInt aColumnIndex)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexIntParam, &aStmt, aColumnIndex));
-
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLCOLUMNREADSTREAM_COLUMNTEXT_ENTRY, "Entry;0x%X;RSqlColumnReadStream::ColumnText;aStmt=0x%X;aColumnIndex=%d", (TUint)this, (TUint)&aStmt, aColumnIndex));
TRAPD(err, Attach(aStmt.Impl().ColumnSourceL(aColumnIndex)));
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLCOLUMNREADSTREAM_COLUMNTEXT_EXIT, "Exit;0x%X;RSqlColumnReadStream::ColumnText;err=%d", (TUint)this, err));
return err;
}
@@ -63,10 +67,9 @@
*/
EXPORT_C TInt RSqlColumnReadStream::ColumnBinary(RSqlStatement& aStmt, TInt aColumnIndex)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexIntParam, &aStmt, aColumnIndex));
-
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLCOLUMNREADSTREAM_COLUMNBINARY_ENTRY, "Entry;0x%X;RSqlColumnReadStream::ColumnBinary;aStmt=0x%X;aColumnIndex=%d", (TUint)this, (TUint)&aStmt, aColumnIndex));
TRAPD(err, Attach(aStmt.Impl().ColumnSourceL(aColumnIndex)));
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLCOLUMNREADSTREAM_COLUMNBINARY_EXIT, "Exit;0x%X;RSqlColumnReadStream::ColumnBinary;err=%d", (TUint)this, err));
return err;
}
@@ -87,10 +90,9 @@
*/
EXPORT_C void RSqlColumnReadStream::ColumnTextL(RSqlStatement& aStmt, TInt aColumnIndex)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexIntParam, &aStmt, aColumnIndex));
-
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLCOLUMNREADSTREAM_COLUMNTEXTL_ENTRY, "Entry;0x%X;RSqlColumnReadStream::ColumnTextL;aStmt=0x%X;aColumnIndex=%d", (TUint)this, (TUint)&aStmt, aColumnIndex));
Attach(aStmt.Impl().ColumnSourceL(aColumnIndex));
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLCOLUMNREADSTREAM_COLUMNTEXTL_EXIT, "Exit;0x%X;RSqlColumnReadStream::ColumnTextL", (TUint)this));
}
/**
@@ -110,10 +112,9 @@
*/
EXPORT_C void RSqlColumnReadStream::ColumnBinaryL(RSqlStatement& aStmt, TInt aColumnIndex)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexIntParam, &aStmt, aColumnIndex));
-
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLCOLUMNREADSTREAM_COLUMNBINARYL_ENTRY, "Entry;0x%X;RSqlColumnReadStream::ColumnBinaryL;aStmt=0x%X;aColumnIndex=%d", (TUint)this, (TUint)&aStmt, aColumnIndex));
Attach(aStmt.Impl().ColumnSourceL(aColumnIndex));
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLCOLUMNREADSTREAM_COLUMNBINARYL_EXIT, "Exit;0x%X;RSqlColumnReadStream::ColumnBinaryL", (TUint)this));
}
////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -141,10 +142,9 @@
*/
EXPORT_C TInt RSqlParamWriteStream::BindText(RSqlStatement& aStmt, TInt aParameterIndex)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexIntParam, &aStmt, aParameterIndex));
-
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLPARAMWRITESTREAM_BINDTEXT_ENTRY, "Entry;0x%X;RSqlParamWriteStream::BindText;aStmt=0x%X;aParameterIndex=%d", (TUint)this, (TUint)&aStmt, aParameterIndex));
TRAPD(err, Attach(aStmt.Impl().ParamSinkL(ESqlSrvStmtTxtParamSink16, aParameterIndex)));
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLPARAMWRITESTREAM_BINDTEXT_EXIT, "Exit;0x%X;RSqlParamWriteStream::BindText;err=%d", (TUint)this, err));
return err;
}
@@ -169,10 +169,9 @@
*/
EXPORT_C TInt RSqlParamWriteStream::BindBinary(RSqlStatement& aStmt, TInt aParameterIndex)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexIntParam, &aStmt, aParameterIndex));
-
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLPARAMWRITESTREAM_BINDBINARY_ENTRY, "Entry;0x%X;RSqlParamWriteStream::BindBinary;aStmt=0x%X;aParameterIndex=%d", (TUint)this, (TUint)&aStmt, aParameterIndex));
TRAPD(err, Attach(aStmt.Impl().ParamSinkL(ESqlSrvStmtBinParamSink, aParameterIndex)));
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLPARAMWRITESTREAM_BINDBINARY_EXIT, "Exit;0x%X;RSqlParamWriteStream::BindBinary;err=%d", (TUint)this, err));
return err;
}
@@ -196,10 +195,9 @@
*/
EXPORT_C void RSqlParamWriteStream::BindTextL(RSqlStatement& aStmt, TInt aParameterIndex)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexIntParam, &aStmt, aParameterIndex));
-
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLPARAMWRITESTREAM_BINDTEXTL_ENTRY, "Entry;0x%X;RSqlParamWriteStream::BindTextL;aStmt=0x%X;aParameterIndex=%d", (TUint)this, (TUint)&aStmt, aParameterIndex));
Attach(aStmt.Impl().ParamSinkL(ESqlSrvStmtTxtParamSink16, aParameterIndex));
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLPARAMWRITESTREAM_BINDTEXTL_EXIT, "Exit;0x%X;RSqlParamWriteStream::BindTextL", (TUint)this));
}
/**
@@ -222,9 +220,8 @@
*/
EXPORT_C void RSqlParamWriteStream::BindBinaryL(RSqlStatement& aStmt, TInt aParameterIndex)
{
- SQLUTRACE_PROFILER(this);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KHexIntParam, &aStmt, aParameterIndex));
-
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLPARAMWRITESTREAM_BINDBINARYL_ENTRY, "Entry;0x%X;RSqlParamWriteStream::BindBinaryL;aStmt=0x%X;aParameterIndex=%d", (TUint)this, (TUint)&aStmt, aParameterIndex));
Attach(aStmt.Impl().ParamSinkL(ESqlSrvStmtBinParamSink, aParameterIndex));
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLPARAMWRITESTREAM_BINDBINARYL_EXIT, "Exit;0x%X;RSqlParamWriteStream::BindBinaryL", (TUint)this));
}
--- a/persistentstorage/sql/SRC/Common/SqlAssert.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlAssert.h Tue Aug 31 16:57:14 2010 +0300
@@ -17,17 +17,68 @@
#define __SQLASSERT_H__
#include <e32std.h>
-#include "UTraceSql.h"
+#include "SqlPanic.h" //TSqlPanic
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+//Enable _SQLPROFILER if you want to use the TSqlResourceProfiler functions. Do not forget the same macro declaration in os_symbian.cpp file.
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+//All macros in this header will have a non-void definition only if the OST_TRACE_COMPILER_IN_USE macro
+//is defined.
+//In order to get the traces enabled, the OST_TRACE_COMPILER_IN_USE macro has to be defined in
+//OstTraceDefinitions.h file.
+//After that, the trace output can be redirected by defining _SQL_RDEBUG_PRINT or specific categories
+//of traces can be enabled/disabled.
+
+//Enable _SQL_RDEBUG_PRINT if you want to redirect the tracing output via RDebug::Print()
+//#define _SQL_RDEBUG_PRINT
-//#define _SQLPROFILER //Enable _SQLPROFILER if you want to use the TSqlResourceProfiler functions. Do not forget the same macro declaration in os_symbian.cpp file.
+//Enable _SQL_BORDER_TRACE_ENABLED if you want to get the entry/exit traces compiled in the binary
+//#define _SQL_BORDER_TRACE_ENABLED
+
+//Enable _SQL_INTERNALS_TRACE_ENABLED if you want to get the internal traces compiled in the binary
+//#define _SQL_INTERNALS_TRACE_ENABLED
+
+//Enable _SQL_BUR_TRACE_ENABLED if you want to get the backup&restore traces compiled in the binary
+//#define _SQL_BUR_TRACE_ENABLED
+
+//Enable _SQL_COMPACT_TRACE_ENABLED if you want to get the background compaction traces compiled in the binary
+//#define _SQL_COMPACT_TRACE_ENABLED
+
+//Enable _SQL_SESSION_TRACE_ENABLED if you want to get the client and server sessions traces compiled in the binary
+//#define _SQL_SESSION_TRACE_ENABLED
+
+//Enable _SQL_AUTHORIZER_TRACE_ENABLED if you want to trace the authorizer parameters
+//#define _SQL_AUTHORIZER_TRACE_ENABLED
+
+//Enable _SQL_BLOB_TRACE_ENABLED if you want to trace the server side BLOB calls
+//#define _SQL_BLOB_TRACE_ENABLED
#ifdef _DEBUG
-#define _ASSERTIONS
-//#define _LOGGING
-//#define _NOTIFY //Enable _NOTIFY if you want to get more detailed output in _DEBUG mode
+ //Enable _SQL_PANIC_TRACE_ENABLED if you want to get more detailed output regarding panics
+ //#define _SQL_PANIC_TRACE_ENABLED
+
+ //Enable _SQL_LEAVE_TRACE_ENABLED if you want to get more detailed output regarding leaving locations
+ //#define _SQL_LEAVE_TRACE_ENABLED
#endif
-const TInt KSqlLeavePanic = -359;//The (last-1) error code from the reserved area for the SQL component.
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+//Wrap every string (file name, file path, etc.) you want to trace, in a __SQLPRNSTR()/__SQLPRNSTR8() macro.
+//There is a difference how RDebug::Print() and OstTraceExt<n>() work.
+#if defined _SQL_RDEBUG_PRINT
+ const TInt KSqlMaxPrnStrLen = 512;
+ #define __SQLPRNSTR(des) &des
+ const TDesC* SqlDes8to16Ptr(const TDesC8& aDes, TDes& aOut);
+ #define __SQLPRNSTR8(des, out) SqlDes8to16Ptr(des, out)
+#else
+ #define __SQLPRNSTR(des) des
+ #define __SQLPRNSTR8(des, out) des
+#endif
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//Forward declarations
class RMessage2;
@@ -37,98 +88,104 @@
@internalComponent
*/
-class Util
+class TSqlUtil
{
friend void UtilFileNameTest();
public:
static void GetTimeStr(TDes& aWhere);
- static TInt Assert(const TText* aFile, TInt aLine, TInt aPanicCode);
- static void Leave(const TText* aFile, TInt aLine, TInt aError);
- static TInt LeaveIfError(const TText* aFile, TInt aLine, TInt aError);
- static const void* LeaveIfNull(const TText* aFile, TInt aLine, const void* aPtr);
- static TInt PanicClientL(const TText* aFile, TInt aLine, const RMessage2& aMessage, TInt aPanicCode);
- static void ErrorPrint(const TDesC& aMsg, TInt aErr);
- static void ErrorPrint(const TDesC& aMsg, const TDesC& aStr);
+ static TInt Panic(const TText* aFile, TInt aLine, TInt aPanicCode, TUint aHandle);
+ static void Leave(const TText* aFile, TInt aLine, TInt aError, TUint aHandle);
+ static TInt LeaveIfError(const TText* aFile, TInt aLine, TInt aError, TUint aHandle);
+ static void* LeaveIfNull(const TText* aFile, TInt aLine, void* aPtr, TUint aHandle);
+ static TInt PanicClientL(const TText* aFile, TInt aLine, const RMessage2& aMessage, TInt aPanicCode, TUint aHandle);
private:
- static TPtrC Filename(const TText* aFile);
+ static TPtrC FileName(const TText* aFile);
};
-#define __STRING(str) _S(str)
-
-//This macro should be used when there is a need to panic the client/server if "expr" condition is not satisfied.
-//Works in both debug and release modes.
-#define __SQLASSERT_ALWAYS(expr, panicCode) (void)((expr) || Util::Assert(__STRING(__FILE__), __LINE__, panicCode))
-
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-////////////////////////////// _ASSERTIONS /////////////////////////////////////////////////////////
-#ifdef _ASSERTIONS
-//This macro should be used when there is a need to panic the client/server if "expr" condition is not satisfied.
-//Works in only in debug mode. In release mode evaluates to nothing.
-#define __SQLASSERT(expr, panicCode) (void)((expr) || Util::Assert(__STRING(__FILE__), __LINE__, panicCode))
-
-#else
-
-#define __SQLASSERT(expr, panicCode) void(0)
-
-#endif //_ASSERTIONS
+#define __SQLSTRING(str) _S(str)
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-////////////////////////////// _LOGGING //////////////////////////////////////////////////////////
-#if defined _LOGGING || defined SYMBIAN_TRACE_SQL_ERR
-//This macro should be used to log the message "msg" containing the "err" error code.
-//The message "msg" should contain the format specifier %d.
-//Works only in debug mode. In release mode evaluates to nothing.
-#define __SQLLOG_ERR(msg, err) Util::ErrorPrint(msg, err)
-
-//This macro should be used to log the message "msg" containing the "str" string.
-//The message "msg" should contain the format specifier %S.
-//Works only in debug mode. In release mode evaluates to nothing.
-#define __SQLLOG_STRING(msg, str) Util::ErrorPrint(msg, str)
-
-#else
-
-#define __SQLLOG_ERR(msg, err) do {} while(0)
-#define __SQLLOG_STRING(msg, str) do {} while(0)
-
-#endif //_LOGGING || SYMBIAN_TRACE_SQL_ERR
+//__SQLPANIC/__SQLPANIC2 macro is used for printing out additional information when panic occurs in SQL:
+//source file name, line number, "this" pointer, panic category.
+#define __SQLPANIC(aPanicCode) TSqlUtil::Panic(__SQLSTRING(__FILE__), __LINE__, aPanicCode, (TUint)this)
+#define __SQLPANIC2(aPanicCode) TSqlUtil::Panic(__SQLSTRING(__FILE__), __LINE__, aPanicCode, 0)
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-////////////////////////////// _NOTIFY ///////////////////////////////////////////////////////////
-#if defined _NOTIFY || defined SYMBIAN_TRACE_SQL_ERR
//This macro should be used to leave with "err" error code.
//In debug mode prints the file name and the line number where the leaving occurs and then leaves.
//In release mode only leaves.
-#define __SQLLEAVE(err) Util::Leave(__STRING(__FILE__), __LINE__, err)
+#define __SQLLEAVE(err) TSqlUtil::Leave(__SQLSTRING(__FILE__), __LINE__, err, (TUint)this)
+#define __SQLLEAVE2(err) TSqlUtil::Leave(__SQLSTRING(__FILE__), __LINE__, err, 0)
//This macro should be used to leave with "err" error code, if the error code is negative.
//In debug mode prints the file name and the line number where the leaving occurs and then leaves.
//In release mode only leaves.
-#define __SQLLEAVE_IF_ERROR(err) Util::LeaveIfError(__STRING(__FILE__), __LINE__, err)
+#define __SQLLEAVE_IF_ERROR(err) TSqlUtil::LeaveIfError(__SQLSTRING(__FILE__), __LINE__, err, (TUint)this)
+#define __SQLLEAVE_IF_ERROR2(err) TSqlUtil::LeaveIfError(__SQLSTRING(__FILE__), __LINE__, err, 0)
//This macro should be used to leave with KErrNoMemory if "ptr" argument is NULL.
//In debug mode prints the file name and the line number where the leaving occurs and then leaves.
//In release mode only leaves.
-#define __SQLLEAVE_IF_NULL(ptr) Util::LeaveIfNull(__STRING(__FILE__), __LINE__, ptr)
+#define __SQLLEAVE_IF_NULL(ptr) TSqlUtil::LeaveIfNull(__SQLSTRING(__FILE__), __LINE__, ptr, (TUint)this)
//This macro should be used to panic the client and leave if "expr" condition is not satisfied.
//In debug mode prints the file name and the line number where the leaving occurs and then
//panics the client and leaves.
//In release mode only panics the client and leaves.
-#define __SQLPANIC_CLIENT(expr, msg, panicCode) (void)((expr) || Util::PanicClientL(__STRING(__FILE__), __LINE__, msg, panicCode))
+#define __SQLPANIC_CLIENT(expr, msg, panicCode) (void)((expr) || TSqlUtil::PanicClientL(__SQLSTRING(__FILE__), __LINE__, msg, panicCode, (TUint)this))
+#define __SQLPANIC_CLIENT2(expr, msg, panicCode) (void)((expr) || TSqlUtil::PanicClientL(__SQLSTRING(__FILE__), __LINE__, msg, panicCode, 0))
+
+//===================================================================================
+
+#ifdef _SQL_BORDER_TRACE_ENABLED
+ #define SQL_TRACE_BORDER(trace) trace
+#else
+ #define SQL_TRACE_BORDER(trace) do {} while(0)
+#endif
+#ifdef _SQL_INTERNALS_TRACE_ENABLED
+ #define SQL_TRACE_INTERNALS(trace) trace
#else
+ #define SQL_TRACE_INTERNALS(trace) do {} while(0)
+#endif
+
+#ifdef _SQL_BUR_TRACE_ENABLED
+ #define SQL_TRACE_BUR(trace) trace
+#else
+ #define SQL_TRACE_BUR(trace) do {} while(0)
+#endif
-#define __SQLLEAVE(err) User::Leave(err)
-#define __SQLLEAVE_IF_ERROR(err) User::LeaveIfError(err)
-#define __SQLLEAVE_IF_NULL(ptr) User::LeaveIfNull(ptr)
-#define __SQLPANIC_CLIENT(expr, msg, panicCode) (void)((expr) || ::SqlPanicClientL(msg, panicCode))
+#ifdef _SQL_COMPACT_TRACE_ENABLED
+ #define SQL_TRACE_COMPACT(trace) trace
+#else
+ #define SQL_TRACE_COMPACT(trace) do {} while(0)
+#endif
+
+#ifdef _SQL_SESSION_TRACE_ENABLED
+ #define SQL_TRACE_SESSION(trace) trace
+#else
+ #define SQL_TRACE_SESSION(trace) do {} while(0)
+#endif
-#endif //_NOTIFY || SYMBIAN_TRACE_SQL_ERR
+#ifdef _SQL_AUTHORIZER_TRACE_ENABLED
+ #define SQL_TRACE_AUTHORIZER(trace) trace
+#else
+ #define SQL_TRACE_AUTHORIZER(trace) do {} while(0)
+#endif
+
+#ifdef _SQL_BLOB_TRACE_ENABLED
+ #define SQL_TRACE_BLOB(trace) trace
+#else
+ #define SQL_TRACE_BLOB(trace) do {} while(0)
+#endif
+
+//===================================================================================
#endif//__SQLASSERT_H__
--- a/persistentstorage/sql/SRC/Common/SqlBufFlat.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlBufFlat.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -15,6 +15,7 @@
#include "SqlUtil.h"
#include "SqlBufFlat.h"
+#include "OstTraceDefinitions.h"
/**
Sets the flat buffer pointer to NULL
@@ -45,7 +46,7 @@
*/
TInt RSqlBufFlat::SetCount(TInt aCount)
{
- __SQLASSERT(aCount >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aCount >= 0, __SQLPANIC(ESqlPanicBadArgument));
TInt headerSize = sizeof(RSqlBufFlat::TCell) * aCount;
TInt newSize = headerSize + sizeof(RSqlBufFlat::TBufFlat);
if(DoReAlloc(newSize) != KErrNone)
@@ -110,7 +111,7 @@
iMaxSize = KBufLimit - 1; //to force the reallocation
(void)DoReAlloc(KBufLimit);//User::ReAlloc() does not fail if the new requested size is less than the current block size
}
- __SQLASSERT(oldBuf == iBuf, ESqlPanicInternalError);
+ __ASSERT_DEBUG(oldBuf == iBuf, __SQLPANIC(ESqlPanicInternalError));
SQLFLATBUF_INVARIANT();
}
@@ -156,12 +157,12 @@
TInt RSqlBufFlat::SetField(TInt aIndex, TInt aType, const void* aData, TInt aDataLength)
{
SQLFLATBUF_INVARIANT();
- __SQLASSERT((TUint)aIndex < iBuf->iCount, ESqlPanicBadArgument);
- __SQLASSERT((TUint)aType < RSqlBufFlat::EMaxType, ESqlPanicBadArgument);
- __SQLASSERT((TUint)aDataLength < RSqlBufFlat::EMaxLength, ESqlPanicBadArgument);
+ __ASSERT_DEBUG((TUint)aIndex < iBuf->iCount, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG((TUint)aType < RSqlBufFlat::EMaxType, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG((TUint)aDataLength < RSqlBufFlat::EMaxLength, __SQLPANIC(ESqlPanicBadArgument));
if(aData) //field value "present"
{
- __SQLASSERT(aDataLength >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDataLength >= 0, __SQLPANIC(ESqlPanicBadArgument));
if(aDataLength > 0)
{
if(Reserve(aDataLength) != KErrNone)
@@ -195,9 +196,9 @@
void RSqlBufFlat::DoInit()
{
TBufFlat& buf = *iBuf;
- __SQLASSERT(buf.iCount >= 0, ESqlPanicInternalError);
- __SQLASSERT(buf.iSize <= iMaxSize, ESqlPanicInternalError);
- __SQLASSERT(buf.iHeaderSize == sizeof(RSqlBufFlat::TCell) * buf.iCount, ESqlPanicInternalError);
+ __ASSERT_DEBUG(buf.iCount >= 0, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(buf.iSize <= iMaxSize, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(buf.iHeaderSize == sizeof(RSqlBufFlat::TCell) * buf.iCount, __SQLPANIC(ESqlPanicInternalError));
if(buf.iHeaderSize > 0)
{
Mem::FillZ(Header(), buf.iHeaderSize);
@@ -244,10 +245,10 @@
void RSqlBufFlat::DoSet(TInt aIndex, TInt aType, const void* aData, TInt aDataLength)
{
TBufFlat& buf = *iBuf;
- __SQLASSERT((TUint)aDataLength < RSqlBufFlat::EMaxLength, ESqlPanicBadArgument);
- __SQLASSERT(aDataLength > 0 ? aData != NULL : ETrue, ESqlPanicBadArgument);
- __SQLASSERT(aDataLength <= (iMaxSize - buf.iSize), ESqlPanicInternalError);
- __SQLASSERT(::IsAligned8(buf.iSize), ESqlPanicInternalError);
+ __ASSERT_DEBUG((TUint)aDataLength < RSqlBufFlat::EMaxLength, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aDataLength > 0 ? aData != NULL : ETrue, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aDataLength <= (iMaxSize - buf.iSize), __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(::IsAligned8(buf.iSize), __SQLPANIC(ESqlPanicInternalError));
RSqlBufFlat::TCell& cell = *(Header() + aIndex);
cell.iBits = (TUint)(((TUint)aType << RSqlBufFlat::EWidthLen) | (TUint)aDataLength);
cell.iPos = 1; //not 0, because 0 means "not present"
@@ -291,24 +292,24 @@
*/
void RSqlBufFlat::Invariant() const
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
const TBufFlat& buf = *iBuf;
- __SQLASSERT(buf.iCount >= 0, ESqlPanicInternalError);
- __SQLASSERT(buf.iHeaderSize == sizeof(RSqlBufFlat::TCell) * buf.iCount, ESqlPanicInternalError);
- __SQLASSERT(::IsAligned8(buf.iSize), ESqlPanicInternalError);
- __SQLASSERT(buf.iSize >= buf.iHeaderSize + sizeof(RSqlBufFlat::TBufFlat), ESqlPanicInternalError);
- __SQLASSERT(buf.iSize <= iMaxSize, ESqlPanicInternalError);
- __SQLASSERT(buf.iSize <= User::AllocLen(iBuf), ESqlPanicInternalError);
+ __ASSERT_DEBUG(buf.iCount >= 0, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(buf.iHeaderSize == sizeof(RSqlBufFlat::TCell) * buf.iCount, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(::IsAligned8(buf.iSize), __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(buf.iSize >= buf.iHeaderSize + sizeof(RSqlBufFlat::TBufFlat), __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(buf.iSize <= iMaxSize, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(buf.iSize <= User::AllocLen(iBuf), __SQLPANIC(ESqlPanicInternalError));
for(TInt i=0;i<(TInt)buf.iCount;++i)
{
const RSqlBufFlat::TCell& cell = *((reinterpret_cast <const RSqlBufFlat::TCell*> (iBuf + 1)) + i);
- __SQLASSERT(cell.Type() < RSqlBufFlat::EMaxType, ESqlPanicInternalError);
+ __ASSERT_DEBUG(cell.Type() < RSqlBufFlat::EMaxType, __SQLPANIC(ESqlPanicInternalError));
if(cell.Size() > 0 && cell.iPos >= buf.iHeaderSize) //only for present fields with length > 0
{
- __SQLASSERT((TUint)cell.Size() <= buf.iSize, ESqlPanicInternalError);
- __SQLASSERT(cell.iPos < (buf.iSize - sizeof(RSqlBufFlat::TBufFlat)), ESqlPanicInternalError);
+ __ASSERT_DEBUG((TUint)cell.Size() <= buf.iSize, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(cell.iPos < (buf.iSize - sizeof(RSqlBufFlat::TBufFlat)), __SQLPANIC(ESqlPanicInternalError));
TUint64 val = *(TUint64*)(reinterpret_cast <TUint8*> (iBuf) + cell.iPos + sizeof(RSqlBufFlat::TBufFlat) - sizeof(KSqlBufFlatMagicValue));
- __SQLASSERT(val == KSqlBufFlatMagicValue, ESqlPanicInternalError);
+ __ASSERT_DEBUG(val == KSqlBufFlatMagicValue, __SQLPANIC(ESqlPanicInternalError));
}
}
}
--- a/persistentstorage/sql/SRC/Common/SqlBufFlat.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlBufFlat.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -17,7 +17,7 @@
#define __SQLBUFFLAT_H__
#include <e32base.h>
-#include "SqlPanic.h"
+#include "SqlAssert.h"
//Forward declarations
class TSqlBufRIterator;
--- a/persistentstorage/sql/SRC/Common/SqlBufIterator.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlBufIterator.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -26,7 +26,7 @@
*/
inline TInt TSqlBufRIterator::AsInt() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
return *reinterpret_cast <const TInt32*> (reinterpret_cast <const TUint8*> (iBegin) + iCurrent->iPos);
}
@@ -35,7 +35,7 @@
*/
inline TInt64 TSqlBufRIterator::AsInt64() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
return *reinterpret_cast <const TInt64*> (reinterpret_cast <const TUint8*> (iBegin) + iCurrent->iPos);
}
@@ -44,7 +44,7 @@
*/
inline TReal TSqlBufRIterator::AsReal() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
return *reinterpret_cast <const TReal*> (reinterpret_cast <const TUint8*> (iBegin) + iCurrent->iPos);
}
@@ -56,7 +56,7 @@
*/
TInt TSqlBufRIterator::Int() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
switch(Type())
{
case ESqlInt64:
@@ -94,7 +94,7 @@
*/
TInt64 TSqlBufRIterator::Int64() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
switch(Type())
{
case ESqlInt:
@@ -128,7 +128,7 @@
*/
TReal TSqlBufRIterator::Real() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
switch(Type())
{
case ESqlInt:
@@ -159,7 +159,7 @@
*/
TPtrC8 TSqlBufRIterator::Binary() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
TInt size = Size();
if(Type() != ESqlBinary || size == 0)
{
@@ -176,7 +176,7 @@
*/
TPtrC16 TSqlBufRIterator::Text() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
TInt size = Size();
if(Type() != ESqlText || size == 0)
{
@@ -196,7 +196,7 @@
public:
static HReadOnlyBuf* NewL(const TUint8* aFrom, TInt aLen)
{
- __SQLASSERT(aLen >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aLen >= 0, __SQLPANIC2(ESqlPanicBadArgument));
HReadOnlyBuf* self = new (ELeave) HReadOnlyBuf;
TUint8* p = const_cast <TUint8*> (aFrom);
self->Set(p, p + aLen, MStreamBuf::ERead);
@@ -219,7 +219,7 @@
*/
MStreamBuf* TSqlBufRIterator::StreamL() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
if(!::IsSequenceSqlType(Type()))
{
__SQLLEAVE(KErrArgument);
--- a/persistentstorage/sql/SRC/Common/SqlBufIterator.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlBufIterator.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -18,7 +18,7 @@
#include <sqldb.h> //TSqlColumnType
#include "SqlBufFlat.h" //RSqlBufFlat
-#include "SqlPanic.h"
+#include "SqlAssert.h"
//Forward declarations
class MStreamBuf;
--- a/persistentstorage/sql/SRC/Common/SqlBufIterator.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlBufIterator.inl Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -46,7 +46,7 @@
*/
inline void TSqlBufRIterator::MoveTo(TInt aIndex)
{
- __SQLASSERT((iBegin + (TUint)aIndex) < iEnd, ESqlPanicBadArgument);
+ __ASSERT_DEBUG((iBegin + (TUint)aIndex) < iEnd, __SQLPANIC(ESqlPanicBadArgument));
iCurrent = iBegin + aIndex;
}
@@ -55,7 +55,7 @@
*/
inline TBool TSqlBufRIterator::IsPresent() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
return iCurrent->iPos > 0;
}
@@ -64,7 +64,7 @@
*/
inline TInt TSqlBufRIterator::Type() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
return iCurrent->Type();
}
@@ -73,7 +73,7 @@
*/
inline TInt TSqlBufRIterator::Size() const
{
- __SQLASSERT(iCurrent >= iBegin && iCurrent < iEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCurrent >= iBegin && iCurrent < iEnd, __SQLPANIC(ESqlPanicInternalError));
return Type() == ESqlText ? iCurrent->Size() / sizeof(TUint16) : iCurrent->Size();
}
@@ -101,7 +101,7 @@
*/
inline TBool TSqlBufWIterator::Next()
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
return ++iIndex < iBuf->Count();
}
@@ -112,8 +112,8 @@
*/
inline void TSqlBufWIterator::MoveTo(TInt aIndex)
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
- __SQLASSERT((TUint)aIndex < iBuf->Count(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG((TUint)aIndex < iBuf->Count(), __SQLPANIC(ESqlPanicInternalError));
iIndex = aIndex;
}
@@ -122,8 +122,8 @@
*/
inline void TSqlBufWIterator::SetNull()
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
- __SQLASSERT((TUint)iIndex < iBuf->Count(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG((TUint)iIndex < iBuf->Count(), __SQLPANIC(ESqlPanicInternalError));
(void)iBuf->SetField(iIndex, ESqlNull, NULL, 0);
}
@@ -135,10 +135,10 @@
*/
inline void TSqlBufWIterator::SetAsNotPresent(TInt aType, TInt aLength)
{
- __SQLASSERT(::IsSequenceSqlType(aType), ESqlPanicBadArgument);
- __SQLASSERT(aLength >= 0, ESqlPanicBadArgument);
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
- __SQLASSERT((TUint)iIndex < iBuf->Count(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(::IsSequenceSqlType(aType), __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aLength >= 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG((TUint)iIndex < iBuf->Count(), __SQLPANIC(ESqlPanicInternalError));
iBuf->SetField(iIndex, aType, NULL, aType == ESqlText ? aLength * sizeof(TUint16) : aLength);
}
@@ -152,8 +152,8 @@
*/
inline TInt TSqlBufWIterator::SetInt(TInt aValue)
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
- __SQLASSERT((TUint)iIndex < iBuf->Count(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG((TUint)iIndex < iBuf->Count(), __SQLPANIC(ESqlPanicInternalError));
return iBuf->SetField(iIndex, ESqlInt, &aValue, sizeof(TInt));
}
@@ -167,8 +167,8 @@
*/
inline TInt TSqlBufWIterator::SetInt64(TInt64 aValue)
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
- __SQLASSERT((TUint)iIndex < iBuf->Count(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG((TUint)iIndex < iBuf->Count(), __SQLPANIC(ESqlPanicInternalError));
return iBuf->SetField(iIndex, ESqlInt64, &aValue, sizeof(TInt64));
}
@@ -182,8 +182,8 @@
*/
inline TInt TSqlBufWIterator::SetReal(TReal aValue)
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
- __SQLASSERT((TUint)iIndex < iBuf->Count(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG((TUint)iIndex < iBuf->Count(), __SQLPANIC(ESqlPanicInternalError));
return iBuf->SetField(iIndex, ESqlReal, &aValue, sizeof(TReal));
}
@@ -197,8 +197,8 @@
*/
inline TInt TSqlBufWIterator::SetBinary(const TDesC8& aValue)
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
- __SQLASSERT((TUint)iIndex < iBuf->Count(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG((TUint)iIndex < iBuf->Count(), __SQLPANIC(ESqlPanicInternalError));
return iBuf->SetField(iIndex, ESqlBinary, aValue.Ptr(), aValue.Length());
}
@@ -212,8 +212,8 @@
*/
inline TInt TSqlBufWIterator::SetText(const TDesC16& aValue)
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
- __SQLASSERT((TUint)iIndex < iBuf->Count(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG((TUint)iIndex < iBuf->Count(), __SQLPANIC(ESqlPanicInternalError));
return iBuf->SetField(iIndex, ESqlText, aValue.Ptr(), aValue.Length() * sizeof(TUint16));
}
@@ -228,7 +228,7 @@
*/
inline TInt TSqlBufWIterator::SetZeroBlob(TInt aSize)
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInternalError);
- __SQLASSERT((TUint)iIndex < iBuf->Count(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG((TUint)iIndex < iBuf->Count(), __SQLPANIC(ESqlPanicInternalError));
return iBuf->SetField(iIndex, ESqlZeroBlob, &aSize, sizeof(TInt));
}
--- a/persistentstorage/sql/SRC/Common/SqlMap.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlMap.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2004-2010 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"
@@ -18,7 +18,7 @@
#ifndef __SQLMAP_H__
#define __SQLMAP_H__
-#include "SqlPanic.h"
+#include "SqlAssert.h"
//Forward declaration
template <class KEY, class DATA, class REFCNTR, class DESTRUCTOR> class RSqlMap;
--- a/persistentstorage/sql/SRC/Common/SqlMap.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlMap.inl Tue Aug 31 16:57:14 2010 +0300
@@ -142,7 +142,7 @@
}
return;
}
- __SQLASSERT(EFalse, ESqlPanicInternalError);
+ __ASSERT_DEBUG(EFalse, __SQLPANIC(ESqlPanicInternalError));
}
/**
--- a/persistentstorage/sql/SRC/Common/SqlPanic.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlPanic.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -16,11 +16,6 @@
#ifndef __SQLPANIC_H__
#define __SQLPANIC_H__
-#include "SqlAssert.h"
-
-//Forward declarations
-class RMessage2;
-
/**
TSqlPanic contains panic codes which may used by the SQL component (SqlDb.dll and SqlSrv.exe).
@@ -44,27 +39,4 @@
ESqlPanicBadDescriptor = 13
};
-/**
-This function panics the thread where it is called from with aPanicCode panic code.
-
-@param aPanicCode Panic code
-
-@internalComponent
-*/
-void SqlPanic(TSqlPanic aPanicCode);
-
-/**
-This function is used inside the SQL server to panic the calling client.
-
-@param aMessage The message which processing causes the panic.
-@param aPanicCode Panic code
-
-@leave KSqlLeavePanic
-
-@return KErrNone
-
-@internalComponent
-*/
-TInt SqlPanicClientL(const RMessage2& aMessage, TSqlPanic aPanicCode);
-
#endif //__SQLPANIC_H__
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/SRC/Common/SqlTraceDef.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,103 @@
+// Copyright (c) 2009 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:
+//
+#ifndef SQLTRACEDEF_H
+#define SQLTRACEDEF_H
+
+#include <e32def.h>
+#include "SqlAssert.h"
+
+//////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_BORDER_TRACE_ENABLED
+ #define __SQLTRACE_BORDERVAR(var) var
+ #define __SQLTRACE_BORDEREXPR(expr) expr
+#else
+ #define __SQLTRACE_BORDERVAR(var)
+ #define __SQLTRACE_BORDEREXPR(expr)
+#endif
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_INTERNALS_TRACE_ENABLED
+ #define __SQLTRACE_INTERNALSVAR(var) var
+ #define __SQLTRACE_INTERNALSEXPR(expr) expr
+#else
+ #define __SQLTRACE_INTERNALSVAR(var)
+ #define __SQLTRACE_INTERNALSEXPR(expr)
+#endif
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_BUR_TRACE_ENABLED
+ #define __SQLTRACE_BURVAR(var) var
+ #define __SQLTRACE_BUREXPR(expr) expr
+#else
+ #define __SQLTRACE_BURVAR(var)
+ #define __SQLTRACE_BUREXPR(expr)
+#endif
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_COMPACT_TRACE_ENABLED
+ #define __SQLTRACE_COMPACTVAR(var) var
+ #define __SQLTRACE_COMPACTEXPR(expr) expr
+#else
+ #define __SQLTRACE_COMPACTVAR(var)
+ #define __SQLTRACE_COMPACTEXPR(expr)
+#endif
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_SESSION_TRACE_ENABLED
+ #define __SQLTRACE_SESSIONVAR(var) var
+ #define __SQLTRACE_SESSIONEXPR(expr) expr
+#else
+ #define __SQLTRACE_SESSIONVAR(var)
+ #define __SQLTRACE_SESSIONEXPR(expr)
+#endif
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_AUTHORIZER_TRACE_ENABLED
+ #define __SQLTRACE_AUTHORIZERVAR(var) var
+ #define __SQLTRACE_AUTHORIZEREXPR(expr) expr
+#else
+ #define __SQLTRACE_AUTHORIZERVAR(var)
+ #define __SQLTRACE_AUTHORIZEREXPR(expr)
+#endif
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_BLOB_TRACE_ENABLED
+ #define __SQLTRACE_BLOBVAR(var) var
+ #define __SQLTRACE_BLOBEXPR(expr) expr
+#else
+ #define __SQLTRACE_BLOBVAR(var)
+ #define __SQLTRACE_BLOBEXPR(expr)
+#endif
+
+//////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_RDEBUG_PRINT
+ #undef OstTrace0
+ #undef OstTrace1
+ #undef OstTraceExt1
+ #undef OstTraceExt2
+ #undef OstTraceExt3
+ #undef OstTraceExt4
+ #undef OstTraceExt5
+
+ void SqlPrintf(TInt aGroupName, TInt aTraceName, const char* aFormat, ...);
+
+ #define OstTrace0 SqlPrintf
+ #define OstTrace1 SqlPrintf
+ #define OstTraceExt1 SqlPrintf
+ #define OstTraceExt2 SqlPrintf
+ #define OstTraceExt3 SqlPrintf
+ #define OstTraceExt4 SqlPrintf
+ #define OstTraceExt5 SqlPrintf
+#endif//defined OST_TRACE_COMPILER_IN_USE && defined _SQL_RDEBUG_PRINT
+
+//////////////////////////////////////////////////////////////////////////////////////
+
+#endif//SQLTRACEDEF_H
--- a/persistentstorage/sql/SRC/Common/SqlUtil.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlUtil.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -14,18 +14,101 @@
//
#include <e32svr.h>
+#include "SqlAssert.h"
#include <sqldb.h> //ESqlAtRow, ESqlAtEnd, ESqlErrGeneral
-#include "SqlUtil.h"
-#include "SqlPanic.h" //SqlPanic(), TSqlPanic
#include "sqlite3.h" //SQLITE_OK, SQLITE_ROW, SQLITE_DONE
-#include "UTraceSql.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlUtilTraces.h"
+#endif
+#include "SqlTraceDef.h"
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+const TInt KSqlLeavePanic = -359;//The (last-1) error code from the reserved area for the SQL component.
+
+#define UNUSED_ARG(arg) arg = arg
+#define UNUSED_DES(arg) arg
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_RDEBUG_PRINT
+
+/**
+This class has been added here to avoid the crashes when _SQL_RDEBUG_PRINT macro is defined but the
+data to be printed out is too big and cannot fit into the buffer with size KSqlMaxPrnStrLen.
+@internalComponent
+*/
+class TSqlDes16Overflow : public TDes16Overflow
+ {
+public:
+ virtual void Overflow(TDes16& /*aDes*/)
+ {
+ }
+ };
+
+//Replaces:
+// 1) "%lld" with "%ld"
+// 2) "%s" with "%S"
+//These are the differences in format specification between RDebig::Print and OST functions.
+//The new format spec length should be less or equal than the old format spec length.
+static void ReplaceFmtSpec(TDes& aFormat, const TDesC& aFmtSpec, const TDesC& aNewFmtSpec)
+ {
+ TInt fmtLength = aFormat.Length();
+ const TInt KDiff = aFmtSpec.Length() - aNewFmtSpec.Length();
+ TPtr ptr((TText*)aFormat.Ptr(), fmtLength, fmtLength);
+ TInt pos;
+ while((pos = ptr.Find(aFmtSpec)) >= 0)
+ {
+ ptr.Replace(pos, aFmtSpec.Length(), aNewFmtSpec);
+ fmtLength -= KDiff;
+ ptr.Set(ptr.MidTPtr(pos));
+ }
+ aFormat.SetLength(fmtLength);
+ }
+
+void SqlPrintf(TInt /*aGroupName*/, TInt /*aTraceName*/, const char* aFormat, ...)
+ {
+ VA_LIST list;
+ VA_START(list, aFormat);
+ TBuf<128> format;
+ _LIT(KTraceIdent, "SQL;");
+ format.Copy(TPtrC8((const TUint8*)aFormat));
+ format.Insert(0, KTraceIdent);
+ format.Append(_L("\r\n"));
+ _LIT(KOstI64Fmt, "%lld");
+ _LIT(KDbgPrnI64Fmt, "%ld");
+ ReplaceFmtSpec(format, KOstI64Fmt, KDbgPrnI64Fmt);
+ _LIT(KOstDes8Fmt, "%s");
+ _LIT(KDbgPrnDesFmt, "%S");
+ ReplaceFmtSpec(format, KOstDes8Fmt, KDbgPrnDesFmt);
+ TBuf<KSqlMaxPrnStrLen> buf;
+ TSqlDes16Overflow overflowHandler;
+ buf.AppendFormatList(format, list, &overflowHandler);
+#ifdef _SQL_RDEBUG_PRINT
+ RDebug::RawPrint(buf);
+#endif
+ }
+
+const TDesC* SqlDes8to16Ptr(const TDesC8& aDes, TDes& aOut)
+ {
+ TPtrC8 ptr(aDes.Ptr(), Min(aDes.Length(), aOut.MaxLength()));
+ aOut.Copy(ptr);
+ return &aOut;
+ }
+
+#endif//defined OST_TRACE_COMPILER_IN_USE && defined _SQL_RDEBUG_PRINT
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/**
SQL panic category.
@internalComponent
*/
-_LIT(KPanicCategory,"SqlDb");
+_LIT(KPanicCategory, "SqlDb");
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/**
Panics the caller with aPanicCode panic code.
@@ -35,11 +118,13 @@
@internalComponent
*/
-void SqlPanic(TSqlPanic aPanicCode)
+static void SqlPanic(TSqlPanic aPanicCode)
{
User::Panic(KPanicCategory, aPanicCode);
}
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
/**
Panics the client with aPanicCode panic code.
This function is used by the SQL server to panic the caller (the client).
@@ -53,13 +138,158 @@
@internalComponent
*/
-TInt SqlPanicClientL(const RMessage2& aMessage, TSqlPanic aPanicCode)
+static TInt SqlPanicClientL(const RMessage2& aMessage, TSqlPanic aPanicCode)
{
aMessage.Panic(KPanicCategory, aPanicCode);
- __SQLLEAVE(KSqlLeavePanic);
+ __SQLLEAVE2(KSqlLeavePanic);
return KErrNone;
- }
-
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+The function prints out a "SQL panic" message to the console and panics the thread where it is called from.
+It gives a useful information about the found error together with the source file name and line number where
+it occurred.
+
+Note: this function will output information regarding the panic only if _SQL_PANIC_TRACE_ENABLED macro is defined
+
+@param aFile Source file name
+@param aLine Source line number
+@param aPanicCode Panic code
+@param aHandle Numeric value, uniquely identfying the leaving location (the "this" pointer for example)
+
+@return KErrNone
+
+@internalComponent
+*/
+TInt TSqlUtil::Panic(const TText* aFile, TInt aLine, TInt aPanicCode, TUint aHandle)
+ {
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_PANIC_TRACE_ENABLED
+ TPtrC fname(FileName(aFile));
+ OstTraceExt5(TRACE_FATAL, TSQLUTIL_PANIC, "Panic;0x%X;%S;%d;%S;%d", aHandle, __SQLPRNSTR(fname), aLine, __SQLPRNSTR(KPanicCategory), aPanicCode);
+#else
+ UNUSED_ARG(aFile);
+ UNUSED_ARG(aLine);
+ UNUSED_ARG(aHandle);
+#endif
+ ::SqlPanic(static_cast <TSqlPanic> (aPanicCode));
+ return KErrNone;
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+The function prints out a "SQL leave" message to the console and leaves with aError error code.
+It gives a usefull information about the found error together with the source file name and line number where
+it occured.
+
+Note: this function will output information regarding the panic only if _SQL_LEAVE_TRACE_ENABLED macro is defined
+
+@param aFile Source file name
+@param aLine Source line number
+@param aError Error code
+@param aHandle Numeric value, uniquely identfying the leaving location (the "this" pointer for example)
+
+@internalComponent
+*/
+void TSqlUtil::Leave(const TText* aFile, TInt aLine, TInt aError, TUint aHandle)
+ {
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_LEAVE_TRACE_ENABLED
+ TPtrC fname(FileName(aFile));
+ OstTraceExt4(TRACE_ERROR, TSQLUTIL_LEAVE, "Leave;0x%X;%S;%d;Error=%d", aHandle, __SQLPRNSTR(fname), aLine, aError);
+#else
+ UNUSED_ARG(aFile);
+ UNUSED_ARG(aLine);
+ UNUSED_ARG(aHandle);
+#endif
+ User::Leave(aError);
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+The function prints out a "SQL leave" message to the console and leaves with aError error code, if it is
+negative.
+It gives a usefull information about the found error together with the source file name and line number where
+it occured.
+
+Note: this function will output information regarding the panic only if _SQL_LEAVE_TRACE_ENABLED macro is defined
+
+@param aFile Source file name
+@param aLine Source line number
+@param aError Error code
+
+@internalComponent
+*/
+TInt TSqlUtil::LeaveIfError(const TText* aFile, TInt aLine, TInt aError, TUint aHandle)
+ {
+ if(aError < 0)
+ {
+ TSqlUtil::Leave(aFile, aLine, aError, aHandle);
+ }
+ return aError;
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+The function prints out a "SQL leave" message to the console and leaves with KErrNoMemory if
+aPtr parameter is NULL.
+
+Note: this function will output information regarding the panic only if _SQL_LEAVE_TRACE_ENABLED macro is defined
+
+@param aFile Source file name
+@param aLine Source line number
+@param aPtr The pointer to be tested against NULL value.
+
+@internalComponent
+*/
+void* TSqlUtil::LeaveIfNull(const TText* aFile, TInt aLine, void* aPtr, TUint aHandle)
+ {
+ if(!aPtr)
+ {
+ TSqlUtil::Leave(aFile, aLine, KErrNoMemory, aHandle);
+ }
+ return aPtr;
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+The function is used by the SQL server.
+It prints out a "SQL panic" message to the console and panic the client.
+It gives a usefull information about the found error together with the source file name and line number where
+it occured.
+
+Note: this function will output information regarding the panic only if _SQL_PANIC_TRACE_ENABLED macro is defined
+
+@param aFile Source file name
+@param aLine Source line number
+@param aMessage The client message, which processing caused the panic.
+@param aPanicCode Error code
+
+@leave KSqlLeavePanic
+
+@return KErrNone;
+
+@internalComponent
+*/
+TInt TSqlUtil::PanicClientL(const TText* aFile, TInt aLine, const RMessage2& aMessage, TInt aPanicCode, TUint aHandle)
+ {
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQL_PANIC_TRACE_ENABLED
+ TPtrC fname(FileName(aFile));
+ OstTraceExt5(TRACE_FATAL, TSQLUTIL_PANICCLIENTL, "Panic;%X;%S;%d;%S;%d", aHandle, __SQLPRNSTR(fname), aLine, __SQLPRNSTR(KPanicCategory), aPanicCode);
+#else
+ UNUSED_ARG(aFile);
+ UNUSED_ARG(aLine);
+ UNUSED_ARG(aHandle);
+#endif
+ return ::SqlPanicClientL(aMessage, static_cast <TSqlPanic> (aPanicCode));
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
/**
Processes SQL database error code and OS error code and returns unified error code.
If aSqlError == SQLITE_ROW then the function returns KSqlAtRow.
@@ -80,7 +310,8 @@
*/
TInt Sql2OsErrCode(TInt aSqlError, TInt aOsError)
{
- __SQLASSERT(aSqlError >= SQLITE_OK && aOsError <= KErrNone, ESqlPanicBadArgument);
+
+ __ASSERT_DEBUG(aSqlError >= SQLITE_OK && aOsError <= KErrNone, __SQLPANIC2(ESqlPanicBadArgument));
TInt err = KErrNone;
if(aOsError == KErrDiskFull)
{//Whatever is the aSqlError value, even SQLITE_OK, never ignore KErrDiskFull errors
@@ -114,243 +345,19 @@
return err;
}
-////////////////////////////////////////////////////////////////////////////////////////////////////////
-//////////////////////////////// class Util ////////////////////////////////////////////////////////
-////////////////////////////////////////////////////////////////////////////////////////////////////////
-#if defined _LOGGING || defined SYMBIAN_TRACE_SQL_ERR
-
-/**
-This function is used to log the message "msg" containing the "err" error code.
-The message "msg" should contain the format specifier %d.
-
-The function is used when _LOGGING or SYMBIAN_TRACE_SQL_ERR is defined.
-
-@param aMsg Error message
-@param aErr Error code
-
-@internalComponent
-*/
-void Util::ErrorPrint(const TDesC& aMsg, TInt aErr)
- {
- SYMBIAN_TRACE_SQL_ERR_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EError), aMsg, aErr));
- RDebug::Print(aMsg, aErr);
- }
-
-/**
-This macro should be used to log the message "msg" containing the "str" string.
-The message "msg" should contain the format specifier %S.
-
-The function is used when _LOGGING or SYMBIAN_TRACE_SQL_ERR is defined.
-
-@param aMsg Error message
-@param aErr Error code
-
-@internalComponent
-*/
-void Util::ErrorPrint(const TDesC& aMsg, const TDesC& aStr)
- {
- SYMBIAN_TRACE_SQL_ERR_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EError), aMsg, &aStr));
- RDebug::Print(aMsg, &aStr);
- }
-
-#endif //_LOGGING || SYMBIAN_TRACE_SQL_ERR
-
-#if defined _ASSERTIONS
-
-/**
-The function prints out a "SQL panic" message to the console and panics the thread where it is called from.
-It gives a useful information about the found error together with the source file name and line number where
-it occurred.
-
-The function is used when _ASSERTIONS is defined.
-
-@param aFile Source file name
-@param aLine Source line number
-@param aPanicCode Panic code
-
-@return KErrNone
-
-@internalComponent
-*/
-TInt Util::Assert(const TText* aFile, TInt aLine, TInt aPanicCode)
- {
- TBuf<16> tbuf;
- Util::GetTimeStr(tbuf);
- TBuf<80> buf;
- _LIT(KFormat,"**%S* SQL panic %d, at %S(%d)");
- TPtrC fname(Filename(aFile));
- SYMBIAN_TRACE_SQL_ERR_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EError), KSqlPanic, aPanicCode, &fname, aLine));
- buf.Format(KFormat, &tbuf, aPanicCode, &fname, aLine);
- RDebug::Print(buf);
- ::SqlPanic(static_cast <TSqlPanic> (aPanicCode));
- return KErrNone;
- }
-
-#else //_ASSERTIONS
-
-/**
-The function panics the thread where it is called from.
-
-The function is used when _ASSERTIONS is not defined.
-
-@param Not used
-@param Not used
-@param aPanicCode Panic code
-
-@return KErrNone
-
-@internalComponent
-*/
-TInt Util::Assert(const TText*, TInt, TInt aPanicCode)
- {
- ::SqlPanic(static_cast <TSqlPanic> (aPanicCode));
- return KErrNone;
- }
-
-#endif //_ASSERTIONS
-
-#if defined _NOTIFY || defined SYMBIAN_TRACE_SQL_ERR
-
-/**
-The function prints out a "SQL leave" message to the console and leaves with aError error code.
-It gives a usefull information about the found error together with the source file name and line number where
-it occured.
-
-The function is used when _NOTIFY is defined.
-
-@param aFile Source file name
-@param aLine Source line number
-@param aError Error code
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-@internalComponent
-*/
-void Util::Leave(const TText* aFile, TInt aLine, TInt aError)
- {
- SYMBIAN_TRACE_SQL_ERR_ONLY(TPtrC filename(Filename(aFile)));
- SYMBIAN_TRACE_SQL_ERR_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EError), KSqlLeave, aError, &filename, aLine));
-
-#ifdef _NOTIFY
- TBuf<16> tbuf;
- Util::GetTimeStr(tbuf);
- TPtrC f(Filename(aFile));
- TBuf<80> buf;
- _LIT(KFormat,"**%S* SQL leave, error=%d at %S(%d)\r\n");
- buf.Format(KFormat, &tbuf, aError, &f, aLine);
- RDebug::Print(buf);
-#endif //_NOTIFY
- User::Leave(aError);
- }
-
-/**
-The function prints out a "SQL leave" message to the console and leaves with aError error code, if it is
-negative.
-It gives a usefull information about the found error together with the source file name and line number where
-it occured.
-
-The function is used when _NOTIFY is defined.
-
-@param aFile Source file name
-@param aLine Source line number
-@param aError Error code
-
-@internalComponent
-*/
-TInt Util::LeaveIfError(const TText* aFile, TInt aLine, TInt aError)
- {
- if(aError<0)
- Util::Leave(aFile,aLine,aError);
- return aError;
- }
-
-/**
-The function prints out a "SQL leave" message to the console and leaves with KErrNoMemory if
-aPtr parameter is NULL.
-
-The function is used when _NOTIFY is defined.
-
-@param aFile Source file name
-@param aLine Source line number
-@param aPtr The pointer to be tested against NULL value.
+#if defined OST_TRACE_COMPILER_IN_USE && (defined _SQL_PANIC_TRACE_ENABLED || defined _SQL_LEAVE_TRACE_ENABLED)
-@internalComponent
-*/
-const void* Util::LeaveIfNull(const TText* aFile, TInt aLine, const void* aPtr)
- {
- if(!aPtr)
- {
- Util::Leave(aFile, aLine, KErrNoMemory);
- }
- return aPtr;
- }
-
-/**
-The function is used by the SQL server.
-It prints out a "SQL panic" message to the console and panic the client.
-It gives a usefull information about the found error together with the source file name and line number where
-it occured.
-
-The function is used when _NOTIFY is defined.
-
-@param aFile Source file name
-@param aLine Source line number
-@param aMessage The client message, which processing caused the panic.
-@param aPanicCode Error code
-
-@leave KSqlLeavePanic
-
-@return KErrNone;
-
-@internalComponent
-*/
-TInt Util::PanicClientL(const TText* aFile, TInt aLine, const RMessage2& aMessage, TInt aPanicCode)
- {
- SYMBIAN_TRACE_SQL_ERR_ONLY(TPtrC filename(Filename(aFile)));
- SYMBIAN_TRACE_SQL_ERR_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EError), KSqlPanicClient, aPanicCode, &filename, aLine));
-
-#ifdef _NOTIFY
- TBuf<16> tbuf;
- Util::GetTimeStr(tbuf);
- TPtrC fname(Filename(aFile));
- TBuf<80> buf;
- _LIT(KFormat,"**%S* SQL panic=%d at %S(%d)\r\n");
- buf.Format(KFormat, &tbuf, aPanicCode, &fname, aLine);
- RDebug::Print(buf);
-#endif
- return ::SqlPanicClientL(aMessage, static_cast <TSqlPanic> (aPanicCode));
- }
-
-#endif//defined _NOTIFY || SYMBIAN_TRACE_SQL_ERR
-
-#if defined _ASSERTIONS || defined _NOTIFY ||defined SYMBIAN_TRACE_SQL_ERR
-
-/**
-Formats the current time into aWhere descriptor.
-
-@param aWhere Output parameter. The current time will be formatted there. The buffer length should be at least 16 characters.
-
-The function is used when _ASSERT or _NOTIFY or SYMBIAN_TRACE_SQL_ERR is defined.
-
-@internalComponent
-*/
-void Util::GetTimeStr(TDes& aWhere)
- {
- TTime time;
- time.HomeTime();
- TDateTime dt = time.DateTime();
- aWhere.Format(_L("%02d:%02d:%02d.%06d"), dt.Hour(), dt.Minute(), dt.Second(), dt.MicroSecond());
- };
-
/**
The function creates and returns TPtrC object which points to aFile parameter.
@param aFile File name
@return TPtrC object pointing to aFile parameter.
-The function is used when _ASSERT or _NOTIFY or SYMBIAN_TRACE_SQL_ERR is defined.
-
@internalComponent
*/
-TPtrC Util::Filename(const TText* aFile)
+TPtrC TSqlUtil::FileName(const TText* aFile)
{
TPtrC p(aFile);
TInt ix = p.LocateReverse('\\');
@@ -361,4 +368,4 @@
return p;
}
-#endif//defined _ASSERTIONS || defined _NOTIFY || SYMBIAN_TRACE_SQL_ERR
+#endif //defined OST_TRACE_COMPILER_IN_USE && (defined _SQL_PANIC_TRACE_ENABLED || defined _SQL_LEAVE_TRACE_ENABLED)
--- a/persistentstorage/sql/SRC/Common/SqlUtil.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Common/SqlUtil.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2010 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2009 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"
--- a/persistentstorage/sql/SRC/Common/Trace/UTraceSql.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,217 +0,0 @@
-// Copyright (c) 2009 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:
-//
-
-#include <e32std.h>
-
-//The file is used only to compile and include in the executable server image only a single
-//copy of the trace strings.
-#define __SQLTRACE_STRINGS__
-#include "UTraceSql.h"
-
-#ifdef SYMBIAN_TRACE_SQL_EVENTS
-
-/**
-Get the corresponding string to the IPC function from the TSqlSrvFunction enum
-
-@param aFunction Function code
-
-@return A pointer to the string literal associated with the TSqlSrvFunction enum identifiers
-
-@internalComponent
- */
-const TPtrC8 GetIPCFuncStr(TInt aFunction)
- {
- TInt function = aFunction & 0xFF;
-
- //Array of Sql Server's IPC functions.This should map to TSqlSrvFunction
- const TText8* const KSrvFunctionStr[] =
- {
- //Test functions
- _S8("ESqlSrvTestBase"), //0x00
- _S8("ESqlSrvResourceMark"), //0x01
- _S8("ESqlSrvResourceCheck"), //0x02
- _S8("ESqlSrvResourceCount"), //0x03
- _S8("ESqlSrvSetDbHeapFailure"), //0x04
- _S8("ESqlSrvSetHeapFailure"), //0x05
-
- //Profiling functions
- _S8("ESqlSrvProfilerStart"), //0x06
- _S8("ESqlSrvProfilerStop"), //0x07
- _S8("ESqlSrvProfilerReset"), //0x08
- _S8("ESqlSrvProfilerSetRange"), //0x09
- _S8("ESqlSrvProfilerQuery"), //0x0A
-
- //Not Used
- _S8(""), //0x0B
- _S8(""), //0x0C
- _S8(""), //0x0D
- _S8(""), //0x0E
- _S8(""), //0x0F
-
- //Database functions
- _S8("ESqlSrvDbBase"), //0x10
- _S8("ESqlSrvDbCreate"), //0x11
- _S8("ESqlSrvDbCreateSecure"), //0x12
- _S8("ESqlSrvDbOpen"), //0x13
- _S8("ESqlSrvDbOpenFromHandle"), //0x14
- _S8("ESqlSrvDbClose"), //0x15
- _S8("ESqlSrvDbCopy"), //0x16
- _S8("ESqlSrvDbDelete"), //0x17
-
- //All operations with opcode > ESqlSrvDbDelete require valid database object (on the server side)
- _S8("ESqlSrvLastErrorMsg"), //0x18
- _S8("ESqlSrvDbExec8"), //0x19
- _S8("ESqlSrvDbExec16"), //0x1A
- _S8("ESqlSrvDbRowIdExec16"), //0x1B
- _S8("ESqlSrvDbSetIsolationLevel"), //0x1C
- _S8("ESqlSrvDbGetSecurityPolicy"), //0x1D
- _S8("ESqlSrvDbAttach"), //0x1E
- _S8("ESqlSrvDbAttachFromHandle"), //0x1F
- _S8("ESqlSrvDbDetach"), //0x20
- _S8("ESqlSrvDbScalarFullSelect8"), //0x21
- _S8("ESqlSrvDbScalarFullSelect16"), //0x22
- _S8("ESqlSrvDbInTransaction"), //0x23
- _S8("ESqlSrvDbSize"), //0x24
- _S8("ESqlSrvDbSize2"), //0x25
- _S8("ESqlSrvDbBlobSource"), //0x26
- _S8("ESqlSrvDbLastInsertedRowId"), //0x27
- _S8("ESqlSrvDbCompact"), //0x28
-
- //Database - reserved drive space management
- _S8("ESqlSrvDbReserveDriveSpace"), //0x29
- _S8("ESqlSrvDbFreeReservedSpace"), //0x2A
- _S8("ESqlSrvDbGetReserveAccess"), //0x2B
- _S8("ESqlSrvDbReleaseReserveAccess"), //0x2C
-
- //Not Used
- _S8(""), //0x2D
- _S8(""), //0x2E
- _S8(""), //0x2F
- _S8(""), //0x30
- _S8(""), //0x31
- _S8(""), //0x32
- _S8(""), //0x33
- _S8(""), //0x34
- _S8(""), //0x35
- _S8(""), //0x36
- _S8(""), //0x37
- _S8(""), //0x38
- _S8(""), //0x39
- _S8(""), //0x3A
- _S8(""), //0x3B
- _S8(""), //0x3C
- _S8(""), //0x3D
- _S8(""), //0x3E
- _S8(""), //0x3F
- _S8(""), //0x40
- _S8(""), //0x41
- _S8(""), //0x42
- _S8(""), //0x43
- _S8(""), //0x44
- _S8(""), //0x45
- _S8(""), //0x46
- _S8(""), //0x47
- _S8(""), //0x48
- _S8(""), //0x49
- _S8(""), //0x4A
- _S8(""), //0x4B
- _S8(""), //0x4C
- _S8(""), //0x4D
- _S8(""), //0x4E
- _S8(""), //0x4F
-
- //Statement functions
- _S8("ESqlSrvStmtBase"), //0x50
- _S8("ESqlSrvStmtPrepare8"), //0x51
- _S8("ESqlSrvStmtPrepare16"), //0x52
- _S8("ESqlSrvStmtClose"), //0x53
- _S8("ESqlSrvStmtReset"), //0x54
- _S8("ESqlSrvStmtExec"), //0x55
- _S8("ESqlSrvStmtAsyncExec"), //0x56
- _S8("ESqlSrvStmtBindExec"), //0x57
- _S8("ESqlSrvStmtBindExecRowId"), //0x58
- _S8("ESqlSrvStmtAsyncBindExec"), //0x59
- _S8("ESqlSrvStmtNext"), //0x5A
- _S8("ESqlSrvStmtBindNext"), //0x5B
- _S8("ESqlSrvStmtColumnNames"), //0x5C
- _S8("ESqlSrvStmtParamNames"), //0x5D
- _S8("ESqlSrvStmtColumnSource"), //0x5E
- _S8("ESqlSrvStmtBinParamSink"), //0x5F
- _S8("ESqlSrvStmtTxtParamSink8"), //0x60
- _S8("ESqlSrvStmtTxtParamSink16"), //0x61
- _S8("ESqlSrvStmtBufFlat"), //0x62
- _S8("ESqlSrvStmtColumnValue"), //0x63
- _S8("ESqlSrvStmtDeclColumnTypes"), //0x64
- _S8("ESqlSrvStmtEvaluateAll"), //0x65
- _S8("ESqlSrvStmtGoto"), //0x66
-
- //Not Used
- _S8(""), //0x67
- _S8(""), //0x68
- _S8(""), //0x69
- _S8(""), //0x6A
- _S8(""), //0x6B
- _S8(""), //0x6C
- _S8(""), //0x6D
- _S8(""), //0x6E
- _S8(""), //0x6F
-
- //Stream functions
- _S8("ESqlSrvStreamBase"), //0x70
- _S8("ESqlSrvStreamRead"), //0x71
- _S8("ESqlSrvStreamWrite"), //0x72
- _S8("ESqlSrvStreamSize"), //0x73
- _S8("ESqlSrvStreamSynch"), //0x74
- _S8("ESqlSrvStreamClose") //0x75
- };
-
- const TInt KMaxSrvFunctions = sizeof(KSrvFunctionStr) / sizeof(KSrvFunctionStr[0]);
-
- if (function <= KMaxSrvFunctions)
- return KSrvFunctionStr[function];
- else
- return _S8("Unknown");
- }
-#endif //SYMBIAN_TRACE_SQL_EVENTS
-
-#ifdef SYMBIAN_TRACE_SQL_FUNC
-
-/**
-Create the TSqlUTraceProfiler object which inserts a UTF trace, used to signal a function entry
-
-@param aFunctionStr A "const char" pointer describing the function to be profiled.
- Currently this is the type signature of the function returned by
- the __PRETTY_FUNCTION__ macro.
-@param aObj A object pointer used to provide context for the function.
-
-@internalComponent
-*/
-TSqlUTraceProfiler::TSqlUTraceProfiler(const TAny* aObj, const char* aFunctionStr):
-iObj(aObj), iFunctionStr(reinterpret_cast<const TUint8*>(aFunctionStr))
- {
- UTF::Printf(UTF::TTraceContext(UTF::ESystemCharacteristicMetrics), KProfilerBegin, &iFunctionStr, iObj);
- }
-
-/**
-Destroys TSqlUTraceProfiler object which inserts a UTF trace, used to signal a function exit
-
-@internalComponent
-*/
-TSqlUTraceProfiler::~TSqlUTraceProfiler()
- {
- UTF::Printf(UTF::TTraceContext(UTF::ESystemCharacteristicMetrics), KProfilerEnd, &iFunctionStr, iObj);
- }
-
-#endif //SYMBIAN_TRACE_SQL_FUNC
--- a/persistentstorage/sql/SRC/Common/Trace/UTraceSql.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,186 +0,0 @@
-// Copyright (c) 2009 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:
-//
-
-#ifndef UTRACESQL_H
-#define UTRACESQL_H
-
-#if defined SQLSRV_ENABLE_TRACE
-//If this header is included from Sqlsrv.exe then use the UID3 from that process
-#define EXECUTABLE_DEFAULT_MODULEUID 0x10281E17
-#define SQL_ENABLE_TRACE
-
-#elif defined SQLDB_ENABLE_TRACE
-//If this header is included from Sqldb.dll then use the UID3 from that process
-#define EXECUTABLE_DEFAULT_MODULEUID 0x10281E18
-#define SQL_ENABLE_TRACE
-
-#elif defined SQLITELIB_ENABLE_TRACE
-//If this header is included from Sqlite.lib then use the UID3 from that process
-#define EXECUTABLE_DEFAULT_MODULEUID 0x10281E19
-#define SQL_ENABLE_TRACE
-
-#endif //SQLSRV_ENABLE_TRACE, SQLDB_ENABLE_TRACE, SQLITELIB_ENABLE_TRACE
-
-#ifdef SQL_ENABLE_TRACE
-
-//The UTF header can only be included after EXECUTABLE_DEFAULT_MODULEUID is defined
-#include <e32utf.h>
-
-/**
-Enable this macro to compile in the SQL trace points that trace function leaves and panics.
-These traces can be used to assist debugging in client applications and the Symbian SQL.
-
-@SymTraceMacro
-*/
-#undef SYMBIAN_TRACE_SQL_ERR
-
-/**
-Enable this macro to compile in the SQL trace points that trace exported functions and certain
-porting layer functions entry and exit. From the timestamps of these trace, the total time spent
-in these functions can be worked out.
-These traces are particularly useful for performance investigations.
-
-@SymTraceMacro
-*/
-#undef SYMBIAN_TRACE_SQL_FUNC
-
-/**
-Enable this macro to compile in the SQL trace points that trace the following internal events.
- - IPC calls send to and serviced by the SQL Server
- - SQL Server's startup and close
- - No. of full table scans and sort operation performed by a RSqlStatement object
- - Extra internal information for certain exported and porting layer functions
-These traces can be used to assist performance and debug investigations
-
-@SymTraceMacro
-*/
-#undef SYMBIAN_TRACE_SQL_EVENTS
-
-#endif //SQL_ENABLE_TRACE
-
-//////////////////////////////////////////////////////////////////////////////////////////////////////////////
-////////// UTrace Related Strings //////////////////////////
-//////////////////////////////////////////////////////////////////////////////////////////////////////////////
-#ifdef SQL_ENABLE_TRACE
-
-#ifdef __SQLTRACE_STRINGS__
- #define CONST_LIT8(var, val) extern const TLitC8<sizeof(val)> var = {sizeof(val) - 1, val}
- #define CONST_LIT16(var, val) extern const TLitC16<sizeof(L##val)/2> var = {sizeof(L##val)/2 - 1, L##val}
-#else
- #define CONST_LIT8(var, val) extern const TLitC8<sizeof(val)> var
- #define CONST_LIT16(var, val) extern const TLitC16<sizeof(L##val)/2> var
-#endif
-
-//File I/O trace format strings
-CONST_LIT8(KFileRead, "Sqlite: Size - %d bytes, File Offset Position - %d,");
-CONST_LIT8(KFileWrite, "Sqlite: Size - %d bytes, File Offset Position - %d,");
-CONST_LIT8(KFileTruncate, "Sqlite: Size - %d bytes");
-CONST_LIT8(KFileFileCtr, "Sqlite: Opeartion Called - %d");
-CONST_LIT16(KFileOpen, "Sqlite: Sqlite3_file - 0x%x, Filename - \"%S\"");
-CONST_LIT16(KFileName, "Sqlite: Filename - \"%S\"");
-
-//Input pararmeter format strings
-CONST_LIT8(KStrParam, "SqlDb: Parameter %d - \"%S\"");
-CONST_LIT8(KHexStrParam, "SqlDb: Parameter 1 - 0x%x, Parameter 2 - \"%S\"");
-CONST_LIT8(KHexIntParam, "SqlDb: Parameter 1 - 0x%x, Parameter 2 - %d");
-CONST_LIT8(KIntParam, "SqlDb: Parameter 1 - %d");
-CONST_LIT8(KIntSizeParam, "SqlDb: Parameter 1 - %d, Parameter %d - %d bytes");
-
-CONST_LIT16(KStrParam16, "SqlDb: Parameter %d - \"%S\"");
-CONST_LIT16(KStrStrParam16, "SqlDb: Parameter 1 - \"%S\", Parameter 2 - \"%S\"");
-CONST_LIT16(KHexStrParam16, "SqlDb: Parameter 1 - 0x%x, Parameter 2 - \"%S\"");
-CONST_LIT16(KSizeStrParam16, "SqlDb: Parameter %d - %d bytes, Parameter %d - \"%S\"");
-CONST_LIT16(KRSqlBlobParam16, "SqlDb: Parameter 1 - 0x%x, Parameter 2 - \"%S\", Parameter 3 - \"%S\", Parameter 4 - %d, Parameter 5 - \"%S\"");
-
-//IPC request trace format strings
-CONST_LIT8(KDbMsgStr, "SqlDb: Request - %S Sent to SQL Server");
-CONST_LIT8(KSrvMsgStr, "SqlSrv: Request - %S Recieved by SQL Server");
-CONST_LIT8(KSrvStmtCreated, "SqlSrv: sqlite3_stmt Object 0x%x Created");
-CONST_LIT8(KSrvStmtStatus, "SqlSrv: sqlite3_stmt Object 0x%x Destroyed, %d Full Table Scan Performed, %d Sort Performed");
-
-//Server startup and close trace format strings
-CONST_LIT8(KSqlSrvStart, "SqlSrv: SQL Server Startup");
-CONST_LIT8(KSqlSrvClose, "SqlSrv: SQL Server Close");
-
-//TSqlUTraceProfiler trace format strings, used to display function entry and exit
-CONST_LIT8(KProfilerBegin, "Function Entry:\"%S\", Address - 0x%x");
-CONST_LIT8(KProfilerEnd, "Function Exit:\"%S\", Address - 0x%x");
-
-//Panic and leave trace format strings
-CONST_LIT16(KSqlPanic, "Sql: Panic %d at %S(%d)");
-CONST_LIT16(KSqlPanicClient, "Sql: Panic client %d at %S(%d)");
-CONST_LIT16(KSqlLeave, "Sql: Leave error %d at %S(%d)");
-CONST_LIT8(KSqlSrvPanicClient, "SqlSrv ServiceError: Panic Client %d");
-CONST_LIT8(KSqlSrvError, "SqlSrv ServiceError: Error %d");
-
-#endif //SQL_ENABLE_TRACE
-
-////////////////////////////////////////////////////////////////////////////////////////////////////////////
-////////// UTrace Related Macro Functions and Class Declarations ////////////////////
-////////////////////////////////////////////////////////////////////////////////////////////////////////////
-#ifdef SYMBIAN_TRACE_SQL_ERR
-
-//This macro should be used to trace errors occurring within Symbian SQL.
-//To use the macro, insert the full UTF statement as the macro parameter
-//Works only when SYMBIAN_TRACE_SQL_ERR is enabled. Otherwise it evaluates to zero
-#define SYMBIAN_TRACE_SQL_ERR_ONLY(c) c
-
-#else
-
-#define SYMBIAN_TRACE_SQL_ERR_ONLY(c) do {} while(0)
-#endif //SYMBIAN_TRACE_SQL_ERR
-
-
-#ifdef SYMBIAN_TRACE_SQL_FUNC
-
-/**
-This class is used to help trace function entry and exits within Symbian SQL
-Exist only when SYMBIAN_TRACE_SQL_FUNC is enabled.
-
-@internalComponent
-*/
-class TSqlUTraceProfiler
- {
- public:
- TSqlUTraceProfiler(const TAny* aObj, const char* aFunctionStr);
- ~TSqlUTraceProfiler();
- private:
- const TAny* iObj;
- TPtrC8 iFunctionStr;
- };
-
-//This macro should be used to trace function entry and exits within Symbian SQL
-//Works only when SYMBIAN_TRACE_SQL_FUNC is enabled. Otherwise it evaluates to zero
-#define SQLUTRACE_PROFILER(x) TSqlUTraceProfiler _profiler(x, __PRETTY_FUNCTION__)
-
-#else
-
-#define SQLUTRACE_PROFILER(x) do {} while(0)
-#endif //SYMBIAN_TRACE_SQL_FUNC
-
-#ifdef SYMBIAN_TRACE_SQL_EVENTS
-
-//This macro should be used to trace events occurring within Symbian SQL.
-//To use the macro, insert the full UTF statement as the macro parameter
-//Works only when SYMBIAN_TRACE_SQL_EVENTS is enabled. Otherwise it evaluates to zero
-#define SYMBIAN_TRACE_SQL_EVENTS_ONLY(c) c
-const TPtrC8 GetIPCFuncStr(TInt aFunction);
-
-#else
-
-#define SYMBIAN_TRACE_SQL_EVENTS_ONLY(c) do {} while(0)
-#endif //SYMBIAN_TRACE_SQL_EVENTS
-////////////////////////////////////////////////////////////////////////////////////////////////////////////
-#endif // UTRACESQL_H
--- a/persistentstorage/sql/SRC/Security/SqlSecurity.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Security/SqlSecurity.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -14,8 +14,12 @@
//
#include "SqlSecurityImpl.h"
-#include "SqlPanic.h"
-#include "UTraceSql.h"
+#include "SqlAssert.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSecurityTraces.h"
+#endif
+#include "SqlTraceDef.h"
const TInt32 KEndOfSPStream = -1;//If found in the stream, given as an argument to RSqlSecurityPolicy::InternalizeL(),
//then there are no more policies in the stream.
@@ -46,8 +50,9 @@
*/
EXPORT_C TInt RSqlSecurityPolicy::Create(const TSecurityPolicy& aDefaultPolicy)
{
- SQLUTRACE_PROFILER(this);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSECURITYPOLICY_CREATE_ENTRY , "Entry;0x%X;RSqlSecurityPolicy::Create;aDefaultPolicy=0x%X", (TUint)this, (TUint)&aDefaultPolicy));
TRAPD(err, CreateL(aDefaultPolicy));
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLSECURITYPOLICY_CREATE_EXIT, "Exit;0x%X;RSqlSecurityPolicy::Create;iImpl=0x%X;err=%d", (TUint)this, (TUint)iImpl, err));
return err;
}
@@ -66,8 +71,9 @@
*/
EXPORT_C void RSqlSecurityPolicy::CreateL(const TSecurityPolicy& aDefaultPolicy)
{
- SQLUTRACE_PROFILER(this);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSECURITYPOLICY_CREATEL_ENTRY , "Entry;0x%X;RSqlSecurityPolicy::CreateL;aDefaultPolicy=0x%X", (TUint)this, (TUint)&aDefaultPolicy));
iImpl = CSqlSecurityPolicy::NewL(aDefaultPolicy);
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSECURITYPOLICY_CREATEL_EXIT, "Exit;0x%X;RSqlSecurityPolicy::CreateL;iImpl=0x%X", (TUint)this, (TUint)iImpl));
}
/**
@@ -77,8 +83,9 @@
*/
EXPORT_C void RSqlSecurityPolicy::Close()
{
- SQLUTRACE_PROFILER(this);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLSECURITYPOLICY_CLOSE_ENTRY , "Entry;0x%X;RSqlSecurityPolicy::Close", (TUint)this));
delete iImpl;
+ SQL_TRACE_BORDER(OstTraceExt2(TRACE_BORDER, RSQLSECURITYPOLICY_CLOSE_EXIT, "Exit;0x%X;RSqlSecurityPolicy::Close;iImpl=0x%X", (TUint)this, (TUint)iImpl));
iImpl = NULL;
}
@@ -103,8 +110,7 @@
*/
EXPORT_C TInt RSqlSecurityPolicy::SetDbPolicy(TPolicyType aPolicyType, const TSecurityPolicy& aPolicy)
{
- SQLUTRACE_PROFILER(this);
- __SQLASSERT_ALWAYS(aPolicyType >= ESchemaPolicy && aPolicyType <= EWritePolicy, ESqlPanicBadArgument);
+ __ASSERT_ALWAYS(aPolicyType >= ESchemaPolicy && aPolicyType <= EWritePolicy, __SQLPANIC(ESqlPanicBadArgument));
Impl().SetDbPolicy(aPolicyType, aPolicy);
return KErrNone;
}
@@ -140,10 +146,9 @@
EXPORT_C TInt RSqlSecurityPolicy::SetPolicy(TObjectType aObjectType, const TDesC& aObjectName,
TPolicyType aPolicyType, const TSecurityPolicy& aPolicy)
{
- SQLUTRACE_PROFILER(this);
- __SQLASSERT_ALWAYS(aObjectType == ETable, ESqlPanicBadArgument);
- __SQLASSERT_ALWAYS(aObjectName.Length() > 0, ESqlPanicBadArgument);
- __SQLASSERT_ALWAYS(aPolicyType >= EReadPolicy && aPolicyType <= EWritePolicy, ESqlPanicBadArgument);
+ __ASSERT_ALWAYS(aObjectType == ETable, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_ALWAYS(aObjectName.Length() > 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_ALWAYS(aPolicyType >= EReadPolicy && aPolicyType <= EWritePolicy, __SQLPANIC(ESqlPanicBadArgument));
return Impl().SetPolicy(aObjectType, aObjectName, aPolicyType, aPolicy);
}
@@ -158,7 +163,6 @@
*/
EXPORT_C TSecurityPolicy RSqlSecurityPolicy::DefaultPolicy() const
{
- SQLUTRACE_PROFILER(this);
return Impl().DefaultPolicy();
}
@@ -179,8 +183,7 @@
*/
EXPORT_C TSecurityPolicy RSqlSecurityPolicy::DbPolicy(TPolicyType aPolicyType) const
{
- SQLUTRACE_PROFILER(this);
- __SQLASSERT_ALWAYS(aPolicyType >= ESchemaPolicy && aPolicyType <= EWritePolicy, ESqlPanicBadArgument);
+ __ASSERT_ALWAYS(aPolicyType >= ESchemaPolicy && aPolicyType <= EWritePolicy, __SQLPANIC(ESqlPanicBadArgument));
return Impl().DbPolicy(aPolicyType);
}
@@ -209,10 +212,9 @@
EXPORT_C TSecurityPolicy RSqlSecurityPolicy::Policy(TObjectType aObjectType, const TDesC& aObjectName,
TPolicyType aPolicyType) const
{
- SQLUTRACE_PROFILER(this);
- __SQLASSERT_ALWAYS(aObjectType == ETable, ESqlPanicBadArgument);
- __SQLASSERT_ALWAYS(aObjectName.Length() > 0, ESqlPanicBadArgument);
- __SQLASSERT_ALWAYS(aPolicyType >= EReadPolicy && aPolicyType <= EWritePolicy, ESqlPanicBadArgument);
+ __ASSERT_ALWAYS(aObjectType == ETable, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_ALWAYS(aObjectName.Length() > 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_ALWAYS(aPolicyType >= EReadPolicy && aPolicyType <= EWritePolicy, __SQLPANIC(ESqlPanicBadArgument));
return Impl().Policy(aObjectType, aObjectName, aPolicyType);
}
@@ -227,7 +229,7 @@
*/
EXPORT_C void RSqlSecurityPolicy::ExternalizeL(RWriteStream& aStream) const
{
- SQLUTRACE_PROFILER(this);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLSECURITYPOLICY_EXTERNALIZEL_ENTRY , "Entry;0x%X;RSqlSecurityPolicy::ExternalizeL;aStream=0x%X;aStream.Sink()=0x%X", (TUint)this, (TUint)&aStream, (TUint)aStream.Sink()));
RSqlSecurityPolicy::TObjectType objectType;
TPtrC objectName;
RSqlSecurityPolicy::TPolicyType policyType;
@@ -253,6 +255,7 @@
}
//Object policy stream - end
aStream << KEndOfSPStream;
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLSECURITYPOLICY_EXTERNALIZEL_EXIT, "Exit;0x%X;RSqlSecurityPolicy::ExternalizeL", (TUint)this));
}
/**
@@ -268,7 +271,7 @@
*/
EXPORT_C void RSqlSecurityPolicy::InternalizeL(RReadStream& aStream)
{
- SQLUTRACE_PROFILER(this);
+ SQL_TRACE_BORDER(OstTraceExt3(TRACE_BORDER, RSQLSECURITYPOLICY_INTERNALIZEL_ENTRY , "Entry;0x%X;RSqlSecurityPolicy::InternalizeL;aStream=0x%X;aStream.Source()=0x%X", (TUint)this, (TUint)&aStream, (TUint)aStream.Source()));
TSecurityPolicy policy;
TBuf8<sizeof(TSecurityPolicy)> policyBuf;
//Default policy
@@ -311,6 +314,7 @@
iImpl = temp;
//Destroy the old policy (which was swapped)
CleanupStack::PopAndDestroy(&newPolicy);
+ SQL_TRACE_BORDER(OstTrace1(TRACE_BORDER, RSQLSECURITYPOLICY_INTERNALIZEL_EXIT, "Exit;0x%X;RSqlSecurityPolicy::InternalizeL", (TUint)this));
}
/**
@@ -333,6 +337,6 @@
*/
CSqlSecurityPolicy& RSqlSecurityPolicy::Impl() const
{
- __SQLASSERT_ALWAYS(iImpl != NULL, ESqlPanicInvalidObj);
+ __ASSERT_ALWAYS(iImpl != NULL, __SQLPANIC(ESqlPanicInvalidObj));
return *iImpl;
}
--- a/persistentstorage/sql/SRC/Security/SqlSecurityImpl.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Security/SqlSecurityImpl.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -43,8 +43,8 @@
*/
inline CSqlSecurityPolicy::TPolicyItem* CSqlSecurityPolicy::PolicyItemPtr(const RSqlBufFlat::TCell* aBegin, const RSqlBufFlat::TCell* aCurrent)
{
- __SQLASSERT(aBegin != NULL && aCurrent != NULL, ESqlPanicBadArgument);
- __SQLASSERT(aCurrent->iPos != 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aBegin != NULL && aCurrent != NULL, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aCurrent->iPos != 0, __SQLPANIC2(ESqlPanicBadArgument));
const TUint8* begin = reinterpret_cast <const TUint8*> (aBegin);
return reinterpret_cast <CSqlSecurityPolicy::TPolicyItem*> (const_cast <TUint8*> (begin) + aCurrent->iPos);
}
@@ -63,7 +63,7 @@
const TDesC& aObjectName) const
{
const RSqlBufFlat::TCell* begin = iBufFlat.Header();
- __SQLASSERT(begin != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(begin != NULL, __SQLPANIC(ESqlPanicInternalError));
const RSqlBufFlat::TCell* end = begin + Count();
const RSqlBufFlat::TCell* current = begin + CSqlSecurityPolicy::EDbPolicyIdx;//ignore default and database policiy types ("current" points before the first non-database policy)
while(++current < end)
@@ -71,8 +71,8 @@
if(current->iPos > 0 && current->Type() == (TInt)aObjectType) //if present and the same type as aObjectType
{
const CSqlSecurityPolicy::TPolicyItem* item = CSqlSecurityPolicy::PolicyItemPtr(begin, current);
- __SQLASSERT(item != NULL, ESqlPanicInternalError);
- __SQLASSERT(((current->Size() - sizeof(CSqlSecurityPolicy::TPolicyItem) - sizeof(TInt)) / sizeof(TUint16)) == item->NameSize(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(item != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(((current->Size() - sizeof(CSqlSecurityPolicy::TPolicyItem) - sizeof(TInt)) / sizeof(TUint16)) == item->NameSize(), __SQLPANIC(ESqlPanicInternalError));
if(::CompareNoCase16(aObjectName, TPtrC(item->NamePtr(), item->NameSize())) == 0)
{
return item;
@@ -147,7 +147,7 @@
TInt CSqlSecurityPolicy::Count() const
{
const RSqlBufFlat::TCell* begin = iBufFlat.Header();
- __SQLASSERT(begin != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(begin != NULL, __SQLPANIC(ESqlPanicInternalError));
return *reinterpret_cast <const TInt*> (reinterpret_cast <const TUint8*> (begin) + (begin + CSqlSecurityPolicy::ECountIdx)->iPos);
}
@@ -156,9 +156,9 @@
*/
void CSqlSecurityPolicy::SetCount(TInt aCount)
{
- __SQLASSERT(aCount >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aCount >= 0, __SQLPANIC(ESqlPanicBadArgument));
RSqlBufFlat::TCell* begin = iBufFlat.Header();
- __SQLASSERT(begin != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(begin != NULL, __SQLPANIC(ESqlPanicInternalError));
*reinterpret_cast <TInt*> (reinterpret_cast <TUint8*> (begin) + (begin + CSqlSecurityPolicy::ECountIdx)->iPos) = aCount;
}
@@ -168,9 +168,9 @@
void CSqlSecurityPolicy::SetDefaultPolicy(const TSecurityPolicy& aPolicy)
{
RSqlBufFlat::TCell* begin = iBufFlat.Header();
- __SQLASSERT(begin != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(begin != NULL, __SQLPANIC(ESqlPanicInternalError));
CSqlSecurityPolicy::TPolicyItem* item = CSqlSecurityPolicy::PolicyItemPtr(begin, begin + CSqlSecurityPolicy::EDefaultPolicyIdx);
- __SQLASSERT(item != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(item != NULL, __SQLPANIC(ESqlPanicInternalError));
item->iPolicy[0] = aPolicy;
}
@@ -184,11 +184,11 @@
void CSqlSecurityPolicy::SetDbPolicy(RSqlSecurityPolicy::TPolicyType aPolicyType, const TSecurityPolicy& aPolicy)
{
const TInt KPolicyIndex = CSqlSecurityPolicy::PolicyType2Index(aPolicyType);
- __SQLASSERT((TUint)KPolicyIndex < EPolicyTypeCount, ESqlPanicBadArgument);
+ __ASSERT_DEBUG((TUint)KPolicyIndex < EPolicyTypeCount, __SQLPANIC(ESqlPanicBadArgument));
RSqlBufFlat::TCell* begin = iBufFlat.Header();
- __SQLASSERT(begin != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(begin != NULL, __SQLPANIC(ESqlPanicInternalError));
CSqlSecurityPolicy::TPolicyItem* item = CSqlSecurityPolicy::PolicyItemPtr(begin, begin + CSqlSecurityPolicy::EDbPolicyIdx);
- __SQLASSERT(item != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(item != NULL, __SQLPANIC(ESqlPanicInternalError));
//KPolicyIndex value is tested at the beginning of the function
//coverity[overrun-local]
item->iPolicy[KPolicyIndex] = aPolicy;
@@ -220,8 +220,8 @@
RSqlSecurityPolicy::TPolicyType aPolicyType, const TSecurityPolicy& aPolicy)
{
const TInt KPolicyIndex = CSqlSecurityPolicy::PolicyType2Index(aPolicyType);
- __SQLASSERT((TUint)KPolicyIndex < EPolicyTypeCount, ESqlPanicBadArgument);
- __SQLASSERT(aObjectName.Length() > 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG((TUint)KPolicyIndex < EPolicyTypeCount, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aObjectName.Length() > 0, __SQLPANIC(ESqlPanicBadArgument));
CSqlSecurityPolicy::TPolicyItem* item = const_cast <CSqlSecurityPolicy::TPolicyItem*> (FindPolicyItemPtr(aObjectType, aObjectName));
if(item)
{//There is a field in the flat buffer for {aObjectType, aObjectName}. Set the policy.
@@ -246,7 +246,7 @@
item = reinterpret_cast <CSqlSecurityPolicy::TPolicyItem*> (buf);
//coverity[DEADCODE]
//The ASSERT might be useful in catching future defect in this function
- __SQLASSERT(item != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(item != NULL, __SQLPANIC(ESqlPanicInternalError));
TSecurityPolicy defaultPolicy = DefaultPolicy();
for(TInt i=0;i<CSqlSecurityPolicy::EPolicyTypeCount;++i)
{
@@ -273,9 +273,9 @@
TSecurityPolicy CSqlSecurityPolicy::DefaultPolicy() const
{
const RSqlBufFlat::TCell* begin = iBufFlat.Header();
- __SQLASSERT(begin != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(begin != NULL, __SQLPANIC(ESqlPanicInternalError));
const CSqlSecurityPolicy::TPolicyItem* item = CSqlSecurityPolicy::PolicyItemPtr(begin, begin + CSqlSecurityPolicy::EDefaultPolicyIdx);
- __SQLASSERT(item != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(item != NULL, __SQLPANIC(ESqlPanicInternalError));
return item->iPolicy[0];
}
@@ -292,11 +292,11 @@
TSecurityPolicy CSqlSecurityPolicy::DbPolicy(RSqlSecurityPolicy::TPolicyType aPolicyType) const
{
const TInt KPolicyIndex = CSqlSecurityPolicy::PolicyType2Index(aPolicyType);
- __SQLASSERT((TUint)KPolicyIndex < EPolicyTypeCount, ESqlPanicBadArgument);
+ __ASSERT_DEBUG((TUint)KPolicyIndex < EPolicyTypeCount, __SQLPANIC(ESqlPanicBadArgument));
const RSqlBufFlat::TCell* begin = iBufFlat.Header();
- __SQLASSERT(begin != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(begin != NULL, __SQLPANIC(ESqlPanicInternalError));
const CSqlSecurityPolicy::TPolicyItem* item = CSqlSecurityPolicy::PolicyItemPtr(begin, begin + CSqlSecurityPolicy::EDbPolicyIdx);
- __SQLASSERT(item != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(item != NULL, __SQLPANIC(ESqlPanicInternalError));
//KPolicyIndex value is tested at the beginning of the function
//coverity[overrun-local]
return item->iPolicy[KPolicyIndex];
@@ -324,8 +324,8 @@
const TDesC& aObjectName, RSqlSecurityPolicy::TPolicyType aPolicyType)
{
const TInt KPolicyIndex = CSqlSecurityPolicy::PolicyType2Index(aPolicyType);
- __SQLASSERT((TUint)KPolicyIndex < EPolicyTypeCount, ESqlPanicBadArgument);
- __SQLASSERT(aObjectName.Length() > 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG((TUint)KPolicyIndex < EPolicyTypeCount, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aObjectName.Length() > 0, __SQLPANIC(ESqlPanicBadArgument));
const CSqlSecurityPolicy::TPolicyItem* item = FindPolicyItemPtr(aObjectType, aObjectName);
//KPolicyIndex value is tested at the beginning of the function
//coverity[overrun-local]
@@ -377,7 +377,7 @@
iEnd(iBegin + aSqlSecurityPolicy.Count()),
iCurPolicyIdx(CSqlSecurityPolicy::EPolicyTypeCount)
{
- __SQLASSERT(iBegin != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBegin != NULL, __SQLPANIC(ESqlPanicInternalError));
}
/**
@@ -402,7 +402,7 @@
}
}
const CSqlSecurityPolicy::TPolicyItem* item = CSqlSecurityPolicy::PolicyItemPtr(iBegin, iCurrent);
- __SQLASSERT(item != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(item != NULL, __SQLPANIC(ESqlPanicInternalError));
aObjectType = static_cast <RSqlSecurityPolicy::TObjectType> (iCurrent->Type());
aPolicyType = static_cast <RSqlSecurityPolicy::TPolicyType> (iCurPolicyIdx);
aPolicy = item->iPolicy[iCurPolicyIdx];
--- a/persistentstorage/sql/SRC/Server/Compact/SqlCompact.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/Compact/SqlCompact.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -13,11 +13,16 @@
// Description:
//
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlCompact.h"
#include "SqlCompactEntry.h"
#include "SqlCompactTimer.h"
#include "SqlUtil.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlCompactTraces.h"
+#endif
+#include "SqlTraceDef.h"
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -38,8 +43,8 @@
*/
void TSqlCompactSettings::Invariant() const
{
- __SQLASSERT(iStepLength > 0, ESqlPanicInternalError);
- __SQLASSERT(iFreePageThresholdKb >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iStepLength > 0, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(iFreePageThresholdKb >= 0, __SQLPANIC(ESqlPanicInternalError));
}
#endif//_DEBUG
@@ -72,8 +77,8 @@
*/
CSqlCompactor* CSqlCompactor::NewL(TSqlCompactConnFactoryL aConnFactoryL, TInt aCompactStepInterval)
{
- __SQLASSERT(aConnFactoryL != NULL, ESqlPanicBadArgument);
- __SQLASSERT(aCompactStepInterval > 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aConnFactoryL != NULL, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aCompactStepInterval > 0, __SQLPANIC2(ESqlPanicBadArgument));
CSqlCompactor* self = new (ELeave) CSqlCompactor(aConnFactoryL);
CleanupStack::PushL(self);
self->ConstructL(aCompactStepInterval);
@@ -89,7 +94,7 @@
{
for(TInt idx=iEntries.Count()-1;idx>=0;--idx)
{
- __SQLASSERT(iEntries[idx] != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iEntries[idx] != NULL, __SQLPANIC(ESqlPanicInternalError));
while(iEntries[idx]->Release() != 0)
{
}
@@ -134,12 +139,13 @@
*/
void CSqlCompactor::AddEntryL(const TDesC& aFullName, const TSqlCompactSettings& aSettings)
{
- __SQLASSERT(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, __SQLPANIC(ESqlPanicBadArgument));
SQLCOMPACTOR_INVARIANT();
CSqlCompactEntry* entry = NULL;
TInt idx = iEntries.FindInOrder(aFullName, &CSqlCompactor::Search);
if(idx == KErrNotFound)
{
+ SQL_TRACE_COMPACT(OstTraceExt4(TRACE_INTERNALS, CSQLCOMPACTOR_ADDENTRYL1, "0x%X;CSqlCompactor::AddEntryL;New entry;aFullName=%S;iStepLength=%d;iFreePageThreashold=%d", (TUint)this, __SQLPRNSTR(aFullName), aSettings.iStepLength, aSettings.iFreePageThresholdKb));
entry = CSqlCompactEntry::NewLC(aFullName, iConnFactoryL, aSettings, *iTimer);
TLinearOrder<CSqlCompactEntry> order(&CSqlCompactor::Compare);
__SQLLEAVE_IF_ERROR(iEntries.InsertInOrder(entry, order));
@@ -147,8 +153,9 @@
}
else
{
+ SQL_TRACE_COMPACT(OstTraceExt4(TRACE_INTERNALS, CSQLCOMPACTOR_ADDENTRYL2, "0x%X;CSqlCompactor::AddEntryL;Reuse entry;aFullName=%S;iStepLength=%d;iFreePageThreashold=%d", (TUint)this, __SQLPRNSTR(aFullName), aSettings.iStepLength, aSettings.iFreePageThresholdKb));
entry = iEntries[idx];
- __SQLASSERT(entry != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(entry != NULL, __SQLPANIC(ESqlPanicInternalError));
(void)entry->AddRef();
}
SQLCOMPACTOR_INVARIANT();
@@ -163,13 +170,14 @@
*/
void CSqlCompactor::ReleaseEntry(const TDesC& aFullName)
{
+ SQL_TRACE_COMPACT(OstTraceExt2(TRACE_INTERNALS, CSQLCOMPACTOR_RELEASEENTRY1, "0x%X;CSqlCompactor::ReleaseEntry;aFullName=%S", (TUint)this, __SQLPRNSTR(aFullName)));
SQLCOMPACTOR_INVARIANT();
TInt idx = iEntries.FindInOrder(aFullName, &CSqlCompactor::Search);
- __SQLASSERT(idx >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(idx >= 0, __SQLPANIC(ESqlPanicInternalError));
if(idx >= 0)
{
CSqlCompactEntry* entry = iEntries[idx];
- __SQLASSERT(entry != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(entry != NULL, __SQLPANIC(ESqlPanicInternalError));
if(entry)
{
if(entry->Release() == 0)
@@ -199,7 +207,7 @@
iConnFactoryL(aConnFactoryL),
iEntries(KEntriesGranularity)
{
- __SQLASSERT(aConnFactoryL != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aConnFactoryL != NULL, __SQLPANIC(ESqlPanicBadArgument));
}
/**
@@ -211,7 +219,7 @@
*/
void CSqlCompactor::ConstructL(TInt aCompactStepInterval)
{
- __SQLASSERT(aCompactStepInterval > 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aCompactStepInterval > 0, __SQLPANIC(ESqlPanicBadArgument));
iTimer = CSqlCompactTimer::NewL(aCompactStepInterval);
}
@@ -223,11 +231,11 @@
*/
/* static */TInt CSqlCompactor::Search(const TDesC* aFullName, const CSqlCompactEntry& aEntry)
{
- __SQLASSERT(&aEntry != NULL, ESqlPanicInternalError);
- __SQLASSERT(aFullName != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(&aEntry != NULL, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aFullName != NULL, __SQLPANIC2(ESqlPanicInternalError));
const TDesC& fullName = *aFullName;
- __SQLASSERT(fullName.Length() > 0 && fullName.Length() <= KMaxFileName, ESqlPanicInternalError);
- __SQLASSERT(aEntry.FullName().Length() > 0 && aEntry.FullName().Length() <= KMaxFileName, ESqlPanicInternalError);
+ __ASSERT_DEBUG(fullName.Length() > 0 && fullName.Length() <= KMaxFileName, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aEntry.FullName().Length() > 0 && aEntry.FullName().Length() <= KMaxFileName, __SQLPANIC2(ESqlPanicInternalError));
return fullName.CompareF(aEntry.FullName());
}
@@ -236,10 +244,10 @@
*/
/* static */TInt CSqlCompactor::Compare(const CSqlCompactEntry& aLeft, const CSqlCompactEntry& aRight)
{
- __SQLASSERT(&aLeft != NULL, ESqlPanicInternalError);
- __SQLASSERT(&aRight != NULL, ESqlPanicInternalError);
- __SQLASSERT(aLeft.FullName().Length() > 0 && aLeft.FullName().Length() <= KMaxFileName, ESqlPanicInternalError);
- __SQLASSERT(aRight.FullName().Length() > 0 && aRight.FullName().Length() <= KMaxFileName, ESqlPanicInternalError);
+ __ASSERT_DEBUG(&aLeft != NULL, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(&aRight != NULL, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aLeft.FullName().Length() > 0 && aLeft.FullName().Length() <= KMaxFileName, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aRight.FullName().Length() > 0 && aRight.FullName().Length() <= KMaxFileName, __SQLPANIC2(ESqlPanicInternalError));
return aLeft.FullName().CompareF(aRight.FullName());
}
@@ -249,12 +257,12 @@
*/
void CSqlCompactor::Invariant() const
{
- __SQLASSERT(iConnFactoryL != NULL, ESqlPanicInternalError);
- __SQLASSERT(iTimer != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iConnFactoryL != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(iTimer != NULL, __SQLPANIC(ESqlPanicInternalError));
iTimer->Invariant();
for(TInt idx=iEntries.Count()-1;idx>=0;--idx)
{
- __SQLASSERT(iEntries[idx] != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iEntries[idx] != NULL, __SQLPANIC(ESqlPanicInternalError));
iEntries[idx]->Invariant();
}
}
--- a/persistentstorage/sql/SRC/Server/Compact/SqlCompactConn.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/Compact/SqlCompactConn.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -15,12 +15,17 @@
#include <f32file.h>
#include <sqldb.h>
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "sqlite3.h"
#include "SqliteSymbian.h" //TSqlFreePageCallback
#include "SqlSrvUtil.h"
#include "SqlSrvStatementUtil.h"
#include "SqlCompactConn.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlCompactConnTraces.h"
+#endif
+#include "SqlTraceDef.h"
/**
Creates a new CSqlCompactConn instance.
@@ -45,12 +50,14 @@
*/
CSqlCompactConn* CSqlCompactConn::NewL(const TDesC& aFullName, TSqlFreePageCallback& aFreePageCallback)
{
- __SQLASSERT(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, ESqlPanicBadArgument);
- __SQLASSERT(aFreePageCallback.IsValid(), ESqlPanicBadArgument);
+ SQL_TRACE_COMPACT(OstTraceExt1(TRACE_INTERNALS, CSQLCOMPACTCONN_NEWLC_ENTRY, "Entry;0;CSqlCompactConn::NewL;aFullName=%S", __SQLPRNSTR(aFullName)));
+ __ASSERT_DEBUG(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aFreePageCallback.IsValid(), __SQLPANIC2(ESqlPanicBadArgument));
CSqlCompactConn* self = new (ELeave) CSqlCompactConn;
CleanupStack::PushL(self);
self->ConstructL(aFullName, aFreePageCallback);
CleanupStack::Pop(self);
+ SQL_TRACE_COMPACT(OstTraceExt2(TRACE_INTERNALS, CSQLCOMPACTCONN_NEWLC_EXIT, "Exit;0x%X;CSqlCompactConn::NewL;aFullName=%S", (TUint)self, __SQLPRNSTR(aFullName)));
return self;
}
@@ -59,6 +66,7 @@
*/
CSqlCompactConn::~CSqlCompactConn()
{
+ SQL_TRACE_COMPACT(OstTrace1(TRACE_INTERNALS, CSQLCOMPACTCONN_CSQLCOMPACTCONN2, "0x%X;CSqlCompactConn::~CSqlCompactConn", (TUint)this));
::CloseDbHandle(iHandle);
}
@@ -89,8 +97,8 @@
*/
TInt CSqlCompactConn::Compact(TInt aPageCount, TInt& aProcessedPageCount, TInt aLength)
{
- __SQLASSERT(aPageCount >= 0, ESqlPanicBadArgument);
- __SQLASSERT(aLength >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aPageCount >= 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aLength >= 0, __SQLPANIC(ESqlPanicBadArgument));
SQLCOMPACTCONN_INVARIANT();
TInt err = ::DbCompact(iHandle, KNullDesC, aPageCount, aProcessedPageCount, aLength);
SQLCOMPACTCONN_INVARIANT();
@@ -123,9 +131,9 @@
*/
void CSqlCompactConn::ConstructL(const TDesC& aFullName, TSqlFreePageCallback& aFreePageCallback)
{
- __SQLASSERT(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, ESqlPanicBadArgument);
- __SQLASSERT(aFreePageCallback.IsValid(), ESqlPanicBadArgument);
- __SQLASSERT(!iHandle, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aFreePageCallback.IsValid(), __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(!iHandle, __SQLPANIC(ESqlPanicInternalError));
TBuf8<KMaxFileName + 1> fname;
(void)::UTF16ToUTF8Z(aFullName, fname);//The file is first open by the main connection.
@@ -190,7 +198,7 @@
*/
void CSqlCompactConn::Invariant() const
{
- __SQLASSERT_ALWAYS(iHandle != NULL, ESqlPanicInternalError);
+ __ASSERT_ALWAYS(iHandle != NULL, __SQLPANIC(ESqlPanicInternalError));
}
#endif//_DEBUG
@@ -222,7 +230,7 @@
*/
MSqlCompactConn* SqlCreateCompactConnL(const TDesC& aFullName, TSqlFreePageCallback& aFreePageCallback)
{
- __SQLASSERT(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, ESqlPanicBadArgument);
- __SQLASSERT(aFreePageCallback.IsValid(), ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aFreePageCallback.IsValid(), __SQLPANIC2(ESqlPanicBadArgument));
return CSqlCompactConn::NewL(aFullName, aFreePageCallback);
}
--- a/persistentstorage/sql/SRC/Server/Compact/SqlCompactEntry.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/Compact/SqlCompactEntry.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -16,10 +16,15 @@
#include <e32debug.h>
#include <hal.h>
#include <sqldb.h>
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlCompactEntry.h"
#include "SqlCompactTimer.h"
#include "SqliteSymbian.h" //TSqlFreePageCallback
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlCompactEntryTraces.h"
+#endif
+#include "SqlTraceDef.h"
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -47,11 +52,13 @@
CSqlCompactEntry* CSqlCompactEntry::NewLC(const TDesC& aFullName, TSqlCompactConnFactoryL aConnFactoryL,
const TSqlCompactSettings& aSettings, CSqlCompactTimer& aTimer)
{
- __SQLASSERT(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, ESqlPanicBadArgument);
- __SQLASSERT(aConnFactoryL != NULL, ESqlPanicBadArgument);
+ SQL_TRACE_COMPACT(OstTraceExt1(TRACE_INTERNALS, CSQLCOMPACTENTRY_NEWLC_ENTRY, "Entry;0;CSqlCompactEntry::NewLC;aFullName=%S", __SQLPRNSTR(aFullName)));
+ __ASSERT_DEBUG(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aConnFactoryL != NULL, __SQLPANIC2(ESqlPanicBadArgument));
CSqlCompactEntry* self = new (ELeave) CSqlCompactEntry(aSettings, aTimer);
CleanupStack::PushL(self);
self->ConstructL(aFullName, aConnFactoryL);
+ SQL_TRACE_COMPACT(OstTrace1(TRACE_INTERNALS, CSQLCOMPACTENTRY_NEWLC_EXIT, "Exit;0x%X;CSqlCompactEntry::NewLC", (TUint)self));
return self;
}
@@ -60,6 +67,7 @@
*/
CSqlCompactEntry::~CSqlCompactEntry()
{
+ SQL_TRACE_COMPACT(OstTraceExt3(TRACE_INTERNALS, CSQLCOMPACTENTRY_CSQLCOMPACTENTRY2, "0x%X;CSqlCompactEntry::~CSqlCompactEntry;iState=%d;iPageCount=%d", (TUint)this, (TInt)iState, iPageCount));
if(iState == CSqlCompactEntry::EInProgress)
{
iTimer.DeQueue(*this);
@@ -78,6 +86,7 @@
*/
TInt CSqlCompactEntry::AddRef()
{
+ SQL_TRACE_COMPACT(OstTraceExt4(TRACE_INTERNALS, CSQLCOMPACTENTRY_ADDREF, "0x%X;CSqlCompactEntry::AddRef;iState=%d;iPageCount=%d;iRefCounter=%d", (TUint)this, (TInt)iState, iPageCount, iRefCounter));
SQLCOMPACTENTRY_INVARIANT();
return ++iRefCounter;
}
@@ -90,6 +99,7 @@
*/
TInt CSqlCompactEntry::Release()
{
+ SQL_TRACE_COMPACT(OstTraceExt4(TRACE_INTERNALS, CSQLCOMPACTENTRY_RELEASE, "0x%X;CSqlCompactEntry::Release;iState=%d;iPageCount=%d;iRefCounter=%d", (TUint)this, (TInt)iState, iPageCount, iRefCounter));
SQLCOMPACTENTRY_INVARIANT();
TInt rc = --iRefCounter;
if(rc == 0)
@@ -114,10 +124,11 @@
*/
/* static */ void CSqlCompactEntry::FreePageCallback(void* aThis, TInt aFreePageCount)
{
- __SQLASSERT(aThis != NULL, ESqlPanicBadArgument);
- __SQLASSERT(aFreePageCount > 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aThis != NULL, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aFreePageCount > 0, __SQLPANIC2(ESqlPanicBadArgument));
CSqlCompactEntry& entry = *(static_cast <CSqlCompactEntry*> (aThis));
+ SQL_TRACE_COMPACT(OstTraceExt3(TRACE_INTERNALS, CSQLCOMPACTENTRY_FREEPAGECALLBACK, "0x%X;CSqlCompactEntry::FreePageCallback;aFreePageCount=%d;iState=%d", (TUint)aThis, aFreePageCount, (TInt)entry.iState));
if(entry.iFreePageCallbackDisabled)
{//The callback is disabled during the background compaction step.
//The server is single-threaded, so no other client can activate the callback.
@@ -161,9 +172,9 @@
*/
void CSqlCompactEntry::ConstructL(const TDesC& aFullName, TSqlCompactConnFactoryL aConnFactoryL)
{
- __SQLASSERT(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, ESqlPanicBadArgument);
- __SQLASSERT(aConnFactoryL != NULL, ESqlPanicBadArgument);
- __SQLASSERT(!iConnection, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aFullName.Length() > 0 && aFullName.Length() <= KMaxFileName, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aConnFactoryL != NULL, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(!iConnection, __SQLPANIC(ESqlPanicInternalError));
__SQLLEAVE_IF_ERROR(iFullName.Create(aFullName));
@@ -173,7 +184,7 @@
//the threshold from Kbs to pages when the connection with the database is established.
TSqlFreePageCallback callback(this, iSettings.iFreePageThresholdKb, &CSqlCompactEntry::FreePageCallback);
iConnection = (*aConnFactoryL)(aFullName, callback);
- __SQLASSERT(iConnection != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iConnection != NULL, __SQLPANIC(ESqlPanicInternalError));
//"callback.iThreshold > 0" is an indication that the background compaction should be kicked-off
if(callback.iThreshold > 0)
@@ -201,19 +212,19 @@
*/
TInt CSqlCompactEntry::Compact()
{
- //RDebug::Print(_L("++ CSqlCompactEntry::Compact() ++\r\n"));
+ SQL_TRACE_COMPACT(OstTraceExt3(TRACE_INTERNALS, CSQLCOMPACTENTRY_COMPACT_ENTRY, "Entry;0x%X;CSqlCompactEntry::Compact;aFreePageCount=%d;iState=%d", (TUint)this, iPageCount, (TInt)iState));
SQLCOMPACTENTRY_INVARIANT();
- __SQLASSERT(iPageCount > 0, ESqlPanicInternalError);
- __SQLASSERT(iState == CSqlCompactEntry::EInProgress, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iPageCount > 0, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(iState == CSqlCompactEntry::EInProgress, __SQLPANIC(ESqlPanicInternalError));
TInt processedPageCount = 0;
iFreePageCallbackDisabled = ETrue;
TInt err = Connection().Compact(iPageCount, processedPageCount, iSettings.iStepLength);
iFreePageCallbackDisabled = EFalse;
- __SQLASSERT(processedPageCount >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(processedPageCount >= 0, __SQLPANIC(ESqlPanicInternalError));
if(err == KErrNone)
{
iPageCount -= processedPageCount;
- __SQLASSERT(iPageCount >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iPageCount >= 0, __SQLPANIC(ESqlPanicInternalError));
}
TBool stopCompaction = err == KSqlErrCorrupt || err == KSqlErrNotDb || err == KErrCorrupt || err == KErrDisMounted;
if(iPageCount <= 0 || stopCompaction)
@@ -221,6 +232,7 @@
ResetState();
iTimer.DeQueue(*this);
}
+ SQL_TRACE_COMPACT(OstTraceExt4(TRACE_INTERNALS, CSQLCOMPACTENTRY_COMPACT_EXIT, "Exit;0x%X;CSqlCompactEntry::Compact;iPageCount=%d;iState=%d;err=%d", (TUint)this, iPageCount, (TInt)iState, err));
SQLCOMPACTENTRY_INVARIANT();
return err;
}
@@ -257,7 +269,7 @@
MSqlCompactConn& CSqlCompactEntry::Connection()
{
SQLCOMPACTENTRY_INVARIANT();
- __SQLASSERT_ALWAYS(iConnection != NULL, ESqlPanicInternalError);
+ __ASSERT_ALWAYS(iConnection != NULL, __SQLPANIC(ESqlPanicInternalError));
return *iConnection;
}
@@ -267,11 +279,11 @@
*/
void CSqlCompactEntry::Invariant() const
{
- __SQLASSERT(iFullName.Length() > 0 && iFullName.Length() <= KMaxFileName, ESqlPanicInternalError);
- __SQLASSERT(iConnection != NULL, ESqlPanicInternalError);
- __SQLASSERT(iRefCounter > 0, ESqlPanicInternalError);
- __SQLASSERT(iState == CSqlCompactEntry::EInactive || iState == CSqlCompactEntry::EInProgress, ESqlPanicInternalError);
- __SQLASSERT(iPageCount >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iFullName.Length() > 0 && iFullName.Length() <= KMaxFileName, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(iConnection != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(iRefCounter > 0, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(iState == CSqlCompactEntry::EInactive || iState == CSqlCompactEntry::EInProgress, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(iPageCount >= 0, __SQLPANIC(ESqlPanicInternalError));
iSettings.Invariant();
}
#endif//_DEBUG
--- a/persistentstorage/sql/SRC/Server/Compact/SqlCompactTimer.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/Compact/SqlCompactTimer.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -14,8 +14,13 @@
//
#include "SqlCompactTimer.h"
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlCompactEntry.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlCompactTimerTraces.h"
+#endif
+#include "SqlTraceDef.h"
/**
Creates new CSqlCompactTimer instance.
@@ -26,11 +31,13 @@
*/
CSqlCompactTimer* CSqlCompactTimer::NewL(TInt aIntervalMs)
{
- __SQLASSERT(aIntervalMs > 0, ESqlPanicBadArgument);
+ SQL_TRACE_COMPACT(OstTrace1(TRACE_INTERNALS, CSQLCOMPACTTIMER_NEWL_ENTRY, "Entry;0;CSqlCompactTimer::NewL;aIntervalMs=%d", aIntervalMs));
+ __ASSERT_DEBUG(aIntervalMs > 0, __SQLPANIC2(ESqlPanicBadArgument));
CSqlCompactTimer* self = new (ELeave) CSqlCompactTimer(aIntervalMs);
CleanupStack::PushL(self);
self->ConstructL();
CleanupStack::Pop(self);
+ SQL_TRACE_COMPACT(OstTraceExt2(TRACE_INTERNALS, CSQLCOMPACTTIMER_NEWL_EXIT, "Exit;0x%X;CSqlCompactTimer::NewL;aIntervalMs=%d", (TUint)self, aIntervalMs));
return self;
}
@@ -39,6 +46,7 @@
*/
CSqlCompactTimer::~CSqlCompactTimer()
{
+ SQL_TRACE_COMPACT(OstTrace1(TRACE_INTERNALS, CSQLCOMPACTTIMER_CSQLCOMPACTTIMER2, "0x%X;CSqlCompactTimer::~CSqlCompactTimer", (TUint)this));
Cancel();
}
@@ -65,6 +73,7 @@
*/
void CSqlCompactTimer::Queue(CSqlCompactEntry& aEntry)
{
+ SQL_TRACE_COMPACT(OstTraceExt3(TRACE_INTERNALS, CSQLCOMPACTTIMER_QUEUE, "0x%X;CSqlCompactTimer::Queue;aEntry=0x%X;Name=%S", (TUint)this, (TUint)&aEntry,__SQLPRNSTR(aEntry.FullName())));
SQLCOMPACTTIMER_INVARIANT();
iQueue.AddFirst(aEntry);
if(!IsActive())
@@ -83,6 +92,7 @@
*/
void CSqlCompactTimer::DeQueue(CSqlCompactEntry& aEntry)
{
+ SQL_TRACE_COMPACT(OstTraceExt2(TRACE_INTERNALS, CSQLCOMPACTTIMER_DEQUEUE, "0x%X;CSqlCompactTimer::DeQueue;aEntry=0x%X", (TUint)this, (TUint)&aEntry));
SQLCOMPACTTIMER_INVARIANT();
iQueue.Remove(aEntry);
if(iQueue.IsEmpty())
@@ -104,7 +114,7 @@
iIntervalMicroSec(aIntervalMs * 1000),
iQueue(_FOFF(CSqlCompactEntry, iLink))
{
- __SQLASSERT(aIntervalMs > 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aIntervalMs > 0, __SQLPANIC(ESqlPanicBadArgument));
}
/**
@@ -128,10 +138,12 @@
*/
void CSqlCompactTimer::RunL()
{
+ SQL_TRACE_COMPACT(OstTrace1(TRACE_INTERNALS, CSQLCOMPACTTIMER_RUNL, "0x%X;CSqlCompactTimer::RunL", (TUint)this));
SQLCOMPACTTIMER_INVARIANT();
- __SQLASSERT_ALWAYS(!iQueue.IsEmpty(), ESqlPanicInternalError);
+ __ASSERT_ALWAYS(!iQueue.IsEmpty(), __SQLPANIC(ESqlPanicInternalError));
CSqlCompactEntry* entry = iQueue.Last();
- __SQLASSERT(entry, ESqlPanicInternalError);
+ SQL_TRACE_COMPACT(OstTraceExt4(TRACE_INTERNALS, CSQLCOMPACTTIMER_RUNL2, "0x%X;CSqlCompactTimer::RunL;Compact;entry=0x%X;Name=%S;iQueue.IsEmpty()=%d", (TUint)this, (TUint)entry,__SQLPRNSTR(entry->FullName()), (TInt)iQueue.IsEmpty()));
+ __ASSERT_DEBUG(entry, __SQLPANIC(ESqlPanicInternalError));
(void)entry->Compact();
if(!iQueue.IsEmpty())
{
@@ -146,11 +158,11 @@
*/
void CSqlCompactTimer::Invariant() const
{
- __SQLASSERT(iIntervalMicroSec > 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iIntervalMicroSec > 0, __SQLPANIC(ESqlPanicInternalError));
if(!iQueue.IsEmpty())
{
CSqlCompactEntry* entry = iQueue.Last();
- __SQLASSERT(entry != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(entry != NULL, __SQLPANIC(ESqlPanicInternalError));
}
}
#endif//_DEBUG
--- a/persistentstorage/sql/SRC/Server/IPC/IPCStream.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/IPC/IPCStream.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -14,7 +14,7 @@
//
#include <s32buf.h>
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "IPCStream.h"
#include "SqlSrvResourceProfiler.h"
--- a/persistentstorage/sql/SRC/Server/IPC/IPCStream.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/IPC/IPCStream.inl Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -31,7 +31,7 @@
iRPos(aReadPos),
iWPos(0)
{
- __SQLASSERT(aHost != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aHost != NULL, __SQLPANIC(ESqlPanicInternalError));
}
/**
--- a/persistentstorage/sql/SRC/Server/SqlBur.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlBur.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -15,7 +15,13 @@
#include "SqlBur.h"
#include "SqlAssert.h"
-#include "SqlPanic.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlBurTraces.h"
+#endif
+#include "SqlTraceDef.h"
+
+#define UNUSED_ARG(arg) arg = arg
//Extracts and returns 32-bit integer from aNumBuf buffer.
static TUint32 GetNumUint32L(const TDesC& aNumBuf)
@@ -23,7 +29,7 @@
TLex lex(aNumBuf);
lex.SkipSpace();
TUint32 num = 0xFFFFFFFF;
- __SQLLEAVE_IF_ERROR(lex.Val(num, EHex));
+ __SQLLEAVE_IF_ERROR2(lex.Val(num, EHex));
return num;
}
@@ -33,7 +39,7 @@
TLex lex(aNumBuf);
lex.SkipSpace();
TInt64 num = -1;
- __SQLLEAVE_IF_ERROR(lex.Val(num, EHex));
+ __SQLLEAVE_IF_ERROR2(lex.Val(num, EHex));
return num;
}
@@ -57,6 +63,7 @@
CSqlBackupClient *self=(CSqlBackupClient *)new(ELeave) CSqlBackupClient(aInterface);
CleanupStack::PushL(self);
self->ConstructL();
+ SQL_TRACE_BUR(OstTrace1(TRACE_INTERNALS, CSQLBACKUPCLIENT_NEWLC, "0x%X;CSqlBackupClient::NewLC", (TUint)self));
return self;
}
@@ -86,6 +93,8 @@
*/
CSqlBackupClient::~CSqlBackupClient()
{
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_CSQLBACKUPCLIENT2, "0x%X;CSqlBackupClient::~CSqlBackupClient;iFile.SubSessionHandle()=0x%X", (TUint)this, (TUint)iFile.SubSessionHandle()));
+
// cancel outstanding requests
Cancel();
@@ -130,8 +139,10 @@
@return a flag indicating whether we actioned the error
@param the error unused
*/
-TInt CSqlBackupClient::RunError(TInt /* aError */)
+TInt CSqlBackupClient::RunError(TInt aError)
{
+ UNUSED_ARG(aError);
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_RUNERROR, "0x%X;CSqlBackupClient::RunError;aError=%d", (TUint)this, aError));
// just satisfy it that we did something!
return KErrNone;
}
@@ -149,6 +160,7 @@
*/
void CSqlBackupClient::NotifyChange()
{
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_NOTIFYCHANGE, "0x%X;CSqlBackupClient::NotifyChange;iBurProperty.Handle()=0x%X", (TUint)this, (TUint)iBurProperty.Handle()));
iBurProperty.Subscribe(iStatus);
SetActive();
}
@@ -161,10 +173,17 @@
*/
void CSqlBackupClient::TestBurStatusL()
{
+ SQL_TRACE_BUR(OstTrace1(TRACE_INTERNALS, CSQLBACKUPCLIENT_TESTBURSTATUSL_ENTRY, "Entry;0x%X;CSqlBackupClient::TestBurStatusL", (TUint)this));
TInt status;
- if(iBurProperty.Get(status)!=KErrNotFound)
+ __SQLTRACE_BURVAR(TInt err = KErrNone);
+ if((__SQLTRACE_BUREXPR(err =) iBurProperty.Get(status)) != KErrNotFound)
{
status&=KBURPartTypeMask;
+#ifdef _SQL_RDEBUG_PRINT
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_TESTBURSTATUSL1, "0x%X;CSqlBackupClient::TestBurStatusL;status=%d", (TUint)this, status));
+#else
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_TESTBURSTATUSL2, "0x%X;CSqlBackupClient::TestBurStatusL;status=%{TBURPartType}", (TUint)this, status));
+#endif
switch(status)
{
case EBURUnset: // same as EBURNormal
@@ -184,9 +203,10 @@
iActiveBackupClient->ConfirmReadyForBURL(KErrNone);
break;
default:
- return;
+ break;
}
}
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_TESTBURSTATUSL_EXIT, "Exit;0x%X;CSqlBackupClient::TestBurStatusL;iProperty.Get() err=%d", (TUint)this, err));
}
/** Called when BUE notifies a BUR event
@@ -209,10 +229,12 @@
@return an arbitrary number
@param TDrive unused
*/
-TUint CSqlBackupClient::GetExpectedDataSize(TDriveNumber /* aDrive */)
+TUint CSqlBackupClient::GetExpectedDataSize(TDriveNumber aDrive)
{
+ UNUSED_ARG(aDrive);
// we have no idea at this point - we even don't know who is to be backed up yet
const TUint KArbitraryNumber = 1024;
+ SQL_TRACE_BUR(OstTraceExt3(TRACE_INTERNALS, CSQLBACKUPCLIENT_GETEXPECTEDDATASIZE, "0x%X;CSqlBackupClient::GetExpectedDataSize;aDrive=%d;rc=%u", (TUint)this, (TInt)aDrive, KArbitraryNumber));
return KArbitraryNumber;
}
@@ -227,11 +249,13 @@
*/
void CSqlBackupClient::GetBackupDataSectionL(TPtr8& aBuffer, TBool& aFinishedFlag)
{
+ SQL_TRACE_BUR(OstTraceExt3(TRACE_INTERNALS, CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL0, "0x%X;CSqlBackupClient::GetBackupDataSectionL;iState=%d;iFileIndex=%d", (TUint)this, (TInt)iState, iFileIndex));
// don't assume they set it to false
aFinishedFlag=EFalse;
// any files to backup
if(iFileList.Count()==0)
{
+ SQL_TRACE_BUR(OstTrace1(TRACE_INTERNALS, CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL1, "0x%X;CSqlBackupClient::GetBackupDataSectionL;file count is 0", (TUint)this));
// nothing to backup - just return the finished flag
aFinishedFlag=ETrue;
// clear down the list
@@ -239,7 +263,7 @@
// iFileList closed in dtor
return;
}
-
+
// run the state machine
for(TInt bufFreeSpace=aBuffer.MaxSize()-aBuffer.Size(); bufFreeSpace>0; bufFreeSpace=aBuffer.MaxSize()-aBuffer.Size())
{
@@ -249,6 +273,7 @@
{
if(iFileIndex>=iFileList.Count())
{
+ SQL_TRACE_BUR(OstTrace1(TRACE_INTERNALS, CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL2, "0x%X;CSqlBackupClient::GetBackupDataSectionL;all files processed", (TUint)this));
// all files have been processed - send the finished flag
aFinishedFlag=ETrue;
// clear down the filelist
@@ -257,6 +282,8 @@
}
// open the database file to send
TInt rc=iFile.Open( iInterface->Fs(), iFileList[iFileIndex].FullName(), EFileRead | EFileShareExclusive);
+ __SQLTRACE_BUREXPR(TPtrC fname = iFileList[iFileIndex].FullName());
+ SQL_TRACE_BUR(OstTraceExt5(TRACE_INTERNALS, CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL3, "0x%X;CSqlBackupClient::GetBackupDataSectionL;BEGIN;fname=%S;iFileIndex=%d;iFile.SubSessionHandle()=0x%X;rc=%d", (TUint)this, __SQLPRNSTR(fname), iFileIndex, (TUint)iFile.SubSessionHandle(), rc));
if(KErrNone!=rc)
{
// there's nothing we can do if we can't open the file so we just skip it
@@ -290,6 +317,7 @@
fileSize, // %16lx
fileName.Length(), // %8x
&fileName); // %S
+ SQL_TRACE_BUR(OstTraceExt4(TRACE_INTERNALS, CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL5, "0x%X;CSqlBackupClient::GetBackupDataSectionL;fileName=%S;hdrPtr=|%S|;fileSize=%lld", (TUint)this, __SQLPRNSTR(fileName), __SQLPRNSTR(iBuffer), fileSize));
// we need it to look like an 8bit buffer
TPtr8 hdrPtr8((TUint8*)iBuffer.Ptr(), iBuffer.Size(), iBuffer.Size());
@@ -357,6 +385,7 @@
}
case EBackupEndOfFile:
{
+ SQL_TRACE_BUR(OstTraceExt3(TRACE_INTERNALS, CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL4, "0x%X;CSqlBackupClient::GetBackupDataSectionL;END;iFile.SubSessionHandle()=0x%X;iFileIndex=%d", (TUint)this, (TUint)iFile.SubSessionHandle(), iFileIndex));
iFile.Close();
++iFileIndex; // move on to next file
iState = EBackupNoFileOpen; // go round again
@@ -374,8 +403,10 @@
Nothing to do here except tell the server
@param TDrive the drive that is being restored (unused)
*/
-void CSqlBackupClient::RestoreComplete(TDriveNumber /* aDrive */)
+void CSqlBackupClient::RestoreComplete(TDriveNumber aDrive)
{
+ UNUSED_ARG(aDrive);
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_RESTORECOMPLETE, "0x%X;CSqlBackupClient::RestoreComplete;aDrive=%d", (TUint)this, (TInt)aDrive));
}
/** This is called to let us know that the given SID is to be backed up
@@ -387,8 +418,10 @@
@param TDriveNumber the drive to be backed up (unused)
@leave
*/
-void CSqlBackupClient::InitialiseGetProxyBackupDataL(TSecureId aSid, TDriveNumber /*aDrive*/)
+void CSqlBackupClient::InitialiseGetProxyBackupDataL(TSecureId aSid, TDriveNumber aDrive)
{
+ UNUSED_ARG(aDrive);
+ SQL_TRACE_BUR(OstTraceExt3(TRACE_INTERNALS, CSQLBACKUPCLIENT_INITIALIZEGETPROXYBACKUPDATAL, "0x%X;CSqlBackupClient::InitialiseGetProxyBackupDataL;aSid=0x%X;aDrive=%d", (TUint)this, (TUint)aSid.iId, (TInt)aDrive));
// get the list of database files to back up - this is provided by the SQL server
GetBackupListL(aSid);
// this is the index of the file being processed - point to the beginning
@@ -404,8 +437,10 @@
@param TDriveNumber the drive to restore (unused)
@leave
*/
-void CSqlBackupClient::InitialiseRestoreProxyBaseDataL(TSecureId aSid, TDriveNumber /* aDrive */)
+void CSqlBackupClient::InitialiseRestoreProxyBaseDataL(TSecureId aSid, TDriveNumber aDrive)
{
+ UNUSED_ARG(aDrive);
+ SQL_TRACE_BUR(OstTraceExt3(TRACE_INTERNALS, CSQLBACKUPCLIENT_INITIALIZERESTOREPROXYBASEDATAL, "0x%X;CSqlBackupClient::InitialiseRestoreProxyBaseDataL;aSid=0x%X;aDrive=%d", (TUint)this, (TUint)aSid.iId, (TInt)aDrive));
iBuffer.Zero();
// this is the first state of the restore state machine
iState=ERestoreExpectChecksum;
@@ -426,6 +461,7 @@
*/
void CSqlBackupClient::RestoreBaseDataSectionL(TDesC8& aInBuffer, TBool aFinishedFlag)
{
+ SQL_TRACE_BUR(OstTraceExt4(TRACE_INTERNALS, CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL0, "0x%X;CSqlBackupClient::RestoreBaseDataSectionL;iState=%d;aInBuffer.Length()=%d;aFinishedFlag=%d", (TUint)this, (TInt)iState, aInBuffer.Length(), (TInt)aFinishedFlag));
// used to walk the buffer
// got a new buffer - because each time this method is called, we have a
// fresh chunk of data
@@ -526,6 +562,7 @@
iState = ERestoreExpectFileNameSize;
iBuffer.Zero();
}
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL1, "0x%X;CSqlBackupClient::RestoreBaseDataSectionL;iFileSize=%lld", (TUint)this, iFileSize));
break;
}
case ERestoreExpectFileNameSize: // the size of the file name to restore
@@ -543,6 +580,7 @@
case ERestoreExpectFileName: // the name of the file to restore
{
CopyBufData(aInBuffer, inBufferPos, iBuffer, iFileNameSize);
+ SQL_TRACE_BUR(OstTraceExt4(TRACE_INTERNALS, CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL2, "0x%X;CSqlBackupClient::RestoreBaseDataSectionL;BEGIN;iBuffer=%S;iBuffer.Length()=%d;iFileNameSize=%d", (TUint)this, __SQLPRNSTR(iBuffer), iBuffer.Length(), iFileNameSize));
if(iBuffer.Length() == iFileNameSize)
{
iState = ERestoreExpectData;
@@ -552,6 +590,7 @@
// once all the temp files are created, then they are renamed to the
// real file names in one fell swoop
__SQLLEAVE_IF_ERROR(iFile.Replace(iInterface->Fs(), iBuffer, EFileWrite | EFileShareExclusive));
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL3, "0x%X;CSqlBackupClient::RestoreBaseDataSectionL;iFile.SubSessionHandle()=0x%X", (TUint)this, (TUint)iFile.SubSessionHandle()));
iBuffer.Zero();
}
break;
@@ -574,8 +613,9 @@
TUint32 cksum = CheckSumL(iFile) & KMaxTUint32;
// done with the file now - has to follow checksum cos it
- // expects an open file
- __SQLLEAVE_IF_ERROR(iFile.Flush());
+ // expects ann open file
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL4, "0x%X;CSqlBackupClient::RestoreBaseDataSectionL;END;iFile.SubSessionHandle()=0x%X", (TUint)this, (TUint)iFile.SubSessionHandle()));
+ __SQLLEAVE_IF_ERROR(iFile.Flush());
iFile.Close();
// validate that the checksum matches
@@ -608,6 +648,7 @@
//the ".bak" file, if exists, will be deleted first.
(void)iInterface->Fs().Delete(bak);
TInt err=iInterface->Fs().Rename(db,bak);
+ SQL_TRACE_BUR(OstTraceExt4(TRACE_INTERNALS, CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL5, "0x%X;CSqlBackupClient::RestoreBaseDataSectionL;END;bak=%S;db=%S;err=%d", (TUint)this, __SQLPRNSTR(bak), __SQLPRNSTR(db), err));
if(err == KErrNone || err == KErrNotFound)
{
// now, rename the .rst as .db
@@ -620,7 +661,6 @@
//its owner. Then "TInt err=iInterface->Fs().Rename(db,bak);" will fail again.
err2 = err;
}
-
// if we got here, we have a backup of the original database in .db.bak
// and the new database in .db
}//end of for(...)
@@ -637,6 +677,7 @@
// files that belong together and not bits of old and new
__SQLLEAVE_IF_ERROR(iInterface->Fs().GetDir(KBackupFilter,KEntryAttNormal,ESortNone,dir));
CleanupStack::PushL(dir);
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL6, "0x%X;CSqlBackupClient::RestoreBaseDataSectionL;bak files count=%d", (TUint)this, dir->Count()));
for(TInt a1=0;a1<dir->Count();++a1)
{
TEntry entry=(*dir)[a1];
@@ -675,6 +716,7 @@
// rename all the .bak files to .db
CDir *dir=NULL;
TInt rc=iInterface->Fs().GetDir(KBackupFilter,KEntryAttNormal,ESortNone,dir);
+ SQL_TRACE_BUR(OstTraceExt3(TRACE_INTERNALS, CSQLBACKUPCLIENT_TERMINATEMULTISTAGEOPERATION1, "0x%X;CSqlBackupClient::TerminateMultiStageOperation;Fs().GetDir() err=%d;file count=%d", (TUint)this, rc, rc == KErrNone ? dir->Count() : 0));
if(KErrNone!=rc)
{
// can't get a file list - can't do anything
@@ -695,7 +737,7 @@
//and continue with the next file.
if(KErrNone != rc)
{
- RDebug::Print(_L(" *** CSqlBackupClient::TerminateMultiStageOperation(), file \"%S\", err=%d\r\n"), &db, rc);
+ SQL_TRACE_BUR(OstTraceExt4(TRACE_INTERNALS, CSQLBACKUPCLIENT_TERMINATEMULTISTAGEOPERATION2, "0x%X;CSqlBackupClient::TerminateMultiStageOperation;Fs().Rename() err=%d;bak=%S;db=%S", (TUint)this, rc, __SQLPRNSTR(bak), __SQLPRNSTR(db)));
}
// backup restored ok
}
@@ -783,6 +825,7 @@
*/
void CSqlBackupClient::GetBackupListL(TSecureId aSid)
{
+ SQL_TRACE_BUR(OstTraceExt2(TRACE_INTERNALS, CSQLBACKUPCLIENT_GETBACKUPLISTL, "0x%X;CSqlBackupClient::GetBackupListL;aSid=0x%X", (TUint)this, (TUint)aSid.iId));
// we own the array - the SQL server just populates it
iInterface->GetBackUpListL(aSid,iFileList);
}
@@ -843,9 +886,9 @@
//
void CSqlBackupClient::CopyBufData(const TDesC8& aInBuf, TInt& aInBufReadPos, TDes& aOutBuf, TInt aDataLen)
{
- __SQLASSERT(aInBufReadPos >= 0, ESqlPanicBadArgument);
- __SQLASSERT(aDataLen > 0, ESqlPanicBadArgument);
- __SQLASSERT(!(aInBuf.Length() & 0x01), ESqlPanicInternalError);
+ __ASSERT_DEBUG(aInBufReadPos >= 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aDataLen > 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(!(aInBuf.Length() & 0x01), __SQLPANIC(ESqlPanicInternalError));
TInt needed = (aDataLen - aOutBuf.Length()) << K8to16bitShift;
TInt available = aInBuf.Size() - aInBufReadPos;
--- a/persistentstorage/sql/SRC/Server/SqlSrvAuthorizer.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvAuthorizer.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -154,7 +154,7 @@
//The function returns the argument number where the table name is.
inline TInt DbOp2TableNameArgIndex(TInt aDbOpType)
{
- __SQLASSERT(aDbOpType > 0 && aDbOpType <= SQLITE_FUNCTION, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbOpType > 0 && aDbOpType <= SQLITE_FUNCTION, __SQLPANIC2(ESqlPanicInternalError));
return KTableNameArgIndex[aDbOpType];
}
@@ -165,12 +165,12 @@
TInt pos = DbOp2TableNameArgIndex(aDbOpType);
if(pos == 2)
{
- __SQLASSERT(aDbObjName2 != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbObjName2 != NULL, __SQLPANIC2(ESqlPanicInternalError));
return aDbObjName2;
}
else if(pos == 1)
{
- __SQLASSERT(aDbObjName1 != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbObjName1 != NULL, __SQLPANIC2(ESqlPanicInternalError));
return aDbObjName1;
}
return NULL;//Some database operations do not use table name
@@ -182,7 +182,7 @@
{
if(aDbOpType == SQLITE_DETACH || aDbOpType == SQLITE_ALTER_TABLE)
{
- __SQLASSERT(aDbObjName1 != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbObjName1 != NULL, __SQLPANIC2(ESqlPanicInternalError));
return aDbObjName1;
}
return aDbName;//It may be NULL for some database operations
@@ -298,7 +298,7 @@
// case SQLITE_CREATE_VTABLE:
// case SQLITE_DROP_VTABLE:
default:
- __SQLASSERT(EFalse, ESqlPanicInternalError);
+ __ASSERT_DEBUG(EFalse, __SQLPANIC2(ESqlPanicInternalError));
break;
}
return res;
@@ -428,7 +428,7 @@
// case SQLITE_CREATE_VTABLE:
// case SQLITE_DROP_VTABLE:
default:
- __SQLASSERT(EFalse, ESqlPanicInternalError);
+ __ASSERT_DEBUG(EFalse, __SQLPANIC2(ESqlPanicInternalError));
break;
}
return res;
@@ -503,9 +503,9 @@
const char* aDbName, const char* aTrgOrViewName)
{
UNUSED_ARG(aTrgOrViewName);
- __SQLASSERT(aDb != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDb != NULL, __SQLPANIC2(ESqlPanicBadArgument));
-#ifdef _NOTIFY
+#ifdef _SQL_AUTHORIZER_TRACE_ENABLED
enum TDbOpType {EOpCreateIndex = 1, EOpCreateTable, EOpCreateTempIndex, EOpCreateTempTable,
EOpCreateTempTrigger, EOpCreateTempView, EOpCreateTrigger, EOpCreateView, EOpDelete, EOpDropIndex,
EOpDropTable, EOpDropTempIndex, EOpDropTempTable, EOpDropTempTrigger, EOpDropTempView, EOpDropTrigger,
@@ -513,7 +513,7 @@
EOpAlterTable, EOpReindex, EOpAnalyze, EOpCreateVTable, EOpDropVTable, EOpFunctionCall};
TDbOpType dbOpType = static_cast <TDbOpType> (aDbOpType);//can be seen now in the debugger
::PrintAuthorizerArguments(dbOpType, aDbObjName1, aDbObjName2, aDbName, aTrgOrViewName);
-#endif//_NOTIFY
+#endif
CSqlSrvDatabase& db = *static_cast <CSqlSrvDatabase*> (aDb);
--- a/persistentstorage/sql/SRC/Server/SqlSrvBlob.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvBlob.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -14,12 +14,19 @@
//
#include "sqlite3.h"
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlSrvBlob.h"
#include "SqliteSymbian.h"
#include "SqlSrvUtil.h"
#include "SqlSrvStrings.h"
#include "SqlDb.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSrvBlobTraces.h"
+#endif
+#include "SqlTraceDef.h"
+
+#define UNUSED_VAR(var) var = var
/**
Creates a new HBlobBuf instance.
@@ -45,14 +52,19 @@
*/
HBlobBuf* HBlobBuf::NewL(sqlite3* aDb, const TDesC8& aDbName, const TDesC8& aTableName, const TDesC8& aColumnName, TInt64 aRowId, TMode aMode)
{
- __SQLASSERT(aDb != NULL, ESqlPanicBadArgument);
- __SQLASSERT(aRowId > 0, ESqlPanicBadArgument);
- __SQLASSERT(aMode == HBlobBuf::EReadOnly || aMode == HBlobBuf::EReadWrite, ESqlPanicBadArgument);
+ __SQLTRACE_BLOBVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_BLOB(OstTraceExt4(TRACE_INTERNALS, HBLOBBUF_NEWL_ENTRY1, "Entry;0;HBlobBuf::NewL;sqlite3*=0x%X;aDbName=%s;aRowId=%lld;aMode=%d", (TUint)aDb, __SQLPRNSTR8(aDbName, des16prnbuf), aRowId, (TInt)aMode));
+ SQL_TRACE_BLOB(OstTraceExt1(TRACE_INTERNALS, HBLOBBUF_NEWL_ENTRY2, "Entry;0;HBlobBuf::NewL;aTableName=%s", __SQLPRNSTR8(aTableName, des16prnbuf)));
+ SQL_TRACE_BLOB(OstTraceExt1(TRACE_INTERNALS, HBLOBBUF_NEWL_ENTRY3, "Entry;0;HBlobBuf::NewL;aColumnName=%s", __SQLPRNSTR8(aColumnName, des16prnbuf)));
+ __ASSERT_DEBUG(aDb != NULL, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aRowId > 0, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aMode == HBlobBuf::EReadOnly || aMode == HBlobBuf::EReadWrite, __SQLPANIC2(ESqlPanicBadArgument));
HBlobBuf* self = new (ELeave) HBlobBuf;
CleanupStack::PushL(self);
self->ConstructL(aDb, aDbName, aTableName, aColumnName, aRowId, aMode);
CleanupStack::Pop(self);
+ SQL_TRACE_BLOB(OstTraceExt2(TRACE_INTERNALS, HBLOBBUF_NEWL_EXIT, "Exit;0x%X;HBlobBuf::NewL;sqlite3_blob*=0x%X", (TUint)self, (TUint)self->iBlobHandle));
return self;
}
@@ -89,16 +101,16 @@
*/
void HBlobBuf::ConstructL(sqlite3* aDb, const TDesC8& aDbName, const TDesC8& aTableName, const TDesC8& aColumnName, TInt64 aRowId, TMode aMode)
{
- __SQLASSERT(aDb != NULL, ESqlPanicBadArgument);
- __SQLASSERT(aRowId > 0, ESqlPanicBadArgument);
- __SQLASSERT(aMode == HBlobBuf::EReadOnly || aMode == HBlobBuf::EReadWrite, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDb != NULL, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aRowId > 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aMode == HBlobBuf::EReadOnly || aMode == HBlobBuf::EReadWrite, __SQLPANIC(ESqlPanicBadArgument));
(void)sqlite3SymbianLastOsError();//clear last OS error
TInt err = sqlite3_blob_open(aDb, (const char*)aDbName.Ptr(), (const char*)aTableName.Ptr(), (const char*)aColumnName.Ptr(),
aRowId, aMode & HBlobBuf::EReadWrite, &iBlobHandle);
__SQLLEAVE_IF_ERROR(::Sql2OsErrCode(err, sqlite3SymbianLastOsError()));
- __SQLASSERT(iBlobHandle != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBlobHandle != NULL, __SQLPANIC(ESqlPanicInternalError));
iBlobSize = sqlite3_blob_bytes(iBlobHandle);
iWrPos = iRdPos = 0;
}
@@ -108,8 +120,11 @@
*/
void HBlobBuf::DoRelease()
{
- TRAP_IGNORE(DoSynchL());
- }
+ SQL_TRACE_BLOB(OstTraceExt2(TRACE_INTERNALS, HBLOBBUF_DORELEASE_ENTRY, "Entry;0x%X;HBlobBuf::DoRelease;sqlite3_blob*=0x%X", (TUint)this, (TUint)iBlobHandle));
+ TRAPD(err, DoSynchL());
+ SQL_TRACE_BLOB(OstTraceExt2(TRACE_INTERNALS, HBLOBBUF_DORELEASE_EXIT, "Exit;0x%X;HBlobBuf::DoRelease;err=%d", (TUint)this, err));
+ UNUSED_VAR(err);
+ }
/**
Closes the blob handle.
@@ -120,6 +135,7 @@
if(iBlobHandle)
{
TInt err = sqlite3_blob_close(iBlobHandle);
+ SQL_TRACE_BLOB(OstTraceExt2(TRACE_INTERNALS, HBLOBBUF_DOSYNCHL, "0x%X;HBlobBuf::DoSynchL;err=%d", (TUint)this, err));
iBlobHandle = NULL; // the close is unconditional, even if an error occurs
__SQLLEAVE_IF_ERROR(::Sql2OsErrCode(err, sqlite3SymbianLastOsError()));
}
@@ -145,9 +161,11 @@
*/
TInt HBlobBuf::DoReadL(TAny* aPtr, TInt aMaxLength)
{
- __SQLASSERT(aPtr != NULL, ESqlPanicBadArgument);
- __SQLASSERT(aMaxLength >= 0, ESqlPanicBadArgument);
- __SQLASSERT(iBlobHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(aPtr != NULL, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aMaxLength >= 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(iBlobHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+
+ SQL_TRACE_BLOB(OstTraceExt5(TRACE_INTERNALS, HBLOBBUF_DOREADL, "0x%X;HBlobBuf::DoReadL;aMaxLength=%d;iBlobSize=%d;iWrPos=%d;iRdPos=%d", (TUint)this, aMaxLength, iBlobSize, iWrPos, iRdPos));
if(aMaxLength <= 0)
{
@@ -188,9 +206,11 @@
*/
void HBlobBuf::DoWriteL(const TAny* aPtr, TInt aLength)
{
- __SQLASSERT(aPtr != NULL, ESqlPanicBadArgument);
- __SQLASSERT(aLength >= 0, ESqlPanicBadArgument);
- __SQLASSERT(iBlobHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(aPtr != NULL, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aLength >= 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(iBlobHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+
+ SQL_TRACE_BLOB(OstTraceExt5(TRACE_INTERNALS, HBLOBBUF_DOWRITEL, "0x%X;HBlobBuf::DoWriteL;aLength=%d;iBlobSize=%d;iWrPos=%d;iRdPos=%d", (TUint)this, aLength, iBlobSize, iWrPos, iRdPos));
if(aLength <= 0)
{
@@ -227,9 +247,10 @@
*/
TStreamPos HBlobBuf::DoSeekL(MStreamBuf::TMark aMark, TStreamLocation aLocation, TInt aOffset)
{
- __SQLASSERT_ALWAYS(!(aMark & ~(ERead | EWrite)), ESqlPanicStreamMarkInvalid);
- __SQLASSERT(aOffset >= 0, ESqlPanicBadArgument);
- __SQLASSERT(iBlobHandle != NULL, ESqlPanicInvalidObj);
+ SQL_TRACE_BLOB(OstTraceExt5(TRACE_INTERNALS, HBLOBBUF_DOSEEKL, "0x%X;HBlobBuf::DoSeekL;aMark=%d;aLocation=%d;aOffset=%d;iBlobSize=%d", (TUint)this, (TInt)aMark, (TInt)aLocation, aOffset, iBlobSize));
+ __ASSERT_ALWAYS(!(aMark & ~(ERead | EWrite)), __SQLPANIC(ESqlPanicStreamMarkInvalid));
+ __ASSERT_DEBUG(aOffset >= 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(iBlobHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
TInt newPos = 0;
switch(aLocation)
@@ -244,7 +265,7 @@
newPos = iBlobSize + aOffset;
break;
default:
- __SQLASSERT(0, ESqlPanicStreamLocationInvalid);
+ __ASSERT_DEBUG(0, __SQLPANIC(ESqlPanicStreamLocationInvalid));
newPos = -1;
break;
}
--- a/persistentstorage/sql/SRC/Server/SqlSrvCollation.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvCollation.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -16,7 +16,7 @@
//
#include "SqlSrvCollation.h"
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlUtil.h"
#include "sqlite3.h"
#include "SqliteSymbian.h" //sqlite3SymbianLastOsError()
@@ -155,7 +155,7 @@
TSqlCollationUtil::TSqlCollationUtil(sqlite3* aDbHandle) :
iDbHandle(aDbHandle)
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicBadArgument));
}
/**
@@ -194,7 +194,7 @@
*/
void TSqlCollationUtil::InstallCollationsL()
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
(void)sqlite3SymbianLastOsError();//clear last OS error
//Register user defined collations
for(TInt i=0;i<KCollationMethodCount;++i)
@@ -224,6 +224,6 @@
*/
TPtrC TSqlCollationUtil::CollationName(TInt aIndex) const
{
- __SQLASSERT((TUint)aIndex < KCollationMethodCount, ESqlPanicBadArgument);
+ __ASSERT_DEBUG((TUint)aIndex < KCollationMethodCount, __SQLPANIC(ESqlPanicBadArgument));
return TPtrC(KCollationMethodName[aIndex]);
}
--- a/persistentstorage/sql/SRC/Server/SqlSrvConfig.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvConfig.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -16,6 +16,11 @@
#include <f32file64.h>
#include "SqlSrvConfig.h"
#include "SqlSrvUtil.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSrvConfigTraces.h"
+#endif
+#include "SqlTraceDef.h"
/**
Initializes TSqlSrvConfigParams data members with their default values.
@@ -46,11 +51,15 @@
*/
void TSqlSrvConfig::InitL(RFs& aFs, const TDesC& aFileName)
{
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, TSQLSRVCONFIGFILE_INITL_ENTRY, "Entry;0;TSqlSrvConfig::InitL;aFs.Handle()=0x%X;aFileName=%S", (TUint)aFs.Handle(), __SQLPRNSTR(aFileName)));
if(::FileExists(aFs, aFileName))
{
+ SQL_TRACE_INTERNALS(OstTrace0(TRACE_INTERNALS, TSQLSRVCONFIGFILE_INITL1, "0;TSqlSrvConfig::InitL;Config file found"));
TBuf8<KSqlSrvMaxConfigStrLen> configFileStr;
//Step 1: get the config string from the config file and store the string in configFileStr
TSqlSrvConfig::GetConfigStringFromFileL(aFs, aFileName, configFileStr);
+ __SQLTRACE_INTERNALSVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_INTERNALS(OstTraceExt1(TRACE_INTERNALS, TSQLSRVCONFIGFILE_INITL2, "0;TSqlSrvConfig::InitL;Config file string=%s", __SQLPRNSTR8(configFileStr, des16prnbuf)));
//Step 2: extract config file parameters from the string (configFileStr) and store them in iConfigFileParams
TSqlSrvConfig::ExtractConfigParamsFromStringL(configFileStr, iConfigFileParams);
}
@@ -64,6 +73,13 @@
{
iConfigFileParams.iFreePageThresholdKb = KSqlCompactFreePageThresholdKb;
}
+
+#ifdef _SQL_RDEBUG_PRINT
+ SQL_TRACE_INTERNALS(OstTraceExt4(TRACE_INTERNALS, TSQLSRVCONFIGFILE_INITL_EXIT1, "Exit;0;TSqlSrvConfig::InitL;iCacheSize=%d;iPageSize=%d;iDbEncoding=%d;iSoftHeapLimit=%d", iConfigFileParams.iCacheSize, iConfigFileParams.iPageSize, iConfigFileParams.iDbEncoding, iConfigFileParams.iSoftHeapLimitKb));
+#else
+ SQL_TRACE_INTERNALS(OstTraceExt4(TRACE_INTERNALS, TSQLSRVCONFIGFILE_INITL_EXIT2, "Exit;0;TSqlSrvConfig::InitL;iCacheSize=%d;iPageSize=%d;iDbEncoding=%{TSqlSrvConfig_TDbEncoding};iSoftHeapLimit=%d", iConfigFileParams.iCacheSize, iConfigFileParams.iPageSize, iConfigFileParams.iDbEncoding, iConfigFileParams.iSoftHeapLimitKb));
+#endif
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, TSQLSRVCONFIGFILE_INITL_EXIT3, "Exit;0;TSqlSrvConfig::InitL;iCompactionMode=%d;iFreePageThresholdKb=%d", iConfigFileParams.iCompactionMode, iConfigFileParams.iFreePageThresholdKb));
}
/**
@@ -82,6 +98,8 @@
*/
void TSqlSrvConfig::GetConfigParamsL(const TDesC8& aConfigStr, TSqlSrvConfigParams& aConfigParams) const
{
+ __SQLTRACE_INTERNALSVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_INTERNALS(OstTraceExt1(TRACE_INTERNALS, TSQLSRVCONFIGFILE_GETCONFIGPARAMSL_ENTRY, "Entry;0;TSqlSrvConfig::GetConfigParamsL;aConfigStr=%s", __SQLPRNSTR8(aConfigStr, des16prnbuf)));
TSqlSrvConfigParams tmpConfigParams;
//Step 1: extract configuration parameters from aConfigStr, store them in tmpConfigParams.
TSqlSrvConfig::ExtractConfigParamsFromStringL(aConfigStr, tmpConfigParams);
@@ -111,18 +129,24 @@
//Step 5: set the free page threshold.
aConfigParams.iFreePageThresholdKb = iConfigFileParams.iFreePageThresholdKb;
//Step 6: assert the parameter values.
- __SQLASSERT(aConfigParams.iPageSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iPageSize >= 0, ESqlPanicInternalError);
- __SQLASSERT(aConfigParams.iCacheSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iCacheSize >= 0, ESqlPanicInternalError);
- __SQLASSERT(aConfigParams.iDbEncoding == TSqlSrvConfigParams::EEncNotSet ||
+ __ASSERT_DEBUG(aConfigParams.iPageSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iPageSize >= 0, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aConfigParams.iCacheSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iCacheSize >= 0, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aConfigParams.iDbEncoding == TSqlSrvConfigParams::EEncNotSet ||
aConfigParams.iDbEncoding == TSqlSrvConfigParams::EEncUtf8 ||
- aConfigParams.iDbEncoding == TSqlSrvConfigParams::EEncUtf16, ESqlPanicInternalError);
- __SQLASSERT(aConfigParams.iSoftHeapLimitKb == TSqlSrvConfigParams::KConfigPrmValueNotSet ||
+ aConfigParams.iDbEncoding == TSqlSrvConfigParams::EEncUtf16, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aConfigParams.iSoftHeapLimitKb == TSqlSrvConfigParams::KConfigPrmValueNotSet ||
(aConfigParams.iSoftHeapLimitKb >= TSqlSrvConfigParams::KMinSoftHeapLimitKb &&
- aConfigParams.iSoftHeapLimitKb <= TSqlSrvConfigParams::KMaxSoftHeapLimitKb), ESqlPanicInternalError);
- __SQLASSERT(aConfigParams.iCompactionMode == ESqlCompactionNotSet || aConfigParams.iCompactionMode == ESqlCompactionManual ||
- aConfigParams.iCompactionMode == ESqlCompactionBackground || aConfigParams.iCompactionMode == ESqlCompactionAuto, ESqlPanicInternalError);
- __SQLASSERT(aConfigParams.iFreePageThresholdKb == TSqlSrvConfigParams::KConfigPrmValueNotSet ||
- aConfigParams.iFreePageThresholdKb >= 0, ESqlPanicInternalError);
+ aConfigParams.iSoftHeapLimitKb <= TSqlSrvConfigParams::KMaxSoftHeapLimitKb), __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aConfigParams.iCompactionMode == ESqlCompactionNotSet || aConfigParams.iCompactionMode == ESqlCompactionManual ||
+ aConfigParams.iCompactionMode == ESqlCompactionBackground || aConfigParams.iCompactionMode == ESqlCompactionAuto, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aConfigParams.iFreePageThresholdKb == TSqlSrvConfigParams::KConfigPrmValueNotSet ||
+ aConfigParams.iFreePageThresholdKb >= 0, __SQLPANIC(ESqlPanicInternalError));
+#ifdef _SQL_RDEBUG_PRINT
+ SQL_TRACE_INTERNALS(OstTraceExt4(TRACE_INTERNALS, TSQLSRVCONFIGFILE_GETCONFIGPARAMSL_EXIT1, "Exit;0;TSqlSrvConfig::GetConfigParamsL;cacheSize=%d;pageSize=%d;dbEncoding=%d;softHeapLimit=%d", aConfigParams.iCacheSize, aConfigParams.iPageSize, aConfigParams.iDbEncoding, aConfigParams.iSoftHeapLimitKb));
+#else
+ SQL_TRACE_INTERNALS(OstTraceExt4(TRACE_INTERNALS, TSQLSRVCONFIGFILE_GETCONFIGPARAMSL_EXIT2, "Exit;0;TSqlSrvConfig::GetConfigParamsL;cacheSize=%d;pageSize=%d;dbEncoding=%{TSqlSrvConfig_TDbEncoding};softHeapLimit=%d", aConfigParams.iCacheSize, aConfigParams.iPageSize, aConfigParams.iDbEncoding, aConfigParams.iSoftHeapLimitKb));
+#endif
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, TSQLSRVCONFIGFILE_GETCONFIGPARAMSL_EXIT3, "Exit;0;TSqlSrvConfig::GetConfigParamsL;compactionMode=%d;freePageThresholdKb=%d", aConfigParams.iCompactionMode, aConfigParams.iFreePageThresholdKb));
}
//The function opeans the aFileName config file and reads the config string, storring it in aConfigStr argument.
@@ -133,10 +157,10 @@
//The function may leave if some of the file I/O operations (open file, read file) fails.
void TSqlSrvConfig::GetConfigStringFromFileL(RFs& aFs, const TDesC& aFileName, TDes8& aConfigStr)
{
- __SQLASSERT(aConfigStr.MaxLength() >= KSqlSrvMaxConfigStrLen, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aConfigStr.MaxLength() >= KSqlSrvMaxConfigStrLen, __SQLPANIC2(ESqlPanicBadArgument));
RFile64 cfgFile;
CleanupClosePushL(cfgFile);
- __SQLLEAVE_IF_ERROR(cfgFile.Open(aFs, aFileName, EFileRead));
+ __SQLLEAVE_IF_ERROR2(cfgFile.Open(aFs, aFileName, EFileRead));
TFileText cfgFileReader;
cfgFileReader.Set(cfgFile);
TBuf<KSqlSrvMaxConfigStrLen> buf;
@@ -156,13 +180,13 @@
CleanupStack::PopAndDestroy(&cfgFile);
if(err != KErrEof)
{//The "read configuration file" operation has failed with "err" (if err != KErrNone)
- __SQLLEAVE_IF_ERROR(err);
+ __SQLLEAVE_IF_ERROR2(err);
}
if(!cfgLineFound)
{//End of config file reached - no valid configuration line found.
- __SQLLEAVE(KErrEof);
+ __SQLLEAVE2(KErrEof);
}
- __SQLASSERT(err == KErrNone || err == KErrEof, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err == KErrNone || err == KErrEof, __SQLPANIC2(ESqlPanicInternalError));
aConfigStr.Copy(buf);
}
@@ -184,18 +208,18 @@
}
}
//Assert the extracted parameter values.
- __SQLASSERT(aConfigParams.iPageSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iPageSize >= 0, ESqlPanicInternalError);
- __SQLASSERT(aConfigParams.iCacheSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iCacheSize >= 0, ESqlPanicInternalError);
- __SQLASSERT(aConfigParams.iDbEncoding == TSqlSrvConfigParams::EEncNotSet ||
+ __ASSERT_DEBUG(aConfigParams.iPageSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iPageSize >= 0, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aConfigParams.iCacheSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iCacheSize >= 0, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aConfigParams.iDbEncoding == TSqlSrvConfigParams::EEncNotSet ||
aConfigParams.iDbEncoding == TSqlSrvConfigParams::EEncUtf8 ||
- aConfigParams.iDbEncoding == TSqlSrvConfigParams::EEncUtf16, ESqlPanicInternalError);
- __SQLASSERT(aConfigParams.iSoftHeapLimitKb == TSqlSrvConfigParams::KConfigPrmValueNotSet ||
+ aConfigParams.iDbEncoding == TSqlSrvConfigParams::EEncUtf16, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aConfigParams.iSoftHeapLimitKb == TSqlSrvConfigParams::KConfigPrmValueNotSet ||
(aConfigParams.iSoftHeapLimitKb >= TSqlSrvConfigParams::KMinSoftHeapLimitKb &&
- aConfigParams.iSoftHeapLimitKb <= TSqlSrvConfigParams::KMaxSoftHeapLimitKb), ESqlPanicInternalError);
- __SQLASSERT(aConfigParams.iCompactionMode == ESqlCompactionNotSet || aConfigParams.iCompactionMode == ESqlCompactionManual ||
- aConfigParams.iCompactionMode == ESqlCompactionBackground || aConfigParams.iCompactionMode == ESqlCompactionAuto, ESqlPanicInternalError);
- __SQLASSERT(aConfigParams.iFreePageThresholdKb == TSqlSrvConfigParams::KConfigPrmValueNotSet ||
- aConfigParams.iFreePageThresholdKb >= 0, ESqlPanicInternalError);
+ aConfigParams.iSoftHeapLimitKb <= TSqlSrvConfigParams::KMaxSoftHeapLimitKb), __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aConfigParams.iCompactionMode == ESqlCompactionNotSet || aConfigParams.iCompactionMode == ESqlCompactionManual ||
+ aConfigParams.iCompactionMode == ESqlCompactionBackground || aConfigParams.iCompactionMode == ESqlCompactionAuto, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aConfigParams.iFreePageThresholdKb == TSqlSrvConfigParams::KConfigPrmValueNotSet ||
+ aConfigParams.iFreePageThresholdKb >= 0, __SQLPANIC2(ESqlPanicInternalError));
}
//The function searches aConfigStr arguments for "PARAM=VALUE;" pair. If such pair is found, then
@@ -237,7 +261,7 @@
pos = prmText.Locate(KAssignment);
if(pos < 0 || pos >= (prmText.Length() - 1))
{
- __SQLLEAVE(KErrArgument);
+ __SQLLEAVE2(KErrArgument);
}
//we've got now prmText pointing to a " PARAM = VALUE " string.
aParamName.Set(TSqlSrvConfig::TrimAndConstructPtr(prmText.Ptr(), pos));
@@ -289,7 +313,7 @@
TInt err = lex.Val(cacheSize);
if(err != KErrNone || cacheSize < 0) //The correct check is for "<=0", but it has to be backward
{ //compatible with the previous implementation
- __SQLLEAVE(KErrArgument);
+ __SQLLEAVE2(KErrArgument);
}
return cacheSize;
}
@@ -303,7 +327,7 @@
TInt err = lex.Val(pageSize);
if(err != KErrNone || pageSize < 0) //The correct check is for "<0", "power of 2", "between 512 and 32768",
{ //but it has to be backward compatible with the previous implementation
- __SQLLEAVE(KErrArgument);
+ __SQLLEAVE2(KErrArgument);
}
return pageSize;
}
@@ -336,7 +360,7 @@
if(err != KErrNone || softHeapLimitKb < 0 ||
(softHeapLimitKb < TSqlSrvConfigParams::KMinSoftHeapLimitKb || softHeapLimitKb > TSqlSrvConfigParams::KMaxSoftHeapLimitKb))
{
- __SQLLEAVE(KErrArgument);
+ __SQLLEAVE2(KErrArgument);
}
return softHeapLimitKb;
}
@@ -372,7 +396,7 @@
TInt err = lex.Val(freePageThreshold);
if(err != KErrNone || freePageThreshold < 0)
{
- __SQLLEAVE(KErrArgument);
+ __SQLLEAVE2(KErrArgument);
}
return freePageThreshold;
}
@@ -383,8 +407,8 @@
//aStr content without leading and trailing whitespace characters.
TPtrC8 TSqlSrvConfig::TrimAndConstructPtr(const TUint8* aStr, TInt aLength)
{
- __SQLASSERT(aStr != NULL, ESqlPanicBadArgument);
- __SQLASSERT(aLength >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aStr != NULL, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aLength >= 0, __SQLPANIC2(ESqlPanicBadArgument));
//Trim left
for(;aLength>0;--aLength,++aStr)
{
--- a/persistentstorage/sql/SRC/Server/SqlSrvConfig.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvConfig.h Tue Aug 31 16:57:14 2010 +0300
@@ -18,7 +18,7 @@
#include <e32std.h>
#include <f32file.h>
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlUtil.h"
//Forward declarations
@@ -54,8 +54,7 @@
KDefaultSoftHeapLimitKb = 1024,
#else
KDefaultSoftHeapLimitKb = 8192,
-#endif
-
+#endif
#ifdef SYSLIBS_TEST
KMinSoftHeapLimitKb = 8,
#else
--- a/persistentstorage/sql/SRC/Server/SqlSrvDatabase.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvDatabase.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -22,6 +22,11 @@
#include "SqlSrvUtil.h" //Global server functions
#include "SqlCompact.h"
#include "SqlSrvResourceProfiler.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSrvDatabaseTraces.h"
+#endif
+#include "SqlTraceDef.h"
//
// The following macro disables the creation/loading of the settings table.
@@ -86,7 +91,7 @@
//aRight argument is NULL.
static TInt Compare(const TSqlAttachDbPair& aLeft, const TSqlAttachDbPair& aRight)
{
- __SQLASSERT(aLeft.iKey != NULL && aRight.iKey != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aLeft.iKey != NULL && aRight.iKey != NULL, __SQLPANIC2(ESqlPanicInternalError));
return ::CompareNoCase8(TPtrC8(aLeft.iKey), TPtrC8(aRight.iKey));
}
@@ -101,7 +106,7 @@
//aRight argument is NULL.
static TInt Compare2(const TSqlCompactDbPair& aLeft, const TSqlCompactDbPair& aRight)
{
- __SQLASSERT(aLeft.iKey != NULL && aRight.iKey != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aLeft.iKey != NULL && aRight.iKey != NULL, __SQLPANIC2(ESqlPanicInternalError));
return ::CompareNoCase(*aLeft.iKey, *aRight.iKey);
}
@@ -115,13 +120,13 @@
TBuf8<KMaxFileName + 1> fileNameZ;
if(!::UTF16ZToUTF8Z(aFileData.FileNameZ(), fileNameZ))
{
- __SQLLEAVE(KErrGeneral);
+ __SQLLEAVE2(KErrGeneral);
}
- __SQLLEAVE_IF_ERROR(::CreateDbHandle8(fileNameZ, aDbHandle));
+ __SQLLEAVE_IF_ERROR2(::CreateDbHandle8(fileNameZ, aDbHandle));
}
else
{
- __SQLLEAVE_IF_ERROR(::CreateDbHandle16(aFileData.FileNameZ(), aDbHandle));
+ __SQLLEAVE_IF_ERROR2(::CreateDbHandle16(aFileData.FileNameZ(), aDbHandle));
}
}
@@ -153,7 +158,7 @@
//The function is used to read the security policy of the main database.
static CSqlSecurityPolicy* LoadDbSecurityPolicyLC(sqlite3* aDbHandle)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicBadArgument));
//Create new database security policy object and initialize it with a default security policy
TSecurityPolicy defaultPolicy(TSecurityPolicy::EAlwaysFail);
CSqlSecurityPolicy* dbPolicy = CSqlSecurityPolicy::NewLC(defaultPolicy);
@@ -168,7 +173,7 @@
//The function panics in _DEBUG mode if aSrc is NULL.
static TUint8* CreateStrCopyLC(const TUint8* aSrc)
{
- __SQLASSERT(aSrc != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aSrc != NULL, __SQLPANIC2(ESqlPanicBadArgument));
TInt len = User::StringLength(aSrc) + 1;
TUint8* copy = new (ELeave) TUint8[len];
Mem::Copy(copy, aSrc, len);
@@ -180,7 +185,7 @@
//during the stack cleanup.
static void EnableAuthorizer(void* aAuthorizerDisabled)
{
- __SQLASSERT(aAuthorizerDisabled != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aAuthorizerDisabled != NULL, __SQLPANIC2(ESqlPanicBadArgument));
TBool* authorizerDisabled = static_cast <TBool*> (aAuthorizerDisabled);
*authorizerDisabled = EFalse;
}
@@ -209,7 +214,7 @@
//CSqlSrvDatabase's ConstructL() method(s) leave (when creating a new database file).
static void DbFileCleanup(void* aDbFileCleanup)
{
- __SQLASSERT(aDbFileCleanup != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDbFileCleanup != NULL, __SQLPANIC2(ESqlPanicBadArgument));
TDbFileCleanup* dbFileCleanup = static_cast <TDbFileCleanup*> (aDbFileCleanup);
dbFileCleanup->Cleanup();
}
@@ -223,23 +228,26 @@
//During the call the authorizer will be disabled.
static TInt ExecPragma(sqlite3* aDbHandle, TBool& aAuthorizerDisabled, const TDesC& aPragma, TInt aValue, const TDesC& aDbName = KMainDb16)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicBadArgument);
+ __SQLTRACE_INTERNALSEXPR(TPtrC pragmaprnptr(aPragma.Left(aPragma.Length() - 1)));
+ SQL_TRACE_INTERNALS(OstTraceExt4(TRACE_INTERNALS, EXECPRAGMA_ENTRY, "Entry;0;ExecPragma;sqlite3*=0x%X;aPragma=%S;aValue=%d;aDbName=%S", (TUint)aDbHandle, __SQLPRNSTR(pragmaprnptr), aValue, __SQLPRNSTR(aDbName)));
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicBadArgument));
TBuf<KMaxFileName + 64> pragmaSql;//(KMaxFileName + 64) characters buffer length is enough for the longest possible PRAGMA statement
pragmaSql.Format(aPragma, &aDbName, aValue);
TBool authorizerDisabledState = aAuthorizerDisabled;
aAuthorizerDisabled = ETrue;
TInt err = DbExecStmt16(aDbHandle, pragmaSql);
aAuthorizerDisabled = authorizerDisabledState;
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, EXECPRAGMA_EXIT, "Exit;0;ExecPragma;sqlite3*=0x%X;err=%d", (TUint)aDbHandle, err));
return err;
}
//The journal size limit is set to be at lest 16 pages and no less than 64 Kb.
static void SetJournalSizeLimitL(sqlite3* aDbHandle, TBool& aAuthorizerDisabled, TInt aPageSize, const TDesC& aDbName = KMainDb16)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicBadArgument));
if(aPageSize == TSqlSrvConfigParams::KConfigPrmValueNotSet)
{
- __SQLLEAVE_IF_ERROR(DbPageSize(aDbHandle, aDbName, aPageSize));
+ __SQLLEAVE_IF_ERROR2(DbPageSize(aDbHandle, aDbName, aPageSize));
}
const TInt KPageMultiplier = 16;
const TInt KDefaultJournalSizeLimit = 64 * 1024;
@@ -247,7 +255,7 @@
const TInt KJournalSizeLimit = Min((aPageSize * KPageMultiplier), KMaxJournalSizeLimit);
if(KJournalSizeLimit > KDefaultJournalSizeLimit)
{
- __SQLLEAVE_IF_ERROR(::ExecPragma(aDbHandle, aAuthorizerDisabled, KJournalSizeLimitPragma, KJournalSizeLimit));
+ __SQLLEAVE_IF_ERROR2(::ExecPragma(aDbHandle, aAuthorizerDisabled, KJournalSizeLimitPragma, KJournalSizeLimit));
}
}
@@ -293,15 +301,16 @@
*/
CSqlSrvDatabase* CSqlSrvDatabase::CreateSecureL(const TSqlSrvFileData& aFileData, CSqlSecurityPolicy* aSecurityPolicy)
{
- __SQLASSERT(aFileData.IsSecureFileNameFmt(), ESqlPanicBadArgument);
- __SQLASSERT(aSecurityPolicy != NULL, ESqlPanicBadArgument);
+ SQL_TRACE_INTERNALS(OstTrace0(TRACE_INTERNALS, CSQLSRVDATABASE_CREATESECUREL_ENTRY, "Entry;0;CSqlSrvDatabase::CreateSecureL"));
+ __ASSERT_DEBUG(aFileData.IsSecureFileNameFmt(), __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aSecurityPolicy != NULL, __SQLPANIC2(ESqlPanicBadArgument));
if(!::SqlServer().SecurityInspector().Check(aSecurityPolicy->DbPolicy(RSqlSecurityPolicy::ESchemaPolicy)))
{
//The caller has no "SCHEMA" policy. Then the client is not given a permission to create the database.
//Delete aSecurityPolicy since no database object is going to be created and the security policy object
//won't be put in the security policies map.
delete aSecurityPolicy;
- __SQLLEAVE(KErrPermissionDenied);
+ __SQLLEAVE2(KErrPermissionDenied);
}
//What does happen with aSecurityPolicy instance?
// If the database is created successfully, then a lookup will be made in the security policies map.
@@ -324,6 +333,7 @@
CleanupStack::PushL(self);
self->ConstructCreateSecureL(aFileData, aSecurityPolicy);
CleanupStack::Pop(self);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_CREATESECUREL_EXIT, "Exit;0x%X;CSqlSrvDatabase::CreateSecureL;sqlite3*=0x%X", (TUint)self, (TUint)self->iDbHandle));
return self;
}
@@ -354,11 +364,13 @@
*/
CSqlSrvDatabase* CSqlSrvDatabase::CreateL(const TSqlSrvFileData& aFileData)
{
- __SQLASSERT(!aFileData.IsSecureFileNameFmt(), ESqlPanicBadArgument);
+ SQL_TRACE_INTERNALS(OstTrace0(TRACE_INTERNALS, CSQLSRVDATABASE_CREATEL_ENTRY, "Entry;0;CSqlSrvDatabase::CreateL"));
+ __ASSERT_DEBUG(!aFileData.IsSecureFileNameFmt(), __SQLPANIC2(ESqlPanicBadArgument));
CSqlSrvDatabase* self = new (ELeave) CSqlSrvDatabase();
CleanupStack::PushL(self);
self->ConstructCreateL(aFileData);
CleanupStack::Pop(self);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_CREATEL_EXIT, "Exit;0x%X;CSqlSrvDatabase::CreateL;sqlite3*=0x%X", (TUint)self, (TUint)self->iDbHandle));
return self;
}
@@ -393,10 +405,12 @@
*/
CSqlSrvDatabase* CSqlSrvDatabase::OpenL(const TSqlSrvFileData& aFileData)
{
+ SQL_TRACE_INTERNALS(OstTrace0(TRACE_INTERNALS, CSQLSRVDATABASE_OPENL_ENTRY, "Entry;0;CSqlSrvDatabase::OpenL"));
CSqlSrvDatabase* self = new (ELeave) CSqlSrvDatabase();
CleanupStack::PushL(self);
aFileData.IsSecureFileNameFmt() ? self->ConstructOpenSecureL(aFileData) : self->ConstructOpenL(aFileData);
CleanupStack::Pop(self);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_OPENL_EXIT, "Exit;0x%X;CSqlSrvDatabase::OpenL;sqlite3*=0x%X", (TUint)self, (TUint)self->iDbHandle));
return self;
}
@@ -405,12 +419,12 @@
*/
CSqlSrvDatabase::~CSqlSrvDatabase()
{
- SQLPROFILER_DB_CLOSE((TUint)iDbHandle);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_CSQLSRVDATABASE2_ENTRY, "Entry;0x%X;CSqlSrvDatabase::~CSqlSrvDatabase;sqlite3*=0x%X", (TUint)this, (TUint)iDbHandle));
TSqlCompactDbMapIterator compactDbIt(iCompactDbMap);
TSqlCompactDbPair compactDbPair;
while(compactDbIt.Next(compactDbPair))
{
- __SQLASSERT(compactDbPair.iData, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(compactDbPair.iData, __SQLPANIC2(ESqlPanicInvalidObj));
::SqlServer().Compactor().ReleaseEntry(*compactDbPair.iData);
}
iCompactDbMap.Close();
@@ -453,11 +467,12 @@
TSqlAttachDbPair attachDbPair;
while(it.Next(attachDbPair))
{
- __SQLASSERT(attachDbPair.iData, ESqlPanicInvalidObj);
- ::SqlServer().SecurityMap().Remove(attachDbPair.iData);
+ __ASSERT_DEBUG(attachDbPair.iData, __SQLPANIC2(ESqlPanicInvalidObj));
+ ::SqlServer().SecurityMap().Remove(attachDbPair.iData);
}
iAttachDbMap.Close();
::CloseDbHandle(iDbHandle);
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, CSQLSRVDATABASE_CSQLSRVDATABASE2_EXIT, "Exit;0x%X;CSqlSrvDatabase::~CSqlSrvDatabase", (TUint)this));
}
/**
@@ -495,6 +510,8 @@
*/
void CSqlSrvDatabase::CreateNewDbFileL(const TSqlSrvFileData& aFileData)
{
+ __SQLTRACE_INTERNALSVAR(TPtrC fname = aFileData.FileName());
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_CREATENEWDBFILEL, "0x%x;CSqlSrvDatabase::CreateNewDbFileL;fname=%S", (TUint)this, __SQLPRNSTR(fname)));
if(::FileExists(aFileData.Fs(), aFileData.FileName()))
{
__SQLLEAVE(KErrAlreadyExists);
@@ -530,6 +547,8 @@
*/
void CSqlSrvDatabase::OpenExistingDbFileL(const TSqlSrvFileData& aFileData)
{
+ __SQLTRACE_INTERNALSVAR(TPtrC fname = aFileData.FileName());
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_OPENEXISTINGDBFILEL, "0x%x;CSqlSrvDatabase::OpenExistingDbFileL;fname=%S", (TUint)this, __SQLPRNSTR(fname)));
if(!aFileData.ContainHandles())
{//This check is valid only if the database is outside application's private data cage
if(!::FileExists(aFileData.Fs(), aFileData.FileName()))
@@ -654,6 +673,7 @@
*/
void CSqlSrvDatabase::AttachDbL(const TSqlSrvFileData& aFileData, const TDesC& aDbName)
{
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_ATTACHDBL_ENTRY, "Entry;0x%X;CSqlSrvDatabase::AttachDbL;aDbName=%S", (TUint)this, __SQLPRNSTR(aDbName)));
if(!aFileData.ContainHandles())
{//This check is valid only if the database is outside application's private data cage
if(!::FileExists(aFileData.Fs(), aFileData.FileName()))
@@ -696,6 +716,7 @@
__SQLLEAVE(err);
}
}
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, CSQLSRVDATABASE_ATTACHDBL_EXIT, "Exit;0x%X;CSqlSrvDatabase::AttachDbL", (TUint)this));
}
/**
@@ -779,6 +800,7 @@
*/
void CSqlSrvDatabase::DetachDbL(const TDesC& aDbName)
{
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_DETACHDBL_ENTRY, "Entry;0x%X;CSqlSrvDatabase::DetachDbL;aDbName=%S", (TUint)this, __SQLPRNSTR(aDbName)));
TInt err = FinalizeAttachedDb(aDbName);
if(err == KErrNone)
{
@@ -788,6 +810,7 @@
{
__SQLLEAVE(err);
}
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, CSQLSRVDATABASE_DETACHDBL_EXIT, "Exit;0x%X;CSqlSrvDatabase::DetachDbL", (TUint)this));
}
/**
@@ -806,7 +829,7 @@
CleanupStack::PushL(TCleanupItem(&EnableAuthorizer, &iAuthorizerDisabled));
TInt pageCount = 0;
__SQLLEAVE_IF_ERROR(::DbPageCount(iDbHandle, aDbName, pageCount));
- __SQLASSERT(pageCount >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(pageCount >= 0, __SQLPANIC(ESqlPanicInternalError));
CleanupStack::PopAndDestroy();
return (TInt64)pageCount * PageSizeL(aDbName);
}
@@ -828,7 +851,7 @@
TInt freePageCount = 0;
__SQLLEAVE_IF_ERROR(::DbFreePageCount(iDbHandle, aDbName, freePageCount));
CleanupStack::PopAndDestroy();
- __SQLASSERT(freePageCount >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(freePageCount >= 0, __SQLPANIC(ESqlPanicInternalError));
return (TInt64)freePageCount * PageSizeL(aDbName);
}
@@ -892,7 +915,8 @@
*/
TInt CSqlSrvDatabase::CompactL(TInt aSize, const TDesC& aDbName)
{
- __SQLASSERT(aSize > 0 || aSize == RSqlDatabase::EMaxCompaction, ESqlPanicBadArgument);
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLSRVDATABASE_COMPACTL_ENTRY, "Entry;0x%X;CSqlSrvDatabase::CompactL;aSize=%d;aDbName=%S", (TUint)this, aSize, __SQLPRNSTR(aDbName)));
+ __ASSERT_DEBUG(aSize > 0 || aSize == RSqlDatabase::EMaxCompaction, __SQLPANIC(ESqlPanicBadArgument));
TInt pageSize = PageSizeL(aDbName);//PageSizeL() will disable/enable the authorizer
TInt pageCount = KMaxTInt;
if(aSize > 0)
@@ -906,6 +930,7 @@
__SQLLEAVE_IF_ERROR(::DbCompact(iDbHandle, aDbName, pageCount, pageCount));
CleanupStack::PopAndDestroy();
}
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLSRVDATABASE_COMPACTL_EXIT, "Exit;0x%X;CSqlSrvDatabase::CompactL;pageCount=%d;pageSize=%d", (TUint)this, pageCount, pageSize));
return pageCount * pageSize;
}
@@ -943,7 +968,7 @@
void CSqlSrvDatabase::AttachCleanup(void* aCleanup)
{
TAttachCleanup* cleanup = reinterpret_cast <TAttachCleanup*> (aCleanup);
- __SQLASSERT(cleanup != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(cleanup != NULL, __SQLPANIC2(ESqlPanicBadArgument));
(void)cleanup->iSelf.FinalizeAttachedDb(cleanup->iDbName);
}
@@ -1078,17 +1103,17 @@
{
//No, it is not in the map. Read the security policies from the security policies tables and
//insert a new item in the map.
- __SQLASSERT(aMapKey != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aMapKey != NULL, __SQLPANIC(ESqlPanicInternalError));
aMapKey = ::CreateStrCopyLC(aMapKey);
CSqlSecurityPolicy* securityPolicy = aAttachedDb ? ::LoadAttachedDbSecurityPolicyLC(aFileData) :
::LoadDbSecurityPolicyLC(iDbHandle);
- __SQLASSERT(!::SqlServer().SecurityMap().Entry(aMapKey), ESqlPanicObjExists);
+ __ASSERT_DEBUG(!::SqlServer().SecurityMap().Entry(aMapKey), __SQLPANIC2(ESqlPanicObjExists));
__SQLLEAVE_IF_ERROR(::SqlServer().SecurityMap().Insert(aMapKey, securityPolicy));
CleanupStack::Pop(2);//iSecurityMap owns aMapKey and securityPolicy objects
aSecurityPolicy = securityPolicy;
}
- __SQLASSERT(aMapKey != NULL, ESqlPanicInternalError);
- __SQLASSERT(aSecurityPolicy != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aMapKey != NULL, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aSecurityPolicy != NULL, __SQLPANIC(ESqlPanicInternalError));
}
/**
@@ -1117,6 +1142,7 @@
*/
void CSqlSrvDatabase::RemoveFromMapsL(const TDesC& aDbName)
{
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_REMOVEFROMMAPSL, "0x%X;CSqlSrvDatabase::RemoveFromMapsL;aDbName=%S", (TUint)this, __SQLPRNSTR(aDbName)));
TPtr8 ptr(iFileNameBuf, sizeof(iFileNameBuf));
if(!::UTF16ToUTF8Z(aDbName, ptr))
{
@@ -1147,6 +1173,7 @@
*/
void CSqlSrvDatabase::InsertInAttachDbMapL(const TDesC& aDbFileName, const TDesC& aDbName)
{
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLSRVDATABASE_INSERTINATTACHDBMAPL, "0x%X;CSqlSrvDatabase::InsertInAttachDbMapL;aDbFileName=%S;aDbName=%S", (TUint)this, __SQLPRNSTR(aDbFileName), __SQLPRNSTR(aDbName)));
//Convert aDbName to UTF8, zero-terminated name
TPtr8 ptr(iFileNameBuf, sizeof(iFileNameBuf));
if(!::UTF16ToUTF8Z(aDbName, ptr))
@@ -1156,7 +1183,7 @@
const TUint8* mapKey = ::CreateStrCopyLC(iFileNameBuf);
const TUint8* mapData = SecurityMapKeyL(aDbFileName);
mapData = ::CreateStrCopyLC(mapData);
- __SQLASSERT(!iAttachDbMap.Entry(mapKey), ESqlPanicObjExists);
+ __ASSERT_DEBUG(!iAttachDbMap.Entry(mapKey), __SQLPANIC(ESqlPanicObjExists));
__SQLLEAVE_IF_ERROR(iAttachDbMap.Insert(mapKey, mapData));
CleanupStack::Pop(2);//iAttachDbMap owns mapKey amd mapData.
}
@@ -1178,7 +1205,7 @@
*/
void CSqlSrvDatabase::ProcessSettingsL(const TSqlSrvFileData& aFileData, const TDesC& aDbName)
{
- __SQLASSERT(!aFileData.IsReadOnly(), ESqlPanicInternalError);
+ __ASSERT_DEBUG(!aFileData.IsReadOnly(), __SQLPANIC(ESqlPanicInternalError));
#if !defined(__SQL_DISABLE_SYMBIAN_SETTINGS_TABLE__)
//Make the journal file persistent - done by SQLite automatically because the locking mode is EXCLUSIVE
//__SQLLEAVE_IF_ERROR(::ExecPragma(iDbHandle, iAuthorizerDisabled, KPersistentJournalPragma, KPersist, aDbName));
@@ -1191,7 +1218,7 @@
TSqlCompactionMode compactionMode = currVacuumMode == ESqliteVacuumOff ? ESqlCompactionManual : ESqlCompactionNotSet;
TSqlDbSysSettings dbSettings(iDbHandle);
dbSettings.LoadSettingsL(aDbName, storedCollationDllName, storedDbConfigFileVer, compactionMode);
- __SQLASSERT(currVacuumMode == ESqliteVacuumOff ? compactionMode == ESqlCompactionManual : 1, ESqlPanicInternalError);
+ __ASSERT_DEBUG(currVacuumMode == ESqliteVacuumOff ? compactionMode == ESqlCompactionManual : 1, __SQLPANIC(ESqlPanicInternalError));
if(aFileData.ContainHandles() && aFileData.IsCreated())
{
compactionMode = aFileData.ConfigParams().iCompactionMode;
@@ -1235,6 +1262,7 @@
//Check whether reindexing is necessary
if(::SqlServer().CollationDllName().CompareF(aStoredCollationDllName) != 0)
{
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLSRVDATABASE_APPLYCONFIGUPDATES2L, "0x%X;CSqlSrvDatabase::ApplyConfigUpdatesL;Reindex db;aStoredCollationDllName=%S;aDbName=%S", (TUint)this, __SQLPRNSTR(aStoredCollationDllName), __SQLPRNSTR(aDbName)));
dbSettings.ReindexDatabaseL(aDbName, ::SqlServer().CollationDllName());
}
@@ -1245,7 +1273,7 @@
TRAPD(err, dbSettings.ConfigureDatabaseL(aStoredDbConfigFileVersion, aFileData, aDbName));
if(KErrNone != err)
{
- __SQLLOG_ERR(_L("SQLLOG: CSqlSrvDatabase::ApplyConfigUpdatesL() - ConfigureDatabaseL() failed with error code %d"), err);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_APPLYCONFIGUPDATESL, "0x%X;CSqlSrvDatabase::ApplyConfigUpdatesL;ConfigureDatabaseL() failed with error code %d", (TUint)this, err));
}
}
@@ -1262,17 +1290,17 @@
*/
void CSqlSrvDatabase::SetConfigL(const TSqlSrvConfigParams& aConfigParams, TBool aSetPageSize, const TDesC& aLogicalDbName)
{
- __SQLASSERT(aConfigParams.iPageSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iPageSize >= 0, ESqlPanicBadArgument);
- __SQLASSERT(aConfigParams.iCacheSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iCacheSize >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aConfigParams.iPageSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iPageSize >= 0, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aConfigParams.iCacheSize == TSqlSrvConfigParams::KConfigPrmValueNotSet || aConfigParams.iCacheSize >= 0, __SQLPANIC(ESqlPanicBadArgument));
if(aSetPageSize && aConfigParams.iPageSize != TSqlSrvConfigParams::KConfigPrmValueNotSet)
{
__SQLLEAVE_IF_ERROR(::ExecPragma(iDbHandle, iAuthorizerDisabled, KPageSizePragma, aConfigParams.iPageSize));
}
const TDesC& logicalDbName = aLogicalDbName.Length() > 0 ? aLogicalDbName : KMainDb16;
-
+
::SetJournalSizeLimitL(iDbHandle, iAuthorizerDisabled, aConfigParams.iPageSize, logicalDbName);
-
+
//Setting the cache size.
//Step 1: Check if aConfigParams.iCacheSize value is set. If it is set, then use it.
if(aConfigParams.iCacheSize != TSqlSrvConfigParams::KConfigPrmValueNotSet)
@@ -1284,8 +1312,8 @@
//Step 2: aConfigParams.iCacheSize value is not set. Then check if aConfigParams.iSoftHeapLimitKb value is set.
if(aConfigParams.iSoftHeapLimitKb != TSqlSrvConfigParams::KConfigPrmValueNotSet)
{
- __SQLASSERT(aConfigParams.iSoftHeapLimitKb >= TSqlSrvConfigParams::KMinSoftHeapLimitKb &&
- aConfigParams.iSoftHeapLimitKb <= TSqlSrvConfigParams::KMaxSoftHeapLimitKb, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aConfigParams.iSoftHeapLimitKb >= TSqlSrvConfigParams::KMinSoftHeapLimitKb &&
+ aConfigParams.iSoftHeapLimitKb <= TSqlSrvConfigParams::KMaxSoftHeapLimitKb, __SQLPANIC(ESqlPanicInternalError));
//Step 3: aConfigParams.iSoftHeapLimitKb value is set. Then use it to calculate the cache size. But we need the page size first.
// aLogicalDbName is used instead of logicalDbName because PageSizeL() if called with non-zero length name,
// "thinks" it is the main database name. KMainDb16 will be interpreted as an attached database name.
@@ -1326,10 +1354,10 @@
void CSqlSrvDatabase::InitCompactionL(TSqlCompactionMode aCompactionMode, TInt aFreePageThresholdKb,
const TDesC& aDbFileName, TSqliteVacuumMode aCurrentVacuumMode, const TDesC& aDbName)
{
- __SQLASSERT(aCompactionMode == ESqlCompactionManual || aCompactionMode == ESqlCompactionBackground || aCompactionMode == ESqlCompactionAuto, ESqlPanicBadArgument);
- __SQLASSERT(aCurrentVacuumMode == ESqliteVacuumOff || aCurrentVacuumMode == ESqliteVacuumAuto ||
- aCurrentVacuumMode == ESqliteVacuumIncremental, ESqlPanicBadArgument);
- __SQLASSERT(aFreePageThresholdKb >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aCompactionMode == ESqlCompactionManual || aCompactionMode == ESqlCompactionBackground || aCompactionMode == ESqlCompactionAuto, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aCurrentVacuumMode == ESqliteVacuumOff || aCurrentVacuumMode == ESqliteVacuumAuto ||
+ aCurrentVacuumMode == ESqliteVacuumIncremental, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aFreePageThresholdKb >= 0, __SQLPANIC(ESqlPanicBadArgument));
TSqliteVacuumMode newSqliteVacuumMode = aCompactionMode == ESqlCompactionAuto ? ESqliteVacuumAuto : ESqliteVacuumIncremental;
if(aCurrentVacuumMode == ESqliteVacuumOff)
{
@@ -1362,6 +1390,7 @@
*/
void CSqlSrvDatabase::NewCompactEntryL(TInt aFreePageThresholdKb, const TDesC& aDbFileName, const TDesC& aDbName)
{
+ SQL_TRACE_INTERNALS(OstTraceExt4(TRACE_INTERNALS, CSQLSRVDATABASE_NEWCOMPACTENTRYL_ENTRY, "Entry;0x%X;CSqlSrvDatabase::NewCompactEntryL;aFreePageThresholdKb=%d;aDbFileName=%S;aDbName=%S", (TUint)this, aFreePageThresholdKb, __SQLPRNSTR(aDbFileName), __SQLPRNSTR(aDbName)));
TSqlCompactSettings settings;
settings.iFreePageThresholdKb = aFreePageThresholdKb;
::SqlServer().Compactor().AddEntryL(aDbFileName, settings);
@@ -1370,7 +1399,7 @@
HBufC* data = aDbFileName.Alloc();
if(key && data)
{
- __SQLASSERT(!iCompactDbMap.Entry(key), ESqlPanicObjExists);
+ __ASSERT_DEBUG(!iCompactDbMap.Entry(key), __SQLPANIC(ESqlPanicObjExists));
err = iCompactDbMap.Insert(key, data);//returns the index of the new entry
}
if(err < 0) //If either "key" or "data" or both is NULL, then "err" is KErrNoMemory and the next "if" will be executed.
@@ -1379,6 +1408,7 @@
delete key;
::SqlServer().Compactor().ReleaseEntry(aDbFileName);
}
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVDATABASE_NEWCOMPACTENTRYL_EXIT, "Exit;0x%X;CSqlSrvDatabase::NewCompactEntryL;err=%d", (TUint)this, err));
__SQLLEAVE_IF_ERROR(err);
}
@@ -1400,6 +1430,7 @@
{
::SqlServer().Compactor().ReleaseEntry(*compactDbPair.iData);
iCompactDbMap.Remove(compactDbPair.iKey);
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, CSQLSRVDATABASE_RELEASECOMPACTENTRY, "0x%X;CSqlSrvDatabase::ReleaseCompactEntry", (TUint)this));
break;
}
}
@@ -1419,7 +1450,7 @@
void CSqlSrvDatabase::CompactCleanup(void* aCleanup)
{
CSqlSrvDatabase* self = reinterpret_cast <CSqlSrvDatabase*> (aCleanup);
- __SQLASSERT(self != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(self != NULL, __SQLPANIC2(ESqlPanicBadArgument));
self->ReleaseCompactEntry(KMainDb16);
}
@@ -1447,7 +1478,7 @@
TInt pageSize = 0;
__SQLLEAVE_IF_ERROR(::DbPageSize(iDbHandle, aDbName, pageSize));
CleanupStack::PopAndDestroy();
- __SQLASSERT(pageSize > 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(pageSize > 0, __SQLPANIC(ESqlPanicInternalError));
if(aDbName == KNullDesC)
{
iPageSize = pageSize;
@@ -1475,13 +1506,13 @@
*/
void CSqlSrvDatabase::ConstructCreateSecureL(const TSqlSrvFileData& aFileData, CSqlSecurityPolicy* aSecurityPolicy)
{
- __SQLASSERT(aSecurityPolicy != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aSecurityPolicy != NULL, __SQLPANIC(ESqlPanicBadArgument));
//Insert a new item in the security policies map.
CleanupStack::PushL(aSecurityPolicy);
const TUint8* mapKey = SecurityMapKeyL(aFileData.FileName());
mapKey = ::CreateStrCopyLC(mapKey);
- __SQLASSERT(!::SqlServer().SecurityMap().Entry(mapKey), ESqlPanicObjExists);
- __SQLLEAVE_IF_ERROR(::SqlServer().SecurityMap().Insert(mapKey, aSecurityPolicy));
+ __ASSERT_DEBUG(!::SqlServer().SecurityMap().Entry(mapKey), __SQLPANIC(ESqlPanicObjExists));
+ __SQLLEAVE_IF_ERROR(::SqlServer().SecurityMap().Insert(mapKey, aSecurityPolicy));
CleanupStack::Pop(2);//iSecurityMap owns mapKey and aSecurityPolicy.
iSecureDbName = mapKey;
iSecurityPolicy = aSecurityPolicy;
@@ -1518,8 +1549,8 @@
//If the method fails and the error is not KErrAlreadyExists, the database file will be closed and deleted.
void CSqlSrvDatabase::DoCommonConstructCreateL(const TSqlSrvFileData& aFileData, TBool aSecureDb)
{
- __SQLASSERT(!iDbHandle, ESqlPanicInternalError);
- __SQLASSERT(aSecureDb ? iSecurityPolicy != NULL : ETrue, ESqlPanicInternalError);
+ __ASSERT_DEBUG(!iDbHandle, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aSecureDb ? iSecurityPolicy != NULL : ETrue, __SQLPANIC(ESqlPanicInternalError));
CreateNewDbFileL(aFileData);
TDbFileCleanup dbFileCleanup(aFileData, iDbHandle);
CleanupStack::PushL(TCleanupItem(&DbFileCleanup, &dbFileCleanup));
--- a/persistentstorage/sql/SRC/Server/SqlSrvDatabase.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvDatabase.inl Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -144,7 +144,7 @@
*/
inline sqlite3* CSqlSrvDatabase::RawDbHandle() const
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInternalError));
return iDbHandle;
}
@@ -224,7 +224,7 @@
*/
inline void CSqlSrvDatabase::StoreSettingsL(const TDesC& aCollationDllName, TInt aDbConfigFileVersion, TSqlCompactionMode aCompactionMode)
{
- __SQLASSERT(aCompactionMode == ESqlCompactionManual || aCompactionMode == ESqlCompactionBackground || aCompactionMode == ESqlCompactionAuto, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aCompactionMode == ESqlCompactionManual || aCompactionMode == ESqlCompactionBackground || aCompactionMode == ESqlCompactionAuto, __SQLPANIC(ESqlPanicBadArgument));
#if !defined(__SQL_DISABLE_SYMBIAN_SETTINGS_TABLE__)
TSqlDbSysSettings dbSettings(iDbHandle);
dbSettings.StoreSettingsL(KMainDb16, aCollationDllName, aDbConfigFileVersion, aCompactionMode);
--- a/persistentstorage/sql/SRC/Server/SqlSrvDbSysSettings.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvDbSysSettings.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -29,6 +29,11 @@
#include "SqlSrvStrings.h" //System table names
#include "SqlSrvUtil.h" //Global functions
#include "SqlSrvFileData.h" //TSqlSrvFileData
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSrvDbSysSettingsTraces.h"
+#endif
+#include "SqlTraceDef.h"
extern TBool IsStatementSupported(const TDesC& aStatementIn, const TDesC& aDbName, TDes& aStatementOut);
@@ -105,7 +110,7 @@
//Panic SqlDb 4 In _DEBUG mode if aHandle argument is NULL.
static void FinalizeStatementHandle(void* aHandle)
{
- __SQLASSERT(aHandle != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aHandle != NULL, __SQLPANIC2(ESqlPanicBadArgument));
sqlite3_stmt* stmtHandle = static_cast <sqlite3_stmt*> (aHandle);
(void)sqlite3_finalize(stmtHandle);
}
@@ -114,7 +119,7 @@
//Panic SqlDb 4 In _DEBUG mode if aDbHandle argument is NULL.
static void RollbackTransaction(void* aDbHandle)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicBadArgument));
(void)::DbExecStmt8(reinterpret_cast <sqlite3*> (aDbHandle), KRollbackTransactionSql);
}
@@ -132,7 +137,7 @@
TSqlDbSysSettings::TSqlDbSysSettings(sqlite3* aDbHandle) :
iDbHandle(aDbHandle)
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicBadArgument));
}
/**
@@ -147,7 +152,7 @@
*/
void TSqlDbSysSettings::StoreSecurityPolicyL(const CSqlSecurityPolicy& aSecurityPolicyCon)
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
__SQLLEAVE_IF_ERROR(::DbExecStmt8(iDbHandle, KBeginTransactionSql()));
CleanupStack::PushL(TCleanupItem(&RollbackTransaction, iDbHandle));
__SQLLEAVE_IF_ERROR(::DbExecStmt8(iDbHandle, KCreateSecuritySql()));
@@ -176,8 +181,8 @@
*/
void TSqlDbSysSettings::StoreSettingsL(const TDesC& aDbName, const TDesC& aCollationDllName, TInt aDbConfigFileVersion, TSqlCompactionMode aCompactionMode)
{
- __SQLASSERT(aCompactionMode == ESqlCompactionManual || aCompactionMode == ESqlCompactionBackground || aCompactionMode == ESqlCompactionAuto, ESqlPanicBadArgument);
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(aCompactionMode == ESqlCompactionManual || aCompactionMode == ESqlCompactionBackground || aCompactionMode == ESqlCompactionAuto, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
HBufC* buf = HBufC::NewLC(Max((TInt)sizeof(KDropSettingsSql),
Max((TInt)sizeof(KCreateSettingsSql), (TInt)sizeof(KInsertSettingsSql))) +
aDbName.Length() + aCollationDllName.Length() + 10);
@@ -216,7 +221,7 @@
*/
void TSqlDbSysSettings::LoadSecurityPolicyL(CSqlSecurityPolicy& aSecurityPolicyCon)
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
//Even if the version of the system settings is bigger than the current one (KSqlSystemVersion constant),
//I think that all future modifications of the system tables shall not affect the already existing
//fields. So it is correct to think that all information available in version 1 should be available
@@ -289,7 +294,7 @@
*/
void TSqlDbSysSettings::LoadSettingsL(const TDesC& aDbName, TDes& aCollationDllName, TInt& aDbConfigFileVersion, TSqlCompactionMode& aCompactionMode)
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
aCollationDllName.Zero();
aDbConfigFileVersion = KSqlNullDbConfigFileVersion;
@@ -319,7 +324,7 @@
StoreSettingsL(aDbName, aCollationDllName, aDbConfigFileVersion, aCompactionMode); // store empty collation dll name, then reindexing will occur
}
}
- __SQLASSERT(aCompactionMode == ESqlCompactionManual || aCompactionMode == ESqlCompactionBackground || aCompactionMode == ESqlCompactionAuto, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aCompactionMode == ESqlCompactionManual || aCompactionMode == ESqlCompactionBackground || aCompactionMode == ESqlCompactionAuto, __SQLPANIC(ESqlPanicInternalError));
}
/**
@@ -345,7 +350,7 @@
void TSqlDbSysSettings::GetSettingsL(const TDesC& aDbName, TDes& aCollationDllName, TInt& aDbConfigFileVersion,
TInt& aSettingsVersion, TSqlCompactionMode& aCompactionMode)
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
HBufC* buf = HBufC::NewLC(sizeof(KGetSettingsSql) + aDbName.Length());
TPtr sql = buf->Des();
@@ -389,7 +394,7 @@
const void* ptr = sqlite3_column_text16(stmtHandle, KCollationDllNameColIdx);
//Null column value - this might be an indication of an "out of memory" problem, if the column text
//is in UTF8 format. (sqlite3_column_text16() may allocate memory for UTF8->UTF16 conversion)
- __SQLLEAVE_IF_NULL(ptr);
+ __SQLLEAVE_IF_NULL(const_cast<void*>(ptr));
TPtrC16 src(reinterpret_cast <const TUint16*> (ptr));
if(src.Length() > aCollationDllName.MaxLength())
{
@@ -423,7 +428,7 @@
*/
void TSqlDbSysSettings::ReindexDatabaseL(const TDesC& aDbName, const TDesC& aCurrentCollationDllName)
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
//Allocate memory for the SQL statements
HBufC* buf = HBufC::NewLC(Max((TInt)sizeof(KUpdateCollationSettingsSql), (TInt)sizeof(KReindexSql)) +
@@ -475,12 +480,15 @@
void TSqlDbSysSettings::ConfigureDatabaseL(TInt aStoredDbConfigFileVersion, const TSqlSrvFileData& aFileData,
const TDesC& aDbName)
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInvalidObj);
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, TSQLDBSYSSETTINGS_CONFIGUREDATABASEL_ENTRY, "Entry;0x%X;TSqlDbSysSettings::ConfigureDatabaseL", (TUint)this));
+
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
if(!aFileData.IsSecureFileNameFmt())
{
//As a first implementation, config files will only be supported for
//shared, secure databases - not for private, secure databases or public databases
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, TSQLDBSYSSETTINGS_CONFIGUREDATABASEL_EXIT1, "Exit;0x%X;TSqlDbSysSettings::ConfigureDatabaseL;Not a secure db", (TUint)this));
return;
}
@@ -514,13 +522,13 @@
if(fileVersion > aStoredDbConfigFileVersion)
{
//The latest version of the configuration file has not yet been processed, so do it now
- __SQLLOG_STRING(_L("SQLLOG: TSqlDbSysSettings::ConfigureDatabaseL() - Processing config file %S"), configFileName);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, TSQLDBSYSSETTINGS_CONFIGUREDATABASEL1, "0x%X;TSqlDbSysSettings::ConfigureDatabaseL;Config file '%S'", (TUint)this, __SQLPRNSTR(configFileName)));
ExecuteConfigurationUpdateL(aFileData, configFileName, fileVersion, aDbName);
- __SQLLOG_STRING(_L("SQLLOG: TSqlDbSysSettings::ConfigureDatabaseL() - SUCCESS! Config file %S was processed"), configFileName);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, TSQLDBSYSSETTINGS_CONFIGUREDATABASEL2, "0x%X;TSqlDbSysSettings::ConfigureDatabaseL;Config file '%S' was processed, no errors", (TUint)this, __SQLPRNSTR(configFileName)));
}
else
{
- __SQLLOG_STRING(_L("SQLLOG: TSqlDbSysSettings::ConfigureDatabaseL() - Not processing config file %S as this or a later version has already been processed"), configFileName);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, TSQLDBSYSSETTINGS_CONFIGUREDATABASEL3, "0x%X;TSqlDbSysSettings::ConfigureDatabaseL;Config file '%S' as this or a later version has already been processed", (TUint)this, __SQLPRNSTR(configFileName)));
}
}
else
@@ -537,9 +545,10 @@
}
else
{
- __SQLLOG_STRING(_L("SQLLOG: TSqlDbSysSettings::ConfigureDatabaseL() - No config file found for database %S"), dbFileNameAndExt);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, TSQLDBSYSSETTINGS_CONFIGUREDATABASEL4, "0x%X;TSqlDbSysSettings::ConfigureDatabaseL;No config file found for database '%S'", (TUint)this, __SQLPRNSTR(dbFileNameAndExt)));
}
}
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, TSQLDBSYSSETTINGS_CONFIGUREDATABASEL_EXIT2, "Exit;0x%X;TSqlDbSysSettings::ConfigureDatabaseL", (TUint)this));
}
/**
@@ -565,7 +574,7 @@
TInt aDbConfigFileVersion,
const TDesC& aDbName)
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
//Execute the specified database config file operations that are supported
#ifdef SYSLIBS_TEST
@@ -609,7 +618,7 @@
*/
void TSqlDbSysSettings::DoExecuteDbConfigFileOpsL(RFs& aFs, const TDesC& aConfigFilePath, const TDesC& aDbName)
{
- __SQLASSERT(iDbHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iDbHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
//Open the config file and read it into a buffer
RFile64 file;
@@ -620,7 +629,7 @@
if(size == 0)
{
//Config file is empty so just return
- __SQLLOG_STRING(_L("SQLLOG: TSqlDbSysSettings::DoExecuteDbConfigFileOpsL() - Config file %S is empty"), aConfigFilePath);
+ SQL_TRACE_INTERNALS(OstTraceExt1(TRACE_INTERNALS, TSQLDBSYSSETTINGS_DOEXECUTEDBCONFIGFILEOPSL, "0;TSqlDbSysSettings::DoExecuteDbConfigFileOpsL();Config file %S is empty", __SQLPRNSTR(aConfigFilePath)));
CleanupStack::PopAndDestroy(); // file
return;
}
@@ -691,12 +700,12 @@
*/
void TSqlDbSysSettings::ProcessStatementL(const TDesC& aStmt, const TDesC& aDbName)
{
- __SQLLOG_STRING(_L("SQLLOG: TSqlDbSysSettings::ProcessStatementL() - Processing statement '%S'"), aStmt);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, TSQLDBSYSSETTINGS_PROCESSSTATEMENTL_ENTRY, "Entry;0x%X;TSqlDbSysSettings::ProcessStatementL;Processing statement '%S'", (TUint)this, __SQLPRNSTR(aStmt)));
//If the statement only contained whitespace then just return
if(aStmt.Length() == 0)
{
- __SQLLOG_STRING(_L("SQLLOG: TSqlDbSysSettings::ProcessStatementL() - Statement '%S' only contains whitespace - statement will be ignored"), aStmt);
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, TSQLDBSYSSETTINGS_PROCESSSTATEMENTL_EXIT1, "Exit;0x%X;TSqlDbSysSettings::ProcessStatementL;The statement ignored because contains only whitespace", (TUint)this));
return;
}
@@ -705,7 +714,7 @@
{
//The statement contains '//' which is an unsupported comment style, but rather
//than leave here and cause the full file to fail, we just ignore this statement
- __SQLLOG_STRING(_L("SQLLOG: TSqlDbSysSettings::ProcessStatementL() - Statement '%S' contains invalid comment style - statement will be ignored"), aStmt);
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, TSQLDBSYSSETTINGS_PROCESSSTATEMENTL_EXIT2, "Exit;0x%X;TSqlDbSysSettings::ProcessStatementL;The statement ignored because contains invalid comment style", (TUint)this));
return;
}
@@ -717,11 +726,11 @@
TInt err = ::DbExecStmt16(iDbHandle, stmtPtr);
if(KErrNone == err)
{
- __SQLLOG_STRING(_L("SQLLOG: TSqlDbSysSettings::ProcessStatementL() - Successfully executed statement '%S'"), aStmt);
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, TSQLDBSYSSETTINGS_PROCESSSTATEMENTL1, "0x%X;TSqlDbSysSettings::ProcessStatementL;Successfully executed statement", (TUint)this));
}
else
{
- __SQLLOG_ERR(_L("SQLLOG: TSqlDbSysSettings::ProcessStatementL() - Failed to execute the statement, err=%d"), err);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, TSQLDBSYSSETTINGS_PROCESSSTATEMENTL2, "0x%X;TSqlDbSysSettings::ProcessStatementL;Failed to execute the statement;err=%d", (TUint)this, err));
if(err == KErrNoMemory)
{
__SQLLEAVE(err);
@@ -730,9 +739,10 @@
}
else
{
- __SQLLOG_STRING(_L("SQLLOG: TSqlDbSysSettings::ProcessStatementL() - Non-supported statement, will be ignored - '%S'"), aStmt);
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, TSQLDBSYSSETTINGS_PROCESSSTATEMENTL3, "0x%X;TSqlDbSysSettings::ProcessStatementL;Non-supported statement, will be ignored", (TUint)this));
}
CleanupStack::PopAndDestroy(); // stmtBuf
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, TSQLDBSYSSETTINGS_PROCESSSTATEMENTL_EXIT3, "Exit;0x%X;TSqlDbSysSettings::ProcessStatementL", (TUint)this));
}
@@ -795,7 +805,7 @@
void TSqlDbSysSettings::StoreSecurityPolicyL(sqlite3_stmt* aStmtHandle, TInt aObjType, const TDesC& aObjName,
TInt aPolicyType, const TSecurityPolicy& aPolicy)
{
- __SQLASSERT(aStmtHandle != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aStmtHandle != NULL, __SQLPANIC(ESqlPanicBadArgument));
__SQLLEAVE_IF_ERROR(::StmtReset(aStmtHandle));
__SQLLEAVE_IF_ERROR(BindSecurityPolicyPrm(aStmtHandle, aObjType, aObjName, aPolicyType, aPolicy));
__SQLLEAVE_IF_ERROR(::StmtExec(aStmtHandle));
@@ -854,7 +864,7 @@
TSecurityPolicy TSqlDbSysSettings::ReadCurrSecurityPolicyL(sqlite3_stmt* aStmtHandle, TInt& aObjType,
TPtrC& aObjName, TInt& aPolicyType)
{
- __SQLASSERT(aStmtHandle != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aStmtHandle != NULL, __SQLPANIC(ESqlPanicBadArgument));
aObjType = sqlite3_column_int(aStmtHandle, KObjTypeColIdx);
//The "ObjectName" column type might be different than SQLITE_TEXT - malformed database.
if(sqlite3_column_type(aStmtHandle, KObjNameColIdx) != SQLITE_TEXT)
@@ -864,7 +874,7 @@
const void* text = sqlite3_column_text16(aStmtHandle, KObjNameColIdx);
//Null column value - this might be an indication of an "out of memory" problem, if the column text
//is in UTF8 format. (sqlite3_column_text16() may allocate memory for UTF8->UTF16 conversion)
- __SQLLEAVE_IF_NULL(text);
+ __SQLLEAVE_IF_NULL(const_cast<void*>(text));
TInt len = (TUint)sqlite3_column_bytes16(aStmtHandle, KObjNameColIdx) / sizeof(TUint16);
aObjName.Set(reinterpret_cast <const TUint16*> (text), len);
aPolicyType = sqlite3_column_int(aStmtHandle, KObjPolicyTypeColIdx);
--- a/persistentstorage/sql/SRC/Server/SqlSrvDbSysSettings.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvDbSysSettings.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -18,7 +18,7 @@
#ifndef __SQLSRVDBSYSSETTINGS_H__
#define __SQLSRVDBSYSSETTINGS_H__
-#include "SqlPanic.h" // __SQLASSERT, ESqlPanicInternalError
+#include "SqlAssert.h" // ESqlPanicInternalError
#include "SqlUtil.h" // TSqlCompactionMode
//Forward declarations
--- a/persistentstorage/sql/SRC/Server/SqlSrvDriveSpace.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvDriveSpace.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2004-2010 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"
@@ -16,7 +16,12 @@
//
#include "SqlSrvDriveSpace.h"
-#include "SqlPanic.h"
+#include "SqlAssert.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSrvDriveSpaceTraces.h"
+#endif
+#include "SqlTraceDef.h"
/**
The amount of the disk space, which will be reserved at the moment of creation of
@@ -52,10 +57,12 @@
*/
CSqlDriveSpace* CSqlDriveSpace::NewLC(RFs& aFs, TDriveNumber aDrive)
{
- __SQLASSERT(aDrive >= EDriveA && aDrive <= EDriveZ, ESqlPanicBadArgument);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLDRIVESPACE_NEWLC_ENTRY, "Entry;0;CSqlDriveSpace::NewLC;aFs.Handle()=0x%X;aDrive=%d", (TUint)aFs.Handle(), (TInt)aDrive));
+ __ASSERT_DEBUG(aDrive >= EDriveA && aDrive <= EDriveZ, __SQLPANIC2(ESqlPanicBadArgument));
CSqlDriveSpace* self = new (ELeave) CSqlDriveSpace(aFs, aDrive);
CleanupStack::PushL(self);
self->ConstructL();
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, CSQLDRIVESPACE_NEWLC_EXIT, "Exit;0x%X;CSqlDriveSpace::NewLC", (TUint)self));
return self;
}
@@ -64,6 +71,7 @@
*/
CSqlDriveSpace::~CSqlDriveSpace()
{
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLDRIVESPACE_CSQLDRIVESPACE2, "0x%X;CSqlDriveSpace::~CSqlDriveSpace;iDrive=%d;iGetAccessRefCnt=%d", (TUint)this, (TInt)iDrive, iGetAccessRefCnt));
SQLDRIVESPACE_INVARIANT();
(void)iFs.ReleaseReserveAccess(static_cast <TInt> (iDrive));
(void)iFs.ReserveDriveSpace(static_cast <TInt> (iDrive), 0);
@@ -82,6 +90,7 @@
*/
void CSqlDriveSpace::GetAccessL()
{
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLDRIVESPACE_GETACCESSL_ENTRY, "Entry;0x%X;CSqlDriveSpace::GetAccessL;iDrive=%d;iGetAccessRefCnt=%d", (TUint)this, (TInt)iDrive, iGetAccessRefCnt));
SQLDRIVESPACE_INVARIANT();
//Gets an access only once, there is only one RFs session instance.
if(iGetAccessRefCnt == 0)
@@ -89,6 +98,7 @@
__SQLLEAVE_IF_ERROR(iFs.GetReserveAccess(static_cast <TInt> (iDrive)));
}
++iGetAccessRefCnt;
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLDRIVESPACE_GETACCESSL_EXIT, "Exit;0x%X;CSqlDriveSpace::GetAccessL;iDrive=%d;iGetAccessRefCnt=%d", (TUint)this, (TInt)iDrive, iGetAccessRefCnt));
SQLDRIVESPACE_INVARIANT();
}
@@ -103,6 +113,7 @@
*/
void CSqlDriveSpace::ReleaseAccess()
{
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLDRIVESPACE_RELEASEACCESS, "0x%X;CSqlDriveSpace::ReleaseAccess;iDrive=%d;iGetAccessRefCnt=%d", (TUint)this, (TInt)iDrive, iGetAccessRefCnt));
SQLDRIVESPACE_INVARIANT();
if(iGetAccessRefCnt == 0)
{
@@ -127,7 +138,7 @@
iFs(aFs),
iDrive(aDrive)
{
- __SQLASSERT(aDrive >= EDriveA && aDrive <= EDriveZ, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDrive >= EDriveA && aDrive <= EDriveZ, __SQLPANIC(ESqlPanicBadArgument));
}
/**
@@ -152,8 +163,8 @@
*/
void CSqlDriveSpace::Invariant() const
{
- __SQLASSERT(iDrive >= EDriveA && iDrive <= EDriveZ, ESqlPanicInternalError);
- __SQLASSERT(iGetAccessRefCnt >= 0, ESqlPanicMisuse);
+ __ASSERT_DEBUG(iDrive >= EDriveA && iDrive <= EDriveZ, __SQLPANIC(ESqlPanicInternalError));
+ __ASSERT_DEBUG(iGetAccessRefCnt >= 0, __SQLPANIC(ESqlPanicMisuse));
}
#endif//_DEBUG
@@ -202,7 +213,7 @@
*/
CSqlDriveSpace* RSqlDriveSpaceCol::Find(TDriveNumber aDrive)
{
- __SQLASSERT(aDrive >= EDriveA && aDrive <= EDriveZ, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDrive >= EDriveA && aDrive <= EDriveZ, __SQLPANIC(ESqlPanicBadArgument));
SQLDRIVESPACECOL_INVARIANT();
for(TInt index=iDriveSpaceCol.Count()-1;index>=0;--index)
{
@@ -230,8 +241,8 @@
*/
CSqlDriveSpace* RSqlDriveSpaceCol::AddL(TDriveNumber aDrive)
{
- __SQLASSERT(aDrive >= EDriveA && aDrive <= EDriveZ, ESqlPanicBadArgument);
- __SQLASSERT(!Find(aDrive), ESqlPanicMisuse);
+ __ASSERT_DEBUG(aDrive >= EDriveA && aDrive <= EDriveZ, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(!Find(aDrive), __SQLPANIC(ESqlPanicMisuse));
SQLDRIVESPACECOL_INVARIANT();
CSqlDriveSpace* drvSpace = CSqlDriveSpace::NewLC(*iFs, aDrive);
__SQLLEAVE_IF_ERROR(iDriveSpaceCol.Append(drvSpace));
@@ -246,7 +257,7 @@
*/
void RSqlDriveSpaceCol::Invariant() const
{
- __SQLASSERT(iFs != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iFs != NULL, __SQLPANIC(ESqlPanicInternalError));
for(TInt index=iDriveSpaceCol.Count()-1;index>=0;--index)
{
iDriveSpaceCol[index]->Invariant();
--- a/persistentstorage/sql/SRC/Server/SqlSrvFileData.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvFileData.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -15,7 +15,7 @@
#include "SqlSrvFileData.h"
#include "SqlSrvUtil.h"
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlSrvStrings.h"
#include "SqlSrvResourceProfiler.h"
@@ -35,13 +35,13 @@
static void CreatePrivateDataPathL(RFs& aFs, TDriveNumber aDriveNumber)
{
TDriveInfo driveInfo;
- __SQLLEAVE_IF_ERROR(aFs.Drive(driveInfo, aDriveNumber));
+ __SQLLEAVE_IF_ERROR2(aFs.Drive(driveInfo, aDriveNumber));
if(!(driveInfo.iDriveAtt & KDriveAttRom))
{
TInt err = aFs.CreatePrivatePath(aDriveNumber);
if(err != KErrNone && err != KErrAlreadyExists)
{
- __SQLLEAVE(err);
+ __SQLLEAVE2(err);
}
}
}
@@ -114,16 +114,16 @@
static void DoFullFileNameL(TDes& aDbFileName, const TDesC& aSysDrivePrivatePath, TDriveNumber& aDrive)
{
TParse parse;
- __SQLLEAVE_IF_ERROR(parse.Set(aDbFileName, &aSysDrivePrivatePath, NULL));
+ __SQLLEAVE_IF_ERROR2(parse.Set(aDbFileName, &aSysDrivePrivatePath, NULL));
if(!parse.NamePresent())
{
- __SQLLEAVE(KErrBadName);
+ __SQLLEAVE2(KErrBadName);
}
aDbFileName.Copy(parse.FullName());
TPtrC driveName = parse.Drive();
- __SQLASSERT(driveName.Length() > 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(driveName.Length() > 0, __SQLPANIC2(ESqlPanicInternalError));
TInt driveNumber = -1;
- __SQLLEAVE_IF_ERROR(RFs::CharToDrive(driveName[0], driveNumber));
+ __SQLLEAVE_IF_ERROR2(RFs::CharToDrive(driveName[0], driveNumber));
aDrive = static_cast <TDriveNumber> (driveNumber);
}
@@ -143,7 +143,7 @@
//If SQL server private path is in the file name - leave
if(::IsPrivatePathInFileName(aDbFileName, aServerPrivatePath))
{
- __SQLLEAVE(KErrArgument);
+ __SQLLEAVE2(KErrArgument);
}
//Extract database SID from the name
aIsSecureFileNameFmt = ::IsSecureFileNameFmt(aDbFileName);
@@ -198,8 +198,8 @@
#endif
const TDesC8* aConfigStr)
{
- __SQLASSERT((TUint)aFileNameArgNum < KMaxMessageArguments, ESqlPanicBadArgument);
- __SQLASSERT(iSysDrivePrivatePath.DriveAndPath().Length() > 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG((TUint)aFileNameArgNum < KMaxMessageArguments, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(iSysDrivePrivatePath.DriveAndPath().Length() > 0, __SQLPANIC(ESqlPanicInternalError));
if(aFileNameLen < 1 || aFileNameLen > KMaxFileName)
{
--- a/persistentstorage/sql/SRC/Server/SqlSrvMain.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvMain.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -25,10 +25,14 @@
#include "SqlCompact.h"
#include "SqlCompactConn.h"
#include "SqlSrvResourceProfiler.h"
-#include "UTraceSql.h"
#ifdef _DEBUG
#include <stdio.h>
#endif
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSrvMainTraces.h"
+#endif
+#include "SqlTraceDef.h"
#ifndef SQLSRV_STARTUP_TEST
static
@@ -66,7 +70,7 @@
//aRight argument is NULL.
static TInt Compare(const TSqlSecurityPair& aLeft, const TSqlSecurityPair& aRight)
{
- __SQLASSERT(aLeft.iKey != NULL && aRight.iKey != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aLeft.iKey != NULL && aRight.iKey != NULL, __SQLPANIC2(ESqlPanicInternalError));
return ::CompareNoCase8(TPtrC8(aLeft.iKey), TPtrC8(aRight.iKey));
}
@@ -81,7 +85,7 @@
*/
CSqlServer& SqlServer(void)
{
- __SQLASSERT_ALWAYS(TheServer != NULL, ESqlPanicInvalidObj);
+ __ASSERT_ALWAYS(TheServer != NULL, __SQLPANIC2(ESqlPanicInvalidObj));
return *TheServer;
}
@@ -95,9 +99,11 @@
*/
CSqlServer* CSqlServer::NewLC()
{
+ SQL_TRACE_INTERNALS(OstTrace0(TRACE_INTERNALS, CSQLSERVER_NEWLC_ENTRY, "Entry;0;CSqlServer::NewLC"));
CSqlServer* self = new (ELeave) CSqlServer;
CleanupStack::PushL(self);
self->ConstructL();
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, CSQLSERVER_NEWLC_EXIT, "Exit;0x%X;CSqlServer::NewLC", (TUint)self));
return self;
}
@@ -106,6 +112,7 @@
*/
CSqlServer::~CSqlServer()
{
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, CSQLSERVER_CSQLSERVER2_ENTRY, "Entry;0x%x;CSqlServer::~CSqlServer", (TUint)this));
delete iCompactor;
delete iBackupClient;
iDriveSpaceCol.ResetAndDestroy();
@@ -117,8 +124,7 @@
delete iDbConfigFiles;
sqlite3SymbianLibFinalize();
TheServer = NULL;
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KSqlSrvClose));
- SQLPROFILER_SERVER_STOP();
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, CSQLSERVER_CSQLSERVER2_EXIT, "Exit;0x%x;CSqlServer::~CSqlServer", (TUint)this));
}
/**
@@ -128,7 +134,7 @@
*/
RSqlBufFlat& CSqlServer::GetFlatBufL(TInt aMinLen)
{
- __SQLASSERT(aMinLen >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aMinLen >= 0, __SQLPANIC(ESqlPanicBadArgument));
__SQLLEAVE_IF_ERROR(iFlatBuf.ReAlloc(aMinLen));
SQLPROFILER_REPORT_ALLOC(iFlatBuf.MaxSize());
return iFlatBuf;
@@ -144,10 +150,10 @@
*/
TDes8& CSqlServer::GetBuf8L(TInt aMinLen)
{
- __SQLASSERT(aMinLen >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aMinLen >= 0, __SQLPANIC(ESqlPanicBadArgument));
#ifdef _DEBUG
-TInt maxBufLen = iBufPtr8.MaxLength();
-maxBufLen = maxBufLen;
+ TInt maxBufLen = iBufPtr8.MaxLength();
+ maxBufLen = maxBufLen;
#endif
if(iBufPtr8.MaxLength() < aMinLen)
{
@@ -167,10 +173,10 @@
*/
TDes16& CSqlServer::GetBuf16L(TInt aMinLen)
{
- __SQLASSERT(aMinLen >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aMinLen >= 0, __SQLPANIC(ESqlPanicBadArgument));
#ifdef _DEBUG
-TInt maxBufLen = iBufPtr16.MaxLength();
-maxBufLen = maxBufLen;
+ TInt maxBufLen = iBufPtr16.MaxLength();
+ maxBufLen = maxBufLen;
#endif
if(iBufPtr16.MaxLength() < aMinLen)
{
@@ -196,7 +202,7 @@
if(iBufPtr8.MaxSize() > KBufLimit)
{
(void)ReAllocBuf(KBufLimit);
- __SQLASSERT(oldBuf == iBuf, ESqlPanicInternalError);
+ __ASSERT_DEBUG(oldBuf == iBuf, __SQLPANIC(ESqlPanicInternalError));
}
}
@@ -211,7 +217,7 @@
*/
TInt CSqlServer::ReAllocBuf(TInt aNewBufSize)
{
- __SQLASSERT(aNewBufSize >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aNewBufSize >= 0, __SQLPANIC(ESqlPanicBadArgument));
#ifdef _DEBUG
const TInt KMinBufSize = 8;
#else
@@ -301,7 +307,8 @@
#endif
SQLPROFILER_SERVER_START();
//Configure the SQLite library
- __SQLLEAVE_IF_ERROR(sqlite3_config(SQLITE_CONFIG_LOOKASIDE, KSqliteLookAsideCellSize, KSqliteLookAsideCellCount));
+ TInt sqliteErr = sqlite3_config(SQLITE_CONFIG_LOOKASIDE, KSqliteLookAsideCellSize, KSqliteLookAsideCellCount);
+ __SQLLEAVE_IF_ERROR(::Sql2OsErrCode(sqliteErr, KErrArgument));
//Open SQLITE library - this must be the first call after StartL() (os_symbian.cpp, "TheAllocator" initialization rellated).
__SQLLEAVE_IF_ERROR(sqlite3SymbianLibInit());
//Create buffers
@@ -314,7 +321,6 @@
RFs& fs = sqlite3SymbianFs();
TFileName serverPrivatePath;
__SQLLEAVE_IF_ERROR(fs.PrivatePath(serverPrivatePath));
-
DeleteTempFilesL(sysDrive, serverPrivatePath);
//Load config file parameter values (if config file exists) and initialize iFileData.
TParse parse;
@@ -328,8 +334,8 @@
const TSqlSrvConfigParams& configParams = iFileData.ConfigParams();
if(configParams.iSoftHeapLimitKb > 0)
{
- __SQLASSERT(configParams.iSoftHeapLimitKb >= TSqlSrvConfigParams::KMinSoftHeapLimitKb &&
- configParams.iSoftHeapLimitKb <= TSqlSrvConfigParams::KMaxSoftHeapLimitKb, ESqlPanicInternalError);
+ __ASSERT_DEBUG(configParams.iSoftHeapLimitKb >= TSqlSrvConfigParams::KMinSoftHeapLimitKb &&
+ configParams.iSoftHeapLimitKb <= TSqlSrvConfigParams::KMaxSoftHeapLimitKb, __SQLPANIC(ESqlPanicInternalError));
sqlite3_soft_heap_limit(configParams.iSoftHeapLimitKb * 1024);
}
//Enable shared cache
@@ -360,7 +366,7 @@
const TInt KGreatSize = 1024;
__SQLLEAVE_IF_ERROR(ReAllocBuf(KGreatSize));
#endif //SQLSRV_STARTUP_TEST
-#endif //_DEBUG
+#endif //_DEBUG
}
/**
@@ -415,6 +421,7 @@
fileName.Set(fname, NULL, NULL);
iCollationDllName = fileName.NameAndExt();
}
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLSERVER_GETCOLLATIONDLLNAMEL, "0x%x;CSqlServer::GetCollationDllNameL;iCollationDllName=%S;err=%d", (TUint)this, __SQLPRNSTR(iCollationDllName), err));
}
/**
Finds and caches the name of each database configuration file
@@ -438,7 +445,7 @@
}
else
{
- __SQLLOG_ERR(_L("SQLLOG: CSqlServer::CacheDbConfigFileNamesL() - GetDir() failed with error code %d"), err);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSERVER_CACHEDDBCONFIGFILENAMESL, "0x%X;CSqlServer::CacheDbConfigFileNamesL;GetDir() failed with error code %d", (TUint)this, err));
}
CleanupStack::PopAndDestroy(); // entryList
}
@@ -494,6 +501,7 @@
*/
void CSqlServer::GetBackUpListL(TSecureId aUid, RArray<TParse>& aFileList)
{
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSERVER_GETBACKUPLISTL_ENTRY, "Entry;0x%x;CSqlServer::GetBackUpListL;aUid=0x%X", (TUint)this, (TUint)aUid.iId));
aFileList.Reset();
TFindFile findFile(iFileData.Fs());
CDir* fileNameCol = NULL;
@@ -507,14 +515,14 @@
//The first set of files, which name is matching "[aUid]*" pattern, is ready.
do
{
- __SQLASSERT(fileNameCol != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(fileNameCol != NULL, __SQLPANIC(ESqlPanicInternalError));
CleanupStack::PushL(fileNameCol);
const TDesC& file = findFile.File();//"file" variable contains the drive and the path. the file name in "file" is invalid in this case.
//Check that the drive, where the database files are, is not ROM drive
TParse parse;
(void)parse.Set(file, NULL, NULL);//this call can't file, the file name comes from findFile call.
TPtrC driveName = parse.Drive();
- __SQLASSERT(driveName.Length() > 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(driveName.Length() > 0, __SQLPANIC(ESqlPanicInternalError));
TInt driveNumber = -1;
__SQLLEAVE_IF_ERROR(RFs::CharToDrive(driveName[0], driveNumber));
TDriveInfo driveInfo;
@@ -530,6 +538,8 @@
if(!entry.IsDir())
{
(void)parse.Set(entry.iName, &file, NULL);//"parse" variable now contains the full file path
+ __SQLTRACE_INTERNALSVAR(TPtrC fname = parse.FullName());
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSERVER_GETBACKUPLISTL, "0x%x;CSqlServer::GetBackUpListL;fname=%S", (TUint)this, __SQLPRNSTR(fname)));
__SQLLEAVE_IF_ERROR(aFileList.Append(parse));
}
}
@@ -538,11 +548,12 @@
fileNameCol = NULL;
} while((err = findFile.FindWild(fileNameCol)) == KErrNone);//Get the next set of files
}//end of "if(err == KErrNone)"
- __SQLASSERT(!fileNameCol, ESqlPanicInternalError);
+ __ASSERT_DEBUG(!fileNameCol, __SQLPANIC(ESqlPanicInternalError));
if(err != KErrNotFound && err != KErrNone)
{
__SQLLEAVE(err);
}
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLSERVER_GETBACKUPLISTL_EXIT, "Exit;0x%x;CSqlServer::GetBackUpListL;file count=%d;err=%d", (TUint)this, aFileList.Count(), err));
}
//////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -561,7 +572,6 @@
CActiveScheduler* scheduler = new (ELeave) CActiveScheduler;
CleanupStack::PushL(scheduler);
CActiveScheduler::Install(scheduler);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KSqlSrvStart));
TheServer = CSqlServer::NewLC();
RProcess::Rendezvous(KErrNone);
CActiveScheduler::Start();
--- a/persistentstorage/sql/SRC/Server/SqlSrvMain.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvMain.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -17,7 +17,7 @@
#define __SQLSRVMAIN_H__
#include <f32file.h>
-#include "SqlPanic.h" //TSqlPanic
+#include "SqlAssert.h" //TSqlPanic
#include "SqlSrvFileData.h" //TSqlSrvFileData
#include "SqlSrvAuthorizer.h" //MSqlPolicyInspector
#include "SqlSrvSecurityMap.h" //
@@ -90,7 +90,7 @@
void GetCollationDllNameL();
void CacheDbConfigFileNamesL(RFs& aFs, const TDesC& aServerPrivatePath);
TInt ReAllocBuf(TInt aNewBufSize);
- void DeleteTempFilesL(TInt aDriveNumber, const TDesC& aServerPrivatePath)const;
+ void DeleteTempFilesL(TInt aDriveNumber, const TDesC& aServerPrivatePath) const;
private:
TSqlSrvFileData iFileData; //Used as a temporary storage for file data (file name, drive, path, secure uid)
@@ -163,7 +163,7 @@
*/
inline CSqlCompactor& CSqlServer::Compactor()
{
- __SQLASSERT(iCompactor != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iCompactor != NULL, __SQLPANIC(ESqlPanicInternalError));
return *iCompactor;
}
--- a/persistentstorage/sql/SRC/Server/SqlSrvObjContainer.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvObjContainer.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -17,7 +17,7 @@
#define __SQLSRVOBJCONTAINER_H__
#include <e32std.h>
-#include "SqlPanic.h"
+#include "SqlAssert.h"
/**
Indexed storage for server sdide objects.
--- a/persistentstorage/sql/SRC/Server/SqlSrvObjContainer.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvObjContainer.inl Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -55,7 +55,7 @@
template <class T>
void RDbObjContainer<T>::AllocL()
{
- __SQLASSERT(iFree <= iSize, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iFree <= iSize, __SQLPANIC(ESqlPanicInternalError));
if(iFree == iSize)
{
if(iSize >= KMaxSize)
@@ -87,15 +87,15 @@
template <class T>
TInt RDbObjContainer<T>::Add(T* aObj)
{
- __SQLASSERT(aObj != NULL, ESqlPanicBadArgument);
- __SQLASSERT(iFree <= iSize, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aObj != NULL, __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(iFree <= iSize, __SQLPANIC(ESqlPanicInternalError));
TInt idx = iFree;
if(idx < iSize)
{
/*RDbObjContainer<T>::*/TEntry& entry = iEntries[idx];
- __SQLASSERT(!entry.iObj, ESqlPanicInternalError);
+ __ASSERT_DEBUG(!entry.iObj, __SQLPANIC(ESqlPanicInternalError));
iFree = entry.iNext;
- __SQLASSERT(iFree <= iSize, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iFree <= iSize, __SQLPANIC(ESqlPanicInternalError));
entry.iObj = aObj;
return MakeHandle(idx);
}
@@ -135,7 +135,7 @@
template <class T>
void RDbObjContainer<T>::Remove(TInt aHandle)
{
- __SQLASSERT(iFree <= iSize, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iFree <= iSize, __SQLPANIC(ESqlPanicInternalError));
if(aHandle > 0) //It is a handle, sent by the client. It isn't a server's problem if the handle is <= 0.
{
TInt idx = MakeIndex(aHandle);
@@ -148,7 +148,7 @@
iFree = idx;
}
}
- __SQLASSERT(iFree <= iSize, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iFree <= iSize, __SQLPANIC(ESqlPanicInternalError));
}
/**
--- a/persistentstorage/sql/SRC/Server/SqlSrvResourceProfiler.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvResourceProfiler.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -13,10 +13,8 @@
// Description:
//
-#include <e32std.h>
-#include <e32debug.h>
#include <f32file.h>
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlSrvResourceProfiler.h"
#include "SqlResourceProfiler.h"
#include "SqliteSymbian.h"
@@ -140,7 +138,7 @@
{
TheSqlSrvProfilerTraceEnabled = ETrue;
TInt len = aMessage.Int1();
- __SQLPANIC_CLIENT((TUint)len < 64, aMessage, ESqlPanicBadArgument);
+ __SQLPANIC_CLIENT2((TUint)len < 64, aMessage, ESqlPanicBadArgument);
if(len > 0)
{
TBuf8<64> prmBuf;
@@ -193,7 +191,7 @@
err = KErrNotSupported;
break;
}
- __SQLLEAVE_IF_ERROR(err);
+ __SQLLEAVE_IF_ERROR2(err);
}
/**
@@ -237,7 +235,7 @@
err = KErrNotSupported;
break;
}
- __SQLLEAVE_IF_ERROR(err);
+ __SQLLEAVE_IF_ERROR2(err);
}
/**
@@ -278,7 +276,7 @@
err = KErrNotSupported;
break;
}
- __SQLLEAVE_IF_ERROR(err);
+ __SQLLEAVE_IF_ERROR2(err);
}
/**
@@ -351,7 +349,7 @@
err = KErrNotSupported;
break;
}
- __SQLLEAVE_IF_ERROR(err);
+ __SQLLEAVE_IF_ERROR2(err);
aMessage.WriteL(2, ipcBuf);
}
@@ -590,7 +588,7 @@
default:
return KErrNotSupported;
};
- __SQLASSERT((TUint)rc < KIpcTraceTypeCount || rc == KErrNotFound, ESqlPanicInternalError);
+ __ASSERT_DEBUG((TUint)rc < KIpcTraceTypeCount || rc == KErrNotFound, __SQLPANIC2(ESqlPanicInternalError));
return rc;
}
@@ -603,7 +601,7 @@
TInt err = HAL::Get(HAL::EFastCounterFrequency, freq);
if(err != KErrNone)
{
- SqlPanic((TSqlPanic)err);
+ __SQLPANIC2((TSqlPanic)err);
}
}
TInt64 diffTicks = (TInt64)aEndTicks - (TInt64)aStartTicks;
@@ -1011,22 +1009,22 @@
void TSqlSrvResourceProfiler::StartL(const RMessage2&)
{
- __SQLLEAVE(KErrNotSupported);
+ __SQLLEAVE2(KErrNotSupported);
}
void TSqlSrvResourceProfiler::StopL(const RMessage2&)
{
- __SQLLEAVE(KErrNotSupported);
+ __SQLLEAVE2(KErrNotSupported);
}
void TSqlSrvResourceProfiler::ResetL(const RMessage2&)
{
- __SQLLEAVE(KErrNotSupported);
+ __SQLLEAVE2(KErrNotSupported);
}
void TSqlSrvResourceProfiler::QueryL(const RMessage2&)
{
- __SQLLEAVE(KErrNotSupported);
+ __SQLLEAVE2(KErrNotSupported);
}
#endif//_SQLPROFILER
--- a/persistentstorage/sql/SRC/Server/SqlSrvSession.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvSession.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,12 @@
#include "SqlSrvBlob.h"
#include "SqlResourceProfiler.h"
#include "SqlCompact.h"
-#include "UTraceSql.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSrvSessionTraces.h"
+#endif
+#include "SqlTraceDef.h"
+
///////////////////////////////////////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -159,7 +164,7 @@
template <class T> T& SqlSessObjFind(RDbObjContainer<T>& aContainer, TInt aHandle, const RMessage2& aMessage)
{
T* obj = aContainer.Find(aHandle);
- __SQLPANIC_CLIENT(obj != NULL, aMessage, ESqlPanicBadArgument);
+ __SQLPANIC_CLIENT2(obj != NULL, aMessage, ESqlPanicBadArgument);
return *obj;
}
@@ -183,6 +188,7 @@
if(aError == KSqlErrFull && !HasFreeDiskSpace(aFs, aDrive))
{
aError = KErrDiskFull;
+ SQL_TRACE_SESSION(OstTrace1(TRACE_INTERNALS, CONVERTSQLFULL2DISKFULLERRROR, "0;ConvertSqlFull2DiskFullErr;aError=KSqlErrFull;!HasFreeDiskSpace();aDrive=%d", (TInt)aDrive));
}
return aError;
}
@@ -206,10 +212,12 @@
*/
CSqlSrvSession* CSqlSrvSession::NewL()
{
+ SQL_TRACE_SESSION(OstTrace0(TRACE_INTERNALS, CSQLSRVSESSION_NEWL_ENTRY, "Entry;0;CSqlSrvSession::NewL"));
CSqlSrvSession* self = new (ELeave) CSqlSrvSession;
CleanupStack::PushL(self);
self->ConstructL();
CleanupStack::Pop(self);
+ SQL_TRACE_SESSION(OstTrace1(TRACE_INTERNALS, CSQLSRVSESSION_NEWL_EXIT, "Exit;0x%X;CSqlSrvSession::NewL", (TUint)self));
return self;
}
@@ -218,11 +226,13 @@
*/
CSqlSrvSession::~CSqlSrvSession()
{
+ SQL_TRACE_SESSION(OstTraceExt2(TRACE_INTERNALS, CSQLSRVSESSION_CSQLSRVSESSION2_ENTRY, "Entry;0x%X;CSqlSrvSession::~CSqlSrvSession;iDatabase=0x%X", (TUint)this, (TUint)iDatabase));
StopDbTestMode();
DbFreeReservedSpace();
iIpcStreams.Close();
iStatements.Close();
delete iDatabase;
+ SQL_TRACE_SESSION(OstTrace1(TRACE_INTERNALS, CSQLSRVSESSION_CSQLSRVSESSION2_EXIT, "Exit;0x%X;CSqlSrvSession::~CSqlSrvSession", (TUint)this));
}
/**
@@ -247,11 +257,9 @@
{
SQLPROFILER_REPORT_IPC(ESqlIpcRq, 0);
}
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(TPtrC8 funcName = GetIPCFuncStr(funcCode));
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EBorder), KSrvMsgStr, &funcName));
-
- SQLPROFILER_IPC_START(iIpcCounter, iDatabase ? (TUint)iDatabase->RawDbHandle() : 0);
-
+ __SQLTRACE_SESSIONEXPR(++iIpcCallCounter);
+ SQL_TRACE_SESSION(OstTraceExt4(TRACE_INTERNALS, CSQLSRVSESSION_SERVICEL_ENTRY, "Entry;0x%X;CSqlSrvSession::ServiceL;aMessage.Handle()=0x%X;funcCode=0x%X;iIpcCallCounter=%u", (TUint)this, (TUint)aMessage.Handle(), (TUint)funcCode, iIpcCallCounter));
+ SQLPROFILER_IPC_START(iIpcCallCounter, iDatabase ? (TUint)iDatabase->RawDbHandle() : 0);
switch(funcCode)
{
////////////////////// resource check operations ///////////////////////////
@@ -447,7 +455,7 @@
{
aMessage.Complete(retCode);
}
- SQLPROFILER_IPC_END(iIpcCounter, funcCode, iDatabase ? (TUint)iDatabase->RawDbHandle() : 0, iIpcTraceData, retCode);
+ SQL_TRACE_SESSION(OstTraceExt4(TRACE_INTERNALS, CSQLSRVSESSION_SERVICEL_EXIT, "Exit;0x%X;CSqlSrvSession::ServiceL;funcCode=0x%X;retCode=%d;iIpcCallCounter=%u", (TUint)this, (TUint)funcCode, retCode, iIpcCallCounter));
}
/**
@@ -457,6 +465,7 @@
*/
void CSqlSrvSession::ServiceError(const RMessage2& aMessage, TInt aError)
{
+ SQL_TRACE_SESSION(OstTraceExt4(TRACE_INTERNALS, CSQLSRVSESSION_SERVICEERROR_ENTRY, "Entry;0x%X;CSqlSrvSession::ServiceError;aMessage.Function()=0x%X;aError=%d;iIpcCallCounter=%u", (TUint)this, (TUint)aMessage.Function(), aError, iIpcCallCounter));
Server().MinimizeBuffers();
aError = ::ConvertSqlFull2DiskFullErr(aError, Server().FileData().Fs(), iDrive);
if(aError == KErrBadDescriptor)
@@ -464,15 +473,12 @@
//The __SQLPANIC_CLIENT() macro cannot be used here because it calls a leaving function. A leaving call
//from a leaving call will terminate the server.
_LIT(KPanicCategory, "SqlDb");
-
- SYMBIAN_TRACE_SQL_ERR_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EError), KSqlSrvPanicClient, aError));
aMessage.Panic(KPanicCategory, ESqlPanicBadDescriptor);
}
-
- SYMBIAN_TRACE_SQL_ERR_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EError), KSqlSrvError, aError));
- SQLPROFILER_IPC_ERROR(iIpcCounter, static_cast <TSqlSrvFunction> (KSqlSrvFunctionMask & aMessage.Function()),
+ SQLPROFILER_IPC_ERROR(iIpcCallCounter, static_cast <TSqlSrvFunction> (KSqlSrvFunctionMask & aMessage.Function()),
iDatabase ? (TUint)iDatabase->RawDbHandle() : 0, aError);
CSession2::ServiceError(aMessage, aError);
+ SQL_TRACE_SESSION(OstTraceExt3(TRACE_INTERNALS, CSQLSRVSESSION_SERVICEERROR_EXIT, "Exit;0x%X;CSqlSrvSession::ServiceError;aMessage.Function()=0x%X;iIpcCallCounter=%u", (TUint)this, (TUint)aMessage.Function(), iIpcCallCounter));
}
///////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -726,10 +732,8 @@
__SQLLEAVE(KErrPermissionDenied);
}
}
- #ifdef _NOTIFY
- TPtrC fname = fileData.FileName();
- RDebug::Print(_L("--SrvSess, delete, fname=\"%S\"\r\n"), &fname);
- #endif
+ __SQLTRACE_SESSIONVAR(TPtrC fname(fileData.FileName()));
+ SQL_TRACE_SESSION(OstTraceExt2(TRACE_INTERNALS, CSQLSRVSESSION_DBDELETEFILEL, "0x%X;CSqlSrvSession::DbDeleteFileL;file='%S'", (TUint)this, __SQLPRNSTR(fname)));
__SQLLEAVE_IF_ERROR(fileData.Fs().Delete(fileData.FileName()));
}
@@ -1166,7 +1170,7 @@
__SQLLEAVE(KErrBadName);
}
}
- __SQLASSERT(len > 0, ESqlPanicInternalError);//The "if" above should have hanled the case with "len == 0"
+ __ASSERT_DEBUG(len > 0, __SQLPANIC2(ESqlPanicInternalError));//The "if" above should have hanled the case with "len == 0"
if((TUint)len > KMaxFileName)
{
__SQLLEAVE(KErrBadName);
@@ -1380,7 +1384,7 @@
SQLPROFILER_REPORT_IPC(ESqlIpcWrite, size);
}
__SQLLEAVE_IF_ERROR(err);
- __SQLASSERT(err == KSqlAtRow || err == KSqlAtEnd, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err == KSqlAtRow || err == KSqlAtEnd, __SQLPANIC(ESqlPanicInternalError));
return err;
}
@@ -1550,7 +1554,7 @@
aStreamBuf->PushL();
iIpcStreams.AllocL();
TInt size = aStreamBuf->SizeL();
- __SQLASSERT(size >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(size >= 0, __SQLPANIC(ESqlPanicInternalError));
TPckgBuf<TIpcStreamBuf> ipcBuf;
// read the first buffer-full
TInt len = Min(size, KIpcBufSize);
--- a/persistentstorage/sql/SRC/Server/SqlSrvSession.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvSession.h Tue Aug 31 16:57:14 2010 +0300
@@ -135,8 +135,8 @@
TBool iDriveSpaceReserved; //True if this session reserved drive space
TBool iDriveSpaceInUse; //True if the client has been given an access to the reserved drive space
TDriveNumber iDrive; //the drive number, where the database file is
+ TUint iIpcCallCounter;
#ifdef _SQLPROFILER
- TUint iIpcCounter;
TSqlSrvIpcTraceData iIpcTraceData[KIpcTraceTypeCount];
#endif
};
--- a/persistentstorage/sql/SRC/Server/SqlSrvStatement.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvStatement.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -9,7 +9,7 @@
// Nokia Corporation - initial contribution.
//
// Contributors:
-// NTT DOCOMO, INC - Fix for Bug 1915 "SQL server panics when using long column type strings"
+// NTT DOCOMO, INC - Fix for defect 1915 "SQL server panics when using long column type strings"
//
// Description:
//
@@ -21,7 +21,12 @@
#include "SqlSrvStatement.h"
#include "SqlBufIterator.h" //TSqlBufRIterator
#include "SqlSrvResourceProfiler.h"
-#include "UTraceSql.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSrvStatementTraces.h"
+#endif
+#include "SqlTraceDef.h"
+
//////////////////////////////////////////////////////////////////////////////////////////////////////
///////////////////////////// local const data ////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -137,14 +142,16 @@
*/
CSqlSrvStatement* CSqlSrvStatement::NewLC(sqlite3* aDbHandle, const TDesC16& aSqlStmt, TInt& aColumnCount, TInt& aParamCount)
{
- __SQLASSERT(aSqlStmt.Length() > 0 ? (TInt)aSqlStmt[aSqlStmt.Length() - 1] == 0 : ETrue, ESqlPanicBadArgument);
+ __SQLTRACE_INTERNALSEXPR(TPtrC sqlprnptr(aSqlStmt.Left(aSqlStmt.Length() - 1)));
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVSTATEMENT_NEWLC_ENTRY, "Entry;0;CSqlSrvStatement::NewLC-16;aDbHandle=0x%X;aSqlStmt=%S", (TUint)aDbHandle, __SQLPRNSTR(sqlprnptr)));
+ __ASSERT_DEBUG(aSqlStmt.Length() > 0 ? (TInt)aSqlStmt[aSqlStmt.Length() - 1] == 0 : ETrue, __SQLPANIC2(ESqlPanicBadArgument));
CSqlSrvStatement* self = new (ELeave) CSqlSrvStatement;
CleanupStack::PushL(self);
self->ConstructL(aDbHandle, aSqlStmt);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KSrvStmtCreated, self));
aColumnCount = self->iColumnCount;
aParamCount = self->iParamCount;
+ SQL_TRACE_INTERNALS(OstTraceExt4(TRACE_INTERNALS, CSQLSRVSTATEMENT_NEWLC_EXIT, "Exit;0x%X;CSqlSrvStatement::NewLC-16;iStmtHandle=0x%X;aColumnCount=%d;aParamCount=%d", (TUint)self, (TUint)self->iStmtHandle, aColumnCount, aParamCount));
return self;
}
@@ -169,14 +176,17 @@
*/
CSqlSrvStatement* CSqlSrvStatement::NewLC(sqlite3* aDbHandle, const TDesC8& aSqlStmt, TInt& aColumnCount, TInt& aParamCount)
{
- __SQLASSERT(aSqlStmt.Length() > 0 ? (TInt)aSqlStmt[aSqlStmt.Length() - 1] == 0 : ETrue, ESqlPanicBadArgument);
+ __SQLTRACE_INTERNALSEXPR(TPtrC8 sqlprnptr(aSqlStmt.Left(aSqlStmt.Length() - 1)));
+ __SQLTRACE_INTERNALSVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVSTATEMENT_NEWLC_ENTRY2, "Entry;0;CSqlSrvStatement::NewLC-8;aDbHandle=0x%X;aSqlStmt=%s", (TUint)aDbHandle, __SQLPRNSTR8(sqlprnptr, des16prnbuf)));
+ __ASSERT_DEBUG(aSqlStmt.Length() > 0 ? (TInt)aSqlStmt[aSqlStmt.Length() - 1] == 0 : ETrue, __SQLPANIC2(ESqlPanicBadArgument));
CSqlSrvStatement* self = new (ELeave) CSqlSrvStatement;
CleanupStack::PushL(self);
self->ConstructL(aDbHandle, aSqlStmt);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KSrvStmtCreated, self));
aColumnCount = self->iColumnCount;
aParamCount = self->iParamCount;
+ SQL_TRACE_INTERNALS(OstTraceExt4(TRACE_INTERNALS, CSQLSRVSTATEMENT_NEWLC_EXIT2, "Exit;0x%X;CSqlSrvStatement::NewLC-8;iStmtHandle=0x%X;aColumnCount=%d;aParamCount=%d", (TUint)self, (TUint)self->iStmtHandle, aColumnCount, aParamCount));
return self;
}
@@ -185,17 +195,19 @@
*/
CSqlSrvStatement::~CSqlSrvStatement()
{
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, CSQLSRVSTATEMENT_CSQLSRVSTATEMENT2_ENTRY, "Entry;0x%X;CSqlSrvStatement::~CSqlSrvStatement;iStmtHandle=0x%X", (TUint)this, (TUint)iStmtHandle));
DestroyParamBufArray();
iBufFlat.Close();
if(iStmtHandle)
{
-#ifdef SYMBIAN_TRACE_SQL_EVENTS
- TInt scanCount = sqlite3_stmt_status(iStmtHandle, SQLITE_STMTSTATUS_FULLSCAN_STEP, ETrue);
- TInt sortCount = sqlite3_stmt_status(iStmtHandle, SQLITE_STMTSTATUS_SORT, ETrue);
- SYMBIAN_TRACE_SQL_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KSrvStmtStatus, this, scanCount, sortCount));
-#endif
+#ifdef SYMBIAN_USE_SQLITE_VERSION_3_6_4
+ __SQLTRACE_INTERNALSEXPR(TInt scanCount = sqlite3_stmt_status(iStmtHandle, SQLITE_STMTSTATUS_FULLSCAN_STEP, ETrue));
+ __SQLTRACE_INTERNALSEXPR(TInt sortCount = sqlite3_stmt_status(iStmtHandle, SQLITE_STMTSTATUS_SORT, ETrue));
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, CSQLSRVSTATEMENT_CSQLSRVSTATEMENT2, "0x%X;CSqlSrvStatement::~CSqlSrvStatement;scan count=%d;sort count=%d", (TUint)this, scanCount, sortCount));
+#endif
(void)sqlite3_finalize(iStmtHandle);
}
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, CSQLSRVSTATEMENT_CSQLSRVSTATEMENT2_EXIT, "Exit;0x%X;CSqlSrvStatement::~CSqlSrvStatement", (TUint)this));
}
/**
@@ -214,7 +226,7 @@
*/
void CSqlSrvStatement::BindL(const RSqlBufFlat& aParamBuf)
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
(void)sqlite3SymbianLastOsError();//clear last OS error
@@ -282,7 +294,7 @@
*/
const RSqlBufFlat& CSqlSrvStatement::ColumnNamesL()
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
iBufFlatType = static_cast <TSqlBufFlatType> (-1);
__SQLLEAVE_IF_ERROR(iBufFlat.SetCount(iColumnCount));
TSqlBufWIterator it;
@@ -311,7 +323,7 @@
*/
const RSqlBufFlat& CSqlSrvStatement::ParamNamesL()
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
iBufFlatType = static_cast <TSqlBufFlatType> (-1);
__SQLLEAVE_IF_ERROR(iBufFlat.SetCount(iParamCount));
TSqlBufWIterator it;
@@ -353,7 +365,7 @@
*/
const RSqlBufFlat& CSqlSrvStatement::ColumnValuesL()
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
iBufFlatType = static_cast <TSqlBufFlatType> (-1);
iBufFlat.SetCount(iColumnCount);
@@ -393,7 +405,7 @@
{//sqlite3_column_bytes16() already allocated the needed memory if a UTF8->UTF16 conversion
//had to be performed. The sqlite3_column_text16() on the next line is guaranteed to succeed.
const TUint16* text = reinterpret_cast <const TUint16*> (sqlite3_column_text16(iStmtHandle, colIdx));
- __SQLASSERT(text != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(text != NULL, __SQLPANIC(ESqlPanicInternalError));
__SQLLEAVE_IF_ERROR(it.SetText(TPtrC16(text, charLength)));
}
}
@@ -415,7 +427,7 @@
it.SetNull();
break;
default:
- __SQLASSERT(EFalse, ESqlPanicInternalError);
+ __ASSERT_DEBUG(EFalse, __SQLPANIC(ESqlPanicInternalError));
break;
}//end of switch(...)
}//end of - while(it.Next())
@@ -437,15 +449,15 @@
*/
TInt CSqlSrvStatement::ColumnSource(TInt aColumnIndex, TPtrC8& aColumnSource) const
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
TInt colType = sqlite3_column_type(iStmtHandle, aColumnIndex);
if(colType == SQLITE_TEXT)
{//Since the first called function after the Next() operation is always CSqlSrvStatement::ColumnValuesL(), then
//sqlite3_column_bytes16() (called from ColumnValuesL()) already allocated the needed memory if a UTF8->UTF16
//conversion had to be performed. The sqlite3_column_text16() on the next line is guaranteed to succeed.
const void* text = sqlite3_column_text16(iStmtHandle, aColumnIndex);
- __SQLASSERT(text != NULL, ESqlPanicInternalError);
- TInt length = sqlite3_column_bytes16(iStmtHandle, aColumnIndex);
+ __ASSERT_DEBUG(text != NULL, __SQLPANIC2(ESqlPanicInternalError));
+ TInt length = sqlite3_column_bytes16(iStmtHandle, aColumnIndex);
aColumnSource.Set(reinterpret_cast <const TUint8*> (text), length);
}
else if(colType == SQLITE_BLOB)
@@ -468,7 +480,7 @@
*/
void CSqlSrvStatement::DoCommonConstructL()
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
iColumnCount = sqlite3_column_count(iStmtHandle);
iParamCount = sqlite3_bind_parameter_count(iStmtHandle);
__SQLLEAVE_IF_ERROR(iBufFlat.SetCount(Max(iColumnCount, iParamCount)));
@@ -507,10 +519,10 @@
*/
void CSqlSrvStatement::BindParamBufL(TInt aParamIndex)
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
- __SQLASSERT(aParamIndex >= 0 && aParamIndex < sqlite3_bind_parameter_count(iStmtHandle), ESqlPanicBadArgument);
- __SQLASSERT(aParamIndex < iParamBufArray.Count(), ESqlPanicBadArgument);
- __SQLASSERT(iParamBufArray[aParamIndex] != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ __ASSERT_DEBUG(aParamIndex >= 0 && aParamIndex < sqlite3_bind_parameter_count(iStmtHandle), __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aParamIndex < iParamBufArray.Count(), __SQLPANIC(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(iParamBufArray[aParamIndex] != NULL, __SQLPANIC(ESqlPanicBadArgument));
(void)sqlite3SymbianLastOsError();//clear last OS error
//Bind the parameter value.
//SQLITE_STATIC is used as an argument, because the text/blob data will be kept and can be used by the next bind call
@@ -546,8 +558,8 @@
*/
TInt CSqlSrvStatement::ColumnInt(TInt aColIdx) const
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
- __SQLASSERT((TUint)aColIdx < iColumnCount, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ __ASSERT_DEBUG((TUint)aColIdx < iColumnCount, __SQLPANIC(ESqlPanicBadArgument));
TInt colType = sqlite3_column_type(iStmtHandle, aColIdx);
switch(colType)
{
@@ -586,8 +598,8 @@
*/
TInt64 CSqlSrvStatement::ColumnInt64(TInt aColIdx) const
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
- __SQLASSERT((TUint)aColIdx < iColumnCount, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ __ASSERT_DEBUG((TUint)aColIdx < iColumnCount, __SQLPANIC(ESqlPanicBadArgument));
TInt colType = sqlite3_column_type(iStmtHandle, aColIdx);
switch(colType)
{
@@ -623,8 +635,8 @@
*/
TReal CSqlSrvStatement::ColumnReal(TInt aColIdx) const
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
- __SQLASSERT((TUint)aColIdx < iColumnCount, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ __ASSERT_DEBUG((TUint)aColIdx < iColumnCount, __SQLPANIC(ESqlPanicBadArgument));
TInt colType = sqlite3_column_type(iStmtHandle, aColIdx);
switch(colType)
{
@@ -657,8 +669,8 @@
*/
TPtrC CSqlSrvStatement::ColumnTextL(TInt aColIdx) const
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
- __SQLASSERT((TUint)aColIdx < iColumnCount, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ __ASSERT_DEBUG((TUint)aColIdx < iColumnCount, __SQLPANIC(ESqlPanicBadArgument));
TPtrC res;
TInt colType = sqlite3_column_type(iStmtHandle, aColIdx);
if(colType == SQLITE_TEXT)
@@ -673,8 +685,8 @@
//sqlite3_column_bytes16() already allocated the needed memory if a UTF8->UTF16 conversion
//had to be performed. The sqlite3_column_text16() on the next line is guaranteed to succeed.
const TUint16* text = reinterpret_cast <const TUint16*> (sqlite3_column_text16(iStmtHandle, aColIdx));
- __SQLASSERT(text != NULL, ESqlPanicInternalError);
- res.Set(text, charLength);
+ __ASSERT_DEBUG(text != NULL, __SQLPANIC(ESqlPanicInternalError));
+ res.Set(text, charLength);
}
return res;
}
@@ -692,8 +704,8 @@
*/
TPtrC8 CSqlSrvStatement::ColumnBinary(TInt aColIdx) const
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
- __SQLASSERT((TUint)aColIdx < iColumnCount, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ __ASSERT_DEBUG((TUint)aColIdx < iColumnCount, __SQLPANIC(ESqlPanicBadArgument));
TPtrC8 res;
TInt colType = sqlite3_column_type(iStmtHandle, aColIdx);
if(colType == SQLITE_BLOB)
@@ -716,8 +728,8 @@
*/
const RSqlBufFlat& CSqlSrvStatement::GetDeclColumnTypesL()
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
- iBufFlatType = static_cast <TSqlBufFlatType> (-1);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ iBufFlatType = static_cast <TSqlBufFlatType> (-1);
__SQLLEAVE_IF_ERROR(iBufFlat.SetCount(iColumnCount));
TSqlBufWIterator it;
it.Set(iBufFlat);
@@ -761,12 +773,12 @@
HSqlSrvStmtParamBuf* CSqlSrvStatement::GetParamBufL(TInt aParamIndex, HSqlSrvStmtParamBuf::TDataType aDataType,
HSqlSrvStmtParamBuf::TBufType aBufType)
{
- __SQLASSERT(aParamIndex >= 0 && aParamIndex < sqlite3_bind_parameter_count(iStmtHandle), ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aParamIndex >= 0 && aParamIndex < sqlite3_bind_parameter_count(iStmtHandle), __SQLPANIC(ESqlPanicBadArgument));
ExtendParamBufArrayL(aParamIndex);
HSqlSrvStmtParamBuf*& paramBuf = iParamBufArray[aParamIndex];
if(paramBuf)
{//Reset and reuse the existing buffer
- __SQLASSERT(paramBuf->ParamIndex() == aParamIndex, ESqlPanicInternalError);
+ __ASSERT_DEBUG(paramBuf->ParamIndex() == aParamIndex, __SQLPANIC(ESqlPanicInternalError));
paramBuf->Reset(aDataType, aBufType);
}
else
@@ -789,8 +801,8 @@
*/
void CSqlSrvStatement::ExtendParamBufArrayL(TInt aParamIndex)
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
- __SQLASSERT(aParamIndex >= 0 && aParamIndex < sqlite3_bind_parameter_count(iStmtHandle), ESqlPanicBadArgument);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ __ASSERT_DEBUG(aParamIndex >= 0 && aParamIndex < sqlite3_bind_parameter_count(iStmtHandle), __SQLPANIC(ESqlPanicBadArgument));
TInt ext = aParamIndex - iParamBufArray.Count() + 1;
while(ext-- > 0)
{
@@ -815,8 +827,8 @@
*/
TPtrC8 CSqlSrvStatement::CopyAndStoreParamL(TInt aParamIndex, HSqlSrvStmtParamBuf::TDataType aDataType, const TDesC8& aParamValue)
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
- __SQLASSERT(aParamIndex >= 0 && aParamIndex < sqlite3_bind_parameter_count(iStmtHandle), ESqlPanicBadArgument);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ __ASSERT_DEBUG(aParamIndex >= 0 && aParamIndex < sqlite3_bind_parameter_count(iStmtHandle), __SQLPANIC(ESqlPanicBadArgument));
HSqlSrvStmtParamBuf* paramBuf = GetParamBufL(aParamIndex, aDataType, HSqlSrvStmtParamBuf::EBufSimpleBind);
return paramBuf->SetDataL(aParamValue);
}
--- a/persistentstorage/sql/SRC/Server/SqlSrvStatement.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvStatement.h Tue Aug 31 16:57:14 2010 +0300
@@ -9,7 +9,7 @@
// Nokia Corporation - initial contribution.
//
// Contributors:
-// NTT DOCOMO, INC - Fix for Bug 1915 "SQL server panics when using long column type strings"
+// NTT DOCOMO, INC - Fix for defect 1915 "SQL server panics when using long column type strings"
//
// Description:
//
--- a/persistentstorage/sql/SRC/Server/SqlSrvStatement.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvStatement.inl Tue Aug 31 16:57:14 2010 +0300
@@ -33,7 +33,7 @@
inline HSqlSrvStmtParamBuf* HSqlSrvStmtParamBuf::NewL(CSqlSrvStatement& aStatement, TInt aParamIndex,
HSqlSrvStmtParamBuf::TDataType aDataType, HSqlSrvStmtParamBuf::TBufType aBufType)
{
- __SQLASSERT(aParamIndex >= 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aParamIndex >= 0, __SQLPANIC2(ESqlPanicBadArgument));
HSqlSrvStmtParamBuf* self = new (ELeave) HSqlSrvStmtParamBuf(aStatement, aParamIndex, aDataType, aBufType);
self->PushL();
self->ConstructL();
@@ -53,7 +53,7 @@
*/
inline void HSqlSrvStmtParamBuf::Reset(HSqlSrvStmtParamBuf::TDataType aDataType, HSqlSrvStmtParamBuf::TBufType aBufType)
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInvalidObj));
iStatementFinalized = EFalse;
iAlive = ETrue;
@@ -65,7 +65,7 @@
if(iBuf->Capacity() > (HSqlSrvStmtParamBuf::EExpandSize * 2))
{
TRAPD(err, iBuf->SetReserveL(HSqlSrvStmtParamBuf::EExpandSize * 2));//the buffer size is minimized, the call can't fail
- __SQLASSERT_ALWAYS(err == KErrNone, ESqlPanicInternalError);
+ __ASSERT_ALWAYS(err == KErrNone, __SQLPANIC(ESqlPanicInternalError));
}
Set(*iBuf, 0, MStreamBuf::ERead | MStreamBuf::EWrite);
}
@@ -83,8 +83,8 @@
*/
inline const TPtrC8 HSqlSrvStmtParamBuf::SetDataL(const TDesC8& aData)
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInvalidObj);
- __SQLASSERT(iBufType == HSqlSrvStmtParamBuf::EBufSimpleBind, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInvalidObj));
+ __ASSERT_DEBUG(iBufType == HSqlSrvStmtParamBuf::EBufSimpleBind, __SQLPANIC(ESqlPanicInternalError));
iBuf->ResizeL(aData.Length());
iBuf->Write(0, aData);
//If the size is 0, then return KNullDesC8, where an empty string is hold, not a null one ("" instead of NULL)
@@ -100,7 +100,7 @@
*/
inline const TPtrC8 HSqlSrvStmtParamBuf::Data() const
{
- __SQLASSERT(iBuf != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iBuf != NULL, __SQLPANIC(ESqlPanicInvalidObj));
//If the size is 0, then return KNullDesC8, where an empty string is hold, not a null one ("" instead of NULL)
return iBuf->Size() == 0 ? KNullDesC8() : iBuf->Ptr(0);
}
@@ -122,7 +122,7 @@
*/
inline TInt HSqlSrvStmtParamBuf::ParamIndex() const
{
- __SQLASSERT(iParamIndex >= 0, ESqlPanicInternalError);
+ __ASSERT_DEBUG(iParamIndex >= 0, __SQLPANIC(ESqlPanicInternalError));
return iParamIndex;
}
@@ -182,7 +182,7 @@
*/
inline TInt CSqlSrvStatement::Next()
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
TInt err = ::StmtNext(iStmtHandle);
iBufFlatType = static_cast <TSqlBufFlatType> (-1);
iBufFlat.ResetAndMinimize();
@@ -202,7 +202,7 @@
*/
inline TInt CSqlSrvStatement::Reset()
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
iBufFlatType = static_cast <TSqlBufFlatType> (-1);
iBufFlat.ResetAndMinimize();
return ::StmtReset(iStmtHandle);
@@ -221,7 +221,7 @@
*/
inline TInt CSqlSrvStatement::Exec()
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
TInt err = ::StmtExec(iStmtHandle);
iBufFlatType = static_cast <TSqlBufFlatType> (-1);
iBufFlat.ResetAndMinimize();
@@ -233,7 +233,7 @@
*/
inline const RSqlBufFlat& CSqlSrvStatement::BufFlatL(TSqlBufFlatType aWhat) const
{
- __SQLASSERT(iStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(iStmtHandle != NULL, __SQLPANIC(ESqlPanicInvalidObj));
if(aWhat != iBufFlatType)
{
__SQLLEAVE(KErrArgument);
@@ -262,7 +262,7 @@
*/
inline void CSqlSrvStatement::ConstructL(sqlite3* aDbHandle, const TDesC16& aSqlStmt)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC(ESqlPanicBadArgument));
iStmtHandle = ::StmtPrepare16L(aDbHandle, aSqlStmt);
DoCommonConstructL();
}
@@ -282,7 +282,7 @@
*/
inline void CSqlSrvStatement::ConstructL(sqlite3* aDbHandle, const TDesC8& aSqlStmt)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC(ESqlPanicBadArgument));
iStmtHandle = ::StmtPrepare8L(aDbHandle, aSqlStmt);
DoCommonConstructL();
}
--- a/persistentstorage/sql/SRC/Server/SqlSrvStatementUtil.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvStatementUtil.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -18,11 +18,16 @@
#include <sqldb.h>
#include "sqlite3.h"
#include "SqlSrvStatementUtil.h"
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlSrvUtil.h"
#include "SqlUtil.h"
#include "SqliteSymbian.h" //sqlite3SymbianLastOsError()
+#include "OstTraceDefinitions.h"
#include "SqlSrvResourceProfiler.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSrvStatementUtilTraces.h"
+#endif
+#include "SqlTraceDef.h"
//The database names in all statements are quoted to avoid the "sql injection" threat.
_LIT8(KPageCountPragma, "PRAGMA \"%S\".page_count\x0");
@@ -35,109 +40,6 @@
///////////////////////////////////////////////////////////////////////////////////////////////////////////////
-#ifdef _NOTIFY
-static void PrintErrMsg8(TBool aCondition, sqlite3* aDbHandle, const char* aFuncNameZ, const TDesC8& aStmt)
- {
- if(!aCondition)
- {
- return;
- }
- TPtrC8 funcName8(reinterpret_cast <const TUint8*> (aFuncNameZ));
- TBuf<32> funcName;
- funcName.Copy(funcName8);
- RDebug::Print(_L("###%S\r\n"), &funcName);
- TInt stmtLen = aStmt.Length();
- if(stmtLen > 0)
- {
- if(aStmt[stmtLen - 1] == 0)
- {
- --stmtLen;
- }
- HBufC* buf = HBufC::New(stmtLen);
- if(buf)
- {
- TPtr sqlStmt = buf->Des();
- sqlStmt.Copy(aStmt.Left(stmtLen));
- if(sqlStmt.Length() > 250)
- {
- sqlStmt.SetLength(250);
- }
- RDebug::Print(_L("###\"%S\"\r\n"), &sqlStmt);
- delete buf;
- }
- }
- TBuf<16> tbuf;
- Util::GetTimeStr(tbuf);
- const void* errMsg = sqlite3_errmsg16(aDbHandle);//"errMsg" - zero terminated string
- if(errMsg)
- {
- TPtrC msg(reinterpret_cast <const TText16*> (errMsg));//terminating zero character excluded.
- if(msg.Length() > 230)
- {
- msg.Set(msg.Left(230));
- }
- RDebug::Print(_L("##%S#ErrMsg=%S\r\n"), &tbuf, &msg);
- }
- else
- {
- RDebug::Print(_L("##%S#ErrMsg=null\r\n"), &tbuf);
- }
- }
-
-static void PrintErrMsg16(TBool aCondition, sqlite3* aDbHandle, const char* aFuncNameZ, const TDesC16& aStmt)
- {
- if(!aCondition)
- {
- return;
- }
- TPtrC8 funcName8(reinterpret_cast <const TUint8*> (aFuncNameZ));
- TBuf<32> funcName;
- funcName.Copy(funcName8);
- RDebug::Print(_L("###%S\r\n"), &funcName);
- TInt stmtLen = aStmt.Length();
- if(stmtLen > 0)
- {
- if(aStmt[stmtLen - 1] == 0)
- {
- --stmtLen;
- }
- TPtrC sqlStmt(aStmt.Ptr(), stmtLen);
- if(sqlStmt.Length() > 250)
- {
- sqlStmt.Set(sqlStmt.Left(250));
- }
- RDebug::Print(_L("###\"%S\"\r\n"), &sqlStmt);
- }
- TBuf<16> tbuf;
- Util::GetTimeStr(tbuf);
- const void* errMsg = sqlite3_errmsg16(aDbHandle);//"errMsg" - zero terminated string
- if(errMsg)
- {
- TPtrC msg(reinterpret_cast <const TText16*> (errMsg));//terminating zero character excluded.
- if(msg.Length() > 230)
- {
- msg.Set(msg.Left(230));
- }
- RDebug::Print(_L("##%S#ErrMsg=%S\r\n"), &tbuf, &msg);
- }
- else
- {
- RDebug::Print(_L("##%S#ErrMsg=null\r\n"), &tbuf);
- }
- }
-
-#define PRINT_ERRMSG8(Condition, DbHandle, FuncNameZ, Stmt) PrintErrMsg8(Condition, DbHandle, FuncNameZ, Stmt)
-#define PRINT_ERRMSG16(Condition, DbHandle, FuncNameZ, Stmt) PrintErrMsg16(Condition, DbHandle, FuncNameZ, Stmt)
-
-#else //_NOTIFY
-
-#define PRINT_ERRMSG8(Condition, DbHandle, FuncNameZ, Stmt)
-#define PRINT_ERRMSG16(Condition, DbHandle, FuncNameZ, Stmt)
-
-#endif //_NOTIFY
-
-///////////////////////////////////////////////////////////////////////////////////////////////////////////////
-
//Calls sqlite3_open16() to create or open database file with aFileNameZ.
//aFileNameZ is UTF16 encoded, zero-terminated.
//The function returns system-wide errors or database specific errors.
@@ -146,7 +48,7 @@
{
(void)sqlite3SymbianLastOsError();//clear last OS error
TInt err = sqlite3_open16(aFileNameZ.Ptr(), &aDbHandle);
- __SQLASSERT(err == SQLITE_OK ? aDbHandle != NULL : ETrue, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err == SQLITE_OK ? aDbHandle != NULL : ETrue, __SQLPANIC2(ESqlPanicInternalError));
if(err == SQLITE_OK)
{
(void)sqlite3_extended_result_codes(aDbHandle, 0);
@@ -169,7 +71,7 @@
{
(void)sqlite3SymbianLastOsError();//clear last OS error
TInt err = sqlite3_open((const char *) aFileNameZ.Ptr(), &aDbHandle);
- __SQLASSERT(err == SQLITE_OK ? aDbHandle != NULL : ETrue, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err == SQLITE_OK ? aDbHandle != NULL : ETrue, __SQLPANIC2(ESqlPanicInternalError));
if(err == SQLITE_OK)
{
(void)sqlite3_extended_result_codes(aDbHandle, 0);
@@ -202,15 +104,15 @@
//If the function fails then it returns one of the SQLITE error codes.
static TInt DoSingleStmtExec16(sqlite3 *aDbHandle, const TDesC16& aSql)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInvalidObj);
- __SQLASSERT(aSql.Length() > 0 ? (TInt)aSql[aSql.Length() - 1] == 0 : ETrue, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInvalidObj));
+ __ASSERT_DEBUG(aSql.Length() > 0 ? (TInt)aSql[aSql.Length() - 1] == 0 : ETrue, __SQLPANIC2(ESqlPanicBadArgument));
sqlite3_stmt* stmtHandle = NULL;
const void* stmtTail = NULL;
//sqlite3_prepare16_v2() expects parameter #3 to be one of the following:
// - byte length of the sql statement (parameter #2), excluding terminating zero;
// - negative value - the sql statement (parameter #2) is zero-terminated;
TInt err = sqlite3_prepare16_v2(aDbHandle, aSql.Ptr(), aSql.Length() * sizeof(TUint16) - sizeof(TUint16), &stmtHandle, &stmtTail);
- __SQLASSERT(err == SQLITE_OK ? !stmtTail || User::StringLength((const TUint16*)stmtTail) == 0 : !stmtHandle, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err == SQLITE_OK ? !stmtTail || User::StringLength((const TUint16*)stmtTail) == 0 : !stmtHandle, __SQLPANIC2(ESqlPanicInternalError));
if(stmtHandle) //stmtHandle can be NULL for statements like this: ";".
{
if(err == SQLITE_OK)
@@ -221,7 +123,7 @@
if(err == SQLITE_ERROR) //It may be "out of memory" problem
{
err = sqlite3_reset(stmtHandle);
- __SQLASSERT(err != SQLITE_OK, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err != SQLITE_OK, __SQLPANIC2(ESqlPanicInternalError));
}
}
(void)sqlite3_finalize(stmtHandle);//sqlite3_finalize() fails only if an invalid statement handle is passed.
@@ -300,10 +202,13 @@
@internalComponent
*/
-TInt DbExecStmt16(sqlite3 *aDbHandle, TDes16& aSqlStmt)
+TInt DbExecStmt16(sqlite3* aDbHandle, TDes16& aSqlStmt)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
- __SQLASSERT(aSqlStmt.Length() > 0 ? (TInt)aSqlStmt[aSqlStmt.Length() - 1] == 0: ETrue, ESqlPanicBadArgument);
+ __SQLTRACE_INTERNALSEXPR(TPtrC sqlprnptr(aSqlStmt.Left(aSqlStmt.Length() - 1)));
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, DBEXECSTMT16_ENTRY, "Entry;0x%X;DbExecStmt16;sql=%S", (TUint)aDbHandle, __SQLPRNSTR(sqlprnptr)));
+
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aSqlStmt.Length() > 0 ? (TInt)aSqlStmt[aSqlStmt.Length() - 1] == 0: ETrue, __SQLPANIC2(ESqlPanicBadArgument));
(void)sqlite3SymbianLastOsError();//clear last OS error
@@ -325,7 +230,7 @@
{
err = KErrNone;
}
- PRINT_ERRMSG16(err <= KSqlErrGeneral, aDbHandle, "DbExecStmt16()", aSqlStmt);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, DBEXECSTMT16_EXIT, "Exit;0x%X;DbExecStmt16;err=%d", (TUint)aDbHandle, err));
return err;
}
@@ -349,10 +254,14 @@
@internalComponent
*/
-TInt DbExecStmt8(sqlite3 *aDbHandle, const TDesC8& aSqlStmt)
+TInt DbExecStmt8(sqlite3* aDbHandle, const TDesC8& aSqlStmt)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
- __SQLASSERT(aSqlStmt.Length() > 0 ? (TInt)aSqlStmt[aSqlStmt.Length() - 1] == 0: ETrue, ESqlPanicBadArgument);
+ __SQLTRACE_INTERNALSEXPR(TPtrC8 sqlprnptr(aSqlStmt.Left(aSqlStmt.Length() - 1)));
+ __SQLTRACE_INTERNALSVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, DBEXECSTMT8_ENTRY, "Entry;0x%X;DbExecStmt8;sql=%s", (TUint)aDbHandle, __SQLPRNSTR8(sqlprnptr, des16prnbuf)));
+
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aSqlStmt.Length() > 0 ? (TInt)aSqlStmt[aSqlStmt.Length() - 1] == 0: ETrue, __SQLPANIC2(ESqlPanicBadArgument));
SQLPROFILER_SQL8_PRINT((TUint)aDbHandle, aSqlStmt.Left(aSqlStmt.Length() - 1), EFalse);
@@ -365,7 +274,7 @@
{
err = KErrNone;
}
- PRINT_ERRMSG8(err <= KSqlErrGeneral, aDbHandle, "DbExecStmt8()", aSqlStmt);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, DBEXECSTMT8_EXIT, "Exit;0x%X;DbExecStmt8;err=%d", (TUint)aDbHandle, err));
return err;
}
@@ -385,8 +294,7 @@
// - negative value - the sql statement (parameter #2) is zero-terminated;
TInt err = sqlite3_prepare16_v2(aDbHandle, aStmt.Ptr(), aStmt.Length() * sizeof(TUint16) - sizeof(TUint16), aStmtHandle, &stmtTail);
aHasTail = stmtTail && static_cast <const TUint16*> (stmtTail)[0] != 0;
- PRINT_ERRMSG16(err != SQLITE_OK, aDbHandle, "DoPrepareStmt16()", aStmt);
- __SQLASSERT(err != SQLITE_OK ? !(*aStmtHandle) : ETrue, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err != SQLITE_OK ? !(*aStmtHandle) : ETrue, __SQLPANIC2(ESqlPanicInternalError));
//(*aStmtHandle) is NULL for ";" statements, when err == SQLITE_OK. Since the server should not panic
//that situation is handled later (not inside the assert above)
return err;
@@ -404,8 +312,7 @@
// - negative value - the sql statement (parameter #2) is zero-terminated;
TInt err = sqlite3_prepare_v2(aDbHandle, reinterpret_cast <const char*> (aStmt), -1, aStmtHandle, &stmtTail);
aHasTail = stmtTail && stmtTail[0] != 0;
- PRINT_ERRMSG8(err != SQLITE_OK, aDbHandle, "DoPrepareStmt8()", TPtrC8(aStmt, aStmt ? User::StringLength(aStmt) : 0));
- __SQLASSERT(err != SQLITE_OK ? !(*aStmtHandle) : ETrue, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err != SQLITE_OK ? !(*aStmtHandle) : ETrue, __SQLPANIC2(ESqlPanicInternalError));
//(*aStmtHandle) is NULL for ";" statements, when err == SQLITE_OK. Since the server should not panic
//that situation is handled later (not inside the assert above)
return err;
@@ -451,7 +358,7 @@
//
static void LeaveIfPrepareErrorL(TInt aSqliteError, TBool aHasTail, sqlite3_stmt* aStmtHandle)
{
- __SQLLEAVE_IF_ERROR(ProcessPrepareError(aSqliteError, aHasTail, aStmtHandle));
+ __SQLLEAVE_IF_ERROR2(ProcessPrepareError(aSqliteError, aHasTail, aStmtHandle));
}
/**
@@ -469,13 +376,14 @@
*/
sqlite3_stmt* StmtPrepare16L(sqlite3* aDbHandle, const TDesC16& aSqlStmt)
{
- SQLPROFILER_SQL16_PRINT((TUint)aDbHandle, aSqlStmt.Left(aSqlStmt.Length() - 1), ETrue);
-
+ __SQLTRACE_INTERNALSEXPR(TPtrC sqlprnptr(aSqlStmt.Left(aSqlStmt.Length() - 1)));
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, STMTPREPARE16L_ENTRY, "Entry;0x%X;StmtPrepare16L;sql=%S", (TUint)aDbHandle, __SQLPRNSTR(sqlprnptr)));
(void)sqlite3SymbianLastOsError();//clear last OS error
TBool hasTail = EFalse;
sqlite3_stmt* stmtHandle = NULL;
TInt err = DoPrepareStmt16(aDbHandle, aSqlStmt, &stmtHandle, hasTail);
LeaveIfPrepareErrorL(err, hasTail, stmtHandle);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, STMTPREPARE16L_EXIT, "Exit;0x%X;StmtPrepare16L;stmtHandle=0x%X", (TUint)aDbHandle, (TUint)stmtHandle));
return stmtHandle;
}
@@ -494,12 +402,15 @@
*/
TInt StmtPrepare8(sqlite3* aDbHandle, const TDesC8& aSqlStmt, sqlite3_stmt*& aStmtHandle)
{
- SQLPROFILER_SQL8_PRINT((TUint)aDbHandle, aSqlStmt.Left(aSqlStmt.Length() - 1), ETrue);
-
+ __SQLTRACE_INTERNALSEXPR(TPtrC8 sqlprnptr(aSqlStmt.Left(aSqlStmt.Length() - 1)));
+ __SQLTRACE_INTERNALSVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, STMTPREPARE8_ENTRY, "Entry;0x%X;StmtPrepare8;sql=%s", (TUint)aDbHandle, __SQLPRNSTR8(sqlprnptr, des16prnbuf)));
(void)sqlite3SymbianLastOsError();//clear last OS error
TBool hasTail = EFalse;
TInt err = DoPrepareStmt8(aDbHandle, aSqlStmt.Ptr(), &aStmtHandle, hasTail);
- return ProcessPrepareError(err, hasTail, aStmtHandle);
+ err = ProcessPrepareError(err, hasTail, aStmtHandle);
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, STMTPREPARE8_EXIT, "Exit;0x%X;StmtPrepare8;aStmtHandle=0x%X;err=%d", (TUint)aDbHandle, (TUint)aStmtHandle, err));
+ return err;
}
/**
@@ -517,13 +428,15 @@
*/
sqlite3_stmt* StmtPrepare8L(sqlite3* aDbHandle, const TDesC8& aSqlStmt)
{
- SQLPROFILER_SQL8_PRINT((TUint)aDbHandle, aSqlStmt.Left(aSqlStmt.Length() - 1), ETrue);
-
+ __SQLTRACE_INTERNALSEXPR(TPtrC8 sqlprnptr(aSqlStmt.Left(aSqlStmt.Length() - 1)));
+ __SQLTRACE_INTERNALSVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, STMTPREPARE8L_ENTRY, "Entry;0x%X;StmtPrepare8L;sql=%s", (TUint)aDbHandle, __SQLPRNSTR8(sqlprnptr, des16prnbuf)));
(void)sqlite3SymbianLastOsError();//clear last OS error
TBool hasTail = EFalse;
sqlite3_stmt* stmtHandle = NULL;
TInt err = DoPrepareStmt8(aDbHandle, aSqlStmt.Ptr(), &stmtHandle, hasTail);
LeaveIfPrepareErrorL(err, hasTail, stmtHandle);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, STMTPREPARE8L_EXIT, "Exit;0x%X;StmtPrepare8L;stmtHandle=0x%X", (TUint)aDbHandle, (TUint)stmtHandle));
return stmtHandle;
}
@@ -544,10 +457,11 @@
*/
TInt StmtExec(sqlite3_stmt* aStmtHandle)
{
- __SQLASSERT(aStmtHandle != NULL, ESqlPanicInvalidObj);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, STMTEXEC_ENTRY, "Entry;0x%X;StmtExec;aStmtHandle=0x%X", (TUint)sqlite3_db_handle(aStmtHandle), (TUint)aStmtHandle));
+ __ASSERT_DEBUG(aStmtHandle != NULL, __SQLPANIC2(ESqlPanicInvalidObj));
(void)sqlite3SymbianLastOsError();//clear last OS error
-
+
TInt err;
while((err = sqlite3_step(aStmtHandle)) == SQLITE_ROW)
{
@@ -556,7 +470,7 @@
if(err == SQLITE_ERROR) //It may be "out of memory" problem
{
err = sqlite3_reset(aStmtHandle);
- __SQLASSERT(err != SQLITE_OK, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err != SQLITE_OK, __SQLPANIC2(ESqlPanicInternalError));
}
err = ::Sql2OsErrCode(err, sqlite3SymbianLastOsError());
@@ -565,7 +479,7 @@
err = KErrNone;
}
- PRINT_ERRMSG16(err <= KSqlErrGeneral, sqlite3_db_handle(aStmtHandle), "StmtExec()", _L(" "));
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, STMTEXEC_EXIT, "Exit;0x%X;StmtExec;aStmtHandle=0x%X;err=%d", (TUint)sqlite3_db_handle(aStmtHandle), (TUint)aStmtHandle, err));
return err;
}
@@ -588,7 +502,8 @@
*/
TInt StmtNext(sqlite3_stmt* aStmtHandle)
{
- __SQLASSERT(aStmtHandle != NULL, ESqlPanicInvalidObj);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, STMTNEXT_ENTRY, "Entry;0x%X;StmtNext;aStmtHandle=0x%X", (TUint)sqlite3_db_handle(aStmtHandle), (TUint)aStmtHandle));
+ __ASSERT_DEBUG(aStmtHandle != NULL, __SQLPANIC2(ESqlPanicInvalidObj));
(void)sqlite3SymbianLastOsError();//clear last OS error
@@ -596,10 +511,10 @@
if(err == SQLITE_ERROR) //It may be "out of memory" problem
{
err = sqlite3_reset(aStmtHandle);
- __SQLASSERT(err != SQLITE_OK, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err != SQLITE_OK, __SQLPANIC2(ESqlPanicInternalError));
}
err = ::Sql2OsErrCode(err, sqlite3SymbianLastOsError());
- PRINT_ERRMSG16(err <= KSqlErrGeneral, sqlite3_db_handle(aStmtHandle), "StmtNext()", _L(" "));
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, STMTNEXT_EXIT, "Exit;0x%X;StmtNext;aStmtHandle=0x%X;err=%d", (TUint)sqlite3_db_handle(aStmtHandle), (TUint)aStmtHandle, err));
return err;
}
@@ -617,12 +532,15 @@
*/
TInt StmtReset(sqlite3_stmt* aStmtHandle)
{
- __SQLASSERT(aStmtHandle != NULL, ESqlPanicInvalidObj);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, STMTRESET_ENTRY, "Entry;0x%X;StmtReset;aStmtHandle=0x%X", (TUint)sqlite3_db_handle(aStmtHandle), (TUint)aStmtHandle));
+ __ASSERT_DEBUG(aStmtHandle != NULL, __SQLPANIC2(ESqlPanicInvalidObj));
(void)sqlite3SymbianLastOsError();//clear last OS error
TInt err = sqlite3_reset(aStmtHandle);
- return ::Sql2OsErrCode(err, sqlite3SymbianLastOsError());
+ err = ::Sql2OsErrCode(err, sqlite3SymbianLastOsError());
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, STMTRESET_EXIT, "Exit;0x%X;StmtReset;aStmtHandle=0x%X;err=%d", (TUint)sqlite3_db_handle(aStmtHandle), (TUint)aStmtHandle, err));
+ return err;
}
/**
@@ -644,12 +562,16 @@
*/
static TInt PreRetrievePragmaValue(sqlite3* aDbHandle, const TDesC& aDbName, const TDesC8& aPragmaSql, sqlite3_stmt*& aStmtHandle)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
- __SQLASSERT(aPragmaSql.Length() > 0, ESqlPanicBadArgument);
- __SQLASSERT(aPragmaSql[aPragmaSql.Length() - 1] == 0, ESqlPanicBadArgument);
+ __SQLTRACE_INTERNALSEXPR(TPtrC8 sqlprnptr(aPragmaSql.Left(aPragmaSql.Length() - 1)));
+ __SQLTRACE_INTERNALSVAR(TBuf<100> des16prnbuf);
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, PRERETRIEVEPRAGMAVALUE_ENTRY, "Entry;0x%X;PreRetrievePragmaValue;aDbName=%S;aPragmaSql=%s", (TUint)aDbHandle, __SQLPRNSTR(aDbName), __SQLPRNSTR8(sqlprnptr, des16prnbuf)));
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aPragmaSql.Length() > 0, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aPragmaSql[aPragmaSql.Length() - 1] == 0, __SQLPANIC2(ESqlPanicBadArgument));
TBuf8<KMaxFileName> dbName;
if(!UTF16ToUTF8(aDbName, dbName))
{
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, PRERETRIEVEPRAGMAVALUE_EXIT1, "Exit;0x%X;PreRetrievePragmaValue;err=KErrGeneral", (TUint)aDbHandle));
return KErrGeneral;
}
TBuf8<KMaxFileName + 64> sql;//64 characters is enough for the longest PRAGMA statement
@@ -665,10 +587,10 @@
TInt err = ::StmtPrepare8(aDbHandle, sql, aStmtHandle);
if(err == KErrNone)
{
- __SQLASSERT(aStmtHandle != NULL, ESqlPanicInvalidObj);
+ __ASSERT_DEBUG(aStmtHandle != NULL, __SQLPANIC2(ESqlPanicInvalidObj));
err = ::StmtNext(aStmtHandle);
}
- PRINT_ERRMSG8(err <= KSqlErrGeneral, aDbHandle, "PreRetrievePragmaValue()", sql);
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, PRERETRIEVEPRAGMAVALUE_EXIT2, "Exit;0x%X;PreRetrievePragmaValue;aStmtHandle=0x%X;err=%d", (TUint)aDbHandle, (TUint)aStmtHandle, err));
return err;
}
@@ -691,9 +613,9 @@
*/
static TInt RetrievePragmaValue(sqlite3* aDbHandle, const TDesC& aDbName, const TDesC8& aPragmaSql, TInt& aPragmaValue)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
- __SQLASSERT(aPragmaSql.Length() > 0, ESqlPanicBadArgument);
- __SQLASSERT(aPragmaSql[aPragmaSql.Length() - 1] == 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aPragmaSql.Length() > 0, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aPragmaSql[aPragmaSql.Length() - 1] == 0, __SQLPANIC2(ESqlPanicBadArgument));
sqlite3_stmt* stmtHandle = NULL;
TInt err = PreRetrievePragmaValue(aDbHandle, aDbName, aPragmaSql, stmtHandle);
if(err == KSqlAtRow)
@@ -724,9 +646,9 @@
*/
static TInt RetrievePragmaValue(sqlite3* aDbHandle, const TDesC& aDbName, const TDesC8& aPragmaSql, TDes8& aPragmaValue)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
- __SQLASSERT(aPragmaSql.Length() > 0, ESqlPanicBadArgument);
- __SQLASSERT(aPragmaSql[aPragmaSql.Length() - 1] == 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
+ __ASSERT_DEBUG(aPragmaSql.Length() > 0, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aPragmaSql[aPragmaSql.Length() - 1] == 0, __SQLPANIC2(ESqlPanicBadArgument));
sqlite3_stmt* stmtHandle = NULL;
TInt err = PreRetrievePragmaValue(aDbHandle, aDbName, aPragmaSql, stmtHandle);
if(err == KSqlAtRow)
@@ -756,7 +678,7 @@
*/
TInt DbPageCount(sqlite3* aDbHandle, const TDesC& aDbName, TInt& aPageCount)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
return RetrievePragmaValue(aDbHandle, aDbName, KPageCountPragma, aPageCount);
}
@@ -777,7 +699,7 @@
*/
TInt DbPageSize(sqlite3* aDbHandle, const TDesC& aDbName, TInt& aPageSize)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
return RetrievePragmaValue(aDbHandle, aDbName, KPageSizePragma, aPageSize);
}
@@ -798,7 +720,7 @@
*/
TInt DbCacheSize(sqlite3* aDbHandle, const TDesC& aDbName, TInt& aCacheSize)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
return RetrievePragmaValue(aDbHandle, aDbName, KCacheSizePragma, aCacheSize);
}
@@ -819,7 +741,7 @@
*/
TInt DbEncoding(sqlite3* aDbHandle, const TDesC& aDbName, TDes8& aEncoding)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
return RetrievePragmaValue(aDbHandle, aDbName, KEncodingPragma, aEncoding);
}
@@ -840,7 +762,7 @@
*/
TInt DbFreePageCount(sqlite3* aDbHandle, const TDesC& aDbName, TInt& aPageCount)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
return RetrievePragmaValue(aDbHandle, aDbName, KFreePageCountPragma, aPageCount);
}
@@ -861,13 +783,13 @@
*/
TInt DbVacuumMode(sqlite3* aDbHandle, const TDesC& aDbName, TInt& aVacuumMode)
{
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
return RetrievePragmaValue(aDbHandle, aDbName, KVacuumModePragma, aVacuumMode);
}
static TBool IsCompactTimeLimitReached(TUint32 aStartTicks, TUint32 aCurrTicks, TInt aMaxTime)
{
- __SQLASSERT(aMaxTime > 0, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aMaxTime > 0, __SQLPANIC2(ESqlPanicBadArgument));
TInt64 tickDiff64 = (TInt64)aCurrTicks - (TInt64)aStartTicks;
if(tickDiff64 < 0)
{
@@ -878,6 +800,7 @@
if(freq == 0)
{
err = HAL::Get(HAL::EFastCounterFrequency, freq);
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, ISCOMPACTTIMELIMITREACHED, "0;IsCompactTimeLimitReached;fast counter frequency=%d;err=%d", freq, err));
}
if(err == KErrNone && freq > 0)
{
@@ -912,12 +835,14 @@
*/
TInt DbCompact(sqlite3* aDbHandle, const TDesC& aDbName, TInt aPageCount, TInt& aProcessedPageCount, TInt aMaxTime)
{
- __SQLASSERT(aPageCount >= 0, ESqlPanicBadArgument);
- __SQLASSERT(aMaxTime >= 0, ESqlPanicBadArgument);
- __SQLASSERT(aDbHandle != NULL, ESqlPanicInternalError);
+ SQL_TRACE_INTERNALS(OstTraceExt4(TRACE_INTERNALS, DBCOMPACT_ENTRY, "Entry;0x%X;DbCompact;aDbName=%S;aPageCount=%d;aMaxTime=%d", (TUint)aDbHandle, __SQLPRNSTR(aDbName), aPageCount, aMaxTime));
+ __ASSERT_DEBUG(aPageCount >= 0, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aMaxTime >= 0, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aDbHandle != NULL, __SQLPANIC2(ESqlPanicInternalError));
TBuf8<KMaxFileName> dbName;
if(!UTF16ToUTF8(aDbName, dbName))
{
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, DBCOMPACT_EXIT1, "Exit;0x%X;DbCompact;err=KErrGeneral", (TUint)aDbHandle));
return KErrGeneral;
}
TBuf8<KMaxFileName + sizeof(KIncrementalVacuumPragma) + 1> sql;
@@ -941,7 +866,7 @@
// - byte length of the sql statement (parameter #2), excluding terminating zero;
// - negative value - the sql statement (parameter #2) is zero-terminated;
TInt err = sqlite3_prepare_v2(aDbHandle, (const char*)sql.Ptr(), sql.Length() - sizeof(TUint8), &stmtHandle, &stmtTail);
- __SQLASSERT(err == SQLITE_OK ? !stmtTail || User::StringLength((const TUint8*)stmtTail) == 0 : !stmtHandle, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err == SQLITE_OK ? !stmtTail || User::StringLength((const TUint8*)stmtTail) == 0 : !stmtHandle, __SQLPANIC2(ESqlPanicInternalError));
if(stmtHandle) //stmtHandle can be NULL for statements like this: ";".
{
if(err == SQLITE_OK)
@@ -963,7 +888,7 @@
if(err == SQLITE_ERROR) //It may be "out of memory" problem
{
err = sqlite3_reset(stmtHandle);
- __SQLASSERT(err != SQLITE_OK, ESqlPanicInternalError);
+ __ASSERT_DEBUG(err != SQLITE_OK, __SQLPANIC2(ESqlPanicInternalError));
}
}
(void)sqlite3_finalize(stmtHandle);//sqlite3_finalize() fails only if an invalid statement handle is passed.
@@ -973,7 +898,7 @@
{
err = KErrNone;
}
- PRINT_ERRMSG8(err <= KSqlErrGeneral, aDbHandle, "DbCompact()", sql);
+ SQL_TRACE_INTERNALS(OstTraceExt3(TRACE_INTERNALS, DBCOMPACT_EXIT2, "Exit;0x%X;DbCompact;aProcessedPageCount=%d;err=%d", (TUint)aDbHandle, aProcessedPageCount, err));
return err;
}
@@ -989,6 +914,7 @@
*/
TInt FinalizeStmtHandle(sqlite3_stmt* aStmtHandle)
{
+ SQL_TRACE_INTERNALS(OstTraceExt2(TRACE_INTERNALS, FINALIZESTMTHANDLE_ENTRY, "Entry;0x%X;FinalizeStmtHandle;aStmtHandle=0x%X", (TUint)sqlite3_db_handle(aStmtHandle), (TUint)aStmtHandle));
TInt err = KErrNone;
if(aStmtHandle)
{
@@ -996,5 +922,6 @@
err = sqlite3_finalize(aStmtHandle);
err = ::Sql2OsErrCode(err, sqlite3SymbianLastOsError());
}
+ SQL_TRACE_INTERNALS(OstTrace1(TRACE_INTERNALS, FINALIZESTMTHANDLE_EXIT, "Exit;0;FinalizeStmtHandle;err=%d", err));
return err;
}
--- a/persistentstorage/sql/SRC/Server/SqlSrvUtil.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvUtil.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -14,10 +14,15 @@
//
#include <stdlib.h> //wchar_t
-#include "SqlPanic.h"
+#include "SqlAssert.h"
#include "SqlSrvUtil.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqlSrvUtilTraces.h"
+#endif
+#include "SqlTraceDef.h"
-#ifdef _NOTIFY
+#ifdef _SQL_AUTHORIZER_TRACE_ENABLED
//Used in PrintAuthorizerArguments()
_LIT8(KCreateIndex, "Create index"); //SQLITE_CREATE_INDEX
@@ -66,9 +71,9 @@
KCreateVTable(), KDropVTable(), KFunctionCall()
};
+#ifdef _DEBUG
const TInt KMaxOpCodes = sizeof(KDbOpNames) / sizeof(KDbOpNames[0]);
-
-_LIT(KFormatStr, "!!Authorize: %20.20S, %40.40S, %10.10S, %10.10S, %10.10S\r\n");
+#endif
/**
This function has a defined implementaion only in _DEBUG mode and is used to print the authorizer arguments.
@@ -78,7 +83,7 @@
void PrintAuthorizerArguments(TInt aDbOpType, const char* aDbObjName1, const char* aDbObjName2,
const char* aDbName, const char* aTrgOrViewName)
{
- __SQLASSERT(aDbOpType > 0 && aDbOpType <= KMaxOpCodes, ESqlPanicInternalError);
+ __ASSERT_DEBUG(aDbOpType > 0 && aDbOpType <= KMaxOpCodes, __SQLPANIC2(ESqlPanicInternalError));
//TPtrC8 objects cannot be used for the function arguments, because the arguments may not be 16-bit aligned!!!
@@ -126,9 +131,9 @@
}
}
- RDebug::Print(KFormatStr, &opName, &dbObjName1, &dbObjName2, &dbName, &trgOrViewName);
+ SQL_TRACE_AUTHORIZER(OstTraceExt5(TRACE_INTERNALS, SQLAUTHORIZER, "0;PrintAuthorizerArguments;%20.20S;%40.40S;%10.10S;%10.10S;%10.10S", __SQLPRNSTR(opName), __SQLPRNSTR(dbObjName1), __SQLPRNSTR(dbObjName2), __SQLPRNSTR(dbName), __SQLPRNSTR(trgOrViewName)));
}
-#endif//_NOTIFY
+#endif//_SQL_AUTHORIZER_TRACE_ENABLED
/**
Converts a UTF16 encoded descriptor to a UTF8 encoded descriptor.
@@ -145,8 +150,8 @@
*/
TBool UTF16ToUTF8(const TDesC& aIn, TDes8& aOut)
{
- __SQLASSERT(aIn.Length() <= KMaxFileName, ESqlPanicBadArgument);
- __SQLASSERT(aOut.MaxLength() >= KMaxFileName, ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aIn.Length() <= KMaxFileName, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aOut.MaxLength() >= KMaxFileName, __SQLPANIC2(ESqlPanicBadArgument));
TBuf16<KMaxFileName + 1> des;
des.Copy(aIn);
des.Append(TChar(0));
@@ -175,9 +180,9 @@
*/
TBool UTF16ZToUTF8Z(const TDesC& aFileName, TDes8& aFileNameDestBuf)
{
- __SQLASSERT(aFileName.Length() <= (KMaxFileName + 1), ESqlPanicBadArgument);
- __SQLASSERT(aFileName[aFileName.Length() - 1] == 0, ESqlPanicBadArgument);
- __SQLASSERT(aFileNameDestBuf.MaxLength() >= (KMaxFileName + 1), ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aFileName.Length() <= (KMaxFileName + 1), __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aFileName[aFileName.Length() - 1] == 0, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aFileNameDestBuf.MaxLength() >= (KMaxFileName + 1), __SQLPANIC2(ESqlPanicBadArgument));
const wchar_t* src = reinterpret_cast <const wchar_t*> (aFileName.Ptr());
TInt len = wcstombs((char*)aFileNameDestBuf.Ptr(), src, KMaxFileName);
//Check the file name length. If it is longer than KMaxFileName characters, then the file name is not valid.
@@ -204,8 +209,8 @@
*/
TBool UTF16ToUTF8Z(const TDesC& aFileName, TDes8& aFileNameDestBuf)
{
- __SQLASSERT(aFileName.Length() <= KMaxFileName, ESqlPanicBadArgument);
- __SQLASSERT(aFileNameDestBuf.MaxLength() >= (KMaxFileName + 1), ESqlPanicBadArgument);
+ __ASSERT_DEBUG(aFileName.Length() <= KMaxFileName, __SQLPANIC2(ESqlPanicBadArgument));
+ __ASSERT_DEBUG(aFileNameDestBuf.MaxLength() >= (KMaxFileName + 1), __SQLPANIC2(ESqlPanicBadArgument));
TBool rc = ::UTF16ToUTF8(aFileName, aFileNameDestBuf);
if(rc)
{
@@ -223,6 +228,6 @@
{//Non-existing file
return EFalse;
}
- __SQLLEAVE_IF_ERROR(err);
+ __SQLLEAVE_IF_ERROR2(err);
return entry.IsReadOnly();
}
--- a/persistentstorage/sql/SRC/Server/SqlSrvUtil.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/SRC/Server/SqlSrvUtil.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -24,10 +24,13 @@
inline TBool IsSystemTableName(const TDesC8& aTableName);
inline TBool IsSqliteTableName(const TDesC8& aTableName);
-#ifdef _NOTIFY
-void PrintAuthorizerArguments(TInt aDbOpType, const char* aDbObjName1, const char* aDbObjName2,
- const char* aDbName, const char* aTrgOrViewName);
-#endif//_NOTIFY
+#ifdef _SQL_AUTHORIZER_TRACE_ENABLED
+void PrintAuthorizerArguments(TInt aDbOpType,
+ const char* aDbObjName1,
+ const char* aDbObjName2,
+ const char* aDbName,
+ const char* aTrgOrViewName);
+#endif
TBool UTF16ToUTF8(const TDesC& aIn, TDes8& aOut);
TBool UTF16ZToUTF8Z(const TDesC& aFileName, TDes8& aFileNameDestBuf);
--- a/persistentstorage/sql/TEST/t_sqldbconfigfile.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/t_sqldbconfigfile.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -85,8 +85,10 @@
_LIT8(KCfgDb1ConfigFileV14CCommentStmt, "CREATE INDEX v14Idx ON table1(i3) /* this is a C comment */;");
//KLongDbName1 is "long" enough to allow "-journal" to be added at the end.
-_LIT(KLongDbName1, "c:[1111C1C1]a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a1234.db");
-_LIT(KLongCfgName1, "c:\\private\\10281e17\\cfg[1111C1C1]a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a1234.db.01");
+//Also, on simulators/emulators the file names have a prefix with length of about 30 characters
+//(something like \epoc\winscw\c\....)
+_LIT(KLongDbName1, "c:[1111C1C1]a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a.db");
+_LIT(KLongCfgName1, "c:\\private\\10281e17\\cfg[1111C1C1]a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a123456789a.db.01");
_LIT(KSqlSrvPrivatePath, "\\private\\10281e17\\");
_LIT(KResetCollationDllSql, "UPDATE symbian_settings SET CollationDllName='hjagafsff'");
--- a/persistentstorage/sql/TEST/t_sqldefect2.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/t_sqldefect2.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -377,46 +377,10 @@
//
TheDb1.Close();
err = RSqlDatabase::Delete(KTestDatabase1);
- TEST2(err, KErrNone);
+ TEST2(err, KErrNone);
}
/**
-@SYMTestCaseID PDS-SQL-CT-4214
-@SYMTestCaseDesc Test for the change "After *#7370# Java apps are not preinstalled again"
-@SYMTestPriority High
-@SYMTestActions The test makes sure there are no issues if the temp folder is removed after the server
- has already started. The test performs the following actions -
- 1. Delete the 'temp' directory.
- 2. Create a transaction which creates temp files.
- 3. Check 'temp' folder exists at the end
-@SYMTestExpectedResults Test must not fail
-*/
-void DeleteTempFolder()
- {
- //1. Delete 'temp' folder
- TInt err = TheFs.RmDir(KServerTempDir);
- TEST2(err, KErrNone);
-
- //2. Create a transaction which creates temp files.
- (void)RSqlDatabase::Delete(KTestDatabase1);
- err = TheDb1.Create(KTestDatabase1);
- TEST2(err, KErrNone);
-
- err = TheDb1.Exec(_L("CREATE TABLE t1(x UNIQUE); INSERT INTO t1 VALUES(1)"));
- TEST(err >= 0);
- err = TheDb1.Exec(_L("BEGIN; UPDATE t1 SET x = 2; UPDATE t1 SET x = 3; COMMIT"));
- TEST(err >= 0);
-
- TheDb1.Close();
- err = RSqlDatabase::Delete(KTestDatabase1);
- TEST2(err, KErrNone);
-
- //3. Check 'temp' folder exists
- err = TheFs.MkDir(KServerTempDir);
- TEST2(err, KErrAlreadyExists);
- }
-
-/**
@SYMTestCaseID PDS-SQL-CT-4213
@SYMTestCaseDesc Tests the ability of the SQL server to store empty strings and retrieve them as
text column values, not NULLs.
@@ -503,6 +467,42 @@
}
}
+/**
+@SYMTestCaseID PDS-SQL-CT-4214
+@SYMTestCaseDesc Test for the change "After *#7370# Java apps are not preinstalled again"
+@SYMTestPriority High
+@SYMTestActions The test makes sure there are no issues if the temp folder is removed after the server
+ has already started. The test performs the following actions -
+ 1. Delete the 'temp' directory.
+ 2. Create a transaction which creates temp files.
+ 3. Check 'temp' folder exists at the end
+@SYMTestExpectedResults Test must not fail
+*/
+void DeleteTempFolder()
+ {
+ //1. Delete 'temp' folder
+ TInt err = TheFs.RmDir(KServerTempDir);
+ TEST2(err, KErrNone);
+
+ //2. Create a transaction which creates temp files.
+ (void)RSqlDatabase::Delete(KTestDatabase1);
+ err = TheDb1.Create(KTestDatabase1);
+ TEST2(err, KErrNone);
+
+ err = TheDb1.Exec(_L("CREATE TABLE t1(x UNIQUE); INSERT INTO t1 VALUES(1)"));
+ TEST(err >= 0);
+ err = TheDb1.Exec(_L("BEGIN; UPDATE t1 SET x = 2; UPDATE t1 SET x = 3; COMMIT"));
+ TEST(err >= 0);
+
+ TheDb1.Close();
+ err = RSqlDatabase::Delete(KTestDatabase1);
+ TEST2(err, KErrNone);
+
+ //3. Check 'temp' folder exists
+ err = TheFs.MkDir(KServerTempDir);
+ TEST2(err, KErrAlreadyExists);
+ }
+
void DoTestsL()
{
TheTest.Start(_L(" @SYMTestCaseID:SYSLIB-SQL-CT-4154 DEF143062: SQL, \"CREATE INDEX\" sql crashes SQL server"));
@@ -514,16 +514,16 @@
TheTest.Next(_L(" @SYMTestCaseID:SYSLIB-SQL-CT-4156 DEF143150: SQL, strftime() returns incorrect result"));
DEF143150();
- TheTest.Next(_L(" @SYMTestCaseID:SYSLIB-SQL-CT-4210 Temp files created during sql operations are not deleted after rebooting the phone - 1"));
+ TheTest.Next(_L(" @SYMTestCaseID:PDS-SQL-CT-4210 Temp files created during sql operations are not deleted after rebooting the phone - 1"));
DeleteTempFile();
- TheTest.Next(_L(" @SYMTestCaseID:SYSLIB-SQL-CT-4211 Temp files created during sql operations are not deleted after rebooting the phone - 2"));
+ TheTest.Next(_L(" @SYMTestCaseID:PDS-SQL-CT-4211 Temp files created during sql operations are not deleted after rebooting the phone - 2"));
TempFileTest();
TheTest.Next(_L(" @SYMTestCaseID:PDS-SQL-CT-4213 No support to store an empty string in symbian's sqlite."));
EmptyTextColumnTest();
-
- TheTest.Next(_L(" @SYMTestCaseID:SYSLIB-SQL-CT-4214 After *#7370# Java apps are not preinstalled again"));
+
+ TheTest.Next(_L(" @SYMTestCaseID:PDS-SQL-CT-4214 After *#7370# Java apps are not preinstalled again"));
DeleteTempFolder();
}
--- a/persistentstorage/sql/TEST/t_sqlood.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/t_sqlood.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -63,7 +63,10 @@
#endif
-const TInt KTestRecordsCount = 350;
+_LIT8(KDatabasePageSizeConfig, "page_size=1024");
+
+const TInt KMaxTestRecordsCount = 350;
+TInt TestRecordsCount = 0;
///////////////////////////////////////////////////////////////////////////////////////
@@ -202,24 +205,78 @@
RDebug::Print(_L("CreateLargeFile: free space after = %ld\r\n"), diskSpace);
}
+
+// Number of bytes in the default journal header size.
+const TInt KJournalHeaderSize = 0x200;
+
+// Number of bytes added to each database page in the journal.
+const TInt KJournalPageOverhead = 8;
+
+// The default amount of reserved space provided by the ReserveDriveSpace API
+const TInt KReserveDriveSpaceAmount = 64*1024;
+
//Creates and fills with some records a test database
void CreateAndFillTestDatabase(RSqlDatabase& aDb)
{
- TInt err = aDb.Create(KTestDatabase);
+ TInt err = aDb.Create(KTestDatabase, &KDatabasePageSizeConfig);
TEST2(err, KErrNone);
err = aDb.Exec(_L("CREATE TABLE A(Id INTEGER, Data TEXT)"));
TEST(err >= 0);
- err = aDb.Exec(_L("BEGIN TRANSACTION"));
- TEST(err >= 0);
- for(TInt i=0;i<KTestRecordsCount;++i)
+
+ //
+ // Find the page size of the database on this media
+ //
+ TBuf<200> sql;
+ sql.Copy(_L("PRAGMA page_size"));
+ TSqlScalarFullSelectQuery q(aDb);
+ TInt pageSize = 0;
+ TRAP(err, pageSize = q.SelectIntL(sql););
+ //RDebug::Print(_L("Error %d Page Size %d"),err,pageSize);
+ TEST2(err, KErrNone);
+ TEST(pageSize > 0);
+ //RDebug::Print(_L("Page Size %d"),pageSize);
+
+ //
+ // Find the sector size of this media
+ //
+ TDriveInfo driveInfo;
+ err = TheFs.Drive(driveInfo, KTestDrive);
+ TEST2(err, KErrNone);
+ TVolumeIOParamInfo volumeInfo;
+ err = TheFs.VolumeIOParam(KTestDrive, volumeInfo);
+ TEST2(err, KErrNone);
+ TInt sectorSize = volumeInfo.iBlockSize;
+ //RDebug::Print(_L("Sector Size %d"),sectorSize);
+
+ TInt journalHeaderSize = Max(sectorSize, KJournalHeaderSize);
+ //RDebug::Print(_L("Journal Header Size %d"),journalHeaderSize);
+
+ //
+ // Keep adding to database until it is a size such that all the data can still be deleted within the reserved disk space size.
+ // Do this piece-wise not in a transaction.
+ //
+ TInt i;
+ for(i=0;i<KMaxTestRecordsCount;++i)
{
- TBuf<200> sql;
sql.Format(_L("INSERT INTO A(Id, Data) VALUES(%d, 'A0123456789B0123456789C0123456789D0123456789E0123456789F0123456789G0123456789H0123456789')"), i + 1);
err = aDb.Exec(sql);
TEST2(err, 1);
+
+ TInt size = aDb.Size();
+ TInt numberOfPages = size/pageSize;
+ TInt predictedJournalSize = journalHeaderSize + numberOfPages * (pageSize + KJournalPageOverhead);
+ //RDebug::Print(_L("Size %d, Pages %d, predictedJournalSize %d"),size, numberOfPages, predictedJournalSize);
+
+ // Will another page take us over the limit ?
+ if ((predictedJournalSize + (pageSize + KJournalPageOverhead)) >= (KReserveDriveSpaceAmount))
+ {
+ break;
+ }
}
- err = aDb.Exec(_L("COMMIT TRANSACTION"));
- TEST(err >= 0);
+ TestRecordsCount = i + 1;
+
+ //RDebug::Print(_L("TestRecordsCount %d"),TestRecordsCount);
+
}
//Tries to delete test database records
@@ -227,7 +284,7 @@
{
TInt err = aDb.Exec(_L("BEGIN TRANSACTION"));
TEST(err >= 0);
- for(TInt i=0;i<KTestRecordsCount;++i)
+ for(TInt i=0;i<TestRecordsCount;++i)
{
TBuf<100> sql;
sql.Format(_L("DELETE FROM A WHERE Id = %d"), i + 1);
@@ -250,7 +307,7 @@
void SimpleCallsTest()
{
RSqlDatabase db, db2;
- TInt err = db.Create(KTestDatabase);
+ TInt err = db.Create(KTestDatabase, &KDatabasePageSizeConfig);
TEST2(err, KErrNone);
err = db2.Open(KTestDatabase);
--- a/persistentstorage/sql/TEST/t_sqloom.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/t_sqloom.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2010 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2009 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"
--- a/persistentstorage/sql/TEST/t_sqloslayer.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/t_sqloslayer.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -27,6 +27,7 @@
#ifdef __cplusplus
} /* End of the 'extern "C"' block */
#endif
+#include "SqliteUtil.h"
///////////////////////////////////////////////////////////////////////////////////////
@@ -52,6 +53,11 @@
TInt TheSqlSrvProfilerFileSetSize = 0;
#endif
+#ifdef _DEBUG
+//SQLite panic category.
+_LIT(KSqlitePanicCategory, "Sqlite");
+#endif
+
///////////////////////////////////////////////////////////////////////////////////////
void DeleteTestFiles()
@@ -773,6 +779,71 @@
User::Free(osFile);
}
+///////////////////////////////////////////////////////////////////////////////////////
+
+//Panic thread function.
+//It will cast aData parameter to a TFunctor pointer and call it.
+//The expectation is that the called function will panic and kill the panic thread.
+TInt ThreadFunc(void* aData)
+ {
+ CTrapCleanup* tc = CTrapCleanup::New();
+ TEST(tc != NULL);
+
+ User::SetJustInTime(EFalse); // disable debugger panic handling
+
+ TFunctor* obj = reinterpret_cast<TFunctor*> (aData);
+ TEST(obj != NULL);
+ (*obj)();//call the panic function
+
+ delete tc;
+
+ return KErrNone;
+ }
+
+//Panic test.
+//PanicTest function will create a new thread - panic thread, giving it a pointer to the function which has to
+//be executed and the expectation is that the function will panic and kill the panic thread.
+//PanicTest function will check the panic thread exit code, exit category and the panic code.
+void PanicTest(TFunctor& aFunctor, TExitType aExpectedExitType, const TDesC& aExpectedCategory, TInt aExpectedPanicCode)
+ {
+ RThread thread;
+ _LIT(KThreadName,"OsLayerPanicThread");
+ TEST2(thread.Create(KThreadName, &ThreadFunc, 0x2000, 0x1000, 0x10000, (void*)&aFunctor, EOwnerThread), KErrNone);
+
+ TRequestStatus status;
+ thread.Logon(status);
+ TEST2(status.Int(), KRequestPending);
+ thread.Resume();
+ User::WaitForRequest(status);
+ User::SetJustInTime(ETrue); // enable debugger panic handling
+
+ TEST2(thread.ExitType(), aExpectedExitType);
+ TEST(thread.ExitCategory() == aExpectedCategory);
+ TEST2(thread.ExitReason(), aExpectedPanicCode);
+
+ CLOSE_AND_WAIT(thread);
+ }
+
+////////////////////////////////////////////////////////////////////////////////////////////////////////////
+////////////////////////////// Panic test functions /////////////////////////////////////////////////
+////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#ifdef _DEBUG
+
+//Panic when calling COsLayerData::Create() is called and the OS layer data has been already created.
+class TOsLayerDataDuplicated : public TFunctor
+ {
+private:
+ virtual void operator()()
+ {
+ (void)sqlite3SymbianLibInit();//This should crash the thread in debug mode (because the Os layer
+ //data was created already in TestEnvInit()).
+ }
+ };
+static TOsLayerDataDuplicated TheOsLayerDataDuplicated;
+
+#endif //_DEBUG
+
/**
@SYMTestCaseID SYSLIB-SQL-CT-1650
@SYMTestCaseDesc SQL, OS porting layer tests.
@@ -806,6 +877,10 @@
VfsOpenTempFileFileIoErrTest();
TheTest.Printf(_L("TVfs::Open(<'delete on close' file>) OOM test\r\n"));
VfsCreateDeleteOnCloseFileOomTest();
+#ifdef _DEBUG
+ TheTest.Printf(_L("'An attempt to create the OS layer data again' panic\r\n"));
+ PanicTest(TheOsLayerDataDuplicated, EExitPanic, KSqlitePanicCategory, ESqliteOsPanicOsLayerDataExists);
+#endif //_DEBUG
}
TInt E32Main()
--- a/persistentstorage/sql/TEST/testexecute/SQLite/config/Robustness.ini.DEVBOARD Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/testexecute/SQLite/config/Robustness.ini.DEVBOARD Tue Aug 31 16:57:14 2010 +0300
@@ -14,9 +14,9 @@
// Add a small amount of data and check it.
NewBlock3=AddBlock10-1
NewBlock4=CheckBlock10-1
-// Fill the disk to within 100K of full. First fill to within 150k so we have
-// an easy way of quickly getting 50K of disk back - by deleting 'fillfile'.
-NewBlock5=FillDisk150K
+// Fill the disk to within 100K of full. First fill to within 160k so we have
+// an easy way of quickly getting 60K of disk back - by deleting 'fillfile'.
+NewBlock5=FillDisk160K
NewBlock6=FillDisk100K
NoOperation7=
@@ -25,7 +25,7 @@
NewBlock8=FillDisk1
Close9=
-// This will return things to 50K of disk free (because we filled to 150K,
+// This will return things to 60K of disk free (because we filled to 160K,
// then to 100K with this file).
Delete10=E:\fillfile.txt
@@ -124,11 +124,11 @@
DiskFree=4194304
EndBlock1=
-// Fill the disk to within 150K of full.
-[FillDisk150K]
+// Fill the disk to within 160K of full.
+[FillDisk160K]
Function0=NearFillDisk
FillFile=E:\fillfile2.txt
-DiskFree=153600
+DiskFree=168960
EndBlock1=
// Fill the disk to within 100K of full.
@@ -298,7 +298,7 @@
Exec7=Create Table TheAttached.Sometable(Someint int, Somereal real, Sometext text);
// Fill the disk to within 100K of full (with a file..)
-NewBlock8=FillDisk150K
+NewBlock8=FillDisk160K
NewBlock9=FillDisk100K
// Fill up the drive with the attached database, first with big records,
@@ -330,9 +330,9 @@
ExpectedError22=KErrInUse
// Beyond this point we can't expect anything to work (necessarily) because
-// there isn't any disk space left. So grab free off 50K to make sure
+// there isn't any disk space left. So grab free off 60K to make sure
// (the fill to within 100K of full file which was created after filling
-// to within 150K of full).
+// to within 160K of full).
Delete23=E:\fillfile.txt
NoOperation24=
NoOperation25=
--- a/persistentstorage/sql/TEST/testexecute/SQLite/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/testexecute/SQLite/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -13,103 +13,59 @@
// Description:
//
-PRJ_EXPORTS
-
-PRJ_MMPFILES
PRJ_TESTEXPORTS
-te_SQL_suite.iby /epoc32/rom/include/te_sql_suite.iby
-
-//SQL TestExecute Main scripts
+te_SQL_suite.iby /epoc32/rom/include/te_sql_suite.iby
-../scripts/te_SQL_suite.script /epoc32/release/winscw/udeb/z/tef_sql/te_sql_suite.script
-../scripts/te_SQL_suite.script /epoc32/release/winscw/urel/z/tef_sql/te_sql_suite.script
-../scripts/BasicSQL2.script /epoc32/release/winscw/udeb/z/tef_sql/basicsql2.script
-../scripts/BasicSQL2.script /epoc32/release/winscw/urel/z/tef_sql/basicsql2.script
-../scripts/BasicSQL2-8S.script /epoc32/release/winscw/udeb/z/tef_sql/basicsql2-8s.script
-../scripts/BasicSQL2-8S.script /epoc32/release/winscw/urel/z/tef_sql/basicsql2-8s.script
-../scripts/Robustness.script /epoc32/release/winscw/udeb/z/tef_sql/robustness.script
-../scripts/Robustness.script /epoc32/release/winscw/urel/z/tef_sql/robustness.script
-../scripts/Panics.script /epoc32/release/winscw/udeb/z/tef_sql/panics.script
-../scripts/Panics.script /epoc32/release/winscw/urel/z/tef_sql/panics.script
-../scripts/TypeConversion.script /epoc32/release/winscw/udeb/z/tef_sql/typeconversion.script
-../scripts/TypeConversion.script /epoc32/release/winscw/urel/z/tef_sql/typeconversion.script
-../scripts/SomeExceptions.script /epoc32/release/winscw/udeb/z/tef_sql/someexceptions.script
-../scripts/SomeExceptions.script /epoc32/release/winscw/urel/z/tef_sql/someexceptions.script
-../scripts/BasicSQL.script /epoc32/release/winscw/udeb/z/tef_sql/basicsql.script
-../scripts/BasicSQL.script /epoc32/release/winscw/urel/z/tef_sql/basicsql.script
-../scripts/Configuration.script /epoc32/release/winscw/udeb/z/tef_sql/configuration.script
-../scripts/Configuration.script /epoc32/release/winscw/urel/z/tef_sql/configuration.script
-../scripts/Concurrent.script /epoc32/release/winscw/udeb/z/tef_sql/concurrent.script
-../scripts/Concurrent.script /epoc32/release/winscw/urel/z/tef_sql/concurrent.script
-../scripts/BUR.script /epoc32/release/winscw/udeb/z/tef_sql/bur.script
-../scripts/BUR.script /epoc32/release/winscw/urel/z/tef_sql/bur.script
-../scripts/security.script /epoc32/release/winscw/udeb/z/tef_sql/security.script
-../scripts/security.script /epoc32/release/winscw/urel/z/tef_sql/security.script
-../scripts/collation.script /epoc32/release/winscw/udeb/z/tef_sql/collation.script
-../scripts/collation.script /epoc32/release/winscw/urel/z/tef_sql/collation.script
+// SQL TestExecute Main scripts
+../scripts/te_SQL_suite.script z:/tef_sql/te_sql_suite.script
+../scripts/BasicSQL2.script z:/tef_sql/basicsql2.script
+../scripts/BasicSQL2-8S.script z:/tef_sql/basicsql2-8s.script
+../scripts/Robustness.script z:/tef_sql/robustness.script
+../scripts/Panics.script z:/tef_sql/panics.script
+../scripts/TypeConversion.script z:/tef_sql/typeconversion.script
+../scripts/SomeExceptions.script z:/tef_sql/someexceptions.script
+../scripts/BasicSQL.script z:/tef_sql/basicsql.script
+../scripts/Configuration.script z:/tef_sql/configuration.script
+../scripts/Concurrent.script z:/tef_sql/concurrent.script
+../scripts/BUR.script z:/tef_sql/bur.script
+../scripts/security.script z:/tef_sql/security.script
+../scripts/collation.script z:/tef_sql/collation.script
-//SQL TestExecute additional files
-../config/APIBasic.ini /epoc32/release/winscw/udeb/z/tef_sql/apibasic.ini
-../config/APIBasic.ini /epoc32/release/winscw/urel/z/tef_sql/apibasic.ini
-../config/APIBasic2.ini /epoc32/release/winscw/udeb/z/tef_sql/apibasic2.ini
-../config/APIBasic2.ini /epoc32/release/winscw/urel/z/tef_sql/apibasic2.ini
-../config/APIBasic2-8S.ini /epoc32/release/winscw/udeb/z/tef_sql/apibasic2-8s.ini
-../config/APIBasic2-8S.ini /epoc32/release/winscw/urel/z/tef_sql/apibasic2-8s.ini
-../config/Robustness.ini.EMULATOR /epoc32/release/winscw/udeb/z/tef_sql/robustness.ini
-../config/Robustness.ini.EMULATOR /epoc32/release/winscw/urel/z/tef_sql/robustness.ini
-../config/Robustness.ini.DEVBOARD /epoc32/release/armv5/udeb/z/tef_sql/robustness.ini
-../config/Robustness.ini.DEVBOARD /epoc32/release/armv5/urel/z/tef_sql/robustness.ini
-../config/Panics.ini /epoc32/release/winscw/udeb/z/tef_sql/panics.ini
-../config/Panics.ini /epoc32/release/winscw/urel/z/tef_sql/panics.ini
-../config/TypeConversion.ini /epoc32/release/winscw/udeb/z/tef_sql/typeconversion.ini
-../config/TypeConversion.ini /epoc32/release/winscw/urel/z/tef_sql/typeconversion.ini
-../config/SomeExceptions.ini /epoc32/release/winscw/udeb/z/tef_sql/someexceptions.ini
-../config/SomeExceptions.ini /epoc32/release/winscw/urel/z/tef_sql/someexceptions.ini
-../config/constraints.ini /epoc32/release/winscw/udeb/z/tef_sql/constraints.ini
-../config/constraints.ini /epoc32/release/winscw/urel/z/tef_sql/constraints.ini
-../config/views.ini /epoc32/release/winscw/udeb/z/tef_sql/views.ini
-../config/views.ini /epoc32/release/winscw/urel/z/tef_sql/views.ini
-../config/robust_size.ini /epoc32/release/winscw/udeb/z/tef_sql/robust_size.ini
-../config/robust_size.ini /epoc32/release/winscw/urel/z/tef_sql/robust_size.ini
-../config/Configuration.ini /epoc32/release/winscw/udeb/z/tef_sql/configuration.ini
-../config/Configuration.ini /epoc32/release/winscw/urel/z/tef_sql/configuration.ini
-../config/Concurrent.ini /epoc32/release/winscw/udeb/z/tef_sql/concurrent.ini
-../config/Concurrent.ini /epoc32/release/winscw/urel/z/tef_sql/concurrent.ini
-../config/BUR.ini /epoc32/release/winscw/udeb/z/tef_sql/bur.ini
-../config/BUR.ini /epoc32/release/winscw/urel/z/tef_sql/bur.ini
-../config/security.ini /epoc32/release/winscw/udeb/z/tef_sql/security.ini
-../config/security.ini /epoc32/release/winscw/urel/z/tef_sql/security.ini
-../config/collation.ini /epoc32/release/winscw/udeb/z/tef_sql/collation.ini
-../config/collation.ini /epoc32/release/winscw/urel/z/tef_sql/collation.ini
+// SQL TestExecute config files
+../config/APIBasic.ini z:/tef_sql/apibasic.ini
+../config/APIBasic2.ini z:/tef_sql/apibasic2.ini
+../config/APIBasic2-8S.ini z:/tef_sql/apibasic2-8s.ini
+../config/Panics.ini z:/tef_sql/panics.ini
+../config/TypeConversion.ini z:/tef_sql/typeconversion.ini
+../config/SomeExceptions.ini z:/tef_sql/someexceptions.ini
+../config/constraints.ini z:/tef_sql/constraints.ini
+../config/views.ini z:/tef_sql/views.ini
+../config/robust_size.ini z:/tef_sql/robust_size.ini
+../config/Configuration.ini z:/tef_sql/configuration.ini
+../config/Concurrent.ini z:/tef_sql/concurrent.ini
+../config/BUR.ini z:/tef_sql/bur.ini
+../config/security.ini z:/tef_sql/security.ini
+../config/collation.ini z:/tef_sql/collation.ini
+// Target specific config files
+../config/Robustness.ini.EMULATOR /epoc32/release/winscw/udeb/z/tef_sql/robustness.ini
+../config/Robustness.ini.EMULATOR /epoc32/release/winscw/urel/z/tef_sql/robustness.ini
+../config/Robustness.ini.DEVBOARD /epoc32/data/z/tef_sql/robustness.ini
// Reference data for various test cases.
-../data/reference1.txt /epoc32/release/winscw/udeb/z/tef_sql/testdata/reference1.txt
-../data/reference1.txt /epoc32/release/winscw/urel/z/tef_sql/testdata/reference1.txt
-../data/reference1.bin /epoc32/release/winscw/udeb/z/tef_sql/testdata/reference1.bin
-../data/reference1.bin /epoc32/release/winscw/urel/z/tef_sql/testdata/reference1.bin
-../data/test1.db /epoc32/release/winscw/udeb/z/tef_sql/testdata/test1.db
-../data/test1.db /epoc32/release/winscw/urel/z/tef_sql/testdata/test1.db
-../data/ShortNonDb.db /epoc32/release/winscw/udeb/z/tef_sql/testdata/shortnondb.db
-../data/ShortNonDb.db /epoc32/release/winscw/urel/z/tef_sql/testdata/shortnondb.db
-../data/LongNonDb.db /epoc32/release/winscw/udeb/z/tef_sql/testdata/longnondb.db
-../data/LongNonDb.db /epoc32/release/winscw/urel/z/tef_sql/testdata/longnondb.db
-../data/ReadOnly.db /epoc32/release/winscw/udeb/z/tef_sql/testdata/readonly.db
-../data/ReadOnly.db /epoc32/release/winscw/urel/z/tef_sql/testdata/readonly.db
-../data/Corrupt.db /epoc32/release/winscw/udeb/z/tef_sql/testdata/corrupt.db
-../data/Corrupt.db /epoc32/release/winscw/urel/z/tef_sql/testdata/corrupt.db
-../data/backup_registration.xml /epoc32/release/winscw/udeb/z/tef_sql/testdata/backup_registration.xml
-../data/backup_registration.xml /epoc32/release/winscw/urel/z/tef_sql/testdata/backup_registration.xml
-../data/{102827c7}corrupt.db /epoc32/release/winscw/udeb/z/tef_sql/testdata/[102827c7]corrupt.db
-../data/{102827c7}corrupt.db /epoc32/release/winscw/urel/z/tef_sql/testdata/[102827c7]corrupt.db
-../data/ext.pol /epoc32/release/winscw/udeb/z/tef_sql/testdata/ext.pol
-../data/ext.pol /epoc32/release/winscw/urel/z/tef_sql/testdata/ext.pol
+../data/reference1.txt z:/tef_sql/testdata/reference1.txt
+../data/reference1.bin z:/tef_sql/testdata/reference1.bin
+../data/test1.db z:/tef_sql/testdata/test1.db
+../data/ShortNonDb.db z:/tef_sql/testdata/shortnondb.db
+../data/LongNonDb.db z:/tef_sql/testdata/longnondb.db
+../data/ReadOnly.db z:/tef_sql/testdata/readonly.db
+../data/Corrupt.db z:/tef_sql/testdata/corrupt.db
+../data/backup_registration.xml z:/tef_sql/testdata/backup_registration.xml
+../data/{102827c7}corrupt.db z:/tef_sql/testdata/[102827c7]corrupt.db
+../data/ext.pol z:/tef_sql/testdata/ext.pol
PRJ_TESTMMPFILES
// TestExecute test binaries
te_SQL_suite.mmp manual
te_SQL_suite_cap1.mmp manual
te_SQL_suite_cap2.mmp manual
-
-
-
--- a/persistentstorage/sql/TEST/testexecute/SQLite/group/te_SQL_suite.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/testexecute/SQLite/group/te_SQL_suite.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,75 +1,70 @@
-/*
-* Copyright (c) 2009 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:
-*
-*/
+// Copyright (c) 2009-2010 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:
+//
+
#ifndef __TE_SQL_SUITE_IBY__
#define __TE_SQL_SUITE_IBY__
#include <testexecute.iby>
-#include "burtestserver.iby"
+#include <burtestserver.iby>
-file=ABI_DIR\BUILD_DIR\Te_SQL_Suite.exe System\bin\Te_SQL_Suite.exe
-file=ABI_DIR\BUILD_DIR\Te_SQL_Suite_cap1.exe System\bin\Te_SQL_Suite_cap1.exe
-file=ABI_DIR\BUILD_DIR\Te_SQL_Suite_cap2.exe System\bin\Te_SQL_Suite_cap2.exe
+file=ABI_DIR\BUILD_DIR\Te_SQL_Suite.exe System\bin\Te_SQL_Suite.exe
+file=ABI_DIR\BUILD_DIR\Te_SQL_Suite_cap1.exe System\bin\Te_SQL_Suite_cap1.exe
+file=ABI_DIR\BUILD_DIR\Te_SQL_Suite_cap2.exe System\bin\Te_SQL_Suite_cap2.exe
-//script files
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\te_SQL_Suite.script TEF_SQL\te_SQL_Suite.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\BasicSQL2.script TEF_SQL\BasicSQL2.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\BasicSQL2-8S.script TEF_SQL\BasicSQL2-8S.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\Robustness.script TEF_SQL\Robustness.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\Concurrent.script TEF_SQL\Concurrent.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\TypeConversion.script TEF_SQL\TypeConversion.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\SomeExceptions.script TEF_SQL\SomeExceptions.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\BasicSQL.script TEF_SQL\BasicSQL.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\BUR.script TEF_SQL\BUR.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\security.script TEF_SQL\security.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\Configuration.script TEF_SQL\Configuration.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\Panics.script TEF_SQL\Panics.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\collation.script TEF_SQL\collation.script
-
-
-//config files
+// Script files
+data=DATAZ_\tef_sql\te_SQL_Suite.script tef_sql\te_SQL_Suite.script
+data=DATAZ_\tef_sql\BasicSQL2.script tef_sql\BasicSQL2.script
+data=DATAZ_\tef_sql\BasicSQL2-8S.script tef_sql\BasicSQL2-8S.script
+data=DATAZ_\tef_sql\Robustness.script tef_sql\Robustness.script
+data=DATAZ_\tef_sql\Concurrent.script tef_sql\Concurrent.script
+data=DATAZ_\tef_sql\TypeConversion.script tef_sql\TypeConversion.script
+data=DATAZ_\tef_sql\SomeExceptions.script tef_sql\SomeExceptions.script
+data=DATAZ_\tef_sql\BasicSQL.script tef_sql\BasicSQL.script
+data=DATAZ_\tef_sql\BUR.script tef_sql\BUR.script
+data=DATAZ_\tef_sql\security.script tef_sql\security.script
+data=DATAZ_\tef_sql\Configuration.script tef_sql\Configuration.script
+data=DATAZ_\tef_sql\Panics.script tef_sql\Panics.script
+data=DATAZ_\tef_sql\collation.script tef_sql\collation.script
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\APIBasic.ini TEF_SQL\APIBasic.ini
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\APIBasic2.ini TEF_SQL\APIBasic2.ini
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\APIBasic2-8S.ini TEF_SQL\APIBasic2-8S.ini
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\SomeExceptions.ini TEF_SQL\SomeExceptions.ini
-data=EPOCROOT##Epoc32\release\armv5\udeb\z\TEF_SQL\Robustness.ini TEF_SQL\Robustness.ini
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\TypeConversion.ini TEF_SQL\TypeConversion.ini
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\constraints.ini TEF_SQL\constraints.ini
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\views.ini TEF_SQL\views.ini
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\robust_size.ini TEF_SQL\robust_size.ini
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\Configuration.ini TEF_SQL\Configuration.ini
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\Concurrent.ini TEF_SQL\Concurrent.ini
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\Panics.ini TEF_SQL\Panics.ini
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\BUR.ini TEF_SQL\BUR.ini
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\security.ini TEF_SQL\security.ini
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\collation.ini TEF_SQL\collation.ini
+// Config files
+data=DATAZ_\tef_sql\APIBasic.ini tef_sql\APIBasic.ini
+data=DATAZ_\tef_sql\APIBasic2.ini tef_sql\APIBasic2.ini
+data=DATAZ_\tef_sql\APIBasic2-8S.ini tef_sql\APIBasic2-8S.ini
+data=DATAZ_\tef_sql\SomeExceptions.ini tef_sql\SomeExceptions.ini
+data=DATAZ_\tef_sql\Robustness.ini tef_sql\Robustness.ini
+data=DATAZ_\tef_sql\TypeConversion.ini tef_sql\TypeConversion.ini
+data=DATAZ_\tef_sql\constraints.ini tef_sql\constraints.ini
+data=DATAZ_\tef_sql\views.ini tef_sql\views.ini
+data=DATAZ_\tef_sql\robust_size.ini tef_sql\robust_size.ini
+data=DATAZ_\tef_sql\Configuration.ini tef_sql\Configuration.ini
+data=DATAZ_\tef_sql\Concurrent.ini tef_sql\Concurrent.ini
+data=DATAZ_\tef_sql\Panics.ini tef_sql\Panics.ini
+data=DATAZ_\tef_sql\BUR.ini tef_sql\BUR.ini
+data=DATAZ_\tef_sql\security.ini tef_sql\security.ini
+data=DATAZ_\tef_sql\collation.ini tef_sql\collation.ini
-//data files
-
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\TestData\reference1.txt TEF_SQL\TestData\reference1.txt
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\TestData\reference1.bin TEF_SQL\TestData\reference1.bin
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\TestData\test1.db TEF_SQL\TestData\test1.db
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\TestData\ShortNonDb.db TEF_SQL\TestData\ShortNonDb.db
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\TestData\LongNonDb.db TEF_SQL\TestData\LongNonDb.db
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\TestData\ReadOnly.db TEF_SQL\TestData\ReadOnly.db
-data=EPOCROOT##epoc32\release\winscw\udeb\z\TEF_SQL\TestData\Corrupt.db TEF_SQL\TestData\Corrupt.db
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\TestData\backup_registration.xml TEF_SQL\TestData\backup_registration.xml
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\TestData\[102827c7]corrupt.db TEF_SQL\TestData\[102827c7]corrupt.db
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\TestData\ext.pol TEF_SQL\TestData\ext.pol
+// Data files
+data=DATAZ_\tef_sql\TestData\reference1.txt tef_sql\TestData\reference1.txt
+data=DATAZ_\tef_sql\TestData\reference1.bin tef_sql\TestData\reference1.bin
+data=DATAZ_\tef_sql\TestData\test1.db tef_sql\TestData\test1.db
+data=DATAZ_\tef_sql\TestData\ShortNonDb.db tef_sql\TestData\ShortNonDb.db
+data=DATAZ_\tef_sql\TestData\LongNonDb.db tef_sql\TestData\LongNonDb.db
+data=DATAZ_\tef_sql\TestData\ReadOnly.db tef_sql\TestData\ReadOnly.db
+data=DATAZ_\tef_sql\TestData\Corrupt.db tef_sql\TestData\Corrupt.db
+data=DATAZ_\tef_sql\TestData\backup_registration.xml tef_sql\TestData\backup_registration.xml
+data=DATAZ_\tef_sql\TestData\[102827c7]corrupt.db tef_sql\TestData\[102827c7]corrupt.db
+data=DATAZ_\tef_sql\TestData\ext.pol tef_sql\TestData\ext.pol
#endif // __TE_SQL_SUITE_IBY__
-
--- a/persistentstorage/sql/TEST/testexecute/SQLite/scripts/Robustness.script Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/testexecute/SQLite/scripts/Robustness.script Tue Aug 31 16:57:14 2010 +0300
@@ -31,6 +31,8 @@
RUN_UTILS DeleteFile E:\fillfile.txt
RUN_UTILS DeleteFile E:\fillfile2.txt
RUN_UTILS DeleteFile E:\fillfile4M.txt
+RUN_UTILS DeleteFile T:\fillDisk*.txt
+RUN_UTILS DeleteFile E:\fillDisk*.txt
START_TESTCASE SYSLIB-SQL-CIT-3348
@@ -161,3 +163,5 @@
RUN_UTILS DeleteFile E:\fillfile2.txt
RUN_UTILS DeleteFile T:\fillfile4M.txt
RUN_UTILS DeleteFile E:\fillfile4M.txt
+RUN_UTILS DeleteFile T:\fillDisk*.txt
+RUN_UTILS DeleteFile E:\fillDisk*.txt
--- a/persistentstorage/sql/TEST/testexecute/SQLite/src/cdtest.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/testexecute/SQLite/src/cdtest.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -312,6 +312,55 @@
return;
}
+//This function is needed for drives with more free space than KMaxTUint32 (4GB -1)
+//This is because in a FAT32 file system, the maximum file size is (4GB-1)
+//In the case where the free space is larger than this limit, this function will create additional
+//file(s)until the disk is under the (4GB-1) limit. After that CSQLCDT::NearFillDisk will fill the
+//disk up to the required amount.
+void CSQLCDT::PrepareLargeDisk(const TDesC& /*acfgblk*/, const TDriveUnit atdu, TInt64 &atowrite)
+ {
+ _LIT(KTestFunction, "PrepareLargeDisk");
+ _LIT(KFillDiskName,"\\FillDisk");
+ _LIT(KFillDiskExt,".txt");
+ TFileName fname;
+ TInt count = 1;
+ TInt err = 0;
+
+ while(atowrite > KMaxTUint32)
+ {
+ RFile64 fillDiskFile;
+ fname.Copy(atdu.Name());
+ fname.Append(KFillDiskName);
+ fname.AppendNum(count);
+ fname.Append(KFillDiskExt);
+
+ if( (err = fillDiskFile.Create(irfs, fname, EFileWrite)) != KErrNone )
+ {
+ SetTestStepResult(EFail);
+ INFO_PRINTF1(HTML_RED);
+ ERR_PRINTF4(_L("%S: Failed to open RFile64 for file %S, err %d"),
+ &KTestFunction, &fname, err );
+ INFO_PRINTF1(HTML_COLOUR_OFF);
+ return;
+ }
+
+ if( (err = fillDiskFile.SetSize(KMaxTUint32)) != KErrNone )
+ {
+ SetTestStepResult(EFail);
+ INFO_PRINTF1(HTML_RED);
+ ERR_PRINTF4(_L("%S: Failed on RFile64::SetSize for file %S, err %d"),
+ &KTestFunction, &fname, err );
+ INFO_PRINTF1(HTML_COLOUR_OFF);
+ fillDiskFile.Close();
+ return;
+ }
+
+ fillDiskFile.Close();
+ atowrite-=KMaxTUint32;
+ count++;
+ }
+ }
+
// Create a file specified by 'FillFile' in the config and write to
// it until 'DiskFree' bytes remain. Note that because files use whole
// sectors (512/1024/2048/4096 or whatever bytes), that attempting to leave
@@ -347,29 +396,33 @@
}
// So how many bytes do we need to write?
- TInt towrite = vol.iFree - free;
- INFO_PRINTF4(_L("%S: Disk writing %d, free %d"), &KTestFunction,
+ TInt64 towrite = vol.iFree - free;
+ INFO_PRINTF4(_L("%S: Disk writing %Ld, free %Ld"), &KTestFunction,
towrite, vol.iFree );
- INFO_PRINTF3(_L("%S: free %d"), &KTestFunction, vol.iFree );
- INFO_PRINTF3(_L("%S: writing %d"), &KTestFunction, towrite );
+ INFO_PRINTF3(_L("%S: free %Ld"), &KTestFunction, vol.iFree );
+ INFO_PRINTF3(_L("%S: writing %Ld"), &KTestFunction, towrite );
if( towrite < 0 )
{
SetTestStepResult(EFail);
INFO_PRINTF1(HTML_RED);
- ERR_PRINTF3(_L("%S: Disk wanted remaining less than current(%d)"),
+ ERR_PRINTF3(_L("%S: Disk wanted remaining less than current(%Ld)"),
&KTestFunction, vol.iFree );
INFO_PRINTF1(HTML_COLOUR_OFF);
return;
}
-
+
+ //In case the disk is large (i.e >4G -1 bytes) we need another function to
+ //create more files to fill it
+ PrepareLargeDisk(acfgblk, tdu, towrite);
+
// Get a file.
- RFile myfile;
+ RFile64 myfile;
if( (err = myfile.Create(irfs, fillfile, EFileWrite)) != KErrNone )
{
SetTestStepResult(EFail);
INFO_PRINTF1(HTML_RED);
- ERR_PRINTF4(_L("%S: Failed to open RFile for file %S, err %d"),
+ ERR_PRINTF4(_L("%S: Failed to open RFile64 for file %S, err %d"),
&KTestFunction, &fillfile, err );
INFO_PRINTF1(HTML_COLOUR_OFF);
return;
@@ -383,18 +436,20 @@
// remaining space tends to be a kilobyte or two less than requested.
// Obviously this is likely to be different between file system types,
// between hardware and emulator and so on.
- TInt size = 0;
+
+
+ TInt64 size = 0;
while(towrite > 0)
{
if(towrite < 1024) break;
- TInt tow = towrite/2;
+ TInt64 tow = towrite/2;
if(towrite < 4096) tow = towrite;
size += tow;
if( (err = myfile.SetSize(size)) != KErrNone )
{
SetTestStepResult(EFail);
INFO_PRINTF1(HTML_RED);
- ERR_PRINTF4(_L("%S: Failed on RFile::SetSize for file %S, err %d"),
+ ERR_PRINTF4(_L("%S: Failed on RFile64::SetSize for file %S, err %d"),
&KTestFunction, &fillfile, err );
INFO_PRINTF1(HTML_COLOUR_OFF);
break;
@@ -421,7 +476,7 @@
&KTestFunction, err);
INFO_PRINTF1(HTML_COLOUR_OFF);
}
- INFO_PRINTF3(_L("%S: Disk remaining is %d"), &KTestFunction, vol.iFree );
+ INFO_PRINTF3(_L("%S: Disk remaining is %Ld"), &KTestFunction, vol.iFree );
myfile.Close();
return;
}
@@ -483,8 +538,8 @@
actual = asfs->SelectIntL(stmt8);
else
actual = asfs->SelectIntL(stmt);
-
- TInt expected;
+
+ TInt expected;
if (res.CompareF(_L("DEFAULT_SOFT_HEAP_LIMIT")) == 0)
{
expected = KDefaultSoftHeapLimitKb;
--- a/persistentstorage/sql/TEST/testexecute/SQLite/src/cdtest.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/testexecute/SQLite/src/cdtest.h Tue Aug 31 16:57:14 2010 +0300
@@ -39,6 +39,9 @@
void FilesDifferBySize(const TDesC &, const TInt );
void SecurityPolicyCheck(const TDesC &, const TInt );
void CollationTest(const TDesC &, const TInt );
+
+private:
+ void PrepareLargeDisk(const TDesC&, const TDriveUnit atdu, TInt64 &atowrite);
};
#endif // CDTEST_H__
--- a/persistentstorage/sql/TEST/testexecute/group/TEF_SQL.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/testexecute/group/TEF_SQL.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,27 +1,25 @@
-/*
-* Copyright (c) 2009 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:
-*
-*/
+// Copyright (c) 2009-2010 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:
+//
+
#ifndef __TEF_SQL_IBY__
#define __TEF_SQL_IBY__
#include <sql.iby>
-
-//Main CentralRepository TEF Scripts
-data=EPOCROOT##Epoc32\release\winscw\udeb\z\TEF_SQL\TEF_SQL.script TEF_SQL\TEF_SQL.script
-
#include <te_SQL_suite.iby>
-#endif
+//Main SQL TEF Scripts
+data=DATAZ_\tef_sql\tef_sql.script tef_sql\tef_sql.script
+
+#endif // __TEF_SQL_IBY__
--- a/persistentstorage/sql/TEST/testexecute/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sql/TEST/testexecute/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -14,10 +14,8 @@
//
PRJ_TESTEXPORTS
-TEF_SQL.iby /epoc32/rom/include/tef_sql.iby
-../scripts/TEF_SQL.script /epoc32/release/winscw/urel/z/tef_sql/tef_sql.script
-../scripts/TEF_SQL.script /epoc32/release/winscw/udeb/z/tef_sql/tef_sql.script
+TEF_SQL.iby /epoc32/rom/include/tef_sql.iby
+../scripts/TEF_SQL.script z:/tef_sql/tef_sql.script
//TEST EXECUTE FRAMEWORK TESTS
#include "../SQLite/group/bld.inf"
-
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/traces_SqlDb/OstTraceDefinitions.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,7 @@
+#ifndef __OSTTRACEDEFINITIONS_H__
+#define __OSTTRACEDEFINITIONS_H__
+// OST_TRACE_COMPILER_IN_USE flag has been added by Trace Compiler
+// REMOVE BEFORE CHECK-IN TO VERSION CONTROL
+//#define OST_TRACE_COMPILER_IN_USE
+#include <opensystemtrace.h>
+#endif
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/traces_SqlDb/fixed_id.definitions Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,154 @@
+#Fixed group and trace id definitions. If this file is removed, the identifiers are rebuilt.
+[GROUP]TRACE_BORDER=0x84
+[GROUP]TRACE_ERROR=0x82
+[GROUP]TRACE_FATAL=0x81
+[GROUP]TRACE_INTERNALS=0x88
+[TRACE]TRACE_BORDER[0x84]_RSQLBLOBREADSTREAM_OPENL_ENTRY=0x3a
+[TRACE]TRACE_BORDER[0x84]_RSQLBLOBREADSTREAM_OPENL_EXIT=0x3b
+[TRACE]TRACE_BORDER[0x84]_RSQLBLOBREADSTREAM_SIZEL_ENTRY=0x3c
+[TRACE]TRACE_BORDER[0x84]_RSQLBLOBREADSTREAM_SIZEL_EXIT=0x3d
+[TRACE]TRACE_BORDER[0x84]_RSQLBLOBWRITESTREAM_OPENL_ENTRY=0x3e
+[TRACE]TRACE_BORDER[0x84]_RSQLBLOBWRITESTREAM_OPENL_EXIT=0x3f
+[TRACE]TRACE_BORDER[0x84]_RSQLBLOBWRITESTREAM_SIZEL_ENTRY=0x40
+[TRACE]TRACE_BORDER[0x84]_RSQLBLOBWRITESTREAM_SIZEL_EXIT=0x41
+[TRACE]TRACE_BORDER[0x84]_RSQLCOLUMNREADSTREAM_COLUMNBINARYL_ENTRY=0x77
+[TRACE]TRACE_BORDER[0x84]_RSQLCOLUMNREADSTREAM_COLUMNBINARYL_EXIT=0x78
+[TRACE]TRACE_BORDER[0x84]_RSQLCOLUMNREADSTREAM_COLUMNBINARY_ENTRY=0x73
+[TRACE]TRACE_BORDER[0x84]_RSQLCOLUMNREADSTREAM_COLUMNBINARY_EXIT=0x74
+[TRACE]TRACE_BORDER[0x84]_RSQLCOLUMNREADSTREAM_COLUMNTEXTL_ENTRY=0x75
+[TRACE]TRACE_BORDER[0x84]_RSQLCOLUMNREADSTREAM_COLUMNTEXTL_EXIT=0x76
+[TRACE]TRACE_BORDER[0x84]_RSQLCOLUMNREADSTREAM_COLUMNTEXT_ENTRY=0x71
+[TRACE]TRACE_BORDER[0x84]_RSQLCOLUMNREADSTREAM_COLUMNTEXT_EXIT=0x72
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_ATTACH_ENTRY=0xf
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_ATTACH_EXIT=0x10
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_CLOSE_ENTRY=0xd
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_CLOSE_EXIT=0xe
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_COMPACTASYNC_ENTRY=0x30
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_COMPACTASYNC_EXIT=0x31
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_COMPACT_ENTRY=0x2e
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_COMPACT_EXIT=0x2f
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_COPY_ENTRY=0x13
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_COPY_EXIT=0x14
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_CREATE2_ENTRY=0x3
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_CREATE2_Exit=0x4
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_CREATEL2_ENTRY=0x9
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_CREATEL2_EXIT=0xa
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_CREATEL_ENTRY=0x7
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_CREATEL_EXIT=0x8
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_CREATE_ENTRY=0x1
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_CREATE_Exit=0x2
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_DELETE_ENTRY=0x15
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_DELETE_EXIT=0x16
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_DETACH_ENTRY=0x11
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_DETACH_EXIT=0x12
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_EXEC16_ENTRY=0x1d
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_EXEC16_EXIT=0x1e
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_EXEC8_ENTRY=0x1f
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_EXEC8_EXIT=0x20
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_EXECASYNC16_ENTRY=0x21
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_EXECASYNC16_EXIT=0x22
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_EXECASYNC8_ENTRY=0x23
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_EXECASYNC8_EXIT=0x24
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_FREERESERVEDSPACE_ENTRY=0x34
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_FREERESERVEDSPACE_EXIT=0x35
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_GETRESERVEACCESS_ENTRY=0x36
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_GETRESERVEACCESS_EXIT=0x37
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_GETSECURITYPOLICYL_ENTRY=0x19
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_GETSECURITYPOLICYL_EXIT=0x1a
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_GETSECURITYPOLICY_ENTRY=0x17
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_GETSECURITYPOLICY_EXIT=0x18
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_INTRABSACTION_ENTRY=0x28
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_INTRABSACTION_EXIT=0x29
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_LASTERRORMESSAGE=0x25
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_LASTINSERTEDROWID_ENTRY=0x26
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_LASTINSERTEDROWID_EXIT=0x27
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_OPENL_ENTRY=0xb
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_OPENL_EXIT=0xc
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_OPEN_ENTRY=0x5
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_OPEN_EXIT=0x6
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_RELEASERESERVEACCESS_ENTRY=0x38
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_RELEASERESERVEACCESS_EXIT=0x39
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_RESERVEDRIVESPACE_ENTRY=0x32
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_RESERVEDRIVESPACE_EXIT=0x33
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_SETISOLATIONLEVEL_ENTRY=0x1b
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_SETISOLATIONLEVEL_EXIT=0x1c
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_SIZE2_ENTRY=0x2c
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_SIZE2_EXIT=0x2d
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_SIZE_ENTRY=0x2a
+[TRACE]TRACE_BORDER[0x84]_RSQLDATABASE_SIZE_EXIT=0x2b
+[TRACE]TRACE_BORDER[0x84]_RSQLPARAMWRITESTREAM_BINDBINARYL_ENTRY=0x7f
+[TRACE]TRACE_BORDER[0x84]_RSQLPARAMWRITESTREAM_BINDBINARYL_EXIT=0x80
+[TRACE]TRACE_BORDER[0x84]_RSQLPARAMWRITESTREAM_BINDBINARY_ENTRY=0x7b
+[TRACE]TRACE_BORDER[0x84]_RSQLPARAMWRITESTREAM_BINDBINARY_EXIT=0x7c
+[TRACE]TRACE_BORDER[0x84]_RSQLPARAMWRITESTREAM_BINDTEXTL_ENTRY=0x7d
+[TRACE]TRACE_BORDER[0x84]_RSQLPARAMWRITESTREAM_BINDTEXTL_EXIT=0x7e
+[TRACE]TRACE_BORDER[0x84]_RSQLPARAMWRITESTREAM_BINDTEXT_ENTRY=0x79
+[TRACE]TRACE_BORDER[0x84]_RSQLPARAMWRITESTREAM_BINDTEXT_EXIT=0x7a
+[TRACE]TRACE_BORDER[0x84]_RSQLSECURITYPOLICY_CLOSE_ENTRY=0x85
+[TRACE]TRACE_BORDER[0x84]_RSQLSECURITYPOLICY_CLOSE_EXIT=0x86
+[TRACE]TRACE_BORDER[0x84]_RSQLSECURITYPOLICY_CREATEL_ENTRY=0x83
+[TRACE]TRACE_BORDER[0x84]_RSQLSECURITYPOLICY_CREATEL_EXIT=0x84
+[TRACE]TRACE_BORDER[0x84]_RSQLSECURITYPOLICY_CREATE_ENTRY=0x81
+[TRACE]TRACE_BORDER[0x84]_RSQLSECURITYPOLICY_CREATE_EXIT=0x82
+[TRACE]TRACE_BORDER[0x84]_RSQLSECURITYPOLICY_EXTERNALIZEL_ENTRY=0x87
+[TRACE]TRACE_BORDER[0x84]_RSQLSECURITYPOLICY_EXTERNALIZEL_EXIT=0x88
+[TRACE]TRACE_BORDER[0x84]_RSQLSECURITYPOLICY_INTERNALIZEL_ENTRY=0x89
+[TRACE]TRACE_BORDER[0x84]_RSQLSECURITYPOLICY_INTERNALIZEL_EXIT=0x8a
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_CLOSE_ENTRY=0x67
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_CLOSE_EXIT=0x68
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_EXECASYNC_ENTRY=0x6d
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_EXECASYNC_EXIT=0x6e
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_EXEC_ENTRY=0x6b
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_EXEC_EXIT=0x6c
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_NEXT_ENTRY=0x6f
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_NEXT_EXIT=0x70
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_PREPARE16L_ENTRY=0x63
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_PREPARE16L_EXIT=0x64
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_PREPARE16_ENTRY=0x5f
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_PREPARE16_EXIT=0x60
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_PREPARE8L_ENTRY=0x65
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_PREPARE8L_EXIT=0x66
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_PREPARE8_ENTRY=0x61
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_PREPARE8_EXIT=0x62
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_RESET_ENTRY=0x69
+[TRACE]TRACE_BORDER[0x84]_RSQLSTATEMENT_RESET_EXIT=0x6a
+[TRACE]TRACE_BORDER[0x84]_TSQLBLOB_GETLC_ENTRY=0x42
+[TRACE]TRACE_BORDER[0x84]_TSQLBLOB_GETLC_EXIT=0x43
+[TRACE]TRACE_BORDER[0x84]_TSQLBLOB_GET_ENTRY=0x44
+[TRACE]TRACE_BORDER[0x84]_TSQLBLOB_GET_EXIT=0x45
+[TRACE]TRACE_BORDER[0x84]_TSQLBLOB_SET_ENTRY=0x46
+[TRACE]TRACE_BORDER[0x84]_TSQLBLOB_SET_ENTRYEXT=0x47
+[TRACE]TRACE_BORDER[0x84]_TSQLBLOB_SET_EXIT=0x48
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTBINARYL_ENTRY16=0x53
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTBINARYL_ENTRY8=0x5d
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTBINARYL_EXIT16=0x54
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTBINARYL_EXIT8=0x5e
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTINT64L_ENTRY16=0x4d
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTINT64L_ENTRY8=0x57
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTINT64L_EXIT16=0x4e
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTINT64L_EXIT8=0x58
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTINTL_ENTRY16=0x4b
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTINTL_ENTRY8=0x55
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTINTL_EXIT16=0x4c
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTINTL_EXIT8=0x56
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTREALL_ENTRY16=0x4f
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTREALL_ENTRY8=0x59
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTREALL_EXIT16=0x50
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTREALL_EXIT8=0x5a
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTTEXTL_ENTRY16=0x51
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTTEXTL_ENTRY8=0x5b
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTTEXTL_EXIT16=0x52
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SELECTTEXTL_EXIT8=0x5c
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_SETDATABASE=0x4a
+[TRACE]TRACE_BORDER[0x84]_TSQLSCALARFULLSELECTQUERY_TSQLSCALARFULLSELECTQUERY=0x49
+[TRACE]TRACE_ERROR[0x82]_TSQLUTIL_LEAVE=0x1
+[TRACE]TRACE_FATAL[0x81]_TSQLUTIL_PANIC=0x1
+[TRACE]TRACE_FATAL[0x81]_TSQLUTIL_PANICCLIENTL=0x2
+[TRACE]TRACE_INTERNALS[0x88]_HIPCBUF_CONSTRUCTL=0x1
+[TRACE]TRACE_INTERNALS[0x88]_HIPCBUF_HIPCBUFL2=0x2
+[TRACE]TRACE_INTERNALS[0x88]_RSQLDBSESSION_CLOSE=0x5
+[TRACE]TRACE_INTERNALS[0x88]_RSQLDBSESSION_CONNECT_ENTRY=0x3
+[TRACE]TRACE_INTERNALS[0x88]_RSQLDBSESSION_CONNECT_EXIT=0x4
+[TRACE]TRACE_INTERNALS[0x88]_RSQLSTATEMENTSESSION_CLOSE=0x8
+[TRACE]TRACE_INTERNALS[0x88]_RSQLSTATEMENTSESSION_PREPARE16=0x6
+[TRACE]TRACE_INTERNALS[0x88]_RSQLSTATEMENTSESSION_PREPARE8=0x7
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/traces_SqlDb/trace.properties Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<trace_properties>
+</trace_properties>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/traces_SqlSrv/OstTraceDefinitions.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,7 @@
+#ifndef __OSTTRACEDEFINITIONS_H__
+#define __OSTTRACEDEFINITIONS_H__
+// OST_TRACE_COMPILER_IN_USE flag has been added by Trace Compiler
+// REMOVE BEFORE CHECK-IN TO VERSION CONTROL
+//#define OST_TRACE_COMPILER_IN_USE
+#include <opensystemtrace.h>
+#endif
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/traces_SqlSrv/fixed_id.definitions Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,174 @@
+#Fixed group and trace id definitions. If this file is removed, the identifiers are rebuilt.
+[GROUP]TRACE_ERROR=0x82
+[GROUP]TRACE_FATAL=0x81
+[GROUP]TRACE_INTERNALS=0x88
+[TRACE]TRACE_ERROR[0x82]_TSQLUTIL_LEAVE=0x1
+[TRACE]TRACE_FATAL[0x81]_TSQLUTIL_PANIC=0x1
+[TRACE]TRACE_FATAL[0x81]_TSQLUTIL_PANICCLIENTL=0x2
+[TRACE]TRACE_INTERNALS[0x88]_CONVERTSQLFULL2DISKFULLERRROR=0x7d
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_CSQLBACKUPCLIENT2=0x17
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL0=0x1f
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL1=0x20
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL2=0x21
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL3=0x22
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL4=0x24
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_GETBACKUPDATASECTIONL5=0x23
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_GETBACKUPLISTL=0x31
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_GETEXPECTEDDATASIZE=0x1e
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_INITIALIZEGETPROXYBACKUPDATAL=0x26
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_INITIALIZERESTOREPROXYBASEDATAL=0x27
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_NEWLC=0x16
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_NOTIFYCHANGE=0x19
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL0=0x28
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL1=0x29
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL2=0x2a
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL3=0x2b
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL4=0x2c
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL5=0x2d
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_RESTOREBASEDATASECTONL6=0x2e
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_RESTORECOMPLETE=0x25
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_RUNERROR=0x18
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_TERMINATEMULTISTAGEOPERATION1=0x2f
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_TERMINATEMULTISTAGEOPERATION2=0x30
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_TESTBURSTATUSL1=0x1b
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_TESTBURSTATUSL2=0x1c
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_TESTBURSTATUSL_ENTRY=0x1a
+[TRACE]TRACE_INTERNALS[0x88]_CSQLBACKUPCLIENT_TESTBURSTATUSL_EXIT=0x1d
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTCONN_CSQLCOMPACTCONN2=0x6
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTCONN_NEWLC_ENTRY=0x4
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTCONN_NEWLC_EXIT=0x5
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTENTRY_ADDREF=0xa
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTENTRY_COMPACT_ENTRY=0xd
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTENTRY_COMPACT_EXIT=0xe
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTENTRY_CSQLCOMPACTENTRY2=0x9
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTENTRY_FREEPAGECALLBACK=0xc
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTENTRY_NEWLC_ENTRY=0x7
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTENTRY_NEWLC_EXIT=0x8
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTENTRY_RELEASE=0xb
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTOR_ADDENTRYL1=0x1
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTOR_ADDENTRYL2=0x2
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTOR_RELEASEENTRY1=0x3
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTTIMER_CSQLCOMPACTTIMER2=0x11
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTTIMER_DEQUEUE=0x13
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTTIMER_NEWL_ENTRY=0xf
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTTIMER_NEWL_EXIT=0x10
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTTIMER_QUEUE=0x12
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTTIMER_RUNL=0x14
+[TRACE]TRACE_INTERNALS[0x88]_CSQLCOMPACTTIMER_RUNL2=0x15
+[TRACE]TRACE_INTERNALS[0x88]_CSQLDRIVESPACE_CSQLDRIVESPACE2=0x70
+[TRACE]TRACE_INTERNALS[0x88]_CSQLDRIVESPACE_GETACCESSL_ENTRY=0x71
+[TRACE]TRACE_INTERNALS[0x88]_CSQLDRIVESPACE_GETACCESSL_EXIT=0x72
+[TRACE]TRACE_INTERNALS[0x88]_CSQLDRIVESPACE_NEWLC_ENTRY=0x6e
+[TRACE]TRACE_INTERNALS[0x88]_CSQLDRIVESPACE_NEWLC_EXIT=0x6f
+[TRACE]TRACE_INTERNALS[0x88]_CSQLDRIVESPACE_RELEASEACCESS=0x73
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSERVER_CACHEDDBCONFIGFILENAMESL=0x79
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSERVER_CSQLSERVER2_ENTRY=0x76
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSERVER_CSQLSERVER2_EXIT=0x77
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSERVER_GETBACKUPLISTL=0x7b
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSERVER_GETBACKUPLISTL_ENTRY=0x7a
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSERVER_GETBACKUPLISTL_EXIT=0x7c
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSERVER_GETCOLLATIONDLLNAMEL=0x78
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSERVER_NEWLC_ENTRY=0x74
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSERVER_NEWLC_EXIT=0x75
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_APPLYCONFIGUPDATES2L=0x5a
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_APPLYCONFIGUPDATESL=0x5b
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_ATTACHDBL_ENTRY=0x52
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_ATTACHDBL_EXIT=0x53
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_COMPACTL_ENTRY=0x56
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_COMPACTL_EXIT=0x57
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_CREATEL_ENTRY=0x4a
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_CREATEL_EXIT=0x4b
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_CREATENEWDBFILEL=0x50
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_CREATESECUREL_ENTRY=0x48
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_CREATESECUREL_EXIT=0x49
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_CSQLSRVDATABASE2_ENTRY=0x4e
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_CSQLSRVDATABASE2_EXIT=0x4f
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_DETACHDBL_ENTRY=0x54
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_DETACHDBL_EXIT=0x55
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_INSERTINATTACHDBMAPL=0x59
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_NEWCOMPACTENTRYL_ENTRY=0x5c
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_NEWCOMPACTENTRYL_EXIT=0x5d
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_OPENEXISTINGDBFILEL=0x51
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_OPENL_ENTRY=0x4c
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_OPENL_EXIT=0x4d
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_RELEASECOMPACTENTRY=0x5e
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVDATABASE_REMOVEFROMMAPSL=0x58
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSESSION_CSQLSRVSESSION2_ENTRY=0x80
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSESSION_CSQLSRVSESSION2_EXIT=0x81
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSESSION_DBDELETEFILEL=0x86
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSESSION_NEWL_ENTRY=0x7e
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSESSION_NEWL_EXIT=0x7f
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSESSION_SERVICEERROR_ENTRY=0x84
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSESSION_SERVICEERROR_EXIT=0x85
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSESSION_SERVICEL_ENTRY=0x82
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSESSION_SERVICEL_EXIT=0x83
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSTATEMENT_CSQLSRVSTATEMENT2=0x8c
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSTATEMENT_CSQLSRVSTATEMENT2_ENTRY=0x8b
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSTATEMENT_CSQLSRVSTATEMENT2_EXIT=0x8d
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSTATEMENT_NEWLC_ENTRY=0x87
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSTATEMENT_NEWLC_ENTRY2=0x89
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSTATEMENT_NEWLC_EXIT=0x88
+[TRACE]TRACE_INTERNALS[0x88]_CSQLSRVSTATEMENT_NEWLC_EXIT2=0x8a
+[TRACE]TRACE_INTERNALS[0x88]_DBCOMPACT_ENTRY=0xa2
+[TRACE]TRACE_INTERNALS[0x88]_DBCOMPACT_EXIT1=0xa3
+[TRACE]TRACE_INTERNALS[0x88]_DBCOMPACT_EXIT2=0xa4
+[TRACE]TRACE_INTERNALS[0x88]_DBEXECSTMT16_ENTRY=0x8e
+[TRACE]TRACE_INTERNALS[0x88]_DBEXECSTMT16_EXIT=0x8f
+[TRACE]TRACE_INTERNALS[0x88]_DBEXECSTMT8_ENTRY=0x90
+[TRACE]TRACE_INTERNALS[0x88]_DBEXECSTMT8_EXIT=0x91
+[TRACE]TRACE_INTERNALS[0x88]_EXECPRAGMA_ENTRY=0x46
+[TRACE]TRACE_INTERNALS[0x88]_EXECPRAGMA_EXIT=0x47
+[TRACE]TRACE_INTERNALS[0x88]_FINALIZESTMTHANDLE_ENTRY=0xa5
+[TRACE]TRACE_INTERNALS[0x88]_FINALIZESTMTHANDLE_EXIT=0xa6
+[TRACE]TRACE_INTERNALS[0x88]_HBLOBBUF_DOREADL=0x39
+[TRACE]TRACE_INTERNALS[0x88]_HBLOBBUF_DORELEASE_ENTRY=0x36
+[TRACE]TRACE_INTERNALS[0x88]_HBLOBBUF_DORELEASE_EXIT=0x37
+[TRACE]TRACE_INTERNALS[0x88]_HBLOBBUF_DOSEEKL=0x3b
+[TRACE]TRACE_INTERNALS[0x88]_HBLOBBUF_DOSYNCHL=0x38
+[TRACE]TRACE_INTERNALS[0x88]_HBLOBBUF_DOWRITEL=0x3a
+[TRACE]TRACE_INTERNALS[0x88]_HBLOBBUF_NEWL_ENTRY1=0x32
+[TRACE]TRACE_INTERNALS[0x88]_HBLOBBUF_NEWL_ENTRY2=0x33
+[TRACE]TRACE_INTERNALS[0x88]_HBLOBBUF_NEWL_ENTRY3=0x34
+[TRACE]TRACE_INTERNALS[0x88]_HBLOBBUF_NEWL_EXIT=0x35
+[TRACE]TRACE_INTERNALS[0x88]_ISCOMPACTTIMELIMITREACHED=0xa1
+[TRACE]TRACE_INTERNALS[0x88]_PRERETRIEVEPRAGMAVALUE_ENTRY=0x9e
+[TRACE]TRACE_INTERNALS[0x88]_PRERETRIEVEPRAGMAVALUE_EXIT1=0x9f
+[TRACE]TRACE_INTERNALS[0x88]_PRERETRIEVEPRAGMAVALUE_EXIT2=0xa0
+[TRACE]TRACE_INTERNALS[0x88]_SQLAUTHORIZER=0xa7
+[TRACE]TRACE_INTERNALS[0x88]_STMTEXEC_ENTRY=0x98
+[TRACE]TRACE_INTERNALS[0x88]_STMTEXEC_EXIT=0x99
+[TRACE]TRACE_INTERNALS[0x88]_STMTNEXT_ENTRY=0x9a
+[TRACE]TRACE_INTERNALS[0x88]_STMTNEXT_EXIT=0x9b
+[TRACE]TRACE_INTERNALS[0x88]_STMTPREPARE16L_ENTRY=0x92
+[TRACE]TRACE_INTERNALS[0x88]_STMTPREPARE16L_EXIT=0x93
+[TRACE]TRACE_INTERNALS[0x88]_STMTPREPARE8L_ENTRY=0x96
+[TRACE]TRACE_INTERNALS[0x88]_STMTPREPARE8L_EXIT=0x97
+[TRACE]TRACE_INTERNALS[0x88]_STMTPREPARE8_ENTRY=0x94
+[TRACE]TRACE_INTERNALS[0x88]_STMTPREPARE8_EXIT=0x95
+[TRACE]TRACE_INTERNALS[0x88]_STMTRESET_ENTRY=0x9c
+[TRACE]TRACE_INTERNALS[0x88]_STMTRESET_EXIT=0x9d
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_CONFIGUREDATABASEL1=0x61
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_CONFIGUREDATABASEL2=0x62
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_CONFIGUREDATABASEL3=0x63
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_CONFIGUREDATABASEL4=0x64
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_CONFIGUREDATABASEL_ENTRY=0x5f
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_CONFIGUREDATABASEL_EXIT1=0x60
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_CONFIGUREDATABASEL_EXIT2=0x65
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_DOEXECUTEDBCONFIGFILEOPSL=0x66
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_PROCESSSTATEMENTL1=0x6a
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_PROCESSSTATEMENTL2=0x6b
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_PROCESSSTATEMENTL3=0x6c
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_PROCESSSTATEMENTL_ENTRY=0x67
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_PROCESSSTATEMENTL_EXIT1=0x68
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_PROCESSSTATEMENTL_EXIT2=0x69
+[TRACE]TRACE_INTERNALS[0x88]_TSQLDBSYSSETTINGS_PROCESSSTATEMENTL_EXIT3=0x6d
+[TRACE]TRACE_INTERNALS[0x88]_TSQLSRVCONFIGFILE_GETCONFIGPARAMSL_ENTRY=0x42
+[TRACE]TRACE_INTERNALS[0x88]_TSQLSRVCONFIGFILE_GETCONFIGPARAMSL_EXIT1=0x43
+[TRACE]TRACE_INTERNALS[0x88]_TSQLSRVCONFIGFILE_GETCONFIGPARAMSL_EXIT2=0x44
+[TRACE]TRACE_INTERNALS[0x88]_TSQLSRVCONFIGFILE_GETCONFIGPARAMSL_EXIT3=0x45
+[TRACE]TRACE_INTERNALS[0x88]_TSQLSRVCONFIGFILE_INITL1=0x3d
+[TRACE]TRACE_INTERNALS[0x88]_TSQLSRVCONFIGFILE_INITL2=0x3e
+[TRACE]TRACE_INTERNALS[0x88]_TSQLSRVCONFIGFILE_INITL_ENTRY=0x3c
+[TRACE]TRACE_INTERNALS[0x88]_TSQLSRVCONFIGFILE_INITL_EXIT1=0x3f
+[TRACE]TRACE_INTERNALS[0x88]_TSQLSRVCONFIGFILE_INITL_EXIT2=0x40
+[TRACE]TRACE_INTERNALS[0x88]_TSQLSRVCONFIGFILE_INITL_EXIT3=0x41
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/traces_SqlSrv/trace.properties Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<trace_properties>
+<enum name="TBURPartType">
+<value id="0">EBURUnset</value>
+<value id="1">EBURNormal</value>
+<value id="2">EBURBackupFull</value>
+<value id="4">EBURBackupPartial</value>
+<value id="8">EBURRestoreFull</value>
+<value id="16">EBURRestorePartial</value>
+</enum>
+<enum name="TSqlBackupState">
+<value id="0">EBackupNoFileOpen</value>
+<value id="1">EBackupOpenNothingSent</value>
+<value id="2">EBackupOpenPartHeaderSent</value>
+<value id="3">EBackupOpenAllHeaderSent</value>
+<value id="4">EBackupEndOfFile</value>
+</enum>
+<enum name="TSqlRestoreState">
+<value id="0">ERestoreExpectChecksum</value>
+<value id="1">ERestoreExpectOldFileSize</value>
+<value id="2">ERestoreExpectVersion</value>
+<value id="3">ERestoreExpectFileSize</value>
+<value id="4">ERestoreExpectFileNameSize</value>
+<value id="5">ERestoreExpectFileName</value>
+<value id="6">ERestoreExpectData</value>
+<value id="7">ERestoreComplete</value>
+</enum>
+<enum name="TSqlSrvConfig_TDbEncoding">
+<value id="0">EEncNotSet</value>
+<value id="1">EEncUtf8</value>
+<value id="2">EEncUtf16</value>
+</enum>
+</trace_properties>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/traces_sqlite/OstTraceDefinitions.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,7 @@
+#ifndef __OSTTRACEDEFINITIONS_H__
+#define __OSTTRACEDEFINITIONS_H__
+// OST_TRACE_COMPILER_IN_USE flag has been added by Trace Compiler
+// REMOVE BEFORE CHECK-IN TO VERSION CONTROL
+//#define OST_TRACE_COMPILER_IN_USE
+#include <opensystemtrace.h>
+#endif
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/traces_sqlite/fixed_id.definitions Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,47 @@
+#Fixed group and trace id definitions. If this file is removed, the identifiers are rebuilt.
+[GROUP]TRACE_FATAL=0x81
+[GROUP]TRACE_INTERNALS=0x88
+[TRACE]TRACE_FATAL[0x81]_TSQLUTIL_PANIC=0x1
+[TRACE]TRACE_INTERNALS[0x88]_COSLAYERDATA_COSLAYERDATA2=0x7
+[TRACE]TRACE_INTERNALS[0x88]_COSLAYERDATA_CREATE_ENTRY=0x2
+[TRACE]TRACE_INTERNALS[0x88]_COSLAYERDATA_CREATE_EXIT1=0x3
+[TRACE]TRACE_INTERNALS[0x88]_COSLAYERDATA_CREATE_EXIT2=0x4
+[TRACE]TRACE_INTERNALS[0x88]_COSLAYERDATA_CREATE_EXIT3=0x5
+[TRACE]TRACE_INTERNALS[0x88]_COSLAYERDATA_DESTROY=0x6
+[TRACE]TRACE_INTERNALS[0x88]_COSLAYERDATA_DOCREATE=0x8
+[TRACE]TRACE_INTERNALS[0x88]_OS2SQLITEERR=0x1
+[TRACE]TRACE_INTERNALS[0x88]_SQLITE3SYMBIANLIBFINALIZE=0xa
+[TRACE]TRACE_INTERNALS[0x88]_SQLITE3SYMBIANLIBINIT=0x9
+[TRACE]TRACE_INTERNALS[0x88]_TDBFILE_TDBFILE=0xb
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_CLOSE1=0xc
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_FILECONTROL_ENTRY=0x17
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_FILECONTROL_EXIT=0x18
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_FILESIZE_ENTRY=0x15
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_FILESIZE_EXIT=0x16
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_READ_ENTRY=0xd
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_READ_EXIT=0xe
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_SYNC_ENTRY=0x13
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_SYNC_EXIT=0x14
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_TRUNCATE_ENTRY=0x11
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_TRUNCATE_EXIT=0x12
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_WRITE_ENTRY=0xf
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_WRITE_EXIT=0x10
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_ACCESS1=0x23
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_ACCESS_ENTRY=0x24
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_ACCESS_EXIT1=0x25
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_ACCESS_EXIT2=0x26
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_ACCESS_EXIT3=0x27
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DELETE1=0x1f
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DELETE2=0x21
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DELETE_ENTRY=0x20
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DELETE_EXIT=0x22
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DOFILESIZECORRUPTIONCHECK1=0x1b
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DOFILESIZECORRUPTIONCHECK2=0x1c
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DOGETGETDEVICECHARACTERISTICSANDSECTORSIZE=0x1a
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DOGETVOLUMEIOPARAMINFO=0x19
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_FULLPATHNAME1=0x28
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_FULLPATHNAME_ENTRY=0x29
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_FULLPATHNAME_EXIT1=0x2a
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_FULLPATHNAME_EXIT2=0x2b
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_OPEN_ENTRY=0x1d
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_OPEN_EXIT=0x1e
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sql/traces_sqlite/trace.properties Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<trace_properties>
+</trace_properties>
--- a/persistentstorage/sqlite3api/GROUP/BLD.INF Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/GROUP/BLD.INF Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
PRJ_EXPORTS
-../SQLite/sqlite3.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/sqlite3.h)
+../SQLite/sqlite3.h OS_LAYER_PUBLIC_EXPORT_PATH(stdapis/sqlite3.h)
../GROUP/sqlite3.iby /epoc32/rom/include/sqlite3.iby
../GROUP/SQLite3_stub.SIS /epoc32/data/z/system/install/sqlite3_stub.sis
@@ -441,6 +441,7 @@
../TEST/TclScript/where5.test z:/private/10285a82/where5.test
../TEST/TclScript/where6.test z:/private/10285a82/where6.test
../TEST/TclScript/zeroblob.test z:/private/10285a82/zeroblob.test
+../TEST/t_sqliteapi.txt z:/private/212C3129/t_sqliteapi.txt
PRJ_TESTMMPFILES
@@ -448,6 +449,7 @@
//tcl.dll is a test library used by the TCL tests
../TEST/TCL/group/tcl84.mmp support
../GROUP/tclsqlite3.mmp manual
+../GROUP/t_sqlitetclstarter.mmp manual
#endif
../GROUP/t_sqliteapi.mmp
../GROUP/t_sqlitewsd.mmp
--- a/persistentstorage/sqlite3api/GROUP/sqlite3.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/GROUP/sqlite3.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -19,14 +19,8 @@
@file
*/
-//#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-#include <e32utrace.mmh>
#include "sqlite3_macro.mmh"
-#ifdef SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-MACRO SQLITE_ENABLE_TRACE
-#endif
-
TARGET sqlite3.dll
TARGETTYPE dll
@@ -78,6 +72,7 @@
//////////////////////////////////////////////////////////////////////////////////////////////////////////
+userinclude ../traces_sqlite3
userinclude ../SQLite
userinclude ../OsLayer
OS_LAYER_LIBC_SYSTEMINCLUDE
@@ -146,14 +141,12 @@
SOURCEPATH ../OsLayer
SOURCE FileBuf64.cpp
SOURCE os_symbian_mt.cpp
+SOURCE SqliteUtil.cpp
#ifdef WINSCW
SOURCE os_symbian_emul.cpp
#else
SOURCE os_symbian_hrdw.cpp
#endif
-#ifdef SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-SOURCE UTraceSqlite.cpp
-#endif
LIBRARY euser.lib
LIBRARY efsrv.lib
--- a/persistentstorage/sqlite3api/GROUP/sqlite3tests.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/GROUP/sqlite3tests.iby Tue Aug 31 16:57:14 2010 +0300
@@ -430,6 +430,7 @@
data=ZPRIVATE\10285a82\where5.test \private\10285a82\where5.test
data=ZPRIVATE\10285a82\where6.test \private\10285a82\where6.test
data=ZPRIVATE\10285a82\zeroblob.test \private\10285a82\zeroblob.test
+data=ZPRIVATE\212C3129\t_sqliteapi.txt \private\212C3129\t_sqliteapi.txt
//The next line to be uncommented if the testing is performed locally. Otherwise tests will fail -
//the following file is missing and needed by the timezone server.
@@ -441,6 +442,7 @@
file=ABI_DIR\BUILD_DIR\t_sqliteperf.exe \test\t_sqliteperf.exe
file=ABI_DIR\BUILD_DIR\t_sqliteperf2.exe \test\t_sqliteperf2.exe
file=ABI_DIR\BUILD_DIR\tclsqlite3.exe \test\tclsqlite3.exe
+file=ABI_DIR\BUILD_DIR\t_sqlitetclstarter.exe \test\t_sqlitetclstarter.exe
file=ABI_DIR\BUILD_DIR\t_sqlitedef.exe \test\t_sqlitedef.exe
file=ABI_DIR\BUILD_DIR\t_sqlitedb64.exe \test\t_sqlitedb64.exe
--- a/persistentstorage/sqlite3api/GROUP/t_sqliteapi.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/GROUP/t_sqliteapi.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -32,5 +32,6 @@
LIBRARY efsrv.lib
VENDORID 0x70000001
+UID 0 0x212C3129
SMPSAFE
--- a/persistentstorage/sqlite3api/GROUP/t_sqlitedef.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/GROUP/t_sqlitedef.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -25,6 +25,7 @@
SOURCEPATH ../TEST
SOURCE t_sqlitedef.cpp
+SOURCE sqliteTestUtl.cpp
LIBRARY euser.lib
LIBRARY sqlite3.lib
--- a/persistentstorage/sqlite3api/GROUP/t_sqliteperf.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/GROUP/t_sqliteperf.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -23,6 +23,7 @@
SOURCEPATH ../TEST
SOURCE t_sqliteperfc.c
SOURCE t_sqliteperf.cpp
+SOURCE sqliteTestUtl.cpp
STATICLIBRARY libcrt0.lib
LIBRARY libc.lib
--- a/persistentstorage/sqlite3api/GROUP/t_sqliteperf2.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/GROUP/t_sqliteperf2.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -22,6 +22,7 @@
SOURCEPATH ../TEST
SOURCE t_sqliteperf2.cpp
+SOURCE sqliteTestUtl.cpp
STATICLIBRARY libcrt0.lib
LIBRARY libc.lib
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sqlite3api/GROUP/t_sqlitetclstarter.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,33 @@
+// Copyright (c) 2005-2010 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:
+//
+
+TARGET t_sqlitetclstarter.exe
+TARGETTYPE EXE
+CAPABILITY All -Tcb
+
+USERINCLUDE .
+OS_LAYER_SYSTEMINCLUDE_SYMBIAN
+
+SOURCEPATH ../TEST
+SOURCE t_sqlitetclstarter.cpp
+
+LIBRARY euser.lib
+LIBRARY efsrv.lib
+LIBRARY bafl.lib
+
+UID 0 0x1111CCCC
+VENDORID 0x70000001
+
+SMPSAFE
\ No newline at end of file
--- a/persistentstorage/sqlite3api/GROUP/t_sqlitewsd.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/GROUP/t_sqlitewsd.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -23,6 +23,7 @@
SOURCEPATH ../TEST
SOURCE t_sqlitewsd.cpp
SOURCE t_sqlitewsdinsert.cpp
+SOURCE sqliteTestUtl.cpp
LIBRARY libc.lib
LIBRARY libpthread.lib
--- a/persistentstorage/sqlite3api/GROUP/tclsqlite3.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/GROUP/tclsqlite3.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -20,7 +20,7 @@
/**
@file
*/
-#include <e32utrace.mmh>
+
#include "tclsqlite3_macro.mmh"
TARGET tclsqlite3.exe
@@ -73,6 +73,7 @@
//////////////////////////////////////////////////////////////////////////////////////////////////////////
+USERINCLUDE ../traces_sqlite3
USERINCLUDE ../SQLite
USERINCLUDE ../OsLayer
OS_LAYER_LIBC_SYSTEMINCLUDE
@@ -171,6 +172,7 @@
SOURCEPATH ../OsLayer
SOURCE FileBuf64.cpp
SOURCE os_symbian_mt.cpp
+SOURCE SqliteUtil.cpp
#ifdef WINSCW
SOURCE os_symbian_emul.cpp
#else
--- a/persistentstorage/sqlite3api/OsLayer/FileBuf64.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/OsLayer/FileBuf64.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -13,58 +13,13 @@
// Description:
//
#include "FileBuf64.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "FileBuf64Traces.h"
+#endif
+#include "SqliteTraceDef.h"
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-/////////////////////////// PROFILER ////////////////////////////////////////////////////////////////////
-//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-
-#ifdef _SQLPROFILER
-
-#define PROFILE_READ(pos,amount) \
- do \
- { \
- ++iFileReadCount; iFileReadAmount += (amount); \
- RDebug::Print(_L(" -- FRead this=%X, Cnt=%d, Pos=%ld, Amt=%d, Ttl=%ld\r\n"), (TUint32)this, iFileReadCount, pos, amount, iFileReadAmount); \
- } while(0)
-
-#define PROFILE_WRITE(pos,amount) \
- do \
- { \
- ++iFileWriteCount; iFileWriteAmount += (amount); \
- RDebug::Print(_L(" -- FWrite this=%X, Cnt=%d, Pos=%ld, Amt=%d, Ttl=%ld\r\n"), (TUint32)this, iFileWriteCount, pos, amount, iFileWriteAmount); \
- } while(0)
-
-#define PROFILE_SIZE() \
- do \
- { \
- ++iFileSizeCount; \
- RDebug::Print(_L(" -- FSize this=%X, Cnt=%d\r\n"), (TUint32)this, iFileSizeCount); \
- } while(0)
-
-#define PROFILE_SETSIZE() \
- do \
- { \
- ++iFileSetSizeCount; \
- RDebug::Print(_L(" -- FSetSize this=%X, Cnt=%d\r\n"), (TUint32)this, iFileSetSizeCount); \
- } while(0)
-
-#define PROFILE_FLUSH() \
- do \
- { \
- ++iFileFlushCount; \
- RDebug::Print(_L(" -- FFlush this=%X, Cnt=%d\r\n"), (TUint32)this, iFileFlushCount); \
- } while(0)
-
-#else
-
-#define PROFILE_READ(pos,amount) void(0)
-#define PROFILE_WRITE(pos,amount) void(0)
-
-#define PROFILE_SIZE() void(0)
-#define PROFILE_SETSIZE() void(0)
-#define PROFILE_FLUSH() void(0)
-
-#endif//_SQLPROFILER
/**
This constant is used for initializing the RFileBuf64::iFileSize data member and means that
@@ -82,90 +37,17 @@
static const TInt KNextReadFilePosNotSet = -1;
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-/////////////////////////// ASSERTS & INVARIANT //////////////////////////////////////////////////////////
+/////////////////////////// FBUF INVARIANT ///////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
#ifdef _DEBUG
#define __FILEBUF64_INVARIANT() Invariant()
-/**
-String literal used in _DEBUG mode for indicating that the reported panic happened inside the RFileBuf64 implementation.
-
-@see TFileBufPanic64
-@internalComponent
-*/
-_LIT(KPanicCategory, "FBuf64");
-
-/**
-Set of numeric constants used together with the KPanicCategory string literal in _DEBUG mode for providing more detailed
-information about the reason of the panic.
-
-@see KPanicCategory
-@internalComponent
-*/
-enum TFileBufPanic64
- {
- EFBufPanicCapacity = 1, //1
- EFBufPanicNullBuf,
- EFBufPanicBufLen,
- EFBufPanicFilePos,
- EFBufPanicFileSize, //5
- EFBufPanicFileHandle,
- EFBufPanicFsHandle,
- EFBufPanicMsgHandle,
- EFBufPanicMsgIndex,
- EFBufPanicFileNameLen, //10
- EFBufPanicNullThis,
- EFBufPanicDirty,
- EFBufPanicNextReadFilePos,
- EFBufPanicNextReadFilePosHits,
- EFBufPanicFileBlockSize, //15
- };
-
-/**
-Helper function used in the implementation of the __FBUF64_ASSERT() macro.
-In case if the expression in __FBUF64_ASSERT() macro evaluates to false,
-PanicFileBuf64() will use the supplied aLine and aPanicCode arguments together with the KPanicCategory string literal
-to prepare and print out a line (including the time of the panic) to the default log. The calling thread will be panic'ed
-after that.
-
-@see TFileBufPanic64
-@see KPanicCategory
-@internalComponent
-*/
-static void PanicFileBuf64(TInt aLine, TFileBufPanic64 aPanicCode)
- {
- TTime time;
- time.HomeTime();
- TDateTime dt = time.DateTime();
- TBuf<16> tbuf;
- tbuf.Format(_L("%02d:%02d:%02d.%06d"), dt.Hour(), dt.Minute(), dt.Second(), dt.MicroSecond());
-
- TBuf<64> buf;
- _LIT(KFormat,"**%S:RFileBuf64 panic %d, at line(%d)");
- buf.Format(KFormat, &tbuf, aPanicCode, aLine);
- RDebug::Print(buf);
- User::Panic(KPanicCategory, aPanicCode);
- }
-
-/**
-This macro should be used when there is a need to panic the client/server if "expr" condition is not satisfied.
-Works in only in debug mode. In release mode evaluates to nothing.
-
-@see TFileBufPanic64
-@see KPanicCategory
-@see PanicFileBuf64()
-@internalComponent
-*/
-#define __FBUF64_ASSERT(expr, panicCode) (void)(!(expr) ? ::PanicFileBuf64(__LINE__, panicCode) : void(0))
-
#else //_DEBUG
#define __FILEBUF64_INVARIANT() void(0)
-#define __FBUF64_ASSERT(expr, panicCode) void(0)
-
#endif//_DEBUG
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -177,13 +59,15 @@
@param aSize Max file buffer size (capacity) in bytes.
-@panic FBuf64 1 In _DEBUG mode - aSize is 0 or negative.
+@panic Sqlite3 1 In _DEBUG mode - aSize is 0 or negative.
*/
RFileBuf64::RFileBuf64(TInt aSize) :
iCapacity(aSize),
+ iBase(NULL),
iReadAheadSize(RFileBuf64::KDefaultReadAheadSize)
{
- __FBUF64_ASSERT(aSize > 0, EFBufPanicCapacity);
+ SQLITE_TRACE_FBUF(OstTraceExt3(TRACE_INTERNALS, RFILEBUF64_RFILEBUF64, "FBuf;0x%X;RFileBuf64::RFileBuf64;aSize=%d;iReadAheadSize=%d", (TUint)this, aSize, iReadAheadSize));
+ __ASSERT_DEBUG(aSize > 0, __SQLITEPANIC(EFBufPanicCapacity));
}
/**
@@ -202,20 +86,22 @@
@see TFileMode
@see RFile64::Create()
-@panic FBuf64 7 In _DEBUG mode - Invalid aFs object (null file session handle).
-@panic FBuf64 10 In _DEBUG mode - Invalid file name length (zero file name length).
+@panic Sqlite3 7 In _DEBUG mode - Invalid aFs object (null file session handle).
+@panic Sqlite3 10 In _DEBUG mode - Invalid file name length (zero file name length).
*/
TInt RFileBuf64::Create(RFs& aFs, const TDesC& aFileName, TUint aFileMode)
{
- __FBUF64_ASSERT(aFs.Handle() != 0, EFBufPanicFsHandle);
- __FBUF64_ASSERT(aFileName.Length() > 0, EFBufPanicFileNameLen);
+ __ASSERT_DEBUG(aFs.Handle() != 0, __SQLITEPANIC(EFBufPanicFsHandle));
+ __ASSERT_DEBUG(aFileName.Length() > 0, __SQLITEPANIC(EFBufPanicFileNameLen));
- TInt err = DoPreInit();
- if(err == KErrNone)
- {
- err = iFile.Create(aFs, aFileName, aFileMode);
- }
- return DoPostInit(err);
+ TInt err = DoPreInit();
+ if(err == KErrNone)
+ {
+ err = iFile.Create(aFs, aFileName, aFileMode);
+ }
+ SQLITE_TRACE_FBUF(OstTraceExt5(TRACE_INTERNALS, RFILEBUF64_CREATE, "FBuf;0x%X;RFileBuf64::Create;aFs.Handle()=0x%X;aFileName=%S;iFile.SubSessionHandle()=0x%X;err=%d", (TUint)this, (TUint)aFs.Handle(), __SQLITEPRNSTR(aFileName), (TUint)iFile.SubSessionHandle(), err));
+ DoPostInit(err);
+ return err;
}
/**
@@ -233,20 +119,22 @@
@see TFileMode
@see RFile64::Open()
-@panic FBuf64 7 In _DEBUG mode - Invalid aFs object (null file session handle).
-@panic FBuf64 10 In _DEBUG mode - Invalid file name length (zero file name length).
+@panic Sqlite3 7 In _DEBUG mode - Invalid aFs object (null file session handle).
+@panic Sqlite3 10 In _DEBUG mode - Invalid file name length (zero file name length).
*/
TInt RFileBuf64::Open(RFs& aFs, const TDesC& aFileName, TUint aFileMode)
{
- __FBUF64_ASSERT(aFs.Handle() != 0, EFBufPanicFsHandle);
- __FBUF64_ASSERT(aFileName.Length() > 0, EFBufPanicFileNameLen);
-
+ __ASSERT_DEBUG(aFs.Handle() != 0, __SQLITEPANIC(EFBufPanicFsHandle));
+ __ASSERT_DEBUG(aFileName.Length() > 0, __SQLITEPANIC(EFBufPanicFileNameLen));
+
TInt err = DoPreInit();
if(err == KErrNone)
{
err = iFile.Open(aFs, aFileName, aFileMode);
}
- return DoPostInit(err);
+ SQLITE_TRACE_FBUF(OstTraceExt5(TRACE_INTERNALS, RFILEBUF64_OPEN, "FBuf;0x%X;RFileBuf64::Open;aFs.Handle()=0x%X;aFileName=%S;iFile.SubSessionHandle()=0x%X;err=%d", (TUint)this, (TUint)aFs.Handle(), __SQLITEPRNSTR(aFileName), (TUint)iFile.SubSessionHandle(), err));
+ DoPostInit(err);
+ return err;
}
/**
@@ -266,18 +154,20 @@
@see TFileMode
@see RFile64::Temp()
-@panic FBuf64 7 In _DEBUG mode - Invalid aFs object (null file session handle).
+@panic Sqlite3 7 In _DEBUG mode - Invalid aFs object (null file session handle).
*/
TInt RFileBuf64::Temp(RFs& aFs, const TDesC& aPath, TFileName& aFileName, TUint aFileMode)
{
- __FBUF64_ASSERT(aFs.Handle() != 0, EFBufPanicFsHandle);
-
+ __ASSERT_DEBUG(aFs.Handle() != 0, __SQLITEPANIC(EFBufPanicFsHandle));
+
TInt err = DoPreInit();
if(err == KErrNone)
{
err = iFile.Temp(aFs, aPath, aFileName, aFileMode);
}
- return DoPostInit(err);
+ SQLITE_TRACE_FBUF(OstTraceExt5(TRACE_INTERNALS, RFILEBUF64_TEMP, "FBuf;0x%X;RFileBuf64::Temp;aFs.Handle()=0x%X;aFileName=%S;iFile.SubSessionHandle()=0x%X;err=%d", (TUint)this, (TUint)aFs.Handle(), __SQLITEPRNSTR(aFileName), (TUint)iFile.SubSessionHandle(), err));
+ DoPostInit(err);
+ return err;
}
/**
@@ -290,6 +180,7 @@
*/
void RFileBuf64::Close()
{
+ SQLITE_TRACE_FBUF(OstTraceExt2(TRACE_INTERNALS, RFILEBUF64_CLOSE, "FBuf;0x%X;RFileBuf64::Close;iFile.SubSessionHandle()=0x%X", (TUint)this, (TUint)iFile.SubSessionHandle()));
if(iFile.SubSessionHandle() != 0 && iBase != 0)
{
(void)DoFileWrite2();
@@ -321,14 +212,15 @@
TInt RFileBuf64::SetReadAheadSize(TInt aBlockSize, TInt aReadRecBufSize)
{
__FILEBUF64_INVARIANT();
- if(aReadRecBufSize > 0 && (aReadRecBufSize & (aReadRecBufSize - 1)) == 0 && aReadRecBufSize > RFileBuf64::KDefaultReadAheadSize)
+ if((aReadRecBufSize & (aReadRecBufSize - 1)) == 0 && aReadRecBufSize > RFileBuf64::KDefaultReadAheadSize)
{
iReadAheadSize = aReadRecBufSize > iCapacity ? iCapacity : aReadRecBufSize;
}
- else if(aBlockSize > 0 && (aBlockSize & (aBlockSize - 1)) == 0 && aBlockSize > RFileBuf64::KDefaultReadAheadSize)
+ else if((aBlockSize & (aBlockSize - 1)) == 0 && aBlockSize > RFileBuf64::KDefaultReadAheadSize)
{
iReadAheadSize = aBlockSize > iCapacity ? iCapacity : aBlockSize;
}
+ SQLITE_TRACE_FBUF(OstTraceExt4(TRACE_INTERNALS, RFILEBUF64_SETREADAHEADSIZE, "FBuf;0x%X;RFileBuf64::SetReadAheadSize;aBlockSize=%d;aReadRecBufSize=%d;iReadAheadSize=%d", (TUint)this, aBlockSize, aReadRecBufSize, iReadAheadSize));
__FILEBUF64_INVARIANT();
return iReadAheadSize;
}
@@ -347,14 +239,14 @@
@return KErrNone if successful, otherwise one of the other system-wide error codes.
-@panic FBuf64 4 In _DEBUG mode - negative aFilePos value.
+@panic Sqlite3 4 In _DEBUG mode - negative aFilePos value.
See RFileBuf64::Invariant() for other possible panics that may occur when this method is called.
@see RFileBuf64::Invariant()
*/
TInt RFileBuf64::Read(TInt64 aFilePos, TDes8& aDes)
{
- __FBUF64_ASSERT(aFilePos >= 0, EFBufPanicFilePos);
+ __ASSERT_DEBUG(aFilePos >= 0, __SQLITEPANIC(EFBufPanicFilePos));
__FILEBUF64_INVARIANT();
aDes.SetLength(0);
//1. The output buffer max len is 0
@@ -374,14 +266,14 @@
TInt len = aDes.MaxLength();
if(len > iCapacity)
{
- if((aFilePos + len) > iFilePos && !(aFilePos >= (iFilePos + iLength)))
+ if((aFilePos + len) > iFilePos && aFilePos < (iFilePos + iLength))
{//Write the pending data if the iDirty flag is set, otherwise preserve the buffer content.
err = DoFileWrite1(aFilePos);
}
if(err == KErrNone)
{
err = iFile.Read(aFilePos, aDes);
- PROFILE_READ(aFilePos, aDes.Size());
+ SQLITE_TRACE_FBUF(OstTraceExt5(TRACE_INTERNALS, RFILEBUF64_READ1, "FBuf;0x%X;RFileBuf64::Read;TooBigRq;iFileSize=%lld;aFilePos=%lld;len=%d;err=%d", (TUint)this, iFileSize, aFilePos, len, err));
}
__FILEBUF64_INVARIANT();
return err;
@@ -412,7 +304,7 @@
iNextReadFilePosHits = 0;
TPtr8 ptr2(outptr, len);
err = iFile.Read(aFilePos, ptr2);
- PROFILE_READ(aFilePos, ptr2.Size());
+ SQLITE_TRACE_FBUF(OstTraceExt5(TRACE_INTERNALS, RFILEBUF64_READ2, "FBuf;0x%X;RFileBuf64::Read;Read;iFileSize=%lld;aFilePos=%lld;len=%d;err=%d", (TUint)this, iFileSize, aFilePos, len, err));
if(err == KErrNone)
{
iNextReadFilePos = aFilePos + len;
@@ -436,7 +328,7 @@
}
TPtr8 ptr(iBase, Min(iCapacity, (len + readahead)));
err = iFile.Read(aFilePos, ptr);
- PROFILE_READ(aFilePos, ptr.Size());
+ SQLITE_TRACE_FBUF(OstTraceExt5(TRACE_INTERNALS, RFILEBUF64_READ3, "FBuf;0x%X;RFileBuf64::Read;ReadAhead;iFileSize=%lld;aFilePos=%lld;len=%d;err=%d", (TUint)this, iFileSize, aFilePos, ptr.MaxLength(), err));
if(err == KErrNone)
{
iFilePos = aFilePos;
@@ -472,14 +364,14 @@
@return KErrNone if successful, otherwise one of the other system-wide error codes.
-@panic FBuf64 4 In _DEBUG mode - negative aFilePos value.
+@panic Sqlite3 4 In _DEBUG mode - negative aFilePos value.
See RFileBuf64::Invariant() for other possible panics that may occur when this method is called.
@see RFileBuf64::Invariant()
*/
TInt RFileBuf64::Write(TInt64 aFilePos, const TDesC8& aData)
{
- __FBUF64_ASSERT(aFilePos >= 0, EFBufPanicFilePos);
+ __ASSERT_DEBUG(aFilePos >= 0, __SQLITEPANIC(EFBufPanicFilePos));
__FILEBUF64_INVARIANT();
if(aData.Length() == 0)
{
@@ -608,14 +500,14 @@
@return KErrNone if successful, otherwise one of the other system-wide error codes.
-@panic FBuf64 5 In _DEBUG mode - negative aFileSize value.
+@panic Sqlite3 5 In _DEBUG mode - negative aFileSize value.
See RFileBuf64::Invariant() for other possible panics that may occur when this method is called.
@see RFileBuf64::Invariant()
*/
TInt RFileBuf64::SetSize(TInt64 aFileSize)
{
- __FBUF64_ASSERT(aFileSize >= 0, EFBufPanicFileSize);
+ __ASSERT_DEBUG(aFileSize >= 0, __SQLITEPANIC(EFBufPanicFileSize));
__FILEBUF64_INVARIANT();
return DoSetFileSize(aFileSize);
}
@@ -634,7 +526,9 @@
TInt RFileBuf64::Lock(TInt64 aFilePos, TInt64 aLength) const
{
__FILEBUF64_INVARIANT();
- return iFile.Lock(aFilePos, aLength);
+ TInt err = iFile.Lock(aFilePos, aLength);
+ SQLITE_TRACE_FBUF(OstTraceExt5(TRACE_INTERNALS, RFILEBUF64_LOCK, "FBuf;0x%X;RFileBuf64::Lock;iFileSize=%lld;aFilePos=%lld;aLength=%lld;err=%d", (TUint)this, iFileSize, aFilePos, aLength, err));
+ return err;
}
/**
@@ -650,7 +544,9 @@
TInt RFileBuf64::UnLock(TInt64 aFilePos, TInt64 aLength) const
{
__FILEBUF64_INVARIANT();
- return iFile.UnLock(aFilePos, aLength);
+ TInt err = iFile.UnLock(aFilePos, aLength);
+ SQLITE_TRACE_FBUF(OstTraceExt5(TRACE_INTERNALS, RFILEBUF64_UNLOCK, "FBuf;0x%X;RFileBuf64::UnLock;iFileSize=%lld;aFilePos=%lld;aLength=%lld;err=%d", (TUint)this, iFileSize, aFilePos, aLength, err));
+ return err;
}
/**
@@ -699,7 +595,9 @@
TInt RFileBuf64::Drive(TInt& aDriveNumber, TDriveInfo& aDriveInfo) const
{
__FILEBUF64_INVARIANT();
- return iFile.Drive(aDriveNumber, aDriveInfo);
+ TInt err = iFile.Drive(aDriveNumber, aDriveInfo);
+ SQLITE_TRACE_FBUF(OstTraceExt5(TRACE_INTERNALS, RFILEBUF64_DRIVE, "FBuf;0x%X;RFileBuf64::Drive;aDriveNumber=%d;driveAtt=0x%X;mediaAtt=0x%X;err=%d", (TUint)this, aDriveNumber, (TUint)aDriveInfo.iDriveAtt, (TUint)aDriveInfo.iMediaAtt, err));
+ return err;
}
/**
@@ -720,20 +618,16 @@
/**
Performs post-initialization of the RFileBuf64 object.
If aInitErr is not KErrNone, then the buffer memory will be released.
-The function returns the aInitErr value to the caller.
@param aInitErr The result of the performed before the call RFileBuf64 initialization.
-
-@return KErrNone if successful, otherwise one of the other system-wide error codes.
*/
-TInt RFileBuf64::DoPostInit(TInt aInitErr)
+void RFileBuf64::DoPostInit(TInt aInitErr)
{
if(aInitErr != KErrNone)
{
User::Free(iBase);
iBase = 0;
}
- return aInitErr;
}
/**
@@ -768,8 +662,8 @@
__FILEBUF64_INVARIANT();
return KErrNone;
}
- PROFILE_SIZE();
TInt err = iFile.Size(iFileSize);
+ SQLITE_TRACE_FBUF(OstTraceExt3(TRACE_INTERNALS, RFILEBUF64_DOFILESIZE, "FBuf;0x%X;RFileBuf64::DoFileSize;iFileSize=%lld;err=%d", (TUint)this, iFileSize, err));
if(err != KErrNone)
{
DoDiscard();
@@ -787,14 +681,14 @@
@return KErrNone if successful, otherwise one of the other system-wide error codes.
-@panic FBuf64 5 In _DEBUG mode - negative aFileSize value.
+@panic Sqlite3 5 In _DEBUG mode - negative aFileSize value.
See RFileBuf64::Invariant() for other possible panics that may occur when this method is called.
@see RFileBuf64::Invariant()
*/
TInt RFileBuf64::DoSetFileSize(TInt64 aFileSize)
{
- __FBUF64_ASSERT(aFileSize >= 0, EFBufPanicFileSize);
+ __ASSERT_DEBUG(aFileSize >= 0, __SQLITEPANIC(EFBufPanicFileSize));
__FILEBUF64_INVARIANT();
if(aFileSize < iFilePos)
{
@@ -806,8 +700,8 @@
{
iLength = aFileSize - iFilePos;
}
- PROFILE_SETSIZE();
TInt err = iFile.SetSize(aFileSize);
+ SQLITE_TRACE_FBUF(OstTraceExt4(TRACE_INTERNALS, RFILEBUF64_DOSETFILESIZE, "FBuf;0x%X;RFileBuf64::DoSetFileSize;iFileSize=%lld;aFileSize=%lld;err=%d", (TUint)this, iFileSize, aFileSize, err));
if(err != KErrNone)
{
DoDiscard();
@@ -838,8 +732,8 @@
__FILEBUF64_INVARIANT();
return err;
}
- PROFILE_FLUSH();
err = iFile.Flush();
+ SQLITE_TRACE_FBUF(OstTraceExt3(TRACE_INTERNALS, RFILEBUF64_DOFILEFLUSH, "FBuf;0x%X;RFileBuf64::DoFileFlush;iFileSize=%lld;err=%d", (TUint)this, iFileSize, err));
if(err != KErrNone)
{
DoDiscard();
@@ -870,9 +764,9 @@
__FILEBUF64_INVARIANT();
return KErrNone;
}
- PROFILE_WRITE(iFilePos, iLength);
TPtrC8 data(iBase, iLength);
TInt err = iFile.Write(iFilePos, data);
+ SQLITE_TRACE_FBUF(OstTraceExt5(TRACE_INTERNALS, RFILEBUF64_DOFILEWRITE, "FBuf;0x%X;RFileBuf64::DoFileWrite;iFileSize=%lld;iFilePos=%lld;iLength=%d;err=%d", (TUint)this, iFileSize, iFilePos, iLength, err));
if(err == KErrNone)
{
iFileSize = Max(iFileSize, (iFilePos + iLength));
@@ -902,7 +796,7 @@
See RFileBuf64::Invariant() for other possible panics that may occur when this method is called.
-@panic FBuf64 4 In _DEBUG mode - negative aNewFilePos value.
+@panic Sqlite3 4 In _DEBUG mode - negative aNewFilePos value.
@see RFileBuf64::Read()
@see RFileBuf64::DoFileWrite()
@@ -911,7 +805,7 @@
*/
TInt RFileBuf64::DoFileWrite1(TInt64 aNewFilePos)
{
- __FBUF64_ASSERT(aNewFilePos >= 0, EFBufPanicFilePos);
+ __ASSERT_DEBUG(aNewFilePos >= 0, __SQLITEPANIC(EFBufPanicFilePos));
__FILEBUF64_INVARIANT();
TInt err = KErrNone;
if(iDirty)
@@ -949,7 +843,7 @@
See RFileBuf64::Invariant() for other possible panics that may occur when this method is called.
-@panic FBuf64 4 In _DEBUG mode - negative aNewFilePos value.
+@panic Sqlite3 4 In _DEBUG mode - negative aNewFilePos value.
@see RFileBuf64::Write()
@see RFileBuf64::DoFileWrite()
@@ -958,7 +852,7 @@
*/
TInt RFileBuf64::DoFileWrite2(TInt64 aNewFilePos)
{
- __FBUF64_ASSERT(aNewFilePos >= 0, EFBufPanicFilePos);
+ __ASSERT_DEBUG(aNewFilePos >= 0, __SQLITEPANIC(EFBufPanicFilePos));
__FILEBUF64_INVARIANT();
TInt err = KErrNone;
if(iDirty)
@@ -1009,29 +903,29 @@
RFileBuf64 invariant. Called in _DEBUG mode at the beginning and before the end of every RFileBuf64 method
(except the init/destroy methods).
-@panic FBuf64 11 In _DEBUG mode - null "this" pointer.
-@panic FBuf64 1 In _DEBUG mode - negative iCapacity value.
-@panic FBuf64 2 In _DEBUG mode - the buffer pointer is null (possible the buffer is not allocated or already destroyed).
-@panic FBuf64 3 In _DEBUG mode - invalid iLength value (negative or bigger than iCapacity).
-@panic FBuf64 4 In _DEBUG mode - negative iFilePos value.
-@panic FBuf64 5 In _DEBUG mode - set but negative iFileSize value.
-@panic FBuf64 6 In _DEBUG mode - null file handle (the RFile64 object is not created or already destroyed).
-@panic FBuf64 13 In _DEBUG mode - set but negative iNextReadFilePos value.
-@panic FBuf64 14 In _DEBUG mode - negative iNextReadFilePosHits value.
-@panic FBuf64 15 In _DEBUG mode - iReadAheadSize is negative or is not power of two.
+@panic Sqlite3 11 In _DEBUG mode - null "this" pointer.
+@panic Sqlite3 1 In _DEBUG mode - negative iCapacity value.
+@panic Sqlite3 2 In _DEBUG mode - the buffer pointer is null (possible the buffer is not allocated or already destroyed).
+@panic Sqlite3 3 In _DEBUG mode - invalid iLength value (negative or bigger than iCapacity).
+@panic Sqlite3 4 In _DEBUG mode - negative iFilePos value.
+@panic Sqlite3 5 In _DEBUG mode - set but negative iFileSize value.
+@panic Sqlite3 6 In _DEBUG mode - null file handle (the RFile64 object is not created or already destroyed).
+@panic Sqlite3 13 In _DEBUG mode - set but negative iNextReadFilePos value.
+@panic Sqlite3 14 In _DEBUG mode - negative iNextReadFilePosHits value.
+@panic Sqlite3 15 In _DEBUG mode - iReadAheadSize is negative or is not power of two.
*/
void RFileBuf64::Invariant() const
{
- __FBUF64_ASSERT(this != 0, EFBufPanicNullThis);
- __FBUF64_ASSERT(iCapacity > 0, EFBufPanicCapacity);
- __FBUF64_ASSERT(iBase != 0, EFBufPanicNullBuf);
- __FBUF64_ASSERT(iLength >= 0 && iLength <= iCapacity, EFBufPanicBufLen);
- __FBUF64_ASSERT(iFilePos >= 0, EFBufPanicFilePos);
- __FBUF64_ASSERT(iFileSize == KFileSizeNotSet || iFileSize >= 0, EFBufPanicFileSize);
- __FBUF64_ASSERT(iFile.SubSessionHandle() != 0, EFBufPanicFileHandle);
- __FBUF64_ASSERT(iNextReadFilePos == KNextReadFilePosNotSet || iNextReadFilePos >= 0, EFBufPanicNextReadFilePos);
- __FBUF64_ASSERT(iNextReadFilePosHits >= 0, EFBufPanicNextReadFilePosHits);
- __FBUF64_ASSERT(iReadAheadSize > 0 && (iReadAheadSize & (iReadAheadSize - 1)) == 0, EFBufPanicFileBlockSize);
+ __ASSERT_DEBUG(this != 0, __SQLITEPANIC(EFBufPanicNullThis));
+ __ASSERT_DEBUG(iCapacity > 0, __SQLITEPANIC(EFBufPanicCapacity));
+ __ASSERT_DEBUG(iBase != 0, __SQLITEPANIC(EFBufPanicNullBuf));
+ __ASSERT_DEBUG(iLength >= 0 && iLength <= iCapacity, __SQLITEPANIC(EFBufPanicBufLen));
+ __ASSERT_DEBUG(iFilePos >= 0, __SQLITEPANIC(EFBufPanicFilePos));
+ __ASSERT_DEBUG(iFileSize == KFileSizeNotSet || iFileSize >= 0, __SQLITEPANIC(EFBufPanicFileSize));
+ __ASSERT_DEBUG(iFile.SubSessionHandle() != 0, __SQLITEPANIC(EFBufPanicFileHandle));
+ __ASSERT_DEBUG(iNextReadFilePos == KNextReadFilePosNotSet || iNextReadFilePos >= 0, __SQLITEPANIC(EFBufPanicNextReadFilePos));
+ __ASSERT_DEBUG(iNextReadFilePosHits >= 0, __SQLITEPANIC(EFBufPanicNextReadFilePosHits));
+ __ASSERT_DEBUG(iReadAheadSize > 0 && (iReadAheadSize & (iReadAheadSize - 1)) == 0, __SQLITEPANIC(EFBufPanicFileBlockSize));
}
#endif
--- a/persistentstorage/sqlite3api/OsLayer/FileBuf64.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/OsLayer/FileBuf64.h Tue Aug 31 16:57:14 2010 +0300
@@ -151,7 +151,7 @@
private:
void Invariant() const;
TInt DoPreInit();
- TInt DoPostInit(TInt aInitErr);
+ void DoPostInit(TInt aInitErr);
void DoDiscard();
TInt DoFileSize();
TInt DoSetFileSize(TInt64 aFileSize);
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sqlite3api/OsLayer/SqliteTraceDef.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,55 @@
+// Copyright (c) 2010 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:
+//
+#ifndef SQLITETRACEDEF_H
+#define SQLITETRACEDEF_H
+
+#include <e32def.h>
+#include "SqliteUtil.h"
+
+//////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_OS_TRACE_ENABLED
+ #define __SQLITETRACE_OSVAR(var) var
+ #define __SQLITETRACE_OSEXPR(expr) expr
+#else
+ #define __SQLITETRACE_OSVAR(var)
+ #define __SQLITETRACE_OSEXPR(expr)
+#endif
+
+//////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_RDEBUG_PRINT
+ #undef OstTrace0
+ #undef OstTrace1
+ #undef OstTraceExt1
+ #undef OstTraceExt2
+ #undef OstTraceExt3
+ #undef OstTraceExt4
+ #undef OstTraceExt5
+
+ void SqlitePrintf(TInt aGroupName, TInt aTraceName, const char* aFormat, ...);
+
+ #define OstTrace0 SqlitePrintf
+ #define OstTrace1 SqlitePrintf
+ #define OstTraceExt1 SqlitePrintf
+ #define OstTraceExt2 SqlitePrintf
+ #define OstTraceExt3 SqlitePrintf
+ #define OstTraceExt4 SqlitePrintf
+ #define OstTraceExt5 SqlitePrintf
+#endif//defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_RDEBUG_PRINT
+
+//////////////////////////////////////////////////////////////////////////////////////
+
+#endif//SQLITETRACEDEF_H
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sqlite3api/OsLayer/SqliteUtil.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,167 @@
+// Copyright (c) 2010 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:
+//
+#include <e32debug.h>
+#include "SqliteUtil.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "SqliteUtilTraces.h"
+#endif
+#include "SqliteTraceDef.h"
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#define UNUSED_ARG(arg) arg = arg
+#define UNUSED_DES(arg) arg
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_RDEBUG_PRINT
+
+/**
+This class has been added here to avoid the crashes when _SQLITE_RDEBUG_PRINT macro is defined but the
+data to be printed out is too big and cannot fit into the buffer with size KSqliteMaxPrnStrLen.
+@internalComponent
+*/
+class TSqliteDes16Overflow : public TDes16Overflow
+ {
+public:
+ virtual void Overflow(TDes16& /*aDes*/)
+ {
+ }
+ };
+
+//Replaces:
+// "%lld" with "%ld"
+//These are the differences in format specification between RDebig::Print and OST functions.
+//The new format spec length should be less or equal than the old format spec length.
+static void ReplaceFmtSpec(TDes& aFormat, const TDesC& aFmtSpec, const TDesC& aNewFmtSpec)
+ {
+ TInt fmtLength = aFormat.Length();
+ const TInt KDiff = aFmtSpec.Length() - aNewFmtSpec.Length();
+ TPtr ptr((TText*)aFormat.Ptr(), fmtLength, fmtLength);
+ TInt pos;
+ while((pos = ptr.Find(aFmtSpec)) >= 0)
+ {
+ ptr.Replace(pos, aFmtSpec.Length(), aNewFmtSpec);
+ fmtLength -= KDiff;
+ ptr.Set(ptr.MidTPtr(pos));
+ }
+ aFormat.SetLength(fmtLength);
+ }
+
+void SqlitePrintf(TInt /*aGroupName*/, TInt /*aTraceName*/, const char* aFormat, ...)
+ {
+ VA_LIST list;
+ VA_START(list, aFormat);
+ TBuf<128> format;
+ _LIT(KTraceIdent, "Sqlite3;");
+ format.Copy(TPtrC8((const TUint8*)aFormat));
+ format.Insert(0, KTraceIdent);
+ format.Append(_L("\r\n"));
+ _LIT(KOstI64Fmt, "%lld");
+ _LIT(KDbgPrnI64Fmt, "%ld");
+ ReplaceFmtSpec(format, KOstI64Fmt, KDbgPrnI64Fmt);
+ TBuf<KSqliteMaxPrnStrLen> buf;
+ TSqliteDes16Overflow overflowHandler;
+ buf.AppendFormatList(format, list, &overflowHandler);
+#ifdef _SQLITE_RDEBUG_PRINT
+ RDebug::RawPrint(buf);
+#endif
+ }
+
+#endif//defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_RDEBUG_PRINT
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+SQLite panic category.
+
+@internalComponent
+*/
+_LIT(KSqlitePanicCategory, "Sqlite3");
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+Panics the caller with aPanicCode panic code.
+The call will terminate the thread where it is called from.
+
+@param aPanicCode Panic code.
+
+@internalComponent
+*/
+static void SqlitePanic(TSqlitePanic aPanicCode)
+ {
+ User::Panic(KSqlitePanicCategory, aPanicCode);
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+The function prints out a "SQLite" panic message to the console and panics the thread where it is called from.
+It gives a useful information about the found error together with the source file name and line number where
+it occurred.
+
+Note: this function will output information regarding the panic only if _SQLITE_PANIC_TRACE_ENABLED macro is defined
+
+@param aFile Source file name
+@param aLine Source line number
+@param aPanicCode Panic code
+@param aHandle Numeric value, uniquely identfying the leaving location (the "this" pointer for example)
+
+@return KErrNone
+
+@internalComponent
+*/
+TInt TSqliteUtil::Panic(const TText* aFile, TInt aLine, TInt aPanicCode, TUint aHandle)
+ {
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_PANIC_TRACE_ENABLED
+ TPtrC fname(FileName(aFile));
+ OstTraceExt5(TRACE_FATAL, TSQLUTIL_PANIC, "Panic;0x%X;%S;%d;%S;%d", aHandle, __SQLITEPRNSTR(fname), aLine, __SQLITEPRNSTR(KSqlitePanicCategory), aPanicCode);
+#else
+ UNUSED_ARG(aFile);
+ UNUSED_ARG(aLine);
+ UNUSED_ARG(aHandle);
+#endif
+ ::SqlitePanic(static_cast <TSqlitePanic> (aPanicCode));
+ return KErrNone;
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#if defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_PANIC_TRACE_ENABLED
+
+/**
+The function creates and returns TPtrC object which points to aFile parameter.
+
+@param aFile File name
+@return TPtrC object pointing to aFile parameter.
+
+@internalComponent
+*/
+TPtrC TSqliteUtil::FileName(const TText* aFile)
+ {
+ TPtrC p(aFile);
+ TInt ix = p.LocateReverse('\\');
+ if(ix<0)
+ ix=p.LocateReverse('/');
+ if(ix>=0)
+ p.Set(p.Mid(1+ix));
+ return p;
+ }
+
+#endif //defined OST_TRACE_COMPILER_IN_USE && defined _SQLITE_PANIC_TRACE_ENABLED
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sqlite3api/OsLayer/SqliteUtil.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,144 @@
+// Copyright (c) 2010 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:
+//
+#ifndef SQLITEUTIL_H
+#define SQLITEUTIL_H
+
+#include <e32std.h>
+
+/**
+Panic codes - used by asserts in the OS porting layer and the file buffer.
+
+@see KPanicCategory
+
+@internalComponent
+*/
+enum TSqlitePanic
+ {
+ ESqliteOsPanicFsCreationError = 1,
+ ESqliteOsPanicMutexCreationError = 2,
+ ESqliteOsPanicInvalidFs = 3,
+ ESqliteOsPanicNullPls1 = 4,
+ ESqliteOsPanicNullPls2 = 5,
+ ESqliteOsPanicNullPls3 = 6,
+ ESqliteOsPanicNullPls4 = 7,
+ ESqliteOsPanicAssert = 8,
+ ESqliteOsPanicMaxKeysExceeded = 9,
+ ESqliteOsPanicBufferSizeExceeded =10,
+ ESqliteOsPanicNullKey =11,
+ ESqliteOsPanicWsdBufSize =12,
+ ESqliteOsPanicWsdEntryCount =13,
+ ESqliteOsPanicInternalError =19,
+ ESqliteOsPanicNullDbFilePtr =20,
+ ESqliteOsPanicInvalidLock =21,
+ ESqliteOsPanicInvalidMutexType =22,
+ ESqliteOsPanicMutexLockCounter =23,
+ ESqliteOsPanicMutexOwner =24,
+ //
+ EFBufPanicCapacity =101,
+ EFBufPanicNullBuf =102,
+ EFBufPanicBufLen =103,
+ EFBufPanicFilePos =104,
+ EFBufPanicFileSize =105,
+ EFBufPanicFileHandle =106,
+ EFBufPanicFsHandle =107,
+ EFBufPanicMsgHandle =108,
+ EFBufPanicMsgIndex =109,
+ EFBufPanicFileNameLen =110,
+ EFBufPanicNullThis =111,
+ EFBufPanicDirty =112,
+ EFBufPanicNextReadFilePos =113,
+ EFBufPanicNextReadFilePosHits =114,
+ EFBufPanicFileBlockSize =115,
+ };
+
+////////////////////////////////////////////////////////////////////////////////////////////
+
+//All macros in this header will have a non-void definition only if the OST_TRACE_COMPILER_IN_USE macro
+//is defined.
+//In order to get the traces enabled, the OST_TRACE_COMPILER_IN_USE macro has to be defined in
+//OstTraceDefinitions.h file.
+//After that, the trace output can be redirected by defining _SQL_RDEBUG_PRINT or specific categories
+//of traces can be enabled/disabled.
+
+//Enable _SQLITE_RDEBUG_PRINT if you want to redirect the OS porting layer and file buffer tracing output via RDebug::Print()
+//#define _SQLITE_RDEBUG_PRINT
+
+//Enable _SQLITE_OS_TRACE_ENABLED if you get the OS porting layer traces compiled in the binary
+//#define _SQLITE_OS_TRACE_ENABLED
+
+//Enable _SQLITE_FBUF_TRACE_ENABLED if you get the file buffer traces compiled in the binary
+//#define _SQLITE_FBUF_TRACE_ENABLED
+
+#ifdef _DEBUG
+ //Enable _SQLITE_PANIC_TRACE_ENABLED if you want to get more detailed output regarding panics
+ //#define _SQLITE_PANIC_TRACE_ENABLED
+#endif
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+//Wrap every string (file name, file path, etc.) you want to trace, in a __SQLITEPRNSTR()/__SQLITEPRNSTR8() macro.
+//There is a difference how RDebug::Print() and OstTraceExt<n>() work.
+#if defined _SQLITE_RDEBUG_PRINT
+ const TInt KSqliteMaxPrnStrLen = 512;
+ #define __SQLITEPRNSTR(des) &des
+#else
+ #define __SQLITEPRNSTR(des) des
+#endif
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+/**
+Set of useful functions to print diagnostic messages on the console when a panic occurs.
+
+@internalComponent
+*/
+class TSqliteUtil
+ {
+public:
+ static TInt Panic(const TText* aFile, TInt aLine, TInt aPanicCode, TUint aHandle);
+
+private:
+ static TPtrC FileName(const TText* aFile);
+
+ };
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#define __SQLITESTRING(str) _S(str)
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+//__SQLITEPANIC/__SQLITEPANIC2 macro is used for printing out additional information when panic occurs in SQLite OS porting layer and the file buffer:
+//source file name, line number, "this" pointer, panic category.
+#define __SQLITEPANIC(aPanicCode) TSqliteUtil::Panic(__SQLITESTRING(__FILE__), __LINE__, aPanicCode, (TUint)this)
+#define __SQLITEPANIC2(aPanicCode) TSqliteUtil::Panic(__SQLITESTRING(__FILE__), __LINE__, aPanicCode, 0)
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#ifdef _SQLITE_OS_TRACE_ENABLED
+ #define SQLITE_TRACE_OS(trace) trace
+#else
+ #define SQLITE_TRACE_OS(trace) do {} while(0)
+#endif
+
+#ifdef _SQLITE_FBUF_TRACE_ENABLED
+ #define SQLITE_TRACE_FBUF(trace) trace
+#else
+ #define SQLITE_TRACE_FBUF(trace) do {} while(0)
+#endif
+
+///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+
+#endif //SQLITEUTIL_H
--- a/persistentstorage/sqlite3api/OsLayer/UTraceSqlite.cpp Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,51 +0,0 @@
-// Copyright (c) 2009 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:
-//
-
-#include <e32std.h>
-
-//The file is used only to compile and include in the image only a single
-//copy of the trace strings.
-#define __SQLITETRACE_STRINGS__
-#include "UTraceSqlite.h"
-
-#ifdef SYMBIAN_TRACE_SQLITE_FUNC
-
-/**
-Create the TSqlUTraceProfiler object which inserts a UTF trace, used to signal a function entry
-
-@param aFunctionStr A "const char" pointer describing the function to be profiled.
- Currently this is the type signature of the function returned by
- the __PRETTY_FUNCTION__ macro.
-@param aObj A object pointer used to provide context for the function.
-
-@internalComponent
-*/
-TSqlUTraceProfiler::TSqlUTraceProfiler(const TAny* aObj, const char* aFunctionStr):
-iObj(aObj), iFunctionStr(reinterpret_cast<const TUint8*>(aFunctionStr))
- {
- UTF::Printf(UTF::TTraceContext(UTF::ESystemCharacteristicMetrics), KProfilerBegin, &iFunctionStr, iObj);
- }
-
-/**
-Destroys TSqlUTraceProfiler object which inserts a UTF trace, used to signal a function exit
-
-@internalComponent
-*/
-TSqlUTraceProfiler::~TSqlUTraceProfiler()
- {
- UTF::Printf(UTF::TTraceContext(UTF::ESystemCharacteristicMetrics), KProfilerEnd, &iFunctionStr, iObj);
- }
-
-#endif //SYMBIAN_TRACE_SQLITE_FUNC
--- a/persistentstorage/sqlite3api/OsLayer/UTraceSqlite.h Thu Aug 19 11:36:21 2010 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,117 +0,0 @@
-// Copyright (c) 2009 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:
-//
-
-#ifndef UTRACESQLITE_H_
-#define UTRACESQLITE_H_
-
-#if defined SQLITE_ENABLE_TRACE
-
-// UID3 of sqlite3.dll
-#define EXECUTABLE_DEFAULT_MODULEUID 0x10285A79
-
-//The UTF header can only be included after EXECUTABLE_DEFAULT_MODULEUID is defined
-#include <e32utf.h>
-
-/**
-Enable this macro to compile in the SQLite trace points that certain porting layer functions entry and exit.
-From the timestamps of these trace, the total time spent in these functions can be worked out.
-These traces are particularly useful for performance investigations.
-
-@SymTraceMacro
-*/
-#undef SYMBIAN_TRACE_SQLITE_FUNC
-
-/**
-Enable this macro to compile in the SQLite trace points that trace the following internal events.
- - Extra internal information for certain porting layer functions
-These traces can be used to assist performance and debug investigations
-
-@SymTraceMacro
-*/
-#undef SYMBIAN_TRACE_SQLITE_EVENTS
-
-#endif //SQLITE_ENABLE_TRACE
-
-
-////////////////////////////////////////////////////////////////////////////////////////////////////////////
-////////// UTrace Related Strings ///////////////////////
-////////////////////////////////////////////////////////////////////////////////////////////////////////////
-#if defined SQLITE_ENABLE_TRACE
-#ifdef __SQLITETRACE_STRINGS__
- #define CONST_LIT8(var, val) extern const TLitC8<sizeof(val)> var = {sizeof(val) - 1, val}
- #define CONST_LIT16(var, val) extern const TLitC16<sizeof(L##val)/2> var = {sizeof(L##val)/2 - 1, L##val}
-#else
- #define CONST_LIT8(var, val) extern const TLitC8<sizeof(val)> var
- #define CONST_LIT16(var, val) extern const TLitC16<sizeof(L##val)/2> var
-#endif
-
-//File I/O trace format strings
-CONST_LIT8(KFileRead, "Sqlite: Size - %d bytes, File Offset Position - %d,");
-CONST_LIT8(KFileWrite, "Sqlite: Size - %d bytes, File Offset Position - %d,");
-CONST_LIT8(KFileTruncate, "Sqlite: Size - %d bytes");
-CONST_LIT8(KFileFileCtr, "Sqlite: Opeartion Called - %d");
-CONST_LIT16(KFileOpen, "Sqlite: Sqlite3_file - 0x%x, Filename - \"%S\"");
-CONST_LIT16(KFileName, "Sqlite: Filename - \"%S\"");
-
-//TSqlUTraceProfiler trace format strings, used to display function entry and exit
-CONST_LIT8(KProfilerBegin, "Function Entry:\"%S\", Address - 0x%x");
-CONST_LIT8(KProfilerEnd, "Function Exit:\"%S\", Address - 0x%x");
-
-#endif //SQLITE_ENABLE_TRACE
-
-////////////////////////////////////////////////////////////////////////////////////////////////////////////
-////////// UTrace Related Macro Functions and Class Declarations ////////////////////
-////////////////////////////////////////////////////////////////////////////////////////////////////////////
-#ifdef SYMBIAN_TRACE_SQLITE_FUNC
-
-/**
-This class is used to help trace function entry and exits within sqlite3.dll
-Exist only when SYMBIAN_TRACE_SQLITE_FUNC is enabled.
-
-@internalComponent
-*/
-class TSqlUTraceProfiler
- {
- public:
- TSqlUTraceProfiler(const TAny* aObj, const char* aFunctionStr);
- ~TSqlUTraceProfiler();
- private:
- const TAny* iObj;
- TPtrC8 iFunctionStr;
- };
-
-//This macro should be used to trace function entry and exits within Symbian SQL
-//Works only when SYMBIAN_TRACE_SQLITE_FUNC is enabled. Otherwise it evaluates to zero
-#define SQLUTRACE_PROFILER(x) TSqlUTraceProfiler _profiler(x, __PRETTY_FUNCTION__)
-
-#else
-
-#define SQLUTRACE_PROFILER(x) void(0)
-#endif //SYMBIAN_TRACE_SQLITE_FUNC
-
-#ifdef SYMBIAN_TRACE_SQLITE_EVENTS
-
-//This macro should be used to trace events occuring within Symbian SQL.
-//To use the macro, insert the full UTF statement as the macro parameter
-//Works only when SYMBIAN_TRACE_SQLITE_EVENTS is enabled. Otherwise it evaluates to zero
-#define SYMBIAN_TRACE_SQLITE_EVENTS_ONLY(c) c
-const TPtrC8 GetFuncString(TInt aFunction);
-
-#else
-
-#define SYMBIAN_TRACE_SQLITE_EVENTS_ONLY(c) void(0)
-#endif //SYMBIAN_TRACE_SQLITE_EVENTS
-////////////////////////////////////////////////////////////////////////////////////////////////////////////
-#endif /* UTRACESQLITE_H_ */
--- a/persistentstorage/sqlite3api/OsLayer/os_symbian.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/OsLayer/os_symbian.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,5 +1,5 @@
/**
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008-2010 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"
@@ -30,45 +30,6 @@
#ifdef SQLITE_OS_SYMBIAN
-/**
-Multi-threaded Symbian OS porting layer panic category.
-
-@see TPanicCodes
-
-@internalComponent
-*/
-_LIT(KPanicCategory, "SqliteMt");
-
-/**
-Panic codes - used by asserts in the multi-threaded OS porting layer.
-
-@see KPanicCategory
-
-@internalComponent
-*/
-enum TPanicCodes
- {
- EPanicFsCreationError = 1,
- EPanicMutexCreationError = 2,
- EPanicInvalidFs = 3,
- EPanicNullPls1 = 4,
- EPanicNullPls2 = 5,
- EPanicNullPls3 = 6,
- EPanicNullPls4 = 7,
- EPanicAssert = 8,
- EPanicMaxKeysExceeded = 9,
- EPanicBufferSizeExceeded =10,
- EPanicNullKey =11,
- EPanicWsdBufSize =12,
- EPanicWsdEntryCount =13,
- EPanicInternalError =19,
- EPanicNullDbFilePtr =20,
- EPanicInvalidLock =21,
- EPanicInvalidMutexType =22,
- EPanicMutexLockCounter =23,
- EPanicMutexOwner =24
- };
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////// TStaticFs /////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -341,6 +302,7 @@
static TInt DoGetDeviceCharacteristics(const TDriveInfo& aDriveInfo, const TVolumeIOParamInfo& aVolumeInfo);
static TInt DoGetSectorSize(const TDriveInfo& aDriveInfo, const TVolumeIOParamInfo& aVolumeInfo);
static TInt DoGetDeviceCharacteristicsAndSectorSize(TDbFile& aDbFile, TInt& aRecReadBufSize);
+ static TInt DoFileSizeCorruptionCheck(TDbFile& aDbFile, const TDesC& aFname, TInt aFmode);
};
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
--- a/persistentstorage/sqlite3api/OsLayer/os_symbian_emul.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/OsLayer/os_symbian_emul.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -22,6 +22,12 @@
#include "os_symbian.h"
#include <pls.h>
#include <e32std.h>
+#include "SqliteUtil.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "os_symbian_emulTraces.h"
+#endif
+#include "SqliteTraceDef.h"
#ifdef SQLITE_OS_SYMBIAN
@@ -78,7 +84,7 @@
{
idx = ++idx % KMaxEntries;
}
- __ASSERT_ALWAYS(cnt < KMaxEntries, User::Panic(KPanicCategory, EPanicMaxKeysExceeded));
+ __ASSERT_ALWAYS(cnt < KMaxEntries, __SQLITEPANIC2(ESqliteOsPanicMaxKeysExceeded));
if(!iTable[idx].iKey)
{
Add(idx, aKey, aLength);
@@ -105,7 +111,7 @@
*/
void Add(TInt aIdx, const TUint8* aKey, TInt aLength)
{
- __ASSERT_ALWAYS((iSize + aLength) <= KBufferSize, User::Panic(KPanicCategory, EPanicBufferSizeExceeded));
+ __ASSERT_ALWAYS((iSize + aLength) <= KBufferSize, __SQLITEPANIC2(ESqliteOsPanicBufferSizeExceeded));
//Add new entry to the hash table and the intial value to the WSD buffer
iTable[aIdx].iKey = aKey;
iTable[aIdx].iData = iNext;
@@ -159,16 +165,20 @@
*/
static TInt PlsInitialize(TPls* aPls)
{
- __ASSERT_ALWAYS(aPls != NULL, User::Panic(KPanicCategory, EPanicNullPls1));
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, PLSINITIALIZE_ENTRY, "OS-Entry;0;PlsInitialize"));
+ __ASSERT_ALWAYS(aPls != NULL, __SQLITEPANIC2(ESqliteOsPanicNullPls1));
//Global RFs object
TInt err = aPls->iStaticFs.Connect();
- __ASSERT_ALWAYS(err == KErrNone , User::Panic(KPanicCategory, EPanicFsCreationError));
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, PLSINITIALIZE1, "OS;0;PlsInitialize;iStaticFs.Connect() err=%d", err));
+ __ASSERT_ALWAYS(err == KErrNone, __SQLITEPANIC2(ESqliteOsPanicFsCreationError));
//Static mutexes
- for(TInt i=0;i<(sizeof(aPls->iStaticMutex)/sizeof(aPls->iStaticMutex[0])) && err==KErrNone;++i)
+ TInt idx = 0;
+ for(;idx<(sizeof(aPls->iStaticMutex)/sizeof(aPls->iStaticMutex[0])) && err==KErrNone;++idx)
{
- err = aPls->iStaticMutex[i].Create();
+ err = aPls->iStaticMutex[idx].Create();
}
- __ASSERT_ALWAYS(err == KErrNone , User::Panic(KPanicCategory, EPanicMutexCreationError));
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, PLSINITIALIZE2, "OS;0;PlsInitialize;iStaticMutex[%d].Create() err=%d", idx, err));
+ __ASSERT_ALWAYS(err == KErrNone , __SQLITEPANIC2(ESqliteOsPanicMutexCreationError));
//WSD map
//...already initialized by its constructor
//sqlite3_vfs object
@@ -191,6 +201,7 @@
aPls->iVfsApi.xCurrentTime = &TVfs::CurrentTime;
aPls->iVfsApi.xGetLastError = &TVfs::GetLastError;
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, PLSINITIALIZE_EXIT, "OS-Exit;0;PlsInitialize"));
return KErrNone;
}
@@ -213,8 +224,8 @@
RFs& TStaticFs::Fs()
{
TPls* pls = ::Pls(KSqliteUid, &PlsInitialize);
- __ASSERT_ALWAYS(pls != 0, User::Panic(KPanicCategory, EPanicNullPls2));
- __ASSERT_DEBUG(pls->iStaticFs.iFs.Handle() != KNullHandle, User::Panic(KPanicCategory, EPanicInvalidFs));
+ __ASSERT_ALWAYS(pls != 0, __SQLITEPANIC2(ESqliteOsPanicNullPls2));
+ __ASSERT_DEBUG(pls->iStaticFs.iFs.Handle() != KNullHandle, __SQLITEPANIC2(ESqliteOsPanicInvalidFs));
return pls->iStaticFs.iFs;
}
@@ -229,8 +240,8 @@
sqlite3_mutex* StaticMutex(TInt aType)
{
TPls* pls = ::Pls(KSqliteUid, &PlsInitialize);
- __ASSERT_ALWAYS(pls != 0, User::Panic(KPanicCategory, EPanicNullPls3));
- __ASSERT_ALWAYS((TUint)aType < (sizeof(pls->iStaticMutex)/sizeof(pls->iStaticMutex[0])), User::Panic(KPanicCategory, EPanicInvalidMutexType));
+ __ASSERT_ALWAYS(pls != 0, __SQLITEPANIC2(ESqliteOsPanicNullPls3));
+ __ASSERT_ALWAYS((TUint)aType < (sizeof(pls->iStaticMutex)/sizeof(pls->iStaticMutex[0])), __SQLITEPANIC2(ESqliteOsPanicInvalidMutexType));
return &pls->iStaticMutex[aType];
}
@@ -253,8 +264,8 @@
*/
int sqlite3_wsd_init(int aWsdBufSize, int aWsdEntryCount)
{
- __ASSERT_ALWAYS(aWsdBufSize <= TWsdMap::KBufferSize, User::Panic(KPanicCategory, EPanicWsdBufSize));
- __ASSERT_ALWAYS(aWsdEntryCount <= TWsdMap::KMaxEntries, User::Panic(KPanicCategory, EPanicWsdEntryCount));
+ __ASSERT_ALWAYS(aWsdBufSize <= TWsdMap::KBufferSize, __SQLITEPANIC2(ESqliteOsPanicWsdBufSize));
+ __ASSERT_ALWAYS(aWsdEntryCount <= TWsdMap::KMaxEntries, __SQLITEPANIC2(ESqliteOsPanicWsdEntryCount));
return SQLITE_OK;
}
@@ -272,7 +283,7 @@
*/
void* sqlite3_wsd_find(void* aKey, int aLength)
{
- __ASSERT_ALWAYS(aKey != NULL, User::Panic(KPanicCategory, EPanicNullKey));
+ __ASSERT_ALWAYS(aKey != NULL, __SQLITEPANIC2(ESqliteOsPanicNullKey));
return ::Pls(KSqliteUid, &PlsInitialize)->iWsdMap.Find(static_cast <const TUint8*> (aKey), aLength);
}
@@ -283,7 +294,7 @@
sqlite3_vfs* VfsApi()
{
TPls* pls = ::Pls(KSqliteUid, &PlsInitialize);
- __ASSERT_ALWAYS(pls != 0, User::Panic(KPanicCategory, EPanicNullPls4));
+ __ASSERT_ALWAYS(pls != 0, __SQLITEPANIC2(ESqliteOsPanicNullPls4));
return &pls->iVfsApi;
}
--- a/persistentstorage/sqlite3api/OsLayer/os_symbian_hrdw.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/OsLayer/os_symbian_hrdw.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -20,6 +20,12 @@
@file
*/
#include "os_symbian.h"
+#include "SqliteUtil.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "os_symbian_hrdwTraces.h"
+#endif
+#include "SqliteTraceDef.h"
#ifdef SQLITE_OS_SYMBIAN
@@ -47,7 +53,7 @@
TInt err = Connect();
if(err != KErrNone)
{
- RDebug::Print(_L("===SQLITE OS porting layer, file session creation has failed with err=%d.\r\n"), err);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TSTATICFS_TSTATICFS, "OS;0x%X;TStaticFs::TStaticFs;err=%d", (TUint)this, err));
User::Exit(err);
}
}
@@ -63,7 +69,7 @@
*/
RFs& TStaticFs::Fs()
{
- __ASSERT_DEBUG(TheFs.iFs.Handle() != KNullHandle, User::Panic(KPanicCategory, EPanicInvalidFs));
+ __ASSERT_DEBUG(TheFs.iFs.Handle() != KNullHandle, __SQLITEPANIC2(ESqliteOsPanicInvalidFs));
return TheFs.iFs;
}
@@ -91,14 +97,14 @@
TInt err = Create();
if(err != KErrNone)
{
- RDebug::Print(_L("===SQLITE OS porting layer, static mutex creation has failed with err=%d.\r\n"), err);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TSTATICMUTEX_TSTATICMUTEX, "OS;0x%X;TStaticMutex::TStaticMutex;err=%d", (TUint)this, err));
User::Exit(err);
}
}
sqlite3_mutex* StaticMutex(TInt aType)
{
- __ASSERT_ALWAYS((TUint)aType < (sizeof(TheStaticMutex)/sizeof(TheStaticMutex[0])), User::Panic(KPanicCategory, EPanicInvalidMutexType));
+ __ASSERT_ALWAYS((TUint)aType < (sizeof(TheStaticMutex)/sizeof(TheStaticMutex[0])), __SQLITEPANIC2(ESqliteOsPanicInvalidMutexType));
return &TheStaticMutex[aType];
}
--- a/persistentstorage/sqlite3api/OsLayer/os_symbian_mt.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/OsLayer/os_symbian_mt.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -36,7 +36,16 @@
}
#include <e32math.h>
#include "os_symbian.h"
-#include "UTraceSqlite.h"
+#include "SqliteUtil.h"
+#include "OstTraceDefinitions.h"
+#ifdef OST_TRACE_COMPILER_IN_USE
+#include "os_symbian_mtTraces.h"
+#endif
+#include "SqliteTraceDef.h"
+
+//Bit-mask constant. If xOpen()'s "aFlag" parameter contains one of these bits set, then the the file top be
+//opened or created is a journal file.
+const TUint KJournalFileTypeBitMask = SQLITE_OPEN_MAIN_JOURNAL | SQLITE_OPEN_TEMP_JOURNAL | SQLITE_OPEN_SUBJOURNAL | SQLITE_OPEN_MASTER_JOURNAL;
#ifdef SQLITE_TEST
@@ -96,7 +105,7 @@
return SQLITE_FULL;
default:
#ifdef _DEBUG
- RDebug::Print(_L("SQLite3 C API, Os2SqliteErr(), err=%d\n"), aOsErr);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, OS2SQLITEERR, "OS;0;Os2SqliteErr;aOsErr=%d", aOsErr));
#endif
break;
}
@@ -125,6 +134,7 @@
{
iFs.Close();
}
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TSTATICFS_CONNECT, "OS;0;TStaticFs::Connect;iFs.Handle()=0x%X;err=%d", iFs.Handle(), err));
return err;
}
@@ -139,6 +149,7 @@
iRefCount(0),
iOwnerThreadId(KMaxTUint64)
{
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, SQLITE3_MUTEX_SQLITE3_MUTEX, "OS;0x%X;sqlite3_mutex::sqlite3_mutex", (TUint)this));
}
/**
@@ -146,6 +157,7 @@
*/
sqlite3_mutex::~sqlite3_mutex()
{
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, SQLITE3_MUTEX_SQLITE3_MUTEX2, "OS;0x%X;sqlite3_mutex::~sqlite3_mutex", (TUint)this));
iMutex.Close();
}
@@ -159,7 +171,7 @@
*/
void sqlite3_mutex::Enter()
{
- __ASSERT_DEBUG(iRefCount >= 0, User::Panic(KPanicCategory, EPanicMutexLockCounter));
+ __ASSERT_DEBUG(iRefCount >= 0, __SQLITEPANIC(ESqliteOsPanicMutexLockCounter));
iMutex.Wait();
RThread currThread;
iOwnerThreadId = currThread.Id();
@@ -177,10 +189,10 @@
*/
void sqlite3_mutex::Leave()
{
- __ASSERT_DEBUG(iRefCount > 0, User::Panic(KPanicCategory, EPanicMutexLockCounter));
+ __ASSERT_DEBUG(iRefCount > 0, __SQLITEPANIC(ESqliteOsPanicMutexLockCounter));
#ifdef _DEBUG
RThread currThread;
- __ASSERT_DEBUG(iOwnerThreadId == currThread.Id(), User::Panic(KPanicCategory, EPanicMutexOwner));
+ __ASSERT_DEBUG(iOwnerThreadId == currThread.Id(), __SQLITEPANIC(ESqliteOsPanicMutexOwner));
#endif
--iRefCount;
iMutex.Signal();
@@ -205,7 +217,9 @@
*/
TInt sqlite3_mutex::Create()
{
- return iMutex.CreateLocal();
+ TInt err = iMutex.CreateLocal();
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, SQLITE3_MUTEX_CREATE, "OS;0x%X;sqlite3_mutex::Create;err=%d", (TUint)this, err));
+ return err;
}
/**
@@ -224,6 +238,7 @@
self = NULL;
}
}
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, CRECURSIVEMUTEX_NEWL, "OS;0x%X;CRecursiveMutex::New", (TUint)self));
return self;
}
@@ -243,7 +258,6 @@
*/
int TMutexApi::Init()
{
- SQLUTRACE_PROFILER(0);
return SQLITE_OK;
}
@@ -255,7 +269,6 @@
*/
int TMutexApi::End()
{
- SQLUTRACE_PROFILER(0);
return SQLITE_OK;
}
@@ -268,7 +281,6 @@
*/
sqlite3_mutex* TMutexApi::Alloc(int aType)
{
- SQLUTRACE_PROFILER(0);
sqlite3_mutex* mutex = NULL;
switch(aType)
{
@@ -281,6 +293,7 @@
//value is 2 (SQLITE_MUTEX_FAST is 0, SQLITE_MUTEX_RECURSIVE is 1).
break;
}
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TMUTEXAPI_ALLOC, "OS;0;TMutexApi::Alloc;aType=%d;mutex=0x%X", aType, (TUint)mutex));
return mutex;
}
@@ -290,7 +303,7 @@
*/
void TMutexApi::Free(sqlite3_mutex* aMutex)
{
- SQLUTRACE_PROFILER(0);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TMUTEXAPI_FREE, "OS;0;TMutexApi::Free;mutex=0x%X", (TUint)aMutex));
delete aMutex;
}
@@ -304,7 +317,6 @@
*/
void TMutexApi::Enter(sqlite3_mutex* aMutex)
{
- SQLUTRACE_PROFILER(0);
aMutex->Enter();
}
@@ -315,7 +327,6 @@
*/
int TMutexApi::Try(sqlite3_mutex*)
{
- SQLUTRACE_PROFILER(0);
return SQLITE_BUSY;
}
@@ -329,7 +340,6 @@
*/
void TMutexApi::Leave(sqlite3_mutex* aMutex)
{
- SQLUTRACE_PROFILER(0);
aMutex->Leave();
}
@@ -345,7 +355,6 @@
*/
int TMutexApi::Held(sqlite3_mutex* aMutex)
{
- SQLUTRACE_PROFILER(0);
return aMutex->IsHeld();
}
@@ -361,7 +370,6 @@
*/
int TMutexApi::Notheld(sqlite3_mutex* aMutex)
{
- SQLUTRACE_PROFILER(0);
return !aMutex->IsHeld();
}
@@ -374,7 +382,9 @@
*/
extern "C" SQLITE_EXPORT int sqlite3_os_init(void)
{
- return sqlite3_vfs_register(VfsApi(), 1);
+ TInt err = sqlite3_vfs_register(VfsApi(), 1);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, SQLITE3_OS_INIT, "OS;0;sqlite3_os_init;err=%d", err));
+ return err;
}
/**
@@ -382,7 +392,9 @@
*/
extern "C" SQLITE_EXPORT int sqlite3_os_end(void)
{
- return sqlite3_vfs_unregister(VfsApi());
+ TInt err = sqlite3_vfs_unregister(VfsApi());
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, SQLITE3_OS_END, "OS;0;sqlite3_os_end;err=%d", err));
+ return err;
}
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -521,6 +533,7 @@
iDeviceCharacteristics(-1)
{
pMethods = 0;
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TDBFILE_TDBFILE, "OS;0x%X;TDbFile::TDbFile", (TUint)this));
}
/**
@@ -541,7 +554,7 @@
*/
static inline TDbFile& DbFile(sqlite3_file* aDbFile)
{
- __ASSERT_DEBUG(aDbFile != 0, User::Panic(KPanicCategory, EPanicNullDbFilePtr));
+ __ASSERT_DEBUG(aDbFile != 0, __SQLITEPANIC2(ESqliteOsPanicNullDbFilePtr));
return *(static_cast <TDbFile*> (aDbFile));
}
@@ -563,13 +576,14 @@
*/
/* static */ int TFileIo::Close(sqlite3_file* aDbFile)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TFILEIO_CLOSE1, "OS;0x%X;TFileIo::Close", (TUint)&dbFile));
dbFile.iFileBuf.Close();
if(dbFile.iFullName)
{//"iFullName" will not be NULL only when TVfs::Open() is called with SQLITE_OPEN_DELETEONCLOSE flag.
//That means - SQlite expects the file to be deleted after the file close operation.
- (void)TStaticFs::Fs().Delete(*dbFile.iFullName);
+ __SQLITETRACE_OSEXPR(TInt err = ) TStaticFs::Fs().Delete(*dbFile.iFullName);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_CLOSE2, "OS;0x%X;TFileIo::Close;delete fileName=%S;err=%d", (TUint)&dbFile, __SQLITEPRNSTR(*dbFile.iFullName), err));
delete dbFile.iFullName;
dbFile.iFullName = NULL;
}
@@ -598,10 +612,9 @@
*/
/* static */ int TFileIo::Read(sqlite3_file* aDbFile, void* aBuf, int aAmt, sqlite3_int64 aOffset)
{
- SQLUTRACE_PROFILER(aDbFile);
- SYMBIAN_TRACE_SQLITE_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileRead, aAmt, aOffset));
SimulateIOError(return SQLITE_IOERR_READ);
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_READ_ENTRY, "OS-Entry;0x%X;TFileIo::Read;aAmt=%d;aOffset=%lld", (TUint)&dbFile, aAmt, aOffset));
TPtr8 ptr((TUint8*)aBuf, 0, aAmt);
TInt err = dbFile.iFileBuf.Read(aOffset, ptr);
TInt cnt = ptr.Length();
@@ -611,6 +624,7 @@
Mem::FillZ(static_cast <TUint8*> (aBuf) + cnt, aAmt - cnt);
sqliteErr = SQLITE_IOERR_SHORT_READ;
}
+ SQLITE_TRACE_OS(OstTraceExt4(TRACE_INTERNALS, TFILEIO_READ_EXIT, "OS-Exit;0x%X;TFileIo::Read;cnt=%d;err=%d;sqliteErr=%d", (TUint)&dbFile, cnt, err, sqliteErr));
return sqliteErr;
}
@@ -634,18 +648,19 @@
*/
/* static */ int TFileIo::Write(sqlite3_file* aDbFile, const void* aData, int aAmt, sqlite3_int64 aOffset)
{
- SQLUTRACE_PROFILER(aDbFile);
- SYMBIAN_TRACE_SQLITE_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileWrite, aAmt, aOffset));
SimulateIOError(return SQLITE_IOERR_WRITE);
SimulateDiskfullError(return SQLITE_FULL);
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_WRITE_ENTRY, "OS-Entry;0x%X;TFileIo::Write;aAmt=%d;aOffset=%lld", (TUint)&dbFile, aAmt, aOffset));
TInt err = KErrAccessDenied;
if(!dbFile.iReadOnly)
{
TPtrC8 ptr((const TUint8*)aData, aAmt);
err = dbFile.iFileBuf.Write(aOffset, ptr);
}
- return ::Os2SqliteErr(err, SQLITE_IOERR_WRITE);
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_IOERR_WRITE);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_WRITE_EXIT, "OS-Exit;0x%X;TFileIo::Write;err=%d;sqliteErr=%d", (TUint)&dbFile, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -666,16 +681,17 @@
*/
/* static */ int TFileIo::Truncate(sqlite3_file* aDbFile, sqlite3_int64 aLength)
{
- SQLUTRACE_PROFILER(aDbFile);
- SYMBIAN_TRACE_SQLITE_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileTruncate, aLength));
SimulateIOError(return SQLITE_IOERR_TRUNCATE);
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_TRUNCATE_ENTRY, "OS-Entry;0x%X;TFileIo::Truncate;aLength=%lld", (TUint)&dbFile, aLength));
TInt err = KErrAccessDenied;
if(!dbFile.iReadOnly)
{
err = dbFile.iFileBuf.SetSize(aLength);
}
- return ::Os2SqliteErr(err, SQLITE_IOERR_TRUNCATE);
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_IOERR_TRUNCATE);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_TRUNCATE_EXIT, "OS-Exit;0x%X;TFileIo::Truncate;err=%d;sqliteErr=%d", (TUint)&dbFile, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -696,9 +712,9 @@
*/
/* static */int TFileIo::Sync(sqlite3_file* aDbFile, int aFlags)
{
- SQLUTRACE_PROFILER(aDbFile);
SimulateIOError(return SQLITE_IOERR_FSYNC);
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TFILEIO_SYNC_ENTRY, "OS-Entry;0x%X;TFileIo::Sync", (TUint)&dbFile));
#ifdef SQLITE_TEST
if(aFlags & SQLITE_SYNC_FULL)
{
@@ -713,7 +729,9 @@
{
err = dbFile.iFileBuf.Flush();
}
- return ::Os2SqliteErr(err, SQLITE_IOERR_FSYNC);
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_IOERR_FSYNC);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_SYNC_EXIT, "OS-Exit;0x%X;TFileIo::Sync;err=%d;sqliteErr=%d", (TUint)&dbFile, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -732,11 +750,13 @@
*/
/* static */ int TFileIo::FileSize(sqlite3_file* aDbFile, sqlite3_int64* aSize)
{
- SQLUTRACE_PROFILER(aDbFile);
SimulateIOError(return SQLITE_IOERR_FSTAT);
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TFILEIO_FILESIZE_ENTRY, "OS-Entry;0x%X;TFileIo::FileSize", (TUint)&dbFile));
TInt err = dbFile.iFileBuf.Size(*aSize);
- return ::Os2SqliteErr(err, SQLITE_IOERR_FSTAT);
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_IOERR_FSTAT);
+ SQLITE_TRACE_OS(OstTraceExt4(TRACE_INTERNALS, TFILEIO_FILESIZE_EXIT, "OS-Exit;0x%X;TFileIo::FileSize;aSize=%lld;err=%d;sqliteErr=%d", (TUint)&dbFile, *aSize, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -779,6 +799,7 @@
break;
}
}
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_GETREADLOCK, "OS;0x%X;TFileIo::GetReadLock;rc=%d", (TUint)&aDbFile, rc));
return rc;
}
@@ -795,7 +816,9 @@
*/
/* static */TInt TFileIo::UnlockReadLock(TDbFile& aDbFile)
{
- return aDbFile.iFileBuf.UnLock(SHARED_FIRST + aDbFile.iSharedLockByte, 1);
+ TInt err = aDbFile.iFileBuf.UnLock(SHARED_FIRST + aDbFile.iSharedLockByte, 1);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_UNLOCKREADLOCK, "OS;0x%X;TFileIo::UnlockReadLock;err=%d", (TUint)&aDbFile, err));
+ return err;
}
/**
@@ -832,11 +855,11 @@
*/
/* static */ int TFileIo::Lock(sqlite3_file* aDbFile, int aLockType)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
//If there is already a lock of this type or more restrictive on the aDbFile, then - do nothing.
if(dbFile.iLockType >= aLockType)
{
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_LOCK1, "OS;0x%X;TFileIo::Lock;dbFile.iLockType=%d;aLockType=%d", (TUint)&dbFile, dbFile.iLockType, aLockType));
return SQLITE_OK;
}
@@ -848,14 +871,15 @@
TInt err = dbFile.iFileBuf.Flush(ETrue);
if(err != KErrNone)
{
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_LOCK2, "OS;0x%X;TFileIo::Lock;iFileBuf.Flush() failed, err=%d", (TUint)&dbFile, err));
return ::Os2SqliteErr(err, SQLITE_IOERR_LOCK);
}
}
//Make sure the locking sequence is correct
- __ASSERT_DEBUG(dbFile.iLockType != SQLITE_LOCK_NONE || aLockType == SQLITE_LOCK_SHARED, User::Panic(KPanicCategory, EPanicInvalidLock));
- __ASSERT_DEBUG(aLockType != SQLITE_LOCK_PENDING, User::Panic(KPanicCategory, EPanicInvalidLock));
- __ASSERT_DEBUG(aLockType != SQLITE_LOCK_RESERVED || dbFile.iLockType == SQLITE_LOCK_SHARED, User::Panic(KPanicCategory, EPanicInvalidLock));
+ __ASSERT_DEBUG(dbFile.iLockType != SQLITE_LOCK_NONE || aLockType == SQLITE_LOCK_SHARED, __SQLITEPANIC2(ESqliteOsPanicInvalidLock));
+ __ASSERT_DEBUG(aLockType != SQLITE_LOCK_PENDING, __SQLITEPANIC2(ESqliteOsPanicInvalidLock));
+ __ASSERT_DEBUG(aLockType != SQLITE_LOCK_RESERVED || dbFile.iLockType == SQLITE_LOCK_SHARED, __SQLITEPANIC2(ESqliteOsPanicInvalidLock));
TInt rc = SQLITE_OK; //Return code from subroutines
TBool locked = ETrue; //Result of a file lock call (the default value means: "lock accuired")
@@ -892,10 +916,11 @@
//Acquire a shared lock
if(aLockType == SQLITE_LOCK_SHARED && locked)
{
- __ASSERT_DEBUG(dbFile.iLockType == SQLITE_LOCK_NONE, User::Panic(KPanicCategory, EPanicInvalidLock));
+ __ASSERT_DEBUG(dbFile.iLockType == SQLITE_LOCK_NONE, __SQLITEPANIC2(ESqliteOsPanicInvalidLock));
TInt err = TFileIo::GetReadLock(dbFile);
if(err != KErrNone && err != KErrLocked)
{
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_LOCK3, "OS;0x%X;TFileIo::Lock;TFileIo::GetReadLock() failed, err=%d", (TUint)&dbFile, err));
return ::Os2SqliteErr(err, SQLITE_IOERR_LOCK);
}
locked = (err == KErrNone);
@@ -908,10 +933,11 @@
//Acquire a RESERVED lock
if(aLockType == SQLITE_LOCK_RESERVED && locked)
{
- __ASSERT_DEBUG(dbFile.iLockType == SQLITE_LOCK_SHARED, User::Panic(KPanicCategory, EPanicInvalidLock));
+ __ASSERT_DEBUG(dbFile.iLockType == SQLITE_LOCK_SHARED, __SQLITEPANIC2(ESqliteOsPanicInvalidLock));
TInt err = dbFile.iFileBuf.Lock(RESERVED_BYTE, 1);
if(err != KErrNone && err != KErrLocked)
{
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_LOCK4, "OS;0x%X;TFileIo::Lock;iFileBuf.Lock() failed, err=%d", (TUint)&dbFile, err));
return ::Os2SqliteErr(err, SQLITE_IOERR_LOCK);
}
locked = (err == KErrNone);
@@ -931,11 +957,12 @@
//Acquire an EXCLUSIVE lock
if(aLockType == SQLITE_LOCK_EXCLUSIVE && locked)
{
- __ASSERT_DEBUG(dbFile.iLockType >= SQLITE_LOCK_SHARED, User::Panic(KPanicCategory, EPanicInvalidLock));
+ __ASSERT_DEBUG(dbFile.iLockType >= SQLITE_LOCK_SHARED, __SQLITEPANIC2(ESqliteOsPanicInvalidLock));
(void)TFileIo::UnlockReadLock(dbFile);
TInt err = dbFile.iFileBuf.Lock(SHARED_FIRST, SHARED_SIZE);
if(err != KErrNone && err != KErrLocked)
{
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_LOCK5, "OS;0x%X;TFileIo::Lock;iFileBuf.Lock()-2 failed, err=%d", (TUint)&dbFile, err));
return ::Os2SqliteErr(err, SQLITE_IOERR_LOCK);
}
locked = (err == KErrNone);
@@ -949,13 +976,15 @@
// release it now.
if(gotPendingLock && aLockType == SQLITE_LOCK_SHARED)
{
- (void)dbFile.iFileBuf.UnLock(PENDING_BYTE, 1);
+ __SQLITETRACE_OSEXPR(TInt err =) dbFile.iFileBuf.UnLock(PENDING_BYTE, 1);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_LOCK6, "OS;0x%X;TFileIo::Lock;iFileBuf.UnLock()=%d", (TUint)&dbFile, err));
}
// Update the state of the lock has held in the file descriptor then
// return the appropriate result code.
rc = locked ? SQLITE_OK : SQLITE_BUSY;
dbFile.iLockType = newLockType;
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_LOCK7, "OS;0x%X;TFileIo::Lock;rc=%d;newLockType=%d", (TUint)&dbFile, rc, newLockType));
return rc;
}
@@ -986,21 +1015,22 @@
*/
/* static */ int TFileIo::Unlock(sqlite3_file* aDbFile, int aLockType)
{
- __ASSERT_DEBUG(aLockType <= SQLITE_LOCK_SHARED, User::Panic(KPanicCategory, EPanicInvalidLock));
+ __ASSERT_DEBUG(aLockType <= SQLITE_LOCK_SHARED, __SQLITEPANIC2(ESqliteOsPanicInvalidLock));
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
TInt rc = SQLITE_OK;
TInt currLockType = dbFile.iLockType;
if(currLockType >= SQLITE_LOCK_EXCLUSIVE)
{
- (void)dbFile.iFileBuf.UnLock(SHARED_FIRST, SHARED_SIZE);
+ __SQLITETRACE_OSEXPR(TInt err2 =) dbFile.iFileBuf.UnLock(SHARED_FIRST, SHARED_SIZE);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_UNLOCK1, "OS;0x%X;TFileIo::Unlock;iFileBuf.UnLock()=%d", (TUint)&dbFile, err2));
if(aLockType == SQLITE_LOCK_SHARED)
{
TInt err = TFileIo::GetReadLock(dbFile);
if(err != KErrNone && err != KErrLocked)
{
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_UNLOCK2, "OS;0x%X;TFileIo::Unlock;TFileIo::GetReadLock() failed, err=%d", (TUint)&dbFile, err));
return ::Os2SqliteErr(err, SQLITE_IOERR_UNLOCK);
}
if(err == KErrLocked)
@@ -1012,18 +1042,22 @@
}
if(currLockType >= SQLITE_LOCK_RESERVED)
{
- (void)dbFile.iFileBuf.UnLock(RESERVED_BYTE, 1);
+ __SQLITETRACE_OSEXPR(TInt err2 =) dbFile.iFileBuf.UnLock(RESERVED_BYTE, 1);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_UNLOCK3, "OS;0x%X;TFileIo::Unlock;iFileBuf.UnLock()-2=%d", (TUint)&dbFile, err2));
}
if(aLockType == SQLITE_LOCK_NONE && currLockType >= SQLITE_LOCK_SHARED)
{
- (void)TFileIo::UnlockReadLock(dbFile);
+ __SQLITETRACE_OSEXPR(TInt err2 =) TFileIo::UnlockReadLock(dbFile);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_UNLOCK4, "OS;0x%X;TFileIo::Unlock;TFileIo::UnlockReadLock()=%d", (TUint)&dbFile, err2));
}
if(currLockType>= SQLITE_LOCK_PENDING)
{
- (void)dbFile.iFileBuf.UnLock(PENDING_BYTE, 1);
+ __SQLITETRACE_OSEXPR(TInt err2 =) dbFile.iFileBuf.UnLock(PENDING_BYTE, 1);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_UNLOCK5, "OS;0x%X;TFileIo::Unlock;iFileBuf.UnLock()-3=%d", (TUint)&dbFile, err2));
}
dbFile.iLockType = aLockType;
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_UNLOCK6, "OS;0x%X;TFileIo::Unlock;rc=%d;newLockType=%d", (TUint)&dbFile, rc, aLockType));
return rc;
}
@@ -1046,7 +1080,6 @@
*/
/* static */ int TFileIo::CheckReservedLock(sqlite3_file* aDbFile, int *aResOut)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
TInt rc;
if(dbFile.iLockType >= SQLITE_LOCK_RESERVED)
@@ -1058,16 +1091,19 @@
TInt err = dbFile.iFileBuf.Lock(RESERVED_BYTE, 1);
if(err != KErrNone && err != KErrLocked)
{
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_CHECKRESERVEDLOCK1, "OS;0x%X;TFileIo::CheckReservedLock;iFileBuf.Lock(), err=%d", (TUint)&dbFile, err));
return ::Os2SqliteErr(err, SQLITE_IOERR_CHECKRESERVEDLOCK);
}
rc = (err == KErrNone);
if(rc) //non-zero rc means: the lock has been successful (there wasn't a reserved lock on this file)
{
- (void)dbFile.iFileBuf.UnLock(RESERVED_BYTE, 1);
+ __SQLITETRACE_OSEXPR(TInt err2 =) dbFile.iFileBuf.UnLock(RESERVED_BYTE, 1);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_CHECKRESERVEDLOCK2, "OS;0x%X;TFileIo::CheckReservedLock;iFileBuf.UnLock()=%d", (TUint)&dbFile, err2));
}
rc = !rc;
}
*aResOut = rc;
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TFILEIO_CHECKRESERVEDLOCK3, "OS;0x%X;TFileIo::CheckReservedLock;rc=%d", (TUint)&dbFile, rc));
return SQLITE_OK;
}
@@ -1092,9 +1128,7 @@
*/
/* static */ int TFileIo::FileControl(sqlite3_file* aDbFile, int aOp, void* aArg)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
- SYMBIAN_TRACE_SQLITE_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileFileCtr, aOp, dbFile.iFullName));
TInt err = KErrNone;
switch(aOp)
{
@@ -1105,7 +1139,9 @@
err = KErrArgument;
break;
}
- return err == KErrNone ? SQLITE_OK : SQLITE_ERROR;
+ TInt sqliteErr = err == KErrNone ? SQLITE_OK : SQLITE_ERROR;
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TFILEIO_FILECONTROL, "OS;0x%X;TFileIo::FileControl;err=%d;sqliteErr=%d", (TUint)&dbFile, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -1127,9 +1163,8 @@
*/
/* static */ int TFileIo::SectorSize(sqlite3_file* aDbFile)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
- __ASSERT_DEBUG(dbFile.iSectorSize > 0, User::Panic(KPanicCategory, EPanicInternalError));
+ __ASSERT_DEBUG(dbFile.iSectorSize > 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
if(dbFile.iSectorSize > 0)
{
return dbFile.iSectorSize;
@@ -1156,9 +1191,8 @@
*/
/* static */ int TFileIo::DeviceCharacteristics(sqlite3_file* aDbFile)
{
- SQLUTRACE_PROFILER(aDbFile);
TDbFile& dbFile = ::DbFile(aDbFile);
- __ASSERT_DEBUG(dbFile.iDeviceCharacteristics >= 0, User::Panic(KPanicCategory, EPanicInternalError));
+ __ASSERT_DEBUG(dbFile.iDeviceCharacteristics >= 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
if(dbFile.iDeviceCharacteristics >= 0)
{
return dbFile.iDeviceCharacteristics;
@@ -1185,7 +1219,9 @@
*/
/* static */ inline TInt TVfs::DoGetVolumeIoParamInfo(RFs& aFs, TInt aDriveNo, TVolumeIOParamInfo& aVolumeInfo)
{
- return aFs.VolumeIOParam(aDriveNo, aVolumeInfo);
+ TInt err = aFs.VolumeIOParam(aDriveNo, aVolumeInfo);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TVFS_DOGETVOLUMEIOPARAMINFO, "OS;0;TVfs::DoGetVolumeIoParamInfo;aDriveNo=%d;err=%d", aDriveNo, err));
+ return err;
}
/**
@@ -1277,7 +1313,7 @@
sectorSize = aVolumeInfo.iBlockSize;
}
}
- __ASSERT_DEBUG(sectorSize > 0 && (sectorSize & (sectorSize - 1)) == 0, User::Panic(KPanicCategory, EPanicInternalError));
+ __ASSERT_DEBUG(sectorSize > 0 && (sectorSize & (sectorSize - 1)) == 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
return sectorSize;
}
@@ -1306,8 +1342,8 @@
*/
/* static */ TInt TVfs::DoGetDeviceCharacteristicsAndSectorSize(TDbFile& aDbFile, TInt& aRecReadBufSize)
{
- __ASSERT_DEBUG(aDbFile.iDeviceCharacteristics < 0, User::Panic(KPanicCategory, EPanicInternalError));
- __ASSERT_DEBUG(aDbFile.iSectorSize <= 0, User::Panic(KPanicCategory, EPanicInternalError));
+ __ASSERT_DEBUG(aDbFile.iDeviceCharacteristics < 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
+ __ASSERT_DEBUG(aDbFile.iSectorSize <= 0, __SQLITEPANIC2(ESqliteOsPanicInternalError));
TInt driveNo;
TDriveInfo driveInfo;
TInt err = aDbFile.iFileBuf.Drive(driveNo, driveInfo);
@@ -1324,6 +1360,7 @@
aDbFile.iDeviceCharacteristics = TVfs::DoGetDeviceCharacteristics(driveInfo, volumeInfo);
aDbFile.iSectorSize = TVfs::DoGetSectorSize(driveInfo, volumeInfo);
aRecReadBufSize = volumeInfo.iRecReadBufSize;
+ SQLITE_TRACE_OS(OstTraceExt5(TRACE_INTERNALS, TVFS_DOGETGETDEVICECHARACTERISTICSANDSECTORSIZE, "OS;0x%X;TVfs::DoGetDeviceCharacteristicsAndSectorSize;driveNo=%d;sectorSize=%d;devCharact=0x%X;readBufSize=%d", (TUint)&aDbFile, driveNo, aDbFile.iSectorSize, (TUint)aDbFile.iDeviceCharacteristics, volumeInfo.iRecReadBufSize));
return KErrNone;
}
@@ -1361,6 +1398,64 @@
/**
SQLite OS porting layer API.
+The behaviour of the RFile/RFile64::SetSize operation is not atomic for non-rugged drives.
+When RFile/RFile64::SetSize() is called 2 operations occurs:-
+
+1)The cluster chain of the file is updated.
+2)The new file size is added to the file cache.
+
+If a power loss occurs after a SetSize there is a chance that the cluster chain was updated
+but the new file size is not yet flushed to the file. This puts the file into an inconsistent state.
+This is most likely to occur in the journal file where the time between a SetSize and Flush can
+be long.
+
+For this reason this check is added when the file is opened to see if the end of the file can
+be read straight away, if an error is returned then it is assumed that the SetSize has not be
+completed previously. In this case the file is deleted and re-created.
+
+@param aDbFile A pointer to a TDbFile instance, that contains the file handle.
+@param aFname A string of 16-bit wide characters containing name of the file to be checked.
+@param aFmode The mode in which the file is opened. These mode are documented in TFileMode.
+
+@return KErrNone, The operation has completed succesfully;
+ Note that other system-wide error codes may also be returned.
+@see TFileMode
+@see TVfs::Open()
+@see TDbFile
+*/
+/* static */ TInt TVfs::DoFileSizeCorruptionCheck(TDbFile& aDbFile, const TDesC& aFname, TInt aFmode)
+ {
+ const TInt KMinSize = 16;
+ TInt64 size;
+ TInt err = KErrNone ;
+ TBuf8<KMinSize> buf;
+
+ err = aDbFile.iFileBuf.Size(size);
+ if (err != KErrNone)
+ {
+ return err;
+ }
+ TBool IsMinFileSize = (size >= KMinSize);
+
+ if (IsMinFileSize)
+ {
+ err = aDbFile.iFileBuf.Read(size - KMinSize, buf);
+ }
+
+ if (err == KErrCorrupt || err == KErrEof || !IsMinFileSize)
+ {
+ aDbFile.iFileBuf.Close();
+ __SQLITETRACE_OSEXPR(TInt err2 =) TStaticFs::Fs().Delete(aFname);
+ SQLITE_TRACE_OS(OstTraceExt4(TRACE_INTERNALS, TVFS_DOFILESIZECORRUPTIONCHECK1, "OS;0x%X;TVfs::DoFileSizeCorruptionCheck;size=%lld;err=%d;deleteErr=%d", (TUint)&aDbFile, size, err, err2));
+ err = aDbFile.iFileBuf.Create(TStaticFs::Fs(), aFname, aFmode);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TVFS_DOFILESIZECORRUPTIONCHECK2, "OS;0x%X;TVfs::DoFileSizeCorruptionCheck;createErr=%d", (TUint)&aDbFile, err));
+ }
+ return err;
+ }
+
+/**
+SQLite OS porting layer API.
+
Opens or creates a file which name is in the aFileName parameter.
If the function succeeds, the file handle and other related information will be stored in the place pointed by the
aDbFile parameter, a memory block of sizeof(TDbFile) size for which is allocated by the caller.
@@ -1388,20 +1483,21 @@
*/
/* static */ int TVfs::Open(sqlite3_vfs* aVfs, const char* aFileName, sqlite3_file* aDbFile, int aFlags, int* aOutFlags)
{
- SQLUTRACE_PROFILER(aVfs);
TFileName fname;
if(aFileName && !::ConvertToUnicode(aFileName, fname))
{
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_OPEN1, "OS;0;TVfs::Open;ConvertToUnicode() failed"));
return SQLITE_CANTOPEN;
}
- SYMBIAN_TRACE_SQLITE_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileOpen, aDbFile, &fname));
new (aDbFile) TDbFile;
TDbFile& dbFile = ::DbFile(aDbFile);
+ SQLITE_TRACE_OS(OstTraceExt3(TRACE_INTERNALS, TVFS_OPEN_ENTRY, "OS-Entry;0x%X;TVfs::Open;fname=%S;aFlags=0x%X", (TUint)&aDbFile, __SQLITEPRNSTR(fname), (TUint)aFlags));
if(aFileName && (aFlags & SQLITE_OPEN_DELETEONCLOSE))
{
dbFile.iFullName = fname.Alloc();
if(!dbFile.iFullName)
{
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_OPEN2, "OS;0;TVfs::Open;fname.Alloc() failed"));
return SQLITE_IOERR_NOMEM;
}
}
@@ -1427,22 +1523,31 @@
}
else
{
- err = KErrGeneral;//The error has to be set here, because, there is case where none of the file create/open operations will be executed
+ err = KErrAccessDenied;//The error has to be set here, because, there is a case where none of the file create/open operations will be executed
+ TInt prevErr = KErrNone;
if(aFlags & SQLITE_OPEN_CREATE)
{
- err = dbFile.iFileBuf.Create(TStaticFs::Fs(), fname, fmode);
+ prevErr = err = dbFile.iFileBuf.Create(TStaticFs::Fs(), fname, fmode);
}
- if(err != KErrNone && err != KErrNoMemory)
+ if(err != KErrNone && err != KErrNoMemory && err != KErrDiskFull)
{
err = dbFile.iFileBuf.Open(TStaticFs::Fs(), fname, fmode);
+ if(err == KErrNone && (aFlags & KJournalFileTypeBitMask))
+ {
+ err = TVfs::DoFileSizeCorruptionCheck(dbFile, fname, fmode);
+ }
}
- if((err != KErrNone && err != KErrNoMemory) && (aFlags & SQLITE_OPEN_READWRITE))
+ if((err != KErrNone && err != KErrNoMemory && err != KErrDiskFull) && (aFlags & SQLITE_OPEN_READWRITE))
{
aFlags &= ~SQLITE_OPEN_READWRITE;
aFlags |= SQLITE_OPEN_READONLY;
fmode &= ~EFileWrite;
err = dbFile.iFileBuf.Open(TStaticFs::Fs(), fname, fmode);
}
+ if(err != KErrNone && prevErr == KErrAccessDenied)
+ {
+ err = KErrAccessDenied;
+ }
}
if(err == KErrNone)
{
@@ -1453,6 +1558,11 @@
dbFile.iFileBuf.Close();
delete dbFile.iFullName;
dbFile.iFullName = NULL;
+ if(!aFileName && fname.Length() > 0)
+ {//temporary file, the error is not KErrNone. Then delete the file (after a successfull
+ //temporary file creation there could be a failed memory allocation)
+ (void)TStaticFs::Fs().Delete(fname);
+ }
}
else
{
@@ -1465,7 +1575,9 @@
(void)dbFile.iFileBuf.SetReadAheadSize(dbFile.iSectorSize, recReadBufSize);
OpenCounter(+1);
}
- return ::Os2SqliteErr(err, SQLITE_CANTOPEN);
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_CANTOPEN);
+ SQLITE_TRACE_OS(OstTraceExt4(TRACE_INTERNALS, TVFS_OPEN_EXIT, "OS-Exit;0x%X;TVfs::Open;outFlags=0x%X;err=%d;sqliteErr=%d", (TUint)&aDbFile, aOutFlags ? (TUint)*aOutFlags : 0, err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -1483,16 +1595,17 @@
*/
/* static */ int TVfs::Delete(sqlite3_vfs* aVfs, const char* aFileName, int /*aSyncDir*/)
{
- SQLUTRACE_PROFILER(aVfs);
SimulateIOError(return SQLITE_IOERR_DELETE);
TFileName fname;
if(!::ConvertToUnicode(aFileName, fname))
{
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_DELETE1, "OS;0;TVfs::Delete;ConvertToUnicode() failed"));
return SQLITE_ERROR;
}
- SYMBIAN_TRACE_SQLITE_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileName, &fname));
TInt err = TStaticFs::Fs().Delete(fname);
- return ::Os2SqliteErr(err, SQLITE_IOERR_DELETE);
+ TInt sqliteErr = ::Os2SqliteErr(err, SQLITE_IOERR_DELETE);
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TVFS_DELETE2, "OS;0;TVfs::Delete;err=%d;sqliteErr=%d", err, sqliteErr));
+ return sqliteErr;
}
/**
@@ -1511,22 +1624,24 @@
*/
/* static */ int TVfs::Access(sqlite3_vfs* aVfs, const char* aFileName, int aFlags, int* aResOut)
{
- SQLUTRACE_PROFILER(aVfs);
TFileName fname;
if(!::ConvertToUnicode(aFileName, fname))
{
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_ACCESS1, "OS;0;TVfs::Access;ConvertToUnicode() failed"));
return SQLITE_IOERR_ACCESS;
}
- SYMBIAN_TRACE_SQLITE_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileName, &fname));
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TVFS_ACCESS_ENTRY, "OS-Entry;0;TVfs::Access;fname=%S;aFlags=0x%X", __SQLITEPRNSTR(fname), (TUint)aFlags));
TEntry entry;
TInt err = TStaticFs::Fs().Entry(fname, entry);
if(aFlags == SQLITE_ACCESS_EXISTS && err == KErrNotFound)
{
*aResOut = 0;
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_ACCESS_EXIT1, "OS-Exit;0;TVfs::Access;Exists-NoFound"));
return SQLITE_OK;
}
if(err != KErrNone)
{
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TVFS_ACCESS_EXIT2, "OS-Exit;0;TVfs::Access;err=%d", err));
return err == KErrNoMemory ? SQLITE_IOERR_NOMEM : SQLITE_IOERR_ACCESS;
}
*aResOut = 0;
@@ -1544,6 +1659,7 @@
default:
break;
}
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TVFS_ACCESS_EXIT3, "OS-Exit;0;TVfs::Access;aResOut=%d", *aResOut));
return SQLITE_OK;
}
@@ -1575,18 +1691,19 @@
*/
/* static */ int TVfs::FullPathName(sqlite3_vfs* aVfs, const char* aRelative, int aBufLen, char* aBuf)
{
- SQLUTRACE_PROFILER(aVfs);
if(!aRelative) //NULL argument
{
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_FULLPATHNAME1, "OS;0;TVfs::FullPathName;err=SQLITE_ERROR"));
return SQLITE_ERROR;
}
//Convert the received file name to UTF16
TBuf<KMaxFileName + 1> fname;
if(!::ConvertToUnicode(aRelative, fname))
{
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_FULLPATHNAME_EXIT1, "OS-Exit;0;TVfs::FullPathName;ConvertToUnicode() failed"));
return SQLITE_ERROR;
}
- SYMBIAN_TRACE_SQLITE_EVENTS_ONLY(UTF::Printf(UTF::TTraceContext(UTF::EInternals), KFileName, &fname));
+ SQLITE_TRACE_OS(OstTraceExt2(TRACE_INTERNALS, TVFS_FULLPATHNAME_ENTRY, "OS-Entry;0;TVfs::FullPathName;fname=%S;aBufLen=%d", __SQLITEPRNSTR(fname), aBufLen));
//Search if the file name begins with ".\" - current directory
if(fname.Find(KCwd) == 0)
{
@@ -1597,6 +1714,7 @@
TInt err = TStaticFs::Fs().SessionPath(defaultPath);
if(err != KErrNone)
{
+ SQLITE_TRACE_OS(OstTrace1(TRACE_INTERNALS, TVFS_FULLPATHNAME_EXIT4, "OS-Exit;0;TVfs::FullPathName;SessionPath() failed, err=%d", err));
return SQLITE_ERROR;
}
TParse parse;
@@ -1604,8 +1722,10 @@
TPtr8 dest8(reinterpret_cast <TUint8*> (aBuf), aBufLen);
if(!::ConvertFromUnicode(parse.FullName(), dest8))
{
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_FULLPATHNAME_EXIT2, "OS-Exit;0;TVfs::FullPathName;ConvertFromUnicode() failed"));
return SQLITE_ERROR;
}
+ SQLITE_TRACE_OS(OstTrace0(TRACE_INTERNALS, TVFS_FULLPATHNAME_EXIT3, "OS-Exit;0;TVfs::FullPathName;err=SQLITE_OK"));
return SQLITE_OK;
}
@@ -1621,7 +1741,6 @@
*/
/* static */ int TVfs::Randomness(sqlite3_vfs* aVfs, int aBufLen, char* aBuf)
{
- SQLUTRACE_PROFILER(aVfs);
const TInt KRandIterations = aBufLen / sizeof(int);
for(TInt i=0;i<KRandIterations;++i)
{
@@ -1642,7 +1761,6 @@
*/
/* static */ int TVfs::Sleep(sqlite3_vfs* aVfs, int aMicrosec)
{
- SQLUTRACE_PROFILER(aVfs);
User::AfterHighRes(TTimeIntervalMicroSeconds32(aMicrosec));
return aMicrosec;
}
@@ -1660,7 +1778,6 @@
*/
/* static */ int TVfs::CurrentTime(sqlite3_vfs* aVfs, double* aNow)
{
- SQLUTRACE_PROFILER(aVfs);
TTime now;
now.UniversalTime();
TDateTime date = now.DateTime();
@@ -1700,7 +1817,6 @@
*/
/* static */int TVfs::GetLastError(sqlite3_vfs* aVfs, int /*aBufLen*/, char* /*aBuf*/)
{
- SQLUTRACE_PROFILER(aVfs);
return 0;
}
--- a/persistentstorage/sqlite3api/TEST/SRC/tclsqlite.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/SRC/tclsqlite.c Tue Aug 31 16:57:14 2010 +0300
@@ -273,7 +273,7 @@
p->iSeek = sqlite3_blob_bytes(p->pBlob) + offset;
break;
- default: assert(!"Bad seekMode");
+ default: assert(0); /* Bad seekMode */
}
return p->iSeek;
--- a/persistentstorage/sqlite3api/TEST/SRC/test6.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/SRC/test6.c Tue Aug 31 16:57:14 2010 +0300
@@ -321,7 +321,7 @@
}
default:
- assert(!"Cannot happen");
+ assert(0); /* Cannot happen */
}
if( pWrite==pFinal ) break;
--- a/persistentstorage/sqlite3api/TEST/TCL/tcldistribution/generic/tclMain.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/TCL/tcldistribution/generic/tclMain.c Tue Aug 31 16:57:14 2010 +0300
@@ -32,7 +32,9 @@
*/
#if !defined(MAC_TCL)
+# if !defined(__SYMBIAN32__)
extern int isatty _ANSI_ARGS_((int fd));
+# endif
#else
#include <unistd.h>
#endif
--- a/persistentstorage/sqlite3api/TEST/TCL/tcldistribution/unix/tclUnixPort.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/TCL/tcldistribution/unix/tclUnixPort.h Tue Aug 31 16:57:14 2010 +0300
@@ -508,7 +508,9 @@
#if defined(_sgi) || defined(__sgi) || (defined(__APPLE__) && defined(__DYNAMIC__))
# define environ _environ
#endif
+#ifndef __SYMBIAN32__ // added to prevent RVCT warnings on armv5
extern char **environ;
+#endif
/*
* At present (12/91) not all stdlib.h implementations declare strtod.
@@ -517,8 +519,9 @@
* an int. There's no ANSI prototype for it because there would end
* up being too many conflicts with slightly-different prototypes.
*/
-
+#ifndef __SYMBIAN32__ // added to prevent RVCT warnings on armv5
extern double strtod();
+#endif
/*
* There is no platform-specific panic routine for Unix in the Tcl internals.
--- a/persistentstorage/sqlite3api/TEST/TclScript/misc7.test Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/TclScript/misc7.test Tue Aug 31 16:57:14 2010 +0300
@@ -1,6 +1,6 @@
# 2006 September 4
#
-# Portions Copyright (c) 2007-2008 Nokia Corporation and/or its subsidiaries. All rights reserved.
+# Portions Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiaries. All rights reserved.
#
# The author disclaims copyright to this source code. In place of
# a legal notice, here is a blessing:
@@ -97,7 +97,7 @@
execsql { CREATE TABLE abc(a PRIMARY KEY, b, c); }
db close
-if {$tcl_platform(platform)!="windows"} {
+if {$tcl_platform(platform)!="windows" && $tcl_platform(platform)!="symbian"} {
do_fileopen_test misc7-6.1 {
BEGIN;
INSERT INTO abc VALUES(1, 2, 3);
--- a/persistentstorage/sqlite3api/TEST/TclScript/tester.tcl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/TclScript/tester.tcl Tue Aug 31 16:57:14 2010 +0300
@@ -1,6 +1,6 @@
# 2001 September 15
#
-# Portions Copyright (c) 2007-2008 Nokia Corporation and/or its subsidiaries. All rights reserved.
+# Portions Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiaries. All rights reserved.
#
# The author disclaims copyright to this source code. In place of
# a legal notice, here is a blessing:
@@ -250,14 +250,17 @@
puts "\nError: $result"
# Symbian OS: Set and increase error count with do_fail procedure (definition in Tester.tcl)
do_fail $name
+ print_text $name "FAILED"
if {$nErr>$maxErr} {puts "*** Giving up..."; finalize_testing}
} elseif {[string compare $result $expected]} {
puts "\nExpected: \[$expected\]\n Got: \[$result\]"
# Symbian OS: Set and increase error count with do_fail procedure (definition in Tester.tcl)
do_fail $name
+ print_text $name "FAILED"
if {$nErr>=$maxErr} {puts "*** Giving up..."; finalize_testing}
} else {
puts " Ok"
+ print_text $name "OK"
}
flush stdout
if {[info exists ::tester_do_binarylog]} {
--- a/persistentstorage/sqlite3api/TEST/sqliteTestUtl.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/sqliteTestUtl.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -21,40 +21,65 @@
static TBuf8<500> TheBuf8;
static TBuf16<500> TheBuf16;
-static RTest TheTest(_L("t_sqliteapi test"));
+static RTest* TheTest;
-extern "C" void TestTitle(void)
+extern "C" void TestOpen(const char* title)
{
- TheTest.Title();
+ TPtrC8 p((const unsigned char*)title);
+ TheBuf16.Copy(p);
+ TheTest = new RTest(TheBuf16);
+ }
+
+extern "C" void TestTitle()
+ {
+ TheTest->Title();
}
extern "C" void TestStart(const char* title)
{
TPtrC8 p((const unsigned char*)title);
TheBuf16.Copy(p);
- TheTest.Start(TheBuf16);
+ TheTest->Start(TheBuf16);
}
extern "C" void TestNext(const char* title)
{
TPtrC8 p((const unsigned char*)title);
TheBuf16.Copy(p);
- TheTest.Next(TheBuf16);
+ TheTest->Next(TheBuf16);
}
extern "C" void TestClose(void)
{
- TheTest.Close();
+ TheTest->Close();
+ delete TheTest;
}
extern "C" void TestEnd(void)
{
- TheTest.End();
+ TheTest->End();
}
extern "C" void TestAbort(int aLine)
{
- TheTest(0, aLine);
+ TheTest->operator()(0, aLine);
+ }
+
+extern "C" void TestTestLine(int aResult, int aLine)
+ {
+ TheTest->operator()(aResult, aLine);
+ }
+
+extern "C" void TestTest(int aResult)
+ {
+ TheTest->operator()(aResult);
+ }
+
+extern "C" void TestPrintf(const char* title)
+ {
+ TPtrC8 p((const unsigned char*)title);
+ TheBuf16.Copy(p);
+ TheTest->Printf(TheBuf16);
}
extern "C" void TestHeapMark(void)
@@ -115,9 +140,9 @@
{
RFs TheFs;
TInt err = TheFs.Connect();
- TheTest(err == KErrNone);
+ TheTest->operator()(err == KErrNone);
err = TheFs.CreatePrivatePath(EDriveC);
TheFs.Close();
- TheTest(err == KErrNone || err == KErrAlreadyExists);
+ TheTest->operator()(err == KErrNone || err == KErrAlreadyExists);
}
--- a/persistentstorage/sqlite3api/TEST/sqliteTestUtl.h Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/sqliteTestUtl.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,12 +24,16 @@
extern "C" {
#endif
+void TestOpen(const char* title);
void TestTitle(void);
void TestStart(const char* title);
void TestNext(const char* title);
void TestClose(void);
void TestEnd(void);
void TestAbort(TInt aLine);
+void TestTestLine(int aResult, int aLine);
+void TestTest(int aResult);
+void TestPrintf(const char* title);
void TestHeapMark(void);
void TestHeapMarkEnd(void);
--- a/persistentstorage/sqlite3api/TEST/t_sqliteapi.c Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/t_sqliteapi.c Tue Aug 31 16:57:14 2010 +0300
@@ -942,6 +942,8 @@
}
}
+ srand((unsigned)&ThreadFunc);
+
PrintS("Thread \"%s\" - begin\r\n", (char*)pname);
err = sqlite3_open(TheTestDbName, &db);
TEST2(err, SQLITE_OK);
@@ -949,6 +951,10 @@
while(records < KRecordsCount)
{
+ if((records % 10) == 0)
+ {
+ PrintSI("Thread \"%s\", %d records.\r\n", (char*)pname, records);
+ }
err = sqlite3_exec(db, "BEGIN", 0, 0, &errmsg);
if(err == SQLITE_OK)
{
@@ -966,7 +972,7 @@
if(err == SQLITE_OK)
{
TheInsertRecCnt[threadIdx] += KCommitRecordsCount;
- records += 2;
+ records += KCommitRecordsCount;
}
else if(err == SQLITE_BUSY)
{
@@ -974,11 +980,15 @@
(void)sqlite3_exec(db, "ROLLBACK", 0, 0, 0);
if(errmsg)
{
- PrintSI("Err msg: %s. Err: %d.\r\n", errmsg, err);
+ char fmt[100];
+ strcpy(fmt, "Thread \"");
+ strcat(fmt, (char*)pname);
+ strcat(fmt, "\". Err msg: %s. Err: %d.\r\n");
+ PrintSI(fmt, errmsg, err);
sqlite3_free(errmsg);
errmsg = 0;
}
- usleep(100);
+ usleep((rand() % 3000) + 500);
}
}
@@ -1347,6 +1357,7 @@
UNUSED_ARG(argc);
UNUSED_ARG(argv);
+ TestOpen("t_sqliteapi test");
TestTitle();
TestHeapMark();
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sqlite3api/TEST/t_sqliteapi.txt Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,3 @@
+This file is not used by any of the SQLite tests.
+The only purpose of this file is: to create a private branch
+on Z: drive for t_sqliteapi test and copy the file there.
--- a/persistentstorage/sqlite3api/TEST/t_sqlitedef.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/t_sqlitedef.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -20,10 +20,10 @@
#include <e32math.h>
#include <sqlite3.h>
-#include "e32des16.h"
+#include "sqliteTestUtl.h"
+const char* const KTestName = "t_sqlitedef";
-static RTest TheTest(_L("t_sqlitedef"));
static RFs TheFs;
static sqlite3* TheDb = NULL;
@@ -46,15 +46,15 @@
static void CreateTestEnv()
{
TInt err = TheFs.Connect();
- TheTest(err == KErrNone);
+ TestTestLine(err == KErrNone, __LINE__);
err = TheFs.ShareAuto();
- TheTest(err == KErrNone);
+ TestTestLine(err == KErrNone,__LINE__);
TFileName testDir;
testDir.Copy(TPtrC8((const TUint8*)KTestDir));
err = TheFs.MkDir(testDir);
- TheTest(err == KErrNone || err == KErrAlreadyExists);
+ TestTestLine(err == KErrNone || err == KErrAlreadyExists, __LINE__);
TFileName fname;
fname.Copy(TPtrC8((const TUint8*)KTestDb));
@@ -110,7 +110,7 @@
{
PrintErrMsg();
DestroyTestEnv();
- TheTest(EFalse, aLine);
+ TestTestLine(EFalse, aLine);
}
}
static void Check(TInt aValue, TInt aExpected, TInt aLine)
@@ -120,7 +120,7 @@
PrintErrMsg();
DestroyTestEnv();
RDebug::Print(_L("*** Expected error: %d, got: %d\r\n"), aExpected, aValue);
- TheTest(EFalse, aLine);
+ TestTestLine(EFalse, aLine);
}
}
#define TEST(arg) ::Check((arg), __LINE__)
@@ -420,8 +420,18 @@
DeleteFile(KTestDb);
dtstr1.Format(_L("%04d-%02d-%02d,%02d:%02d:%02d"), dt.Year(), dt.Month() + 1, dt.Day() + 1, dt.Hour(), dt.Minute(), dt.Second());
- TheTest.Printf(_L("Universal date&time=\"%S\"\n"), &dtstr1);
- TheTest.Printf(_L("SQLite date&time=\"%S\"\n"), &dtstr2);
+
+ // For the C-Style printout
+ _LIT8(KUniversalTimeText,"Universal date&time=");
+ _LIT8(KSQLiteTimeText, "SQLite date&time=");
+ TBuf8<96> dtstr1print;
+ TBuf8<96> dtstr2print;
+ dtstr1print.Copy(dtstr1);
+ dtstr2print.Copy(dtstr2);
+ dtstr1print.Insert(0,KUniversalTimeText);
+ dtstr2print.Insert(0,KSQLiteTimeText);
+ TestPrintf((const char*)(dtstr1print.PtrZ()));
+ TestPrintf((const char*)(dtstr2print.PtrZ()));
//Comapare and fail if dates are not equal (+- 1 second)
TLex lex;
@@ -465,19 +475,19 @@
void DoTest()
{
- TheTest.Start(_L("@SYMTestCaseID:PDS-SQLITE3-UT-4029: SQLite file handle test"));
+ TestStart("@SYMTestCaseID:PDS-SQLITE3-UT-4029: SQLite file handle test");
FileHandleTest();
- TheTest.Next(_L("@SYMTestCaseID:PDS-SQLITE3-CT-4028: DEF121506 test"));
+ TestNext("@SYMTestCaseID:PDS-SQLITE3-CT-4028: DEF121506 test");
DEF121506();
- TheTest.Next(_L("@SYMTestCaseID:PDS-SQLITE3-CT-4046: DEF140020 test"));
+ TestNext("@SYMTestCaseID:PDS-SQLITE3-CT-4046: DEF140020 test");
DEF140020();
- TheTest.Next(_L("@SYMTestCaseID:PDS-SQLITE3-CT-4047: SQLITE, \"CREATE INDEX\" sql crashes the SQLite library"));
+ TestNext("@SYMTestCaseID:PDS-SQLITE3-CT-4047: SQLITE, \"CREATE INDEX\" sql crashes the SQLite library");
DEF143066();
- TheTest.Next(_L(" @SYMTestCaseID:SYSLIB-SQL-CT-4048 DEF143151: SQLite, strftime() returns incorrect result"));
+ TestNext(" @SYMTestCaseID:SYSLIB-SQL-CT-4048 DEF143151: SQLite, strftime() returns incorrect result");
DEF143151();
}
@@ -485,7 +495,8 @@
TInt E32Main()
{
- TheTest.Title();
+ TestOpen(KTestName);
+ TestTitle();
CTrapCleanup* tc = CTrapCleanup::New();
__UHEAP_MARK;
@@ -496,8 +507,8 @@
__UHEAP_MARKEND;
- TheTest.End();
- TheTest.Close();
+ TestEnd();
+ TestClose();
delete tc;
User::Heap().Check();
return KErrNone;
--- a/persistentstorage/sqlite3api/TEST/t_sqliteperf.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/t_sqliteperf.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -18,11 +18,13 @@
#include <e32math.h>
#include <hal.h>
#include <sqldb.h>
+#include "sqliteTestUtl.h"
#include "t_sqliteperf.h"
///////////////////////////////////////////////////////////////////////////////////////
-static RTest TheTest(_L("t_sqliteperf test"));
+const char* const KTestName = "t_sqliteperf test";
+
_LIT(KTestDir, "c:\\test\\");
_LIT(KTestDbName, "c:\\test\\t_sqliteperf.db");
_LIT8(KTestDbName8, "c:\\test\\t_sqliteperf.db\x0");
@@ -65,37 +67,11 @@
///////////////////////////////////////////////////////////////////////////////////////
-extern "C" void TestAbort(TInt aLine)
- {
- TheTest(0, aLine);
- }
-
extern "C" const char* TestDbName(void)
{
return (const char*)KTestDbName8().Ptr();
}
-extern "C" void PrintS(const char* aFmt, const char* aMsg)
- {
- TheSqlBuf.Format(TPtrC8((const TUint8*)aFmt), aMsg);
- ThePrintBuf.Copy(TheSqlBuf);
- TheTest.Printf(ThePrintBuf);
- }
-
-extern "C" void PrintI(const char* aFmt, int a1)
- {
- TheSqlBuf.Format(TPtrC8((const TUint8*)aFmt), a1);
- ThePrintBuf.Copy(TheSqlBuf);
- TheTest.Printf(ThePrintBuf);
- }
-
-extern "C" void PrintIII(const char* aFmt, int a1, int a2, int a3)
- {
- TheSqlBuf.Format(TPtrC8((const TUint8*)aFmt), a1, a2, a3);
- ThePrintBuf.Copy(TheSqlBuf);
- TheTest.Printf(ThePrintBuf);
- }
-
static void DeleteTestFiles()
{
TheDb.Close();
@@ -109,7 +85,7 @@
if(!aValue)
{
DeleteTestFiles();
- TheTest(EFalse, aLine);
+ TestTestLine(EFalse, aLine);
}
}
static void Check(TInt aValue, TInt aExpected, TInt aLine)
@@ -118,7 +94,7 @@
{
DeleteTestFiles();
RDebug::Print(_L("*** Expected error: %d, got: %d\r\n"), aExpected, aValue);
- TheTest(EFalse, aLine);
+ TestTestLine(EFalse, aLine);
}
}
#define TEST(arg) ::Check((arg), __LINE__)
@@ -175,7 +151,9 @@
static void GetFastCounterFrequency()
{
TEST2(HAL::Get(HAL::EFastCounterFrequency, TheCounterFreq), KErrNone);
- TheTest.Printf(_L("Counter frequency=%d\r\n"), TheCounterFreq);
+ TBuf8<32> printString;
+ printString.Format(_L8("Counter frequency=%d\r\n"), TheCounterFreq);
+ TestPrintf((const char*)printString.PtrZ());
}
extern "C" unsigned int FastCounterValue(void)
@@ -193,62 +171,71 @@
static void PrintPerfTestResults()
{
+ TBuf8<256> printString;
TInt r1 = FcDiff2Us(ThePerfTestResult[EPerfTestSqlMode] [EPerfTestMultiInsert]);
TInt r2 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteSqlMode] [EPerfTestMultiInsert]);
TInt r3 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteDefaultMode][EPerfTestMultiInsert]);
TInt r4 = (TInt)((Abs(r2 - r1) * 100.0) / r1);
TInt r5 = (TInt)((Abs(r3 - r1) * 100.0) / r1);
- TheTest.Printf(_L("### SQL SQLITE-SQL SQLITE-DEFAULT\r\n"));
- TheTest.Printf(_L("###Mutli Insert: %8dus %8dus %8dus %8d%% %8d%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ TestPrintf("### SQL SQLITE-SQL SQLITE-DEFAULT\r\n");
+ printString.Format(_L8("###Multi Insert: %8dus %8dus %8dus %8d%%%% %8d%%%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ TestPrintf((const char*)printString.PtrZ());
r1 = FcDiff2Us(ThePerfTestResult[EPerfTestSqlMode] [EPerfTestMultiUpdate]);
r2 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteSqlMode] [EPerfTestMultiUpdate]);
r3 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteDefaultMode][EPerfTestMultiUpdate]);
r4 = (TInt)((Abs(r2 - r1) * 100.0) / r1);
r5 = (TInt)((Abs(r3 - r1) * 100.0) / r1);
- TheTest.Printf(_L("###Mutli Update: %8dus %8dus %8dus %8d%% %8d%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ printString.Format(_L8("###Multi Update: %8dus %8dus %8dus %8d%%%% %8d%%%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ TestPrintf((const char*)printString.PtrZ());
r1 = FcDiff2Us(ThePerfTestResult[EPerfTestSqlMode] [EPerfTestMultiDelete]);
r2 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteSqlMode] [EPerfTestMultiDelete]);
r3 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteDefaultMode][EPerfTestMultiDelete]);
r4 = (TInt)((Abs(r2 - r1) * 100.0) / r1);
r5 = (TInt)((Abs(r3 - r1) * 100.0) / r1);
- TheTest.Printf(_L("###Mutli Delete: %8dus %8dus %8dus %8d%% %8d%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ printString.Format(_L8("###Multi Delete: %8dus %8dus %8dus %8d%%%% %8d%%%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ TestPrintf((const char*)printString.PtrZ());
r1 = FcDiff2Us(ThePerfTestResult[EPerfTestSqlMode] [EPerfTestMultiSelect]);
r2 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteSqlMode] [EPerfTestMultiSelect]);
r3 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteDefaultMode][EPerfTestMultiSelect]);
r4 = (TInt)((Abs(r2 - r1) * 100.0) / r1);
r5 = (TInt)((Abs(r3 - r1) * 100.0) / r1);
- TheTest.Printf(_L("###Mutli Select: %8dus %8dus %8dus %8d%% %8d%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ printString.Format(_L8("###Multi Select: %8dus %8dus %8dus %8d%%%% %8d%%%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ TestPrintf((const char*)printString.PtrZ());
r1 = FcDiff2Us(ThePerfTestResult[EPerfTestSqlMode] [EPerfTestSingleInsert]);
r2 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteSqlMode] [EPerfTestSingleInsert]);
r3 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteDefaultMode][EPerfTestSingleInsert]);
r4 = (TInt)((Abs(r2 - r1) * 100.0) / r1);
r5 = (TInt)((Abs(r3 - r1) * 100.0) / r1);
- TheTest.Printf(_L("##Single Insert: %8dus %8dus %8dus %8d%% %8d%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ printString.Format(_L8("##Single Insert: %8dus %8dus %8dus %8d%%%% %8d%%%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ TestPrintf((const char*)printString.PtrZ());
r1 = FcDiff2Us(ThePerfTestResult[EPerfTestSqlMode] [EPerfTestSingleUpdate]);
r2 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteSqlMode] [EPerfTestSingleUpdate]);
r3 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteDefaultMode][EPerfTestSingleUpdate]);
r4 = (TInt)((Abs(r2 - r1) * 100.0) / r1);
r5 = (TInt)((Abs(r3 - r1) * 100.0) / r1);
- TheTest.Printf(_L("##Single Update: %8dus %8dus %8dus %8d%% %8d%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ printString.Format(_L8("##Single Update: %8dus %8dus %8dus %8d%%%% %8d%%%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ TestPrintf((const char*)printString.PtrZ());
r1 = FcDiff2Us(ThePerfTestResult[EPerfTestSqlMode] [EPerfTestSingleDelete]);
r2 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteSqlMode] [EPerfTestSingleDelete]);
r3 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteDefaultMode][EPerfTestSingleDelete]);
r4 = (TInt)((Abs(r2 - r1) * 100.0) / r1);
r5 = (TInt)((Abs(r3 - r1) * 100.0) / r1);
- TheTest.Printf(_L("##Single Delete: %8dus %8dus %8dus %8d%% %8d%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ printString.Format(_L8("##Single Delete: %8dus %8dus %8dus %8d%%%% %8d%%%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ TestPrintf((const char*)printString.PtrZ());
r1 = FcDiff2Us(ThePerfTestResult[EPerfTestSqlMode] [EPerfTestSingleSelect]);
r2 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteSqlMode] [EPerfTestSingleSelect]);
r3 = FcDiff2Us(ThePerfTestResult[EPerfTestSqliteDefaultMode][EPerfTestSingleSelect]);
r4 = (TInt)((Abs(r2 - r1) * 100.0) / r1);
r5 = (TInt)((Abs(r3 - r1) * 100.0) / r1);
- TheTest.Printf(_L("##Single Select: %8dus %8dus %8dus %8d%% %8d%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ printString.Format(_L8("##Single Select: %8dus %8dus %8dus %8d%%%% %8d%%%%\r\n"), r1, r2, r3, r2 > r1 ? -r4 : +r4, r3 > r1 ? -r5 : +r5);
+ TestPrintf((const char*)printString.PtrZ());
}
///////////////////////////////////////////////////////////////////////////////////////
@@ -300,7 +287,7 @@
*/
static void SqlServerMultiInsertTest(const char aInsertSql[], TInt aInsertRecCnt)
{
- TheTest.Next( _L(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4010 "));
+ TestNext(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4010 ");
(void)KillProcess(KSqlSrvName);
TInt err = TheDb.Open(KTestDbName);
@@ -357,7 +344,7 @@
*/
static void SqlServerMultiUpdateTest(const char aUpdateSql[], TInt aUpdateRecIds[], TInt aUpdateRecCnt)
{
- TheTest.Next( _L(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4011 "));
+ TestNext(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4011 ");
(void)KillProcess(KSqlSrvName);
TInt err = TheDb.Open(KTestDbName);
@@ -385,7 +372,7 @@
*/
static void SqlServerMultiDeleteTest(const char aDeleteSql[], TInt aDeleteRecIds[], TInt aDeleteRecCnt)
{
- TheTest.Next( _L(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4012 "));
+ TestNext(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4012 ");
(void)KillProcess(KSqlSrvName);
TInt err = TheDb.Open(KTestDbName);
@@ -413,7 +400,7 @@
*/
static void SqlServerMultiSelectTest(const char aSelectSql[], TInt aSelectRecIds[], TInt aSelectRecCnt)
{
- TheTest.Next( _L(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4013 "));
+ TestNext(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4013 ");
(void)KillProcess(KSqlSrvName);
TInt err = TheDb.Open(KTestDbName);
@@ -462,7 +449,7 @@
*/
static void SqlServerSingleInsertTest(const char aSingleInsertSql[], TInt aInsertRecId)
{
- TheTest.Next( _L(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4014 "));
+ TestNext(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4014 ");
(void)KillProcess(KSqlSrvName);
TInt err = TheDb.Open(KTestDbName);
@@ -489,7 +476,7 @@
*/
static void SqlServerSingleUpdateTest(const char aSingleUpdateSql[], TInt aUpdateRecId)
{
- TheTest.Next( _L(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4015 "));
+ TestNext(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4015 ");
(void)KillProcess(KSqlSrvName);
TInt err = TheDb.Open(KTestDbName);
@@ -517,7 +504,7 @@
*/
static void SqlServerSingleDeleteTest(const char aSingleDeleteSql[], TInt aDeleteRecId)
{
- TheTest.Next( _L(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4016 "));
+ TestNext(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4016 ");
(void)KillProcess(KSqlSrvName);
TInt err = TheDb.Open(KTestDbName);
@@ -545,7 +532,7 @@
*/
static void SqlServerSingleSelectTest(const char aSingleSelectSql[], TInt aSelectRecId)
{
- TheTest.Next( _L(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4017 "));
+ TestNext(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4017 ");
(void)KillProcess(KSqlSrvName);
TInt err = TheDb.Open(KTestDbName);
@@ -589,37 +576,38 @@
static void DoSqlServerTests()
{
- TheTest.Next(_L("SQL: Create the test database"));
+ TestNext("SQL: Create the test database");
CreateTestDatabase();
- TBuf<100> msgbuf;
+ TBuf8<100> msgbuf;
- msgbuf.Format(_L("SQL: insert %d records in a single transaction"), KInsertRecCnt);
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("SQL: insert %d records in a single transaction"), KInsertRecCnt);
+ TestNext((const char*)msgbuf.PtrZ());
SqlServerMultiInsertTest(KMultiInsertSql, KInsertRecCnt);
- msgbuf.Format(_L("SQL: update %d records in a single transaction"), KUpdateRecCnt);
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("SQL: update %d records in a single transaction"), KUpdateRecCnt);
+ TestNext((const char*)msgbuf.PtrZ());
SqlServerMultiUpdateTest(KMultiUpdateSql, TheUpdateRecIds, KUpdateRecCnt);
- msgbuf.Format(_L("SQL: delete %d records in a single transaction"), KDeleteRecCnt);
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("SQL: delete %d records in a single transaction"), KDeleteRecCnt);
+ TestNext((const char*)msgbuf.PtrZ());
SqlServerMultiDeleteTest(KMultiDeleteSql, TheDeleteRecIds, KDeleteRecCnt);
- msgbuf.Format(_L("SQL: select %d records"), KSelectRecCnt);
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("SQL: select %d records"), KSelectRecCnt);
+ msgbuf.Copy(msgbuf);
+ TestNext((const char*)msgbuf.PtrZ());
SqlServerMultiSelectTest(KMultiSelectSql, TheSelectRecIds, KSelectRecCnt);
- TheTest.Next(_L("SQL: insert a single record"));
+ TestNext("SQL: insert a single record");
SqlServerSingleInsertTest(KSingleInsertSql, TheInsertRecId);
- TheTest.Next(_L("SQL: update a single record"));
+ TestNext("SQL: update a single record");
SqlServerSingleUpdateTest(KSingleUpdateSql, TheUpdateRecId);
- TheTest.Next(_L("SQL: delete a single record"));
+ TestNext("SQL: delete a single record");
SqlServerSingleDeleteTest(KSingleDeleteSql, TheDeleteRecId);
- TheTest.Next(_L("SQL: select a single record"));
+ TestNext("SQL: select a single record");
SqlServerSingleSelectTest(KSingleSelectSql, TheSelectRecId);
(void)RSqlDatabase::Delete(KTestDbName);
@@ -631,51 +619,51 @@
SqliteInitialize(aPerfTestMode);
- TheTest.Next( _L("SQLite: Create the test database"));
+ TestNext("SQLite: Create the test database");
CreateTestDatabase();
- TBuf<200> msgbuf;
- _LIT(KSqliteConfigSql, "\"SQL\"");
- _LIT(KSqliteConfigDefault, "\"Default\"");
+ TBuf8<200> msgbuf;
+ _LIT8(KSqliteConfigSql, "\"SQL\"");
+ _LIT8(KSqliteConfigDefault, "\"Default\"");
- msgbuf.Format(_L("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4018: SQLite, configuration: %S: insert %d records in a single transaction"),
+ msgbuf.Format(_L8("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4018: SQLite, configuration: %S: insert %d records in a single transaction"),
aPerfTestMode == EPerfTestSqliteSqlMode ? &KSqliteConfigSql : &KSqliteConfigDefault, KInsertRecCnt);
- TheTest.Next(msgbuf);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteMultiInsertTest(aPerfTestMode, KMultiInsertSql, KInsertRecCnt);
- msgbuf.Format(_L("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4019: SQLite, configuration: %S: update %d records in a single transaction"),
+ msgbuf.Format(_L8("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4019: SQLite, configuration: %S: update %d records in a single transaction"),
aPerfTestMode == EPerfTestSqliteSqlMode ? &KSqliteConfigSql : &KSqliteConfigDefault, KUpdateRecCnt);
- TheTest.Next(msgbuf);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteMultiUpdateTest(aPerfTestMode, KMultiUpdateSql, TheUpdateRecIds, KUpdateRecCnt);
- msgbuf.Format(_L("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4020: SQLite, configuration: %S: delete %d records in a single transaction"),
+ msgbuf.Format(_L8("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4020: SQLite, configuration: %S: delete %d records in a single transaction"),
aPerfTestMode == EPerfTestSqliteSqlMode ? &KSqliteConfigSql : &KSqliteConfigDefault, KDeleteRecCnt);
- TheTest.Next(msgbuf);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteMultiDeleteTest(aPerfTestMode, KMultiDeleteSql, TheDeleteRecIds, KDeleteRecCnt);
- msgbuf.Format(_L("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4021: SQLite, configuration: %S: select %d records"),
+ msgbuf.Format(_L8("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4021: SQLite, configuration: %S: select %d records"),
aPerfTestMode == EPerfTestSqliteSqlMode ? &KSqliteConfigSql : &KSqliteConfigDefault, KSelectRecCnt);
- TheTest.Next(msgbuf);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteMultiSelectTest(aPerfTestMode, KMultiSelectSql, TheSelectRecIds, KSelectRecCnt);
- msgbuf.Format(_L("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4022: SQLite, configuration: %S: insert a single record"),
+ msgbuf.Format(_L8("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4022: SQLite, configuration: %S: insert a single record"),
aPerfTestMode == EPerfTestSqliteSqlMode ? &KSqliteConfigSql : &KSqliteConfigDefault);
- TheTest.Next(msgbuf);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteSingleInsertTest(aPerfTestMode, KSingleInsertSql, TheInsertRecId);
- msgbuf.Format(_L("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4023: SQLite, configuration: %S: update a single record"),
+ msgbuf.Format(_L8("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4023: SQLite, configuration: %S: update a single record"),
aPerfTestMode == EPerfTestSqliteSqlMode ? &KSqliteConfigSql : &KSqliteConfigDefault);
- TheTest.Next(msgbuf);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteSingleUpdateTest(aPerfTestMode, KSingleUpdateSql, TheUpdateRecId);
- msgbuf.Format(_L("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4024: SQLite, configuration: %S: delete a single record"),
+ msgbuf.Format(_L8("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4024: SQLite, configuration: %S: delete a single record"),
aPerfTestMode == EPerfTestSqliteSqlMode ? &KSqliteConfigSql : &KSqliteConfigDefault);
- TheTest.Next(msgbuf);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteSingleDeleteTest(aPerfTestMode, KSingleDeleteSql, TheDeleteRecId);
- msgbuf.Format(_L("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4025: SQLite, configuration: %S: select a single record"),
+ msgbuf.Format(_L8("@SYMTestCaseID:SYSLIB-SQLITE3-UT-4025: SQLite, configuration: %S: select a single record"),
aPerfTestMode == EPerfTestSqliteSqlMode ? &KSqliteConfigSql : &KSqliteConfigDefault);
- TheTest.Next(msgbuf);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteSingleSelectTest(aPerfTestMode, KSingleSelectSql, TheSelectRecId);
(void)RSqlDatabase::Delete(KTestDbName);
@@ -819,13 +807,13 @@
static void DoTests()
{
- TheTest.Start(_L("Get fast counter frequency"));
+ TestStart("Get fast counter frequency");
GetFastCounterFrequency();
- TheTest.Next( _L("Generate test record ids"));
+ TestNext("Generate test record ids");
GenerateTestRecIds();
- TheTest.Next( _L("Verify generated test record ids"));
+ TestNext("Verify generated test record ids");
VerifyGeneratedRecIds();
DoSqlServerTests();
@@ -840,7 +828,8 @@
TInt E32Main()
{
- TheTest.Title();
+ TestOpen(KTestName);
+ TestTitle();
CTrapCleanup* tc = CTrapCleanup::New();
@@ -853,8 +842,8 @@
__UHEAP_MARKEND;
- TheTest.End();
- TheTest.Close();
+ TestEnd();
+ TestClose();
delete tc;
--- a/persistentstorage/sqlite3api/TEST/t_sqliteperf2.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/t_sqliteperf2.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -20,6 +20,7 @@
#include <sqlite3.h>
#include <string.h>
#include <stdio.h>
+#include "sqliteTestUtl.h"
///////////////////////////////////////////////////////////////////////////////////////
@@ -40,7 +41,7 @@
//The performance test case results are stored in the ThePerfTestResult array.
static TUint32 ThePerfTestResult[EPerfTestTypeCnt];
-static RTest TheTest(_L("t_sqliteperf2 test"));
+const char* const KTestName = "t_sqliteperf2 test";
_LIT(KTestDir, "c:\\test\\");
_LIT(KTestDbName, "c:\\test\\t_sqliteperf2.db");
@@ -173,9 +174,8 @@
if(TheDb)
{
const char* msg = sqlite3_errmsg(TheDb);
- TBuf<200> buf;
- buf.Copy(TPtrC8((const TUint8*)msg));
- TheTest.Printf(_L("*** SQLite error message: \"%S\"\r\n"), &buf);
+ TestPrintf("*** SQLite error message:");
+ TestPrintf(msg);
}
}
@@ -186,7 +186,7 @@
{
DeleteTestFiles();
PrintSqliteErrMsg();
- TheTest(EFalse, aLine);
+ TestTestLine(EFalse, aLine);
}
}
static void Check(TInt aValue, TInt aExpected, TInt aLine)
@@ -196,7 +196,7 @@
DeleteTestFiles();
RDebug::Print(_L("*** Expected error: %d, got: %d\r\n"), aExpected, aValue);
PrintSqliteErrMsg();
- TheTest(EFalse, aLine);
+ TestTestLine(EFalse, aLine);
}
}
#define TEST(arg) ::Check((arg), __LINE__)
@@ -218,7 +218,9 @@
static void GetFastCounterFrequency()
{
TEST2(HAL::Get(HAL::EFastCounterFrequency, TheCounterFreq), KErrNone);
- TheTest.Printf(_L("Counter frequency=%d\r\n"), TheCounterFreq);
+ TBuf8<32> printString;
+ printString.Format(_L8("Counter frequency=%d\r\n"), TheCounterFreq);
+ TestPrintf((const char*)printString.PtrZ());
}
TUint32 FastCounterValue(void)
@@ -238,30 +240,40 @@
static void PrintPerfTestResults()
{
+ TBuf8<256> printString;
+
TInt r = FcDiff2Us(ThePerfTestResult[EPerfTestMultiInsert]);
- TheTest.Printf(_L("###Mutli Insert: %8dus\r\n"), r);
+ printString.Format(_L8("###Mutli Insert: %8dus\r\n"), r);
+ TestPrintf((const char*)printString.PtrZ());
r = FcDiff2Us(ThePerfTestResult[EPerfTestMultiUpdate]);
- TheTest.Printf(_L("###Mutli Update: %8dus\r\n"), r);
+ printString.Format(_L8("###Mutli Update: %8dus\r\n"), r);
+ TestPrintf((const char*)printString.PtrZ());
r = FcDiff2Us(ThePerfTestResult[EPerfTestMultiSelect]);
- TheTest.Printf(_L("###Mutli Select: %8dus\r\n"), r);
+ printString.Format(_L8("###Mutli Select: %8dus\r\n"), r);
+ TestPrintf((const char*)printString.PtrZ());
r = FcDiff2Us(ThePerfTestResult[EPerfTestMultiDelete]);
- TheTest.Printf(_L("###Mutli Delete: %8dus\r\n"), r);
+ printString.Format(_L8("###Mutli Delete: %8dus\r\n"), r);
+ TestPrintf((const char*)printString.PtrZ());
r = FcDiff2Us(ThePerfTestResult[EPerfTestSingleInsert]);
- TheTest.Printf(_L("##Single Insert: %8dus\r\n"), r);
+ printString.Format(_L8("##Single Insert: %8dus\r\n"), r);
+ TestPrintf((const char*)printString.PtrZ());
r = FcDiff2Us(ThePerfTestResult[EPerfTestSingleUpdate]);
- TheTest.Printf(_L("##Single Update: %8dus\r\n"), r);
+ printString.Format(_L8("##Single Update: %8dus\r\n"), r);
+ TestPrintf((const char*)printString.PtrZ());
r = FcDiff2Us(ThePerfTestResult[EPerfTestSingleSelect]);
- TheTest.Printf(_L("##Single Select: %8dus\r\n"), r);
+ printString.Format(_L8("##Single Select: %8dus\r\n"), r);
+ TestPrintf((const char*)printString.PtrZ());
r = FcDiff2Us(ThePerfTestResult[EPerfTestSingleDelete]);
- TheTest.Printf(_L("##Single Delete: %8dus\r\n"), r);
+ printString.Format(_L8("##Single Delete: %8dus\r\n"), r);
+ TestPrintf((const char*)printString.PtrZ());
}
///////////////////////////////////////////////////////////////////////////////////////
@@ -277,9 +289,8 @@
(void)TheFs.Delete(KTestDbName);
const char* ver = sqlite3_libversion();
- TBuf<20> buf;
- buf.Copy(TPtrC8((const TUint8*)ver));
- TheTest.Printf(_L("*** SQLite library version: \"%S\"\r\n"), &buf);
+ TestPrintf("*** SQLite library version:");
+ TestPrintf(ver);
TInt err = sqlite3_open(KTestDbName8, &TheDb);
TEST2(err, SQLITE_OK);
@@ -643,44 +654,44 @@
static void DoTests()
{
- TheTest.Start(_L("Get fast counter frequency"));
+ TestStart("Get fast counter frequency");
GetFastCounterFrequency();
- TheTest.Next( _L("SQLite: Create the test database"));
+ TestNext("SQLite: Create the test database");
CreateTestDatabase();
- TBuf<100> msgbuf;
+ TBuf8<100> msgbuf;
- msgbuf.Format(_L("@SYMTestCaseID:PDS-SQLITE3-UT-4030: Insert %d records in a single transaction"), KInsertRecCnt);
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("@SYMTestCaseID:PDS-SQLITE3-UT-4030: Insert %d records in a single transaction"), KInsertRecCnt);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteMultiInsertTest();
- msgbuf.Format(_L("@SYMTestCaseID:PDS-SQLITE3-UT-4031: Update %d records in a single transaction"), KUpdateRecCnt);
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("@SYMTestCaseID:PDS-SQLITE3-UT-4031: Update %d records in a single transaction"), KUpdateRecCnt);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteMultiUpdateTest();
- msgbuf.Format(_L("@SYMTestCaseID:PDS-SQLITE3-UT-4032: Select %d records"), KSelectRecCnt);
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("@SYMTestCaseID:PDS-SQLITE3-UT-4032: Select %d records"), KSelectRecCnt);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteMultiSelectTest();
- msgbuf.Format(_L("@SYMTestCaseID:PDS-SQLITE3-UT-4033: Delete %d records in a single transaction"), KDeleteRecCnt);
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("@SYMTestCaseID:PDS-SQLITE3-UT-4033: Delete %d records in a single transaction"), KDeleteRecCnt);
+ TestNext((const char*)msgbuf.PtrZ());
SqliteMultiDeleteTest();
- msgbuf.Format(_L("@SYMTestCaseID:PDS-SQLITE3-UT-4034: Insert a single record"));
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("@SYMTestCaseID:PDS-SQLITE3-UT-4034: Insert a single record"));
+ TestNext((const char*)msgbuf.PtrZ());
SqliteSingleInsertTest();
- msgbuf.Format(_L("@SYMTestCaseID:PDS-SQLITE3-UT-4035: Update a single record"));
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("@SYMTestCaseID:PDS-SQLITE3-UT-4035: Update a single record"));
+ TestNext((const char*)msgbuf.PtrZ());
SqliteSingleUpdateTest();
- msgbuf.Format(_L("@SYMTestCaseID:PDS-SQLITE3-UT-4036: Select a single record"));
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("@SYMTestCaseID:PDS-SQLITE3-UT-4036: Select a single record"));
+ TestNext((const char*)msgbuf.PtrZ());
SqliteSingleSelectTest();
- msgbuf.Format(_L("@SYMTestCaseID:PDS-SQLITE3-UT-4037: Delete a single record"));
- TheTest.Next(msgbuf);
+ msgbuf.Format(_L8("@SYMTestCaseID:PDS-SQLITE3-UT-4037: Delete a single record"));
+ TestNext((const char*)msgbuf.PtrZ());
SqliteSingleDeleteTest();
(void)TheFs.Delete(KTestDbName);
@@ -690,14 +701,15 @@
TInt E32Main()
{
- TheTest.Title();
+ TestOpen(KTestName);
+ TestTitle();
CTrapCleanup* tc = CTrapCleanup::New();
__UHEAP_MARK;
TInt err = TheFs.Connect();
- TheTest(err == KErrNone);
+ TestTest(err == KErrNone);
CreateTestDir();
DeleteTestFiles();
@@ -707,8 +719,8 @@
__UHEAP_MARKEND;
TheFs.Close();
- TheTest.End();
- TheTest.Close();
+ TestEnd();
+ TestClose();
delete tc;
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sqlite3api/TEST/t_sqlitetclstarter.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,166 @@
+// Copyright (c) 2007-2010 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:
+//
+
+#include <e32test.h>
+#include <e32uid.h>
+#include <f32file.h>
+#include <bautils.h>
+
+
+///////////////////////////////////////////////////////////////////////////////////////
+
+RTest TheTest(_L("t_sqlitetclstarter"));
+
+_LIT(KTclExecutableName,"tclsqlite3.exe");
+_LIT(KTclScriptName,"all.test");
+
+_LIT(KStdioConfigFilePath, "C:\\system\\data\\");
+_LIT(KStdioConfigFile, "C:\\system\\data\\config.ini");
+
+_LIT(KLogsFilePath, "C:\\logs\\testexecute\\");
+
+RFs theFs;
+
+///////////////////////////////////////////////////////////////////////////////////////
+
+//
+// Creates the appropriate stdio ini file to redirect stdio output to a file
+//
+
+void CreateIniFileForStdoutRedirection(void)
+ {
+ TInt err(KErrNone);
+
+ // check path exists otherwise create
+ if (!BaflUtils::FolderExists(theFs, KStdioConfigFilePath))
+ {
+ err = theFs.MkDirAll(KStdioConfigFilePath);
+ TheTest(err == KErrNone, __LINE__);
+ }
+
+
+ // create file
+ RFile file;
+ err = file.Create(theFs, KStdioConfigFile, EFileRead | EFileWrite);
+ TheTest(err == KErrNone, __LINE__);
+
+ TheTest(KErrNone == file.Write(_L8("[STDIO]\r\n")), __LINE__);
+ TheTest(KErrNone == file.Write(_L8("STDIN = MEDIA1\r\n")), __LINE__);
+ TheTest(KErrNone == file.Write(_L8("STDOUT = MEDIA2\r\n")), __LINE__);
+ TheTest(KErrNone == file.Write(_L8("[MEDIA1]\r\n")), __LINE__);
+ TheTest(KErrNone == file.Write(_L8("type = console\r\n")), __LINE__);
+ TheTest(KErrNone == file.Write(_L8("width = -1\r\n")), __LINE__);
+ TheTest(KErrNone == file.Write(_L8("height = -1\r\n")), __LINE__);
+ TheTest(KErrNone == file.Write(_L8("[MEDIA2]\r\n")), __LINE__);
+ TheTest(KErrNone == file.Write(_L8("type = file\r\n")), __LINE__);
+ TheTest(KErrNone == file.Write(_L8("path = C:\\logs\\testexecute\\t_sqlitetclstarter.htm\r\n")), __LINE__);
+ TheTest(KErrNone == file.Flush(),__LINE__);
+
+ file.Close();
+
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////
+
+//
+// Deletes the stdio ini file
+//
+
+void DeleteIniFileForStdoutRedirection(void)
+ {
+ TInt err = theFs.Delete(KStdioConfigFile);
+ TheTest(err == KErrNone || err==KErrNotFound || err==KErrPathNotFound, __LINE__);
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////
+
+//
+// Ensure the directory for the Logs file exists
+//
+
+void EnsureLogsDirectoryExists(void)
+ {
+ TInt err(KErrNone);
+
+ // check path exists otherwise create
+ if (!BaflUtils::FolderExists(theFs, KLogsFilePath))
+ {
+ err = theFs.MkDirAll(KLogsFilePath);
+ TheTest(err == KErrNone, __LINE__);
+ }
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////
+
+//
+// Start the tcl process with a script
+//
+
+void StartTclProcess(void)
+ {
+ RProcess process;
+ TInt err = process.Create(KTclExecutableName,KTclScriptName);
+ TheTest(err==KErrNone, __LINE__);
+
+ TRequestStatus processStatus;
+ process.Logon(processStatus);
+
+ process.Resume();
+
+ TheTest.Printf(_L("Wait for TCL tests to finish\r\n"));
+
+ User::WaitForRequest(processStatus);
+
+ TheTest.Printf(_L("TCL tests finished %d\r\n"),processStatus.Int());
+
+ TheTest(processStatus.Int() == KErrNone, __LINE__);
+ }
+
+///////////////////////////////////////////////////////////////////////////////////////
+
+TInt E32Main()
+ {
+ TheTest.Title();
+ TheTest.Start(_L("TCL tests"));
+
+ CTrapCleanup* tc = CTrapCleanup::New();
+
+ __UHEAP_MARK;
+
+ TInt err = theFs.Connect();
+ TheTest(err == KErrNone, __LINE__);
+
+ DeleteIniFileForStdoutRedirection();
+
+ CreateIniFileForStdoutRedirection();
+
+ EnsureLogsDirectoryExists();
+
+ StartTclProcess();
+
+ DeleteIniFileForStdoutRedirection();
+
+ theFs.Close();
+
+ __UHEAP_MARKEND;
+
+ TheTest.End();
+ TheTest.Close();
+
+ delete tc;
+
+ User::Heap().Check();
+ return KErrNone;
+ }
--- a/persistentstorage/sqlite3api/TEST/t_sqlitewsd.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/sqlite3api/TEST/t_sqlitewsd.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -19,13 +19,14 @@
#include <e32math.h>
#include <sqlite3.h>
#include "t_sqlitewsd.h"
+#include "sqliteTestUtl.h"
#include <spawn.h>
#include <sys/wait.h>
///////////////////////////////////////////////////////////////////////////////////////
-static RTest TheTest(_L("t_sqlitewsd test"));
+const char* const KTestName = "t_sqlitewsd";
static RFs TheFs;
static pid_t TheKSqliteWsdProc2Pid = 0;
@@ -62,7 +63,7 @@
if(!aValue)
{
DestroyTestEnv();
- TheTest(EFalse, aLine);
+ TestTestLine(EFalse, aLine);
}
}
@@ -79,7 +80,7 @@
RDebug::Print(_L("*** SQLITE error msg: \"%S\".\r\n"), &msgBuf);
}
DestroyTestEnv();
- TheTest(EFalse, aLine);
+ TestTestLine(EFalse, aLine);
}
}
@@ -182,14 +183,14 @@
*/
static void DoWsdTests()
{
- TheTest.Start(_L(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4026 Create the test database "));
+ TestStart(" @SYMTestCaseID:SYSLIB-SQLITE3-UT-4026 Create the test database ");
CreateDb();
- TheTest.Next(_L("Run the second process: t_sqlitewsd2"));
+ TestNext("Run the second process: t_sqlitewsd2");
RunSqliteWsd2();
- TheTest.Next(_L("Insert the records"));
+ TestNext("Insert the records");
DoInserts(KWsdProc1Id, KWsdProc1RecId1, KWsdProc1RecId2);
DestroySqliteWsd2();
- TheTest.Next(_L("Verify the inserted records"));
+ TestNext("Verify the inserted records");
DoVerify();
}
@@ -197,7 +198,8 @@
TInt E32Main()
{
- TheTest.Title();
+ TestOpen(KTestName);
+ TestTitle();
CTrapCleanup* tc = CTrapCleanup::New();
@@ -209,8 +211,8 @@
__UHEAP_MARKEND;
- TheTest.End();
- TheTest.Close();
+ TestEnd();
+ TestClose();
delete tc;
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sqlite3api/traces_sqlite3/OstTraceDefinitions.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,7 @@
+#ifndef __OSTTRACEDEFINITIONS_H__
+#define __OSTTRACEDEFINITIONS_H__
+// OST_TRACE_COMPILER_IN_USE flag has been added by Trace Compiler
+// REMOVE BEFORE CHECK-IN TO VERSION CONTROL
+//#define OST_TRACE_COMPILER_IN_USE
+#include <opensystemtrace.h>
+#endif
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sqlite3api/traces_sqlite3/fixed_id.definitions Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,87 @@
+#Fixed group and trace id definitions. If this file is removed, the identifiers are rebuilt.
+[GROUP]TRACE_FATAL=0x81
+[GROUP]TRACE_INTERNALS=0x88
+[TRACE]TRACE_FATAL[0x81]_TSQLUTIL_PANIC=0x1
+[TRACE]TRACE_INTERNALS[0x88]_CRECURSIVEMUTEX_NEWL=0x1a
+[TRACE]TRACE_INTERNALS[0x88]_OS2SQLITEERR=0x15
+[TRACE]TRACE_INTERNALS[0x88]_PLSINITIALIZE1=0x12
+[TRACE]TRACE_INTERNALS[0x88]_PLSINITIALIZE2=0x13
+[TRACE]TRACE_INTERNALS[0x88]_PLSINITIALIZE_ENTRY=0x11
+[TRACE]TRACE_INTERNALS[0x88]_PLSINITIALIZE_EXIT=0x14
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_CLOSE=0x5
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_CREATE=0x2
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_DOFILEFLUSH=0xf
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_DOFILESIZE=0xd
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_DOFILEWRITE=0x10
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_DOSETFILESIZE=0xe
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_DRIVE=0xc
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_LOCK=0xa
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_OPEN=0x3
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_READ1=0x7
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_READ2=0x8
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_READ3=0x9
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_RFILEBUF64=0x1
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_SETREADAHEADSIZE=0x6
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_TEMP=0x4
+[TRACE]TRACE_INTERNALS[0x88]_RFILEBUF64_UNLOCK=0xb
+[TRACE]TRACE_INTERNALS[0x88]_SQLITE3_MUTEX_CREATE=0x19
+[TRACE]TRACE_INTERNALS[0x88]_SQLITE3_MUTEX_SQLITE3_MUTEX=0x17
+[TRACE]TRACE_INTERNALS[0x88]_SQLITE3_MUTEX_SQLITE3_MUTEX2=0x18
+[TRACE]TRACE_INTERNALS[0x88]_SQLITE3_OS_END=0x1e
+[TRACE]TRACE_INTERNALS[0x88]_SQLITE3_OS_INIT=0x1d
+[TRACE]TRACE_INTERNALS[0x88]_TDBFILE_TDBFILE=0x1f
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_CHECKRESERVEDLOCK1=0x3b
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_CHECKRESERVEDLOCK2=0x3c
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_CHECKRESERVEDLOCK3=0x3d
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_CLOSE1=0x20
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_CLOSE2=0x21
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_FILECONTROL=0x3e
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_FILESIZE_ENTRY=0x2a
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_FILESIZE_EXIT=0x2b
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_GETREADLOCK=0x2c
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_LOCK1=0x2e
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_LOCK2=0x2f
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_LOCK3=0x30
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_LOCK4=0x31
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_LOCK5=0x32
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_LOCK6=0x33
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_LOCK7=0x34
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_READ_ENTRY=0x22
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_READ_EXIT=0x23
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_SYNC_ENTRY=0x28
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_SYNC_EXIT=0x29
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_TRUNCATE_ENTRY=0x26
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_TRUNCATE_EXIT=0x27
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_UNLOCK1=0x35
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_UNLOCK2=0x36
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_UNLOCK3=0x37
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_UNLOCK4=0x38
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_UNLOCK5=0x39
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_UNLOCK6=0x3a
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_UNLOCKREADLOCK=0x2d
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_WRITE_ENTRY=0x24
+[TRACE]TRACE_INTERNALS[0x88]_TFILEIO_WRITE_EXIT=0x25
+[TRACE]TRACE_INTERNALS[0x88]_TMUTEXAPI_ALLOC=0x1b
+[TRACE]TRACE_INTERNALS[0x88]_TMUTEXAPI_FREE=0x1c
+[TRACE]TRACE_INTERNALS[0x88]_TSTATICFS_CONNECT=0x16
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_ACCESS1=0x49
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_ACCESS_ENTRY=0x4a
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_ACCESS_EXIT1=0x4b
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_ACCESS_EXIT2=0x4c
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_ACCESS_EXIT3=0x4d
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DELETE1=0x47
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DELETE2=0x48
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DOFILESIZECORRUPTIONCHECK1=0x41
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DOFILESIZECORRUPTIONCHECK2=0x42
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DOGETGETDEVICECHARACTERISTICSANDSECTORSIZE=0x40
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_DOGETVOLUMEIOPARAMINFO=0x3f
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_FULLPATHNAME1=0x4e
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_FULLPATHNAME_ENTRY=0x50
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_FULLPATHNAME_EXIT1=0x4f
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_FULLPATHNAME_EXIT2=0x52
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_FULLPATHNAME_EXIT3=0x53
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_FULLPATHNAME_EXIT4=0x51
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_OPEN1=0x43
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_OPEN2=0x45
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_OPEN_ENTRY=0x44
+[TRACE]TRACE_INTERNALS[0x88]_TVFS_OPEN_EXIT=0x46
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/persistentstorage/sqlite3api/traces_sqlite3/trace.properties Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<trace_properties>
+</trace_properties>
--- a/persistentstorage/store/INC/S32FILE.INL Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/store/INC/S32FILE.INL Tue Aug 31 16:57:14 2010 +0300
@@ -378,7 +378,7 @@
@param aFs Handle to a file server session.
@param aName The full path name of the file to be replaced.
@param aFileMode The mode in which the file is to be accessed. The mode is
-defined by the TFileMode type.
+defined by the TFileMode type.
@return A pointer to the new permanent file store object.
@see TFileMode */
{
@@ -401,7 +401,7 @@
@param aFs Handle to a file server session.
@param aName The full path name of the file to be replaced.
@param aFileMode The mode in which the file is to be accessed. The mode is
-defined by the TFileMode type.
+defined by the TFileMode type.
@return A pointer to the new permanent file store object.
@see TFileMode */
{
@@ -477,6 +477,8 @@
order of file write operations is not guaranteed. This could cause data inconsistency in some
circumstances, for example, when the power is lost in the middle of database transaction.
Therefore, the file write caching should be switched off to maintain integrity.
+
+
The file must already be open before calling this function.
@@ -508,7 +510,7 @@
The file must already be open before calling this function. The existing content
of the file is discarded. It is strongly recommended to set EFileWriteDirectIO
-bit when opening the file. It is because that when file server file write cachingis on, the
+bit when opening the file. It is because that when the file write caching in file server is on, the
order of file writing is not guaranteed which could cause data inconsistency in some
circumstances, for example, when the power is lost in the middle of data transaction.
Therefore, the file write caching should be switched off to maintain the file integrity.
@@ -525,10 +527,10 @@
The file must already be open before calling this function.The existing content
of the file is discarded. It is strongly recommended to set EFileWriteDirectIO
-bit when opening the file. It is because that when the file write caching in file server is on, the
+bit when opening the file. It is because that when the write caching in file server is on, the
order of file writing is not guaranteed which could cause data inconsistency in some
circumstances, for example, when the power is lost in the middle of data transaction.
-Therefore, the file file write caching should be switched off to maintain the file integrity.
+Therefore, the file write caching should be switched off to maintain the file integrity.
Note that ownership of the file passes to the store. The referenced RFile
is cleared and is no longer valid.
--- a/persistentstorage/store/TSTOR/T_BMStreams.inl Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/store/TSTOR/T_BMStreams.inl Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -25,7 +25,7 @@
// Internalize CCompound object from the stream
LOCAL_C void doInternalizeL(const TDesC& aName);
-#define STREAMRUNSIZE 1000
+#define STREAMRUNSIZE 500
// Declare a class used by the example
class CStreamA
{
--- a/persistentstorage/store/TSTRM/t_storstreamperf.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/store/TSTRM/t_storstreamperf.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -510,7 +510,7 @@
store = CPermanentFileStore::OpenLC(TheFs, TheTestFile, EFileWrite | EFileRead);
RPermanentFileStoreIter it4;
it4.ResetLC(*store);
- TStreamId id;
+ TStreamId id(KNullStreamIdValue);
TInt cnt = 0;
fc = User::FastCounter();
while((id = it4.NextL()) != KNullStreamIdValue)
--- a/persistentstorage/store/UFILE/UF_DICT.CPP Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/store/UFILE/UF_DICT.CPP Tue Aug 31 16:57:14 2010 +0300
@@ -154,7 +154,7 @@
for (TInt wait=KLockoutLimit;;)
{
RFile file;
- // When the file server write caching is enabled, the order of file write operations is not guaranteed.
+ // When the file server write caching is enabled, the order of file write operations is not guaranteed.
// This could cause data inconsistency in some circumstances,for example, when the power is lost in the
// middle of a database transaction.Therefore, the file write caching is disabled for this file to maintain integrity.
@@ -179,11 +179,11 @@
}
if (r==KErrCorrupt)
{
- // silently replace the entire file if it is corrupt
- // When the file server write caching is enabled, the order of file write operations is not guaranteed.
- // This could cause data inconsistency in some circumstances,for example, when the power is lost in the
- // middle of a database transaction.Therefore, the file write caching is disabled for this file to maintain integrity.
-
+ // silently replace the entire file if it is corrupt
+ // When the file server write caching is enabled, the order of file write operations is not guaranteed.
+ // This could cause data inconsistency in some circumstances,for example, when the power is lost in the
+ // middle of a database transaction.Therefore, the file write caching is disabled for this file to maintain integrity.
+ //
r=file.Replace(aFs,aName,EFileShareExclusive|EFileWrite|EFileWriteDirectIO);
if (r==KErrInUse)
break; // try again later...
@@ -205,10 +205,9 @@
return;
}
case KErrNotFound:
- // When the file server write caching is enabled, the order of file write operations is not guaranteed.
- // This could cause data inconsistency in some circumstances,for example, when the power is lost in the
- // middle of a database transaction.Therefore, the file write caching is disabled for this file to maintain integrity.
-
+ // When the file server write caching is enabled, the order of file write operations is not guaranteed.
+ // This could cause data inconsistency in some circumstances,for example, when the power is lost in the
+ // middle of a database transaction.Therefore, the file write caching is disabled for this file to maintain integrity.
r=file.Create(aFs,aName,EFileShareExclusive|EFileWrite|EFileWriteDirectIO);
if (r==KErrNone)
{
--- a/persistentstorage/store/USTOR/UT_COLL.CPP Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/store/USTOR/UT_COLL.CPP Tue Aug 31 16:57:14 2010 +0300
@@ -903,7 +903,7 @@
}
return ::ExtentL(Host(),iMark,Coord().Base(),aStream);
}
-
+
/* relocate a stream into [iFree, aExtent)
During compaction, for each string which is to be moved from position A1 to B1, the sequence of operations is:
@@ -942,15 +942,14 @@
when writing to the file.
*/
void CPermanentStoreCollector::RelocateStreamL(const CPermanentStoreCollector::TEntry& aReloc, TInt aExtent)
-
{
if (Coord().Accessed()) // must have exclusive access to relocate the stream
__LEAVE(KErrInUse);
//
TInt end=RelocateL(aReloc.entry.ref,aReloc.len,aReloc.entry.handle == KHandleTocBase ? EFrameDescriptive16 : EFrameData16, aExtent);
- //Step 1
+ //Step 1, 4,....
Coord().RelocateL(aReloc.entry.handle, iFree);
- // Step 2 & 3
+ // Step 2 & 3, 5 & 6,...
iCoordGen=Coord().Generation(); // changed by relocation
iFree = end;
}
--- a/persistentstorage/store/group/BLD.INF Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/store/group/BLD.INF Tue Aug 31 16:57:14 2010 +0300
@@ -26,36 +26,36 @@
PRJ_EXPORTS
-../INC/S32BTREE.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32btree.h)
-../INC/S32BTREE.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32btree.inl)
-../INC/S32BUF.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32buf.h)
-../INC/S32BUF.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32buf.inl)
-../INC/S32CONT.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32cont.h)
-../INC/S32CONT.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32cont.inl)
-../INC/S32CRYPT.H SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(s32crypt.h)
-../INC/S32CRYPT.INL SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(s32crypt.inl)
-../INC/S32FILE.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32file.h)
-../INC/S32FILE.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32file.inl)
+../INC/S32BTREE.H OS_LAYER_PUBLIC_EXPORT_PATH(s32btree.h)
+../INC/S32BTREE.INL OS_LAYER_PUBLIC_EXPORT_PATH(s32btree.inl)
+../INC/S32BUF.H OS_LAYER_PUBLIC_EXPORT_PATH(s32buf.h)
+../INC/S32BUF.INL OS_LAYER_PUBLIC_EXPORT_PATH(s32buf.inl)
+../INC/S32CONT.H OS_LAYER_PUBLIC_EXPORT_PATH(s32cont.h)
+../INC/S32CONT.INL OS_LAYER_PUBLIC_EXPORT_PATH(s32cont.inl)
+../INC/S32CRYPT.H OS_LAYER_PLATFORM_EXPORT_PATH(s32crypt.h)
+../INC/S32CRYPT.INL OS_LAYER_PLATFORM_EXPORT_PATH(s32crypt.inl)
+../INC/S32FILE.H OS_LAYER_PUBLIC_EXPORT_PATH(s32file.h)
+../INC/S32FILE.INL OS_LAYER_PUBLIC_EXPORT_PATH(s32file.inl)
#ifndef SYMBIAN_ENABLE_SPLIT_HEADERS
#ifdef SYMBIAN_OLD_EXPORT_LOCATION
../INC/S32FILEBUFSIZE.H /epoc32/include/s32filebufsize.h
#endif
#endif
-../INC/S32MEM.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32mem.h)
-../INC/S32MEM.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32mem.inl)
-../INC/S32PAGE.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32page.h)
-../INC/S32PAGE.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32page.inl)
-../INC/S32SHARE.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32share.h)
-../INC/S32SHARE.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32share.inl)
-../INC/S32STD.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32std.h)
-../INC/S32STD.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32std.inl)
-../INC/S32STOR.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32stor.h)
-../INC/S32STOR.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32stor.inl)
-../INC/S32STRM.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32strm.h)
-../INC/S32STRM.INL SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32strm.inl)
-../INC/S32UCMP.H SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(s32ucmp.h)
-../INC/S32FileIter.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(s32fileiter.h)
-../INC/S32FileIter.inl SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(s32fileiter.inl)
+../INC/S32MEM.H OS_LAYER_PUBLIC_EXPORT_PATH(s32mem.h)
+../INC/S32MEM.INL OS_LAYER_PUBLIC_EXPORT_PATH(s32mem.inl)
+../INC/S32PAGE.H OS_LAYER_PUBLIC_EXPORT_PATH(s32page.h)
+../INC/S32PAGE.INL OS_LAYER_PUBLIC_EXPORT_PATH(s32page.inl)
+../INC/S32SHARE.H OS_LAYER_PUBLIC_EXPORT_PATH(s32share.h)
+../INC/S32SHARE.INL OS_LAYER_PUBLIC_EXPORT_PATH(s32share.inl)
+../INC/S32STD.H OS_LAYER_PUBLIC_EXPORT_PATH(s32std.h)
+../INC/S32STD.INL OS_LAYER_PUBLIC_EXPORT_PATH(s32std.inl)
+../INC/S32STOR.H OS_LAYER_PUBLIC_EXPORT_PATH(s32stor.h)
+../INC/S32STOR.INL OS_LAYER_PUBLIC_EXPORT_PATH(s32stor.inl)
+../INC/S32STRM.H OS_LAYER_PUBLIC_EXPORT_PATH(s32strm.h)
+../INC/S32STRM.INL OS_LAYER_PUBLIC_EXPORT_PATH(s32strm.inl)
+../INC/S32UCMP.H OS_LAYER_PUBLIC_EXPORT_PATH(s32ucmp.h)
+../INC/S32FileIter.h OS_LAYER_PLATFORM_EXPORT_PATH(s32fileiter.h)
+../INC/S32FileIter.inl OS_LAYER_PLATFORM_EXPORT_PATH(s32fileiter.inl)
../ROM/Store.iby /epoc32/rom/include/store.iby
--- a/persistentstorage/store/pcstore/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/persistentstorage/store/pcstore/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -21,16 +21,16 @@
TOOLS2
PRJ_EXPORTS
-../inc/descriptors.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/descriptors.h)
-../inc/directfilestore.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/directfilestore.h)
-../inc/storewritestream.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/storewritestream.h)
-../inc/storereadstream.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/storereadstream.h)
-../inc/storeexception.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/storeexception.h)
-../inc/pcstoredef.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/pcstoredef.h)
-../inc/streamid.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/streamid.h)
-../inc/uid.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/uid.h)
-../inc/pcstore.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/pcstore.h)
-../inc/checkeduid.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/checkeduid.h)
+../inc/descriptors.h OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/descriptors.h)
+../inc/directfilestore.h OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/directfilestore.h)
+../inc/storewritestream.h OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/storewritestream.h)
+../inc/storereadstream.h OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/storereadstream.h)
+../inc/storeexception.h OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/storeexception.h)
+../inc/pcstoredef.h OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/pcstoredef.h)
+../inc/streamid.h OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/streamid.h)
+../inc/uid.h OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/uid.h)
+../inc/pcstore.h OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/pcstore.h)
+../inc/checkeduid.h OS_LAYER_PUBLIC_EXPORT_PATH(pcstore/checkeduid.h)
PRJ_MMPFILES
#ifdef TOOLS2
--- a/traceservices/commsdebugutility/TE_commsdebugutility/group/designexample.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/commsdebugutility/TE_commsdebugutility/group/designexample.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -25,7 +25,7 @@
USERINCLUDE ../inc
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-#include "comms-infras/commsdebugutility.mmh"
+#include "../group/commsdebugutility.mmh"
SOURCEPATH ../src
SOURCE designexample.cpp
--- a/traceservices/commsdebugutility/TE_commsdebugutility/group/tlog1.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/commsdebugutility/TE_commsdebugutility/group/tlog1.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -22,7 +22,7 @@
CAPABILITY ALL -Tcb
SMPSAFE
-#include "comms-infras/commsdebugutility.mmh"
+#include "../group/commsdebugutility.mmh"
USERINCLUDE ../inc
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
--- a/traceservices/commsdebugutility/TE_commsdebugutility/group/tlog3.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/commsdebugutility/TE_commsdebugutility/group/tlog3.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
CAPABILITY ALL -Tcb
SMPSAFE
-#include "comms-infras/commsdebugutility.mmh"
+#include "../group/commsdebugutility.mmh"
USERINCLUDE ../inc
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
--- a/traceservices/commsdebugutility/TE_commsdebugutility/group/tlog4.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/commsdebugutility/TE_commsdebugutility/group/tlog4.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
#define __FLOGGER_UREL
MACRO __FLOG_SUPPRESS_REL_WARNING
-#include "comms-infras/commsdebugutility.mmh"
+#include "../group/commsdebugutility.mmh"
USERINCLUDE ../inc
OS_LAYER_SYSTEMINCLUDE_SYMBIAN
--- a/traceservices/commsdebugutility/TE_commsdebugutility/src/step_024_xx.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/commsdebugutility/TE_commsdebugutility/src/step_024_xx.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2003-2010 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"
@@ -75,8 +75,10 @@
INFO_PRINTF1(_L("Step 024.01 called "));
if ( executeStepL() == KErrNone )
SetTestStepResult(EPass);
+
else
SetTestStepResult(EFail);
+
return TestStepResult();
}
@@ -286,8 +288,10 @@
{
if ( executeStepL() == KErrNone )
SetTestStepResult(EPass);
+
else
SetTestStepResult(EFail);
+
return TestStepResult();
}
@@ -407,8 +411,10 @@
{
if ( executeStepL() == KErrNone )
SetTestStepResult(EPass);
+
else
SetTestStepResult(EFail);
+
return TestStepResult();
}
@@ -558,8 +564,10 @@
{
if ( executeStepL() == KErrNone )
SetTestStepResult(EPass);
+
else
SetTestStepResult(EFail);
+
return TestStepResult();
}
@@ -671,8 +679,10 @@
{
if ( executeStepL() == KErrNone )
SetTestStepResult(EPass);
+
else
SetTestStepResult(EFail);
+
return TestStepResult();
}
@@ -782,8 +792,10 @@
{
if ( executeStepL() == KErrNone )
SetTestStepResult(EPass);
+
else
SetTestStepResult(EFail);
+
return TestStepResult();
}
@@ -902,8 +914,10 @@
INFO_PRINTF1(_L("Step 027.13 called "));
if ( executeStepL() == KErrNone )
SetTestStepResult(EPass);
+
else
SetTestStepResult(EFail);
+
INFO_PRINTF1(_L("leaving Step 027.13"));
User::After(KTimeForDisplay);
@@ -1067,8 +1081,10 @@
{
if ( executeStepL() == KErrNone )
SetTestStepResult(EPass);
+
else
SetTestStepResult(EFail);
+
User::After(KTimeForDisplay);
@@ -1127,9 +1143,7 @@
User::SetHomeTime(time);
TTime currentMicrosecs;
- TTimeIntervalDays newDate;
currentMicrosecs.HomeTime();
- newDate = currentMicrosecs.DaysFrom(TTime(0));
RFileLogger ::Write(KStdSubsysTag16, KStdCompTag16,EFileLoggingModeAppend, KTestMessage);
User::After(KTimeToLog);
--- a/traceservices/commsdebugutility/group/BLD.INF Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/commsdebugutility/group/BLD.INF Tue Aug 31 16:57:14 2010 +0300
@@ -16,12 +16,12 @@
PRJ_EXPORTS
-commsdebugutility.mmh SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(comms-infras/commsdebugutility.mmh)
+commsdebugutility.mmh OS_LAYER_PUBLIC_EXPORT_PATH(comms-infras/commsdebugutility.mmh)
../tools/splitlog.bat /epoc32/tools/splitlog.bat
../tools/extractlog.pl /epoc32/tools/extractlog.pl
-../INC/commsdebugutility.h SYMBIAN_OS_LAYER_PUBLIC_EXPORT_PATH(comms-infras/commsdebugutility.h)
+../INC/commsdebugutility.h OS_LAYER_PUBLIC_EXPORT_PATH(comms-infras/commsdebugutility.h)
../group/commsdebugutility.iby /epoc32/rom/include/commsdebugutility.iby
../group/commslog.iby /epoc32/rom/include/commslog.iby
--- a/traceservices/commsdebugutility/group/commsdebugutility.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/commsdebugutility/group/commsdebugutility.iby Tue Aug 31 16:57:14 2010 +0300
@@ -27,7 +27,7 @@
file=ABI_DIR\DEBUG_DIR\comsdbgsvr.exe System\bin\comsdbgsvr.exe
#if (!USE_FLOGGER_STUB)
file=ABI_DIR\DEBUG_DIR\comsdbgsvr.dll System\bin\comsdbgsvr.dll
- data=EPOCROOT##Epoc32\data\z\resource\commsdbg.ini resource\commsdbg.ini
+ data=EPOCROOT##epoc32\data\z\resource\commsdbg.ini resource\commsdbg.ini
#else
file=ABI_DIR\DEBUG_DIR\comsdbgstub.dll System\bin\comsdbgsvr.dll
#endif
--- a/traceservices/commsdebugutility/group/te_commsdebugutility.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/commsdebugutility/group/te_commsdebugutility.iby Tue Aug 31 16:57:14 2010 +0300
@@ -25,14 +25,14 @@
file=ABI_DIR\DEBUG_DIR\tlog4.dll System\bin\tlog4.dll
-data=EPOCROOT##epoc32\data\z\TestData\Scripts\te_comsdbg.script testdata\scripts\te_comsdbg.script
-data=EPOCROOT##epoc32\data\z\TestData\Scripts\te_comsdbg_urel.script testdata\scripts\te_comsdbg_urel.script
+data=EPOCROOT##epoc32\data\z\testdata\scripts\te_comsdbg.script testdata\scripts\te_comsdbg.script
+data=EPOCROOT##epoc32\data\z\testdata\scripts\te_comsdbg_urel.script testdata\scripts\te_comsdbg_urel.script
-data=EPOCROOT##epoc32\data\z\TestData\Scripts\te_comsdbg_performance.script testdata\scripts\te_comsdbg_performance.script
+data=EPOCROOT##epoc32\data\z\testdata\scripts\te_comsdbg_performance.script testdata\scripts\te_comsdbg_performance.script
-data=EPOCROOT##epoc32\data\z\TestData\Scripts\te_comsdbg_file.ini testdata\scripts\te_comsdbg_file.ini
-data=EPOCROOT##epoc32\data\z\TestData\Scripts\te_comsdbg_serial1.ini testdata\scripts\te_comsdbg_serial1.ini
-data=EPOCROOT##epoc32\data\z\TestData\Scripts\te_comsdbg_serial2.ini testdata\scripts\te_comsdbg_serial2.ini
+data=EPOCROOT##epoc32\data\z\testdata\scripts\te_comsdbg_file.ini testdata\scripts\te_comsdbg_file.ini
+data=EPOCROOT##epoc32\data\z\testdata\scripts\te_comsdbg_serial1.ini testdata\scripts\te_comsdbg_serial1.ini
+data=EPOCROOT##epoc32\data\z\testdata\scripts\te_comsdbg_serial2.ini testdata\scripts\te_comsdbg_serial2.ini
#endif //__TE_COMMSDEBUGUTILITY_IBY__
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,23 @@
+// Copyright (c) 2010 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:
+// TraceFw
+//
+//
+
+#include "../ulogger/group/bld.inf"
+#include "../utf_trace_api/unit_test/group/bld.inf"
+#include "../ost_trace_api/unit_test/group/bld.inf"
+#include "../ulogger/unit_test/group/bld.inf"
+#include "../integ_test/ulogger/TEF/group/bld.inf"
+#include "../integ_test/ost/TEF/group/bld.inf"
--- a/traceservices/tracefw/integ_test/ost/TEF/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -13,75 +13,60 @@
// Description:
//
-
-
-/**
- @file bld.inf
- @internalTechnology
-*/
-
#include "../perfdevicedriver/group/bld.inf"
#include "../tracecontroltestplugin/group/bld.inf"
PRJ_PLATFORMS
DEFAULT
-PRJ_EXPORTS
-
PRJ_TESTEXPORTS
//iby's
te_ostv2integsuite.iby /epoc32/rom/include/te_ostv2integsuite.iby
//scripts
-../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_integ_tracecollectorclient.script
-../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient_disabled.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_integ_tracecollectorclient_disabled.script
-../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient_enabled.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_integ_tracecollectorclient_enabled.script
-../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorsysstart.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_integ_tracecollectorsysstart.script
-../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorconfigfile.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_integ_tracecollectorconfigfile.script
-../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorconfigfile_winscw.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_integ_tracecollectorconfigfile_winscw.script
+../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient.script z:/testdata/scripts/te_integ_tracecollectorclient.script
+../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient_disabled.script z:/testdata/scripts/te_integ_tracecollectorclient_disabled.script
+../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient_enabled.script z:/testdata/scripts/te_integ_tracecollectorclient_enabled.script
+../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorsysstart.script z:/testdata/scripts/te_integ_tracecollectorsysstart.script
+../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorconfigfile.script z:/testdata/scripts/te_integ_tracecollectorconfigfile.script
+../te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorconfigfile_winscw.script z:/testdata/scripts/te_integ_tracecollectorconfigfile_winscw.script
-../te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_perf_sanity.script
-../te_ostv2integsuite_performance/testdata/scripts/te_perf_outputcsvsanity.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_perf_outputcsvsanity.script
-../te_ostv2integsuite_performance/testdata/scripts/te_perf_default.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_perf_default.script
-../te_ostv2integsuite_performance/testdata/scripts/te_perf_sanityloop.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_perf_sanityloop.script
-../te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity_disabled.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_perf_sanity_disabled.script
-../te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity_enabled.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_perf_sanity_enabled.script
-../te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_perf_guidelines.script
-../te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines_disabled.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_perf_guidelines_disabled.script
-../te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines_enabled.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_perf_guidelines_enabled.script
+../te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity.script z:/testdata/scripts/te_perf_sanity.script
+../te_ostv2integsuite_performance/testdata/scripts/te_perf_outputcsvsanity.script z:/testdata/scripts/te_perf_outputcsvsanity.script
+../te_ostv2integsuite_performance/testdata/scripts/te_perf_default.script z:/testdata/scripts/te_perf_default.script
+../te_ostv2integsuite_performance/testdata/scripts/te_perf_sanityloop.script z:/testdata/scripts/te_perf_sanityloop.script
+../te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity_disabled.script z:/testdata/scripts/te_perf_sanity_disabled.script
+../te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity_enabled.script z:/testdata/scripts/te_perf_sanity_enabled.script
+../te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines.script z:/testdata/scripts/te_perf_guidelines.script
+../te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines_disabled.script z:/testdata/scripts/te_perf_guidelines_disabled.script
+../te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines_enabled.script z:/testdata/scripts/te_perf_guidelines_enabled.script
//configs
-../te_ostv2integsuite_functional/testdata/configs/te_integ_tracecollectorconfigfile_winscw.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_integ_tracecollectorconfigfile_winscw.ini
-../te_ostv2integsuite_functional/testdata/configs/te_integ_tracecollectorconfigfile.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_integ_tracecollectorconfigfile.ini
-../te_ostv2integsuite_functional/testdata/configs/te_integ_tracecollectorsysstart.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_integ_tracecollectorsysstart.ini
-../te_ostv2integsuite_functional/testdata/configs/te_integ_tracecollectorclient.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_integ_tracecollectorclient.ini
+../te_ostv2integsuite_functional/testdata/configs/te_integ_tracecollectorconfigfile_winscw.ini z:/testdata/configs/te_integ_tracecollectorconfigfile_winscw.ini
+../te_ostv2integsuite_functional/testdata/configs/te_integ_tracecollectorconfigfile.ini z:/testdata/configs/te_integ_tracecollectorconfigfile.ini
+../te_ostv2integsuite_functional/testdata/configs/te_integ_tracecollectorsysstart.ini z:/testdata/configs/te_integ_tracecollectorsysstart.ini
+../te_ostv2integsuite_functional/testdata/configs/te_integ_tracecollectorclient.ini z:/testdata/configs/te_integ_tracecollectorclient.ini
-../te_ostv2integsuite_functional/testdata/configs/configfiletracecontrolconfig.ini /epoc32/release/winscw/udeb/z/testdata/configs/configfiletracecontrolconfig.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_default.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_default.ini
-../te_ostv2integsuite_performance/testdata/referencedata/ost_baseline_h4.csv /epoc32/release/winscw/udeb/z/testdata/referencedata/ost_baseline_h4.csv
-../te_ostv2integsuite_performance/testdata/referencedata/ost_baseline_h6.csv /epoc32/release/winscw/udeb/z/testdata/referencedata/ost_baseline_h6.csv
-../te_ostv2integsuite_performance/testdata/referencedata/ost_baseline_winscw.csv /epoc32/release/winscw/udeb/z/testdata/referencedata/ost_baseline_winscw.csv
-../te_ostv2integsuite_performance/testdata/configs/te_perf_gon_con_gmatch_cmatch.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_gon_con_gmatch_cmatch.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_gon_con_gmatch_cmismatch.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_gon_con_gmatch_cmismatch.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_gon_con_gmismatch_cmatch.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_gon_con_gmismatch_cmatch.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_gon_coff_gmatch_cmismatch.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_gon_coff_gmatch_cmismatch.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_gon_coff_gmismatch_cmatch.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_gon_coff_gmismatch_cmatch.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_goff_con_gmismatch_cmatch.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_goff_con_gmismatch_cmatch.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_goff_con_gmatch_cmismatch.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_goff_con_gmatch_cmismatch.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_goff_coff_gmatch_cmatch.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_goff_coff_gmatch_cmatch.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_sanity.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_sanity.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_guidelines.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_guidelines.ini
-../te_ostv2integsuite_performance/testdata/configs/te_perf_outputcsvsanity.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_perf_outputcsvsanity.ini
-
-//export header files for the tcl branch
-../te_ostv2integsuite_common/inc/te_dataparameters.h /epoc32/include/tracecontrol_integrationtest/te_dataparameters.h
-../te_ostv2integsuite_common/inc/te_ostv2integsuite_defs.h /epoc32/include/tracecontrol_integrationtest/te_ostv2integsuite_defs.h
-../../../../common_utils/lightlogger/inc/lightlogger.h /epoc32/include/tracecontrol_integrationtest/lightlogger.h
-../../../../common_utils/lightlogger/inc/te_lightlogger.h /epoc32/include/tracecontrol_integrationtest/te_lightlogger.h
+../te_ostv2integsuite_functional/testdata/configs/configfiletracecontrolconfig.ini z:/testdata/configs/configfiletracecontrolconfig.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_default.ini z:/testdata/configs/te_perf_default.ini
+../te_ostv2integsuite_performance/testdata/referencedata/ost_baseline_h4.csv z:/testdata/referencedata/ost_baseline_h4.csv
+../te_ostv2integsuite_performance/testdata/referencedata/ost_baseline_h6.csv z:/testdata/referencedata/ost_baseline_h6.csv
+../te_ostv2integsuite_performance/testdata/referencedata/ost_baseline_winscw.csv z:/testdata/referencedata/ost_baseline_winscw.csv
+../te_ostv2integsuite_performance/testdata/configs/te_perf_gon_con_gmatch_cmatch.ini z:/testdata/configs/te_perf_gon_con_gmatch_cmatch.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_gon_con_gmatch_cmismatch.ini z:/testdata/configs/te_perf_gon_con_gmatch_cmismatch.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_gon_con_gmismatch_cmatch.ini z:/testdata/configs/te_perf_gon_con_gmismatch_cmatch.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_gon_coff_gmatch_cmismatch.ini z:/testdata/configs/te_perf_gon_coff_gmatch_cmismatch.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_gon_coff_gmismatch_cmatch.ini z:/testdata/configs/te_perf_gon_coff_gmismatch_cmatch.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_goff_con_gmismatch_cmatch.ini z:/testdata/configs/te_perf_goff_con_gmismatch_cmatch.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_goff_con_gmatch_cmismatch.ini z:/testdata/configs/te_perf_goff_con_gmatch_cmismatch.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_goff_coff_gmatch_cmatch.ini z:/testdata/configs/te_perf_goff_coff_gmatch_cmatch.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_sanity.ini z:/testdata/configs/te_perf_sanity.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_guidelines.ini z:/testdata/configs/te_perf_guidelines.ini
+../te_ostv2integsuite_performance/testdata/configs/te_perf_outputcsvsanity.ini z:/testdata/configs/te_perf_outputcsvsanity.ini
PRJ_TESTMMPFILES
-te_ostv2integsuite_enabled.mmp
-te_ostv2integsuite_disabled.mmp
+te_ostv2integsuite_enabled.mmp manual
+te_ostv2integsuite_disabled.mmp manual
//above mmp's and configs/scripts etc will eventually just be below bld.infs when binary split done.
//#include "../te_ostv2integsuite_common/group/bld.inf"
@@ -90,6 +75,3 @@
//move the folder tracefw/integ_test/ost/TEF/traces/... to tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/traces/... when the binary
//split is done for the three test binaries: te_ostv2integsuite_common.dll, te_ostv2integsuite_functional.exe. te_ostv2integsuite_perfromance.exe.
//Update all mmp's and bld.infs accordingly
-
-
-
--- a/traceservices/tracefw/integ_test/ost/TEF/group/te_ostv2integsuite.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/group/te_ostv2integsuite.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
--- a/traceservices/tracefw/integ_test/ost/TEF/group/te_ostv2integsuite_disabled.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/group/te_ostv2integsuite_disabled.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,21 +13,31 @@
// Description:
//
-
-
-/**
- @file te_ostv2integsuite_disabled.mmp
- @internalTechnology
-*/
TARGET te_ostv2integsuite_disabled.exe
TARGETTYPE exe
UID 0x1000007A 0x1028722F
+CAPABILITY CommDD NetworkControl LocalServices
+
+EPOCHEAPSIZE 1048576 4194304 //ask why this epocsize
MACRO TE_UPT_TRACE_DISABLED //could remove this and just #ifdef on SYMBIAN_TRACE_ENABLE
#include <platform/opensystemtrace.mmh>
epocprocesspriority high
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../te_ostv2integsuite_common/inc/
+USERINCLUDE ../traces
+USERINCLUDE ../te_ostv2integsuite_functional/inc/
+USERINCLUDE ../te_ostv2integsuite_performance/inc/
+USERINCLUDE ../te_ostv2integsuite_performance/inc/timer
+USERINCLUDE ../te_ostv2integsuite_performance/inc/sanity
+USERINCLUDE ../te_ostv2integsuite_performance/inc/csvoutput
+USERINCLUDE ../te_ostv2integsuite_functional/inc/record_content
+USERINCLUDE ../perfdevicedriver/inc/
+USERINCLUDE ../../../../common_utils/lightlogger/inc
+
SOURCEPATH ../te_ostv2integsuite_common/src/
SOURCE te_ostv2integsuite_server.cpp
SOURCE te_ostv2integsuite_controller.cpp
@@ -38,6 +48,7 @@
SOURCE te_tracecontrolclearconfig.cpp
SOURCE te_tracecontrolcmds.cpp
SOURCE te_tracecontroldefaultconfig.cpp
+SOURCE te_ctor_disabled.cpp
SOURCEPATH ../te_ostv2integsuite_functional/src/
SOURCE te_tracecollectorclient.cpp
@@ -73,7 +84,6 @@
SOURCE te_perfsanityhelpers.cpp
SOURCE te_perfsanitytimer.cpp
-
SOURCEPATH ../perfdevicedriver/src/
SOURCE te_d32perfdrv.cpp
@@ -84,24 +94,6 @@
SOURCEPATH ../te_ostv2integsuite_functional/src/record_content
SOURCE te_parser.cpp
SOURCE te_tracerecord.cpp
-
-USERINCLUDE ../te_ostv2integsuite_common/inc/
-USERINCLUDE ../traces
-USERINCLUDE ../te_ostv2integsuite_functional/inc/
-USERINCLUDE ../te_ostv2integsuite_performance/inc/
-USERINCLUDE ../te_ostv2integsuite_performance/inc/timer
-USERINCLUDE ../te_ostv2integsuite_performance/inc/sanity
-USERINCLUDE ../te_ostv2integsuite_performance/inc/csvoutput
-USERINCLUDE ../te_ostv2integsuite_functional/inc/record_content
-USERINCLUDE ../perfdevicedriver/inc/
-USERINCLUDE ../../../../common_utils/lightlogger/inc
-
-
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/ecom
-SYSTEMINCLUDE /epoc32/include/platform
-
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
@@ -114,9 +106,4 @@
MACRO __TEST_LIGHTLOGGER_ENABLED
MACRO __LIGHTLOGGER_ENABLED
-
-EPOCHEAPSIZE 1048576 4194304 //ask why this epocsize
-
-CAPABILITY CommDD NetworkControl LocalServices
-
SMPSAFE
--- a/traceservices/tracefw/integ_test/ost/TEF/group/te_ostv2integsuite_enabled.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/group/te_ostv2integsuite_enabled.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,15 +13,12 @@
// Description:
//
-
-
-/**
- @file te_ostv2integsuite_enabled.mmp
- @internalTechnology
-*/
TARGET te_ostv2integsuite_enabled.exe
TARGETTYPE exe
UID 0x1000007A 0x1028722E
+CAPABILITY CommDD NetworkControl LocalServices
+
+EPOCHEAPSIZE 1048576 4194304 //ask why this epocsize
#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
#include <platform/opensystemtrace.mmh>
@@ -33,6 +30,19 @@
epocprocesspriority high
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../te_ostv2integsuite_common/inc/
+USERINCLUDE ../traces
+USERINCLUDE ../te_ostv2integsuite_functional/inc/
+USERINCLUDE ../te_ostv2integsuite_performance/inc/
+USERINCLUDE ../te_ostv2integsuite_performance/inc/timer
+USERINCLUDE ../te_ostv2integsuite_performance/inc/sanity
+USERINCLUDE ../te_ostv2integsuite_performance/inc/csvoutput
+USERINCLUDE ../te_ostv2integsuite_functional/inc/record_content
+USERINCLUDE ../perfdevicedriver/inc/
+USERINCLUDE ../../../../common_utils/lightlogger/inc
+
SOURCEPATH ../te_ostv2integsuite_common/src/
SOURCE te_ostv2integsuite_server.cpp
SOURCE te_ostv2integsuite_controller.cpp
@@ -43,7 +53,7 @@
SOURCE te_tracecontrolclearconfig.cpp
SOURCE te_tracecontrolcmds.cpp
SOURCE te_tracecontroldefaultconfig.cpp
-
+SOURCE te_ctor.cpp
SOURCEPATH ../te_ostv2integsuite_functional/src/
SOURCE te_tracecollectorclient.cpp
@@ -79,7 +89,6 @@
SOURCE te_perfsanityhelpers.cpp
SOURCE te_perfsanitytimer.cpp
-
SOURCEPATH ../perfdevicedriver/src/
SOURCE te_d32perfdrv.cpp
@@ -90,24 +99,6 @@
SOURCEPATH ../te_ostv2integsuite_functional/src/record_content
SOURCE te_parser.cpp
SOURCE te_tracerecord.cpp
-
-USERINCLUDE ../te_ostv2integsuite_common/inc/
-USERINCLUDE ../traces
-USERINCLUDE ../te_ostv2integsuite_functional/inc/
-USERINCLUDE ../te_ostv2integsuite_performance/inc/
-USERINCLUDE ../te_ostv2integsuite_performance/inc/timer
-USERINCLUDE ../te_ostv2integsuite_performance/inc/sanity
-USERINCLUDE ../te_ostv2integsuite_performance/inc/csvoutput
-USERINCLUDE ../te_ostv2integsuite_functional/inc/record_content
-USERINCLUDE ../perfdevicedriver/inc/
-USERINCLUDE ../../../../common_utils/lightlogger/inc
-
-
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/ecom
-SYSTEMINCLUDE /epoc32/include/platform
-
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
@@ -122,8 +113,4 @@
MACRO OST_TRACE_COMPILER_IN_USE
-EPOCHEAPSIZE 1048576 4194304 //ask why this epocsize
-
-CAPABILITY CommDD NetworkControl LocalServices
-
SMPSAFE
--- a/traceservices/tracefw/integ_test/ost/TEF/lauterbach_perftimer_tester/group/test_timer_temp.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/lauterbach_perftimer_tester/group/test_timer_temp.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,27 +15,22 @@
// This is the project specification file for test_timer_temp.
//
-
-
TARGET test_timer_temp.exe
TARGETTYPE exe
UID 0 0xE48A1B8A
-USERINCLUDE ..\inc
-SYSTEMINCLUDE \epoc32\include
-SYSTEMINCLUDE \epoc32\include\platform
+OS_LAYER_SYSTEMINCLUDE
-SOURCEPATH ..\src
+USERINCLUDE ../inc
+USERINCLUDE ../../../performance
+
+SOURCEPATH ../src
SOURCE test_timer_temp.cpp
SOURCEPATH ../../../performance
SOURCE te_upttimer.cpp
-USERINCLUDE ../../../performance
-
-LIBRARY euser.lib
+LIBRARY euser.lib
LIBRARY hal.lib
SMPSAFE
-
-
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/integ_test/ost/TEF/perfdevicedriver/eabi/te_optostdddisabledu.def Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,7 @@
+EXPORTS
+ _Z19CreateLogicalDevicev @ 1 NONAME
+ _ZTI17DUptUTraceChannel @ 2 NONAME
+ _ZTI17DUptUTraceFactory @ 3 NONAME
+ _ZTV17DUptUTraceChannel @ 4 NONAME
+ _ZTV17DUptUTraceFactory @ 5 NONAME
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/integ_test/ost/TEF/perfdevicedriver/eabi/te_optostddenabledu.def Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,7 @@
+EXPORTS
+ _Z19CreateLogicalDevicev @ 1 NONAME
+ _ZTI17DUptUTraceChannel @ 2 NONAME
+ _ZTI17DUptUTraceFactory @ 3 NONAME
+ _ZTV17DUptUTraceChannel @ 4 NONAME
+ _ZTV17DUptUTraceFactory @ 5 NONAME
+
--- a/traceservices/tracefw/integ_test/ost/TEF/perfdevicedriver/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/perfdevicedriver/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -16,10 +16,7 @@
PRJ_PLATFORMS
DEFAULT
-PRJ_EXPORTS
-PRJ_MMPFILES
+
PRJ_TESTMMPFILES
-te_perfdrvenabled.mmp
-te_perfdrvdisabled.mmp
-
-PRJ_TESTEXPORTS
+te_perfdrvenabled.mmp manual
+te_perfdrvdisabled.mmp manual
--- a/traceservices/tracefw/integ_test/ost/TEF/perfdevicedriver/group/te_perfdrvdisabled.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/perfdevicedriver/group/te_perfdrvdisabled.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -25,10 +25,7 @@
VENDORID 0x70000001
capability all
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/ecom
-SYSTEMINCLUDE /epoc32/include/kernel
-
+OS_LAYER_SYSTEMINCLUDE
USERINCLUDE ../inc/
USERINCLUDE ../../te_ostv2integsuite_common/inc/
@@ -53,13 +50,9 @@
SOURCE te_stackinfo.s
#endif
-
-EPOCALLOWDLLDATA
-
start wins
win32_headers
end
SMPSAFE
-
-
+epocallowdlldata
--- a/traceservices/tracefw/integ_test/ost/TEF/perfdevicedriver/group/te_perfdrvenabled.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/perfdevicedriver/group/te_perfdrvenabled.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -14,7 +14,6 @@
// e32\drivers\trace\tracek.mmp
//
-
#include <kernel/kern_ext.mmh>
#define SYMBIAN_TRACE_EXECUTABLE_INCLUDE
@@ -30,9 +29,7 @@
VENDORID 0x70000001
capability all
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/ecom
-SYSTEMINCLUDE /epoc32/include/kernel
+OS_LAYER_SYSTEMINCLUDE
USERINCLUDE ../inc/
USERINCLUDE ../../te_ostv2integsuite_common/inc/
@@ -57,12 +54,9 @@
SOURCE te_stackinfo.s
#endif
-
-
-EPOCALLOWDLLDATA
-
start wins
win32_headers
end
SMPSAFE
+epocallowdlldata
--- a/traceservices/tracefw/integ_test/ost/TEF/perfdevicedriver/src/te_drv.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/perfdevicedriver/src/te_drv.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -48,7 +48,7 @@
* and loose our state. So we solve this by running the device driver as
* as it's own separate thread in the kernel (DLogicalChannelBase runs a user thread in kernel mode,
* DLogicalChannel runs a kernel thread called from a user thread).
- * We also solve the long timing issue by making an asynchrounous call by using the DoRequest call.
+ * We also solve the long timing issue by making an asynchrounous call by using the DoRequestL call.
* For this to work we need to create a DfcQ, i.e. a queue of all the incoming calls from the user side.
* These then get's run in turn.
*/
@@ -68,7 +68,7 @@
// Inherited from DLogicalChannel
virtual TInt DoCreate(TInt aUnit, const TDesC8* anInfo, const TVersion& aVer);
//Make an asynchronous call...
- virtual TInt DoRequest(TInt aReqNo, TRequestStatus* aStatus, TAny* a1, TAny* a2);
+ virtual TInt DoRequestL(TInt aReqNo, TRequestStatus* aStatus, TAny* a1, TAny* a2);
void TestUptTraces(const TApiRunConfig& aApiRunConfig, TApiRunResults& aApiRunResults);
void TimeUptTraces(const TApiRunConfig& aApiRunConfig, TApiRunResults& aApiRunResults);
@@ -80,7 +80,7 @@
TDfcQue* iDfcQ;
TKernelTimer iTimer;
- //This is used to signal when one of the async calls (to DoRequest) is finished.
+ //This is used to signal when one of the async calls (to DoRequestL) is finished.
TRequestStatus iStatus;
};
@@ -164,10 +164,10 @@
message.Complete(KErrNone, ETrue);
return;
}
- if(id < 0 ) //it was a call for DoRequest()
+ if(id < 0 ) //it was a call for DoRequestL()
{
TRequestStatus* status = (TRequestStatus*)message.Ptr0();
- DoRequest(~id, status, message.Ptr1(), message.Ptr2());
+ DoRequestL(~id, status, message.Ptr1(), message.Ptr2());
message.Complete(KErrNone, ETrue);
}
else //it was a call for DoControl, we dont implement that now so just fall through
@@ -178,7 +178,7 @@
}
}
-TInt DUptUTraceChannel::DoRequest(TInt aReqNo, TRequestStatus* aStatus, TAny* a1, TAny* a2)
+TInt DUptUTraceChannel::DoRequestL(TInt aReqNo, TRequestStatus* aStatus, TAny* a1, TAny* a2)
{
TInt error = KErrNone;
@@ -258,11 +258,11 @@
{
TTestTimer timer;
if(aReqNo == RUptUTrace::ESanityTestTimer)
- results.iPass = timer.TestKernelTimer(results.iTime);
+ results.iPass = timer.TestKernelTimerL(results.iTime);
if(aReqNo == RUptUTrace::ESanityTestLongTimer)
- results.iPass = timer.TestKernelLongTimer(results.iTime);
+ results.iPass = timer.TestKernelLongTimerL(results.iTime);
if(aReqNo == RUptUTrace::ESanityUtraceTimer)
- results.iPass = timer.TestUTraceKernelTimer(results.iTime);
+ results.iPass = timer.TestUTraceKernelTimerL(results.iTime);
}
if(!error)
error = Kern::ThreadRawWrite(iClient, a1, (TUint8 *)&results, sizeof(TSanityResults));
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_ctor.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,38 @@
+// Copyright (c) 2007-2010 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:
+//
+
+#ifndef TE_CTOR
+#define TE_CTOR
+#include <e32std.h>
+#include "te_dataparameters.h"
+
+// dummy/unimportant value, only used for initialisation
+_LIT(KTestCtorString, "ABCDE" );
+
+class TTestCtor
+ {
+public:
+ TTestCtor( TUint32 aArg1, TUint32 aArg2 );
+
+ TTestCtor( TUint32 aArg1 );
+
+private:
+ // define arbitrary data members
+ TUint32 iNum1;
+ TUint32 iNum2;
+ TBuf<10> iStr;
+ };
+
+#endif //TE_CTOR
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_instrumentation_enum.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_instrumentation_enum.h Tue Aug 31 16:57:14 2010 +0300
@@ -90,36 +90,38 @@
EOstTraceFunctionEntry0,
EOstTraceFunctionEntry1,
EOstTraceFunctionEntryExt,
- EOstTraceFunctionExit0,//40
+ EOstTraceFunctionEntryExtCtorInitList,//40
+ EOstTraceFunctionEntryExtCtorNoInitList,
+ EOstTraceFunctionExit0,
EOstTraceFunctionExit1,
EOstTraceFunctionExitExt,
- EOstTraceEventStart0,
+ EOstTraceEventStart0,//45
EOstTraceEventStart1,
- EOstTraceState0,//45
+ EOstTraceState0,
EOstTraceState1,
EOstTraceEventStop,
- EOstTraceData96,
+ EOstTraceData96,//50
EOstTraceData1000,
- EUptIsTraceActive,//50
+ EUptIsTraceActive,
//kernel side
//printf
EUptKernelPrintfchar,
EUptKernelPrintfTRefByValueTDesC8,
- EUptKernelPrintfDesc8_big,
+ EUptKernelPrintfDesc8_big,//55
EUptKernelPrintfDesc8_huge,
//trace
- EUptKernelTrace,//55
+ EUptKernelTrace,
EUptKernelTraceTUint32,
EUptKernelTraceTUint32TUint32,
- EUptKernelTraceTAnySmallStruct,
+ EUptKernelTraceTAnySmallStruct,//60
EUptKernelTraceTAnyBigStruct,
- EUptKernelTraceTAnyHugeStruct,//60
+ EUptKernelTraceTAnyHugeStruct,
EUptKernelTraceTemplatedSmallStruct,
EUptKernelTraceTemplatedBigStruct,
- EUptKernelTraceTemplatedHugeStruct,
+ EUptKernelTraceTemplatedHugeStruct,//65
EUptKernelIsTraceActive,
- EUptKernelTraceDesc8_big,//65
+ EUptKernelTraceDesc8_big,
EUptKernelTraceDesc8_huge,
@@ -132,22 +134,22 @@
* Stackbase: 400 byte
*/
UPTTraceTest,
- UPTKernelTraceTest,
+ UPTKernelTraceTest,//70
UPTKernelNegativeFunctionalityTest,
- UPTKernelMultipleFunctionalityTest,//70
+ UPTKernelMultipleFunctionalityTest,
//btrace
BTraceFiltered4,//equivalent of EUptTrace
BTraceFiltered8,// equivalent of EUptTraceTUint32
- BTraceFiltered12,// equivalent of EUptTraceTUint32TUint32
+ BTraceFiltered12,//75 // equivalent of EUptTraceTUint32TUint32
BTraceFilteredBig,//equivalent of EUptTraceTemplatedHugeStruct
- BTrace0,//75
+ BTrace0,
BTrace4,
BTrace8,
- BTrace12,
+ BTrace12,//80
//baseline
UPTBaseline,
- UPTKernelBaseline,//80
+ UPTKernelBaseline,
//foo definitions
UPTFooUserTime,
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_ostv2integsuite_basewrapper.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_ostv2integsuite_basewrapper.h Tue Aug 31 16:57:14 2010 +0300
@@ -22,9 +22,10 @@
#if (!defined TE_ULOGGER_MCL_STEP_BASE)
#define TE_ULOGGER_MCL_STEP_BASE
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include <hal.h>
#include <opensystemtrace.h>
+
#include "te_tracerecord.h"
#include "te_dataparameters.h"
#include "te_parser.h"
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_ostv2integsuite_controller.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_ostv2integsuite_controller.h Tue Aug 31 16:57:14 2010 +0300
@@ -19,8 +19,8 @@
#include <e32std.h>
#include <e32base.h>
-#include <testblockcontroller.h>
-#include <datawrapper.h>
+#include <test/testblockcontroller.h>
+#include <test/datawrapper.h>
class CTe_MCLSuiteController : public CTestBlockController
{
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_ostv2integsuite_defs.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_ostv2integsuite_defs.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -15,11 +15,11 @@
//
-
/**
@file te_uloggerostv2integsuite_defs.h
@internalTechnology
*/
+
#if (!defined TE_ULOGGER_MCL_SUITEDEFS_H)
#define TE_ULOGGER_MCL_SUITEDEFS_H
@@ -31,8 +31,8 @@
public:
~CClearConfig();
CClearConfig();
- void Clear(RULogger& loggerSession);
- void Default(RULogger& loggerSession);
+ void ClearL(RULogger& loggerSession);
+ void DefaultL(RULogger& loggerSession);
//private:
};
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_ostv2integsuite_server.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_ostv2integsuite_server.h Tue Aug 31 16:57:14 2010 +0300
@@ -19,7 +19,7 @@
#include <e32std.h>
#include <e32base.h>
-#include <testserver2.h>
+#include <test/testserver2.h>
#include "te_ostv2integsuite_controller.h"
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_tracecontrolclearconfig.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_tracecontrolclearconfig.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined TE_ULOGGERCLEARCONFIGSTEP_H)
#define TE_ULOGGERCLEARCONFIGSTEP_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_tracecontrolcmds.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_tracecontrolcmds.h Tue Aug 31 16:57:14 2010 +0300
@@ -51,7 +51,7 @@
TInt StopAndDeleteFile(RULogger& aLogger);
TInt Stop(RULogger& aLogger);
TInt DeleteFile();
- void SetFilter(CArrayFixFlat<TUint8>* aFilters);
+ void SetFilterL(CArrayFixFlat<TUint8>* aFilters);
TInt Test();
private:
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_tracecontroldefaultconfig.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/inc/te_tracecontroldefaultconfig.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined TE_ULOGGERDEFAULTCONFIGSTEP_H)
#define TE_ULOGGERDEFAULTCONFIGSTEP_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_ctor.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,51 @@
+// Copyright (c) 2007-2010 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:
+// Test class generating trace data from contructor with/without initialiser list.
+//
+
+#include "te_ctor.h"
+#include "te_ctorTraces.h"
+
+/**
+ * Constructor
+ *
+ * Trace producing constructor with initialiser list.
+ *
+ * Previous versions of the TraceCompiler do not handle initialiser lists correctly.
+ * For such a TC the following code will not compile.
+ */
+
+TTestCtor::TTestCtor( TUint32 aArg1, TUint32 aArg2 )
+:
+ iNum1( aArg1 ),
+ iNum2( aArg2 ),
+ iStr( KTestCtorString )
+ {
+ OstTraceFunctionEntryExt( CTESTCTOR_INITLIST_TRACE, KData1 );
+ }
+
+/**
+ * Constructor
+ *
+ * Trace producing constructor without initialiser list.
+ */
+
+TTestCtor::TTestCtor( TUint32 aArg1 )
+ {
+ iNum1 = aArg1;
+ iNum2 = 0;
+ iStr = KTestCtorString;
+
+ OstTraceFunctionEntryExt( CTESTCTOR_NO_INITLIST_TRACE, KData1 );
+ }
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_ctor_disabled.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,37 @@
+// Copyright (c) 2007-2010 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:
+// Test class generating trace data from contructor with/without initialiser list.
+// used in (logging) disabled mode.
+//
+
+#include "te_ctor.h"
+#include "te_ctor_disabledTraces.h"
+
+TTestCtor::TTestCtor( TUint32 aArg1, TUint32 aArg2 )
+:
+ iNum1( aArg1 ),
+ iNum2( aArg2 ),
+ iStr( KTestCtorString )
+ {
+ OstTraceFunctionEntryExt( CTESTCTOR_INITLIST_TRACE, KData1 );
+ }
+
+TTestCtor::TTestCtor( TUint32 aArg1 )
+ {
+ iNum1 = aArg1;
+ iNum2 = 0;
+ iStr = KTestCtorString;
+
+ OstTraceFunctionEntryExt( CTESTCTOR_NO_INITLIST_TRACE, KData1 );
+ }
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_instrumentationpoints_disabled.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_instrumentationpoints_disabled.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -32,7 +32,7 @@
#include "te_perfstackinfo.h"
#include "te_dataparameters.h"
#include "sanity/te_perfsanityhelpers.h"
-
+#include "te_ctor.h"
@@ -661,7 +661,7 @@
{
__MARK_INITIAL_STACK(aApiRunConfig.iDoStack, stackbase, before);
OstTraceFunctionEntry0( TEST_OSTTraceFunctionalityEntry0 );
- logged = ETrue;
+ logged = EFalse;
__RETURN_STACK_SIZE(aApiRunConfig.iDoStack, stackbase, before, aApiRunResults.iApiStackUsage);
}
break;
@@ -687,6 +687,26 @@
}
break;
+ case EOstTraceFunctionEntryExtCtorInitList:
+ {
+ __MARK_INITIAL_STACK(aApiRunConfig.iDoStack, stackbase, before);
+ TTestCtor testCtorA( 1, 2 );
+ logged = EFalse;
+ __RETURN_STACK_SIZE(aApiRunConfig.iDoStack, stackbase, before, aApiRunResults.iApiStackUsage);
+
+ }
+ break;
+
+ case EOstTraceFunctionEntryExtCtorNoInitList:
+ {
+ __MARK_INITIAL_STACK(aApiRunConfig.iDoStack, stackbase, before);
+ TTestCtor testCtorB( 3 );
+ logged = EFalse;
+ __RETURN_STACK_SIZE(aApiRunConfig.iDoStack, stackbase, before, aApiRunResults.iApiStackUsage);
+
+ }
+ break;
+
case EOstTraceFunctionExit0:
{
__MARK_INITIAL_STACK(aApiRunConfig.iDoStack, stackbase, before);
@@ -750,7 +770,7 @@
{
__MARK_INITIAL_STACK(aApiRunConfig.iDoStack, stackbase, before);
OstTraceState0( TEST_OSTTRACESTATE0, "Test State Name", "Test State Value" );
- logged = ETrue;
+ logged = EFalse;
__RETURN_STACK_SIZE(aApiRunConfig.iDoStack, stackbase, before, aApiRunResults.iApiStackUsage);
}
break;
@@ -761,7 +781,7 @@
__MARK_INITIAL_STACK(aApiRunConfig.iDoStack, stackbase, before);
OstTraceState1( TEST_OSTTRACESTATE1, "Test State Name", "Test State Value", KData1 );
- logged = ETrue;
+ logged = EFalse;
__RETURN_STACK_SIZE(aApiRunConfig.iDoStack, stackbase, before, aApiRunResults.iApiStackUsage);
}
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_instrumentationpoints_enabled.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_instrumentationpoints_enabled.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -32,7 +32,7 @@
#include "te_perfstackinfo.h"
#include "te_dataparameters.h"
#include "sanity/te_perfsanityhelpers.h"
-
+#include "te_ctor.h"
@@ -690,6 +690,26 @@
}
break;
+ case EOstTraceFunctionEntryExtCtorInitList:
+ {
+ __MARK_INITIAL_STACK(aApiRunConfig.iDoStack, stackbase, before);
+ TTestCtor testCtorA( 1, 2 );
+ logged = ETrue;
+ __RETURN_STACK_SIZE(aApiRunConfig.iDoStack, stackbase, before, aApiRunResults.iApiStackUsage);
+
+ }
+ break;
+
+ case EOstTraceFunctionEntryExtCtorNoInitList:
+ {
+ __MARK_INITIAL_STACK(aApiRunConfig.iDoStack, stackbase, before);
+ TTestCtor testCtorB( 3 );
+ logged = ETrue;
+ __RETURN_STACK_SIZE(aApiRunConfig.iDoStack, stackbase, before, aApiRunResults.iApiStackUsage);
+
+ }
+ break;
+
case EOstTraceFunctionExit0:
{
__MARK_INITIAL_STACK(aApiRunConfig.iDoStack, stackbase, before);
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_ostv2integsuite_basewrapper.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_ostv2integsuite_basewrapper.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -697,13 +697,39 @@
ASSERT(trace);
TTraceConfigsOperator::Init(*trace);
TTraceConfigsOperator::SetOptions(*trace, aApi, ETrue, ETrue);
- TTraceConfigsOperator::SetHeader(*trace, TRACE_FLOW, KComponentId, EAddThreadIdentification, ENoProgramCounter, (0x8a0003&TRACEIDMASK)>>TRACEIDSHIFT);
+ TTraceConfigsOperator::SetHeader(*trace, TRACE_FLOW, KComponentId, EAddThreadIdentification, ENoProgramCounter, (0x8a0005&TRACEIDMASK)>>TRACEIDSHIFT);
//fix this - should be a list of the function arguments of this method all these traces are insturmented in
TTraceConfigsOperator::SetData(*trace, KData1);
setThreadId = aHasContext;
aTraceObjects.Append(trace);
}
break;
+ case EOstTraceFunctionEntryExtCtorInitList:
+ {
+ TTraceConfigs* trace = new TTraceConfigs;
+ ASSERT(trace);
+ TTraceConfigsOperator::Init(*trace);
+ TTraceConfigsOperator::SetOptions(*trace, aApi, ETrue, ETrue);
+ TTraceConfigsOperator::SetHeader(*trace, TRACE_FLOW, KComponentId, EAddThreadIdentification, ENoProgramCounter, (0x8a0001&TRACEIDMASK)>>TRACEIDSHIFT);
+ //fix this - should be a list of the function arguments of this method all these traces are insturmented in
+ TTraceConfigsOperator::SetData(*trace,1,2,KData1);
+ setThreadId = aHasContext;
+ aTraceObjects.Append(trace);
+ }
+ break;
+ case EOstTraceFunctionEntryExtCtorNoInitList:
+ {
+ TTraceConfigs* trace = new TTraceConfigs;
+ ASSERT(trace);
+ TTraceConfigsOperator::Init(*trace);
+ TTraceConfigsOperator::SetOptions(*trace, aApi, ETrue, ETrue);
+ TTraceConfigsOperator::SetHeader(*trace, TRACE_FLOW, KComponentId, EAddThreadIdentification, ENoProgramCounter, (0x8a0002&TRACEIDMASK)>>TRACEIDSHIFT);
+ //fix this - should be a list of the function arguments of this method all these traces are insturmented in
+ TTraceConfigsOperator::SetData(*trace,3, KData1);
+ setThreadId = aHasContext;
+ aTraceObjects.Append(trace);
+ }
+ break;
case EOstTraceFunctionExit0:
{
TTraceConfigs* trace = new TTraceConfigs;
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_ostv2integsuite_defs.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_ostv2integsuite_defs.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -36,7 +36,7 @@
/*Constructor*/
}
-void CClearConfig::Clear(RULogger& loggerSession)
+void CClearConfig::ClearL(RULogger& loggerSession)
{
loggerSession.Stop();//C.A. previously:loggerSession.StopOutputting();
loggerSession.DeActivateInputPlugin();
@@ -63,9 +63,9 @@
}
//NB: currently this method does not set the default values for serial and usb! hanging the server
-void CClearConfig::Default(RULogger& loggerSession)
+void CClearConfig::DefaultL(RULogger& loggerSession)
{
- Clear(loggerSession);
+ ClearL(loggerSession);
//Now set default configurations shipped with ulogger
CArrayFixFlat<TUint8> *setfilter=new (ELeave)CArrayFixFlat<TUint8>(1);//CA:added so can use old ulogger api
setfilter->AppendL(3);//CA:added so can use old ulogger api
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_tracecontrolclearconfig.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_tracecontrolclearconfig.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -85,7 +85,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
SetBlockResult(EPass);
return ETrue;
}
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_tracecontrolcmds.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_tracecontrolcmds.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -93,7 +93,7 @@
//clear any configurations stored in the ULogger configuration file
CClearConfig configIni;
- configIni.Clear(aLogger);
+ configIni.ClearL(aLogger);
//prepare arrays for storing the filter settings to configure ULogger (and push any heap objects on the cleanup stack)
CArrayFixFlat<TUint8> *setPrimFilter = new (ELeave)CArrayFixFlat<TUint8>(256);
@@ -139,7 +139,7 @@
if(aGroupIdFilterMatch==1)
{
//if the user specifies that ULogger should have classifiaction filter settings which match the test trace points, then fill the filter arrays with the test trace point identifiers accordingly
- SetFilter(setPrimFilter);
+ SetFilterL(setPrimFilter);
}
else
{
@@ -190,7 +190,7 @@
/** This user-side method sets the filter for OSTv2
*/
-void CUptULogger::SetFilter(CArrayFixFlat<TUint8>* aSetPrimFilter)
+void CUptULogger::SetFilterL(CArrayFixFlat<TUint8>* aSetPrimFilter)
{
aSetPrimFilter->AppendL(KGroupId);
}
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_tracecontroldefaultconfig.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_common/src/te_tracecontroldefaultconfig.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -84,7 +84,7 @@
}
}
CClearConfig configIni;
- configIni.Default(logger);
+ configIni.DefaultL(logger);
SetBlockResult(EPass);
return ETrue;
}
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_advancedfiltering.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_advancedfiltering.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined TE_ULOGGERADPAPITESTSTEP_H)
#define TE_ULOGGERADPAPITESTSTEP_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
@@ -45,7 +45,7 @@
TBool DoCommandL( const TTEFFunction& aCommand,
const TTEFSectionName& aSection,
const TInt aAsyncErrorIndex);
- TVerdict TestGroupIdFiltering(RULogger& aLogger, const TBool aFilter, const TBool aFiltering);
+ TVerdict TestGroupIdFilteringL(RULogger& aLogger, const TBool aFilter, const TBool aFiltering);
private:
CTCMAdvancedGroupIDFilteringWrapper();
@@ -62,7 +62,7 @@
TBool DoCommandL( const TTEFFunction& aCommand,
const TTEFSectionName& aSection,
const TInt aAsyncErrorIndex);
- TVerdict TestComponentIdFiltering(RULogger& aLogger, const TBool aFilter, const TBool aFiltering);
+ TVerdict TestComponentIdFilteringL(RULogger& aLogger, const TBool aFilter, const TBool aFiltering);
// Please add/modify your class members here:
private:
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_buffermode.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_buffermode.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined TE_ULOGGERBUFFERMODESTEP_H)
#define TE_ULOGGERBUFFERMODESTEP_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_buffersizing.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_buffersizing.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined TE_ULOGGERBUFFERSIZINGSTEP_H)
#define TE_ULOGGERBUFFERSIZINGSTEP_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_configfile.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_configfile.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined TE_ULOGGERCONFIGFILESTEP_H)
#define TE_ULOGGERCONFIGFILESTEP_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_filepluginerr.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_filepluginerr.h Tue Aug 31 16:57:14 2010 +0300
@@ -22,7 +22,7 @@
#ifndef __TE_ULOGGERFILEPLUGINTESTERR_H__
#define __TE_ULOGGERFILEPLUGINTESTERR_H__
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_ostv2tracetestwrapper.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_ostv2tracetestwrapper.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -21,7 +21,7 @@
*/
#if (!defined TE_OSTV2TRACETESTWRAPPER_H)
#define TE_OSTV2TRACETESTWRAPPER_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
@@ -46,6 +46,7 @@
TInt CheckResults(const TDesC& aLogFilename);
void TestDuplicatesL();
void TestOstDebugOnlyWrapL();
+ void TestOstCompileTimeMacroL();
TInt OpenUlogger(RULogger& aLogger);
};
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_tracecollectorclient.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_tracecollectorclient.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined TE_ULOGGERAPITESTSTEP_H)
#define TE_ULOGGERAPITESTSTEP_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_tracecollectorfile.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_tracecollectorfile.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined __TE_ULOGGERFILEPLUGNSTEP_H__)
#define __TE_ULOGGERFILEPLUGNSTEP_H__
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_tracecollectorserial.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/inc/te_tracecollectorserial.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined TE_ULOGGERSERIALPLUGINSTEP_H)
#define TE_ULOGGERSERIALPLUGINSTEP_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_advancedfiltering.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_advancedfiltering.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -108,7 +108,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
INFO_PRINTF2(_L("connect err %d"), result);
INFO_PRINTF1(_L("Test setting a single primary filter with the filter, rather than an array"));
@@ -187,7 +187,7 @@
INFO_PRINTF1(_L(" Testing GroupId filtering enabled/ disabled "));
//reset config file
- configIni.Clear(logger);
+ configIni.ClearL(logger);
/***********************************************************/
@@ -195,7 +195,7 @@
/***********************************************************/
INFO_PRINTF1(_L("\n\n Enable test GroupId, enable GroupId filtering.\n Testing error returns and ensuring a trace statement IS carried out "));
- SetBlockResult(TestGroupIdFiltering(logger, ETrue, ETrue));
+ SetBlockResult(TestGroupIdFilteringL(logger, ETrue, ETrue));
/***********************************************************/
/***enable GroupId, disable GroupId filtering*/
@@ -204,7 +204,7 @@
if(BlockResult()==EPass)
{
INFO_PRINTF1(_L("\n\n Enable test GroupId, disable GroupId filtering.\n Testing error returns and ensuring a trace statement IS carried out + lots of kernel traces "));
- SetBlockResult(TestGroupIdFiltering(logger, ETrue, EFalse));
+ SetBlockResult(TestGroupIdFilteringL(logger, ETrue, EFalse));
}
/***********************************************************/
@@ -214,7 +214,7 @@
if(BlockResult()==EPass)
{
INFO_PRINTF1(_L("\n\n Disable test GroupId, disable GroupId filtering.\n Testing error returns and ensuring a trace statement IS carried out + lots of kernel traces"));
- SetBlockResult(TestGroupIdFiltering(logger, EFalse, EFalse));
+ SetBlockResult(TestGroupIdFilteringL(logger, EFalse, EFalse));
}
/***********************************************************/
@@ -224,7 +224,7 @@
if(BlockResult()==EPass)
{
INFO_PRINTF1(_L("\n\n Disable test GroupId, enable GroupId filtering.\n Testing error returns and ensuring a trace statement IS NOT carried out "));
- SetBlockResult(TestGroupIdFiltering(logger, EFalse, ETrue));
+ SetBlockResult(TestGroupIdFilteringL(logger, EFalse, ETrue));
}
}
@@ -249,7 +249,7 @@
// ************** Block end ****************
- configIni.Clear(logger);
+ configIni.ClearL(logger);
logger.Close();
CleanupStack::Pop(3);
if(getfilter)
@@ -263,7 +263,7 @@
}
-TVerdict CTCMAdvancedGroupIDFilteringWrapper::TestGroupIdFiltering(RULogger& aLogger, const TBool aFilter, const TBool aFiltering)
+TVerdict CTCMAdvancedGroupIDFilteringWrapper::TestGroupIdFilteringL(RULogger& aLogger, const TBool aFilter, const TBool aFiltering)
/**
* @return - TVerdict code
* standard function to test error returns and GroupId filtering
@@ -497,7 +497,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
result = logger.SetSecondaryFiltersEnabled(setfilterarray,ETrue);//CA previously:Result = logger.EnableModuleUid(setfilter);
INFO_PRINTF2(_L("Setting single Secondary filter with filter rather than array has been set with single filter, %d, check log"), setfilter);
INFO_PRINTF2(_L("code: %d"), result);
@@ -558,7 +558,7 @@
INFO_PRINTF1(_L(" Testing ComponentId filtering enabled/ disabled "));
//reset config file
- configIni.Clear(logger);
+ configIni.ClearL(logger);
/***********************************************************/
@@ -566,7 +566,7 @@
/***********************************************************/
INFO_PRINTF1(_L("\n\n Enable test ComponentID, enable ComponentID filtering.\n Testing error returns and ensuring a trace statement IS carried out "));
- SetBlockResult(TestComponentIdFiltering(logger, ETrue, ETrue));
+ SetBlockResult(TestComponentIdFilteringL(logger, ETrue, ETrue));
/***********************************************************/
/***enable ComponentId, disable ComponentId filtering*/
@@ -575,7 +575,7 @@
if(BlockResult()==EPass)
{
INFO_PRINTF1(_L("\n\n Enable test ComponentId, disable ComponentId filtering.\n Testing error returns and ensuring a trace statement IS carried out "));
- SetBlockResult(TestComponentIdFiltering(logger, ETrue, EFalse));
+ SetBlockResult(TestComponentIdFilteringL(logger, ETrue, EFalse));
}
/***********************************************************/
@@ -585,7 +585,7 @@
if(BlockResult()==EPass)
{
INFO_PRINTF1(_L("\n\n Disable test ComponentId, disable ComponentId filtering.\n Testing error returns and ensuring a trace statement IS carried out "));
- SetBlockResult(TestComponentIdFiltering(logger, EFalse, EFalse));
+ SetBlockResult(TestComponentIdFilteringL(logger, EFalse, EFalse));
}
/***********************************************************/
@@ -595,7 +595,7 @@
if(BlockResult()==EPass)
{
INFO_PRINTF1(_L("\n\n Disable test ComponentId, enable ComponentId filtering.\n Testing error returns and ensuring a trace statement IS NOT carried out "));
- SetBlockResult(TestComponentIdFiltering(logger, EFalse, ETrue));
+ SetBlockResult(TestComponentIdFilteringL(logger, EFalse, ETrue));
}
}
@@ -621,7 +621,7 @@
// ************** Block end ****************
- configIni.Clear(logger);
+ configIni.ClearL(logger);
logger.Close();
}
return ETrue;
@@ -629,7 +629,7 @@
-TVerdict CTCMAdvancedComponentIDFilteringWrapper::TestComponentIdFiltering(RULogger& aLogger, const TBool aFilter, const TBool aFiltering)
+TVerdict CTCMAdvancedComponentIDFilteringWrapper::TestComponentIdFilteringL(RULogger& aLogger, const TBool aFilter, const TBool aFiltering)
/**
* @return - TVerdict code
* standard function to test error returns and ComponentId filtering
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_buffermode.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_buffermode.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -157,7 +157,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
logger.SetSecondaryFilteringEnabled(EFalse);//C.A. previously:logger.DisableModuleUidFiltering();
// C.A. previously:
/* TBufferMode bufferCircular = ECircular;
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_buffersizing.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_buffersizing.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -136,7 +136,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
logger.SetSecondaryFilteringEnabled(EFalse);//C.A. previously:logger.DisableModuleUidFiltering();
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(KGroupId);
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_configfile.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_configfile.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -229,7 +229,7 @@
Result=logger.Connect();
INFO_PRINTF2(_L("connect err %d"), Result);
CClearConfig configIni;
- configIni.Default(logger);
+ configIni.DefaultL(logger);
/**************First get primary filter*************/
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_filepluginerr.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_filepluginerr.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -87,7 +87,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
_LIT8(KTextmedia,"te_fileplugin");
const TPtrC8 mediaptr(KTextmedia);
INFO_PRINTF1(_L("Setting test plugin as active..."));
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_ostv2tracetestwrapper.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_ostv2tracetestwrapper.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -34,6 +34,8 @@
_LIT(KTestOstDebugOnlyWrap, "TestOstDebugOnlyWrap");
+_LIT(KTestOstCompileTimeMacro, "TestOstCompileTimeMacro");
+
//macro wrapper that works only in _DEBUG mode
#ifndef OST_DEBUG_ONLY
#ifdef _DEBUG
@@ -95,6 +97,10 @@
{
TestOstDebugOnlyWrapL();
}
+ else if (aCommand == KTestOstCompileTimeMacro())
+ {
+ TestOstCompileTimeMacroL();
+ }
else
{
ret = EFalse;
@@ -144,7 +150,7 @@
User::LeaveIfError(OpenUlogger(logger));
// clear the config file
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
// extract the user ids from the values generated by tracecompiler
const TUint8 USER_DEFINED_GID_1 = TEST_OSTTRACEWRAPPER7 >> 16;
@@ -263,7 +269,7 @@
void CTOstv2TraceTestWrapper::TestOstDebugOnlyWrapL()
{
- INFO_PRINTF1(_L("CTOstv2TraceTestWrapper::TestDuplicates"));
+ INFO_PRINTF1(_L("CTOstv2TraceTestWrapper::TestOstDebugOnlyWrap"));
RULogger logger;
@@ -271,7 +277,7 @@
User::LeaveIfError(OpenUlogger(logger));
// clear the config file
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
// extract the user ids from the values generated by tracecompiler
const TUint8 USER_DEFINED_GID_1w = TEST_OSTTRACEWRAPPER7w >> 16;
@@ -388,6 +394,141 @@
}
+void CTOstv2TraceTestWrapper::TestOstCompileTimeMacroL()
+ {
+ INFO_PRINTF1(_L("CTOstv2TraceTestWrapper::TestOstCompileTimeMacro"));
+
+ RULogger logger;
+
+
+ User::LeaveIfError(OpenUlogger(logger));
+ // clear the config file
+ CClearConfig configIni;
+ configIni.ClearL(logger);
+
+ // switch on primary filtering mechanism
+ CArrayFixFlat<TUint8> *setprimfilter =
+ new (ELeave) CArrayFixFlat<TUint8> (22);
+ setprimfilter->AppendL(KGroupId);
+ setprimfilter->AppendL(TRACE_NORMAL);
+ TInt result = logger.SetPrimaryFiltersEnabled(*setprimfilter, ETrue);
+
+ if (result != KErrNone)
+ {
+ ERR_PRINTF2(_L("Failed to set Ulogger primary filters result(%d"), result);
+ SetBlockResult(EFail);
+ }
+
+ // switch off secondary filtering
+ result = logger.SetSecondaryFilteringEnabled(EFalse);
+ if (result != KErrNone)
+ {
+ ERR_PRINTF2(_L("Failed to set Ulogger secondary filters result(%d"), result);
+ SetBlockResult(EFail);
+ }
+
+ delete setprimfilter;
+ setprimfilter = NULL;
+ // setup output file
+ _LIT(KLogFilename, "C:\\logs\\macro_trace_test.utf");
+ EmptyFile(KLogFilename);
+ // setup ulogger to write to the file using its output plugin
+ _LIT8(KTextmedia,"uloggerfileplugin");
+ TPtrC8 mediaptr(KTextmedia);
+ result = logger.ActivateOutputPlugin(mediaptr);
+ if (result == KErrNone)
+ {
+ INFO_PRINTF1(_L("file set as active output plugin ok"));
+ TPluginConfiguration pluginConfig;
+ _LIT(KTextsetting, "output_path");
+ pluginConfig.SetKey(KTextsetting);
+ pluginConfig.SetValue(KLogFilename());
+ result = logger.SetPluginConfigurations(mediaptr, pluginConfig);
+ if (result == KErrNone)
+ {
+ INFO_PRINTF1(_L("output plugin settings set ok"));
+
+ result = logger.Start();
+ if (result == KErrNone)
+ {
+ // now try some traces with compile time Macros
+ //OST_TRACE_CATEGORY_DEBUG
+ #if (OST_TRACE_CATEGORY & OST_TRACE_CATEGORY_DEBUG)
+ AddTraceHelper((TGroupId) TRACE_NORMAL, (TTraceId) TEST_OSTTRACEWRAPPER1m, 0); // should be in UDEB only
+ #endif
+ OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_NORMAL, TEST_OSTTRACEWRAPPER1m, "Foo");
+
+ #ifdef _DEBUG
+ AddTraceHelper((TGroupId) TRACE_NORMAL, (TTraceId) TEST_OSTTRACEWRAPPER2m, 0);
+ #endif
+ OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_NORMAL, TEST_OSTTRACEWRAPPER2m, "Foo"); // should be in UBED only
+
+
+ //OST_TRACE_CATEGORY_PRODUCTION
+ #if (OST_TRACE_CATEGORY & OST_TRACE_CATEGORY_PRODUCTION)
+ AddTraceHelper((TGroupId) TRACE_NORMAL, (TTraceId) TEST_OSTTRACEWRAPPER3m, 0);
+ #endif
+ OstTraceDef0(OST_TRACE_CATEGORY_PRODUCTION, TRACE_NORMAL, TEST_OSTTRACEWRAPPER3m, "Foo"); // should be in UREL and UDEB
+
+ //OST_TRACE_CATEGORY_RND
+ #if (OST_TRACE_CATEGORY & OST_TRACE_CATEGORY_RND)
+ AddTraceHelper((TGroupId) TRACE_NORMAL, (TTraceId) TEST_OSTTRACEWRAPPER4m, 0);
+ #endif
+ OstTraceDef0(OST_TRACE_CATEGORY_RND, TRACE_NORMAL, TEST_OSTTRACEWRAPPER4m, "Foo"); // should be in UREL and UDEB
+
+ #if (OST_TRACE_CATEGORY & OST_TRACE_CATEGORY_PERFORMANCE_MEASUREMENT)
+ AddTraceHelper((TGroupId) TRACE_NORMAL, (TTraceId) TEST_OSTTRACEWRAPPER5m, 0);
+ #endif
+ OstTraceDef0(OST_TRACE_CATEGORY_PERFORMANCE_MEASUREMENT, TRACE_NORMAL, TEST_OSTTRACEWRAPPER5m, "Foo"); // should be in neither UREL nor UDEB
+
+ #if (OST_TRACE_CATEGORY & OST_TRACE_CATEGORY_NONE)
+ AddTraceHelper((TGroupId) TRACE_NORMAL, (TTraceId) TEST_OSTTRACEWRAPPER6m, 0);
+ #endif
+ OstTraceDef0(OST_TRACE_CATEGORY_NONE, TRACE_NORMAL, TEST_OSTTRACEWRAPPER6m, "Foo"); // should be in neither UREL nor UDEB
+
+ #if (OST_TRACE_CATEGORY & OST_TRACE_CATEGORY_ALL)
+ AddTraceHelper((TGroupId) TRACE_NORMAL, (TTraceId) TEST_OSTTRACEWRAPPER7m, 0);
+ #endif
+ OstTraceDef0(OST_TRACE_CATEGORY_ALL, TRACE_NORMAL, TEST_OSTTRACEWRAPPER7m, "Foo"); // should be in UREL and UDEB
+
+ #if (OST_TRACE_CATEGORY & (OST_TRACE_CATEGORY_PRODUCTION | OST_TRACE_CATEGORY_DEBUG))
+ AddTraceHelper((TGroupId) TRACE_NORMAL, (TTraceId) TEST_OSTTRACEWRAPPER8m, 0);
+ #endif
+ OstTraceDef0(OST_TRACE_CATEGORY_PRODUCTION | OST_TRACE_CATEGORY_DEBUG, TRACE_NORMAL, TEST_OSTTRACEWRAPPER8m, "Foo"); // should be in UREL and UDEB
+
+ #if (OST_TRACE_CATEGORY & (OST_TRACE_CATEGORY_PRODUCTION)) || defined (_DEBUG)
+ AddTraceHelper((TGroupId) TRACE_NORMAL, (TTraceId) TEST_OSTTRACEWRAPPER9m, 0);
+ #endif
+ OstTraceDef0(OST_TRACE_CATEGORY_PRODUCTION | OST_TRACE_CATEGORY_DEBUG, TRACE_NORMAL, TEST_OSTTRACEWRAPPER9m, "Foo"); // should be in UREL and UDEB
+
+
+ result = logger.Stop();
+
+ if (result == KErrNone)
+ {
+ SetBlockResult(
+ CheckResults(KLogFilename()) == KErrNone
+ ? EPass
+ : EFail);
+ }
+ }
+ else
+ {
+ INFO_PRINTF2(_L("ulogger start returns error %d"), result);
+ }
+ }
+ else
+ {
+ INFO_PRINTF2(_L("setting output plugin settings failed with err %d"), result);
+ }
+ }
+ else
+ {
+ INFO_PRINTF2(_L("add file as output plugin failed with err %d"), result);
+ }
+ }
+
+
TInt CTOstv2TraceTestWrapper::CheckResults(const TDesC& aLogFilename)
{
// read the logged traces from the log file
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_tracecollectorclient.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_tracecollectorclient.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -103,7 +103,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
INFO_PRINTF2(_L("connect err %d"), result);
result=logger.SetPrimaryFiltersEnabled(*setfilter,ETrue);//C.A. previously:result=logger.EnableClassifications(*setfilter);
@@ -320,7 +320,7 @@
// ************** Block end ****************
- configIni.Clear(logger);
+ configIni.ClearL(logger);
logger.Close();
if(setfilter)
delete setfilter;
@@ -414,7 +414,7 @@
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
result = logger.SetSecondaryFiltersEnabled(setfilter,ETrue);//C.A. previously:result = logger.EnableModuleUids(setfilter);
INFO_PRINTF2(_L("Secondary filter has been set with single filter, %d, check log"), setfilter[0]);
INFO_PRINTF2(_L("code: %d"), result);
@@ -600,7 +600,7 @@
}
}
INFO_PRINTF1(_L("Now call clear config to check removing multiple second filters performance"));
- configIni.Clear(logger);
+ configIni.ClearL(logger);
INFO_PRINTF1(_L("after clear config- multiple second filters performance"));
if(result==1)
@@ -694,7 +694,7 @@
#endif
#ifndef SysStartTest
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
#endif
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(22);
setprimfilter->AppendL(KGroupId);
@@ -993,7 +993,7 @@
{
INFO_PRINTF1(_L("Now do some multiple type logging testing."));
//CClearConfig configIni;
- //configIni.Clear(logger);
+ //configIni.ClearL(logger);
if(result==0)
{
@@ -1205,7 +1205,7 @@
multsetprimfilter=NULL;
}
}
- configIni.Clear(logger);
+ configIni.ClearL(logger);
}
else
INFO_PRINTF1(_L("adding file as output plugin failed"));
@@ -1310,7 +1310,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(KGroupId);
RArray<TUint32> setsecondfilter;
@@ -1580,7 +1580,7 @@
else
SetBlockResult(EFail);
INFO_PRINTF1(_L("Multiple logging to file with kernel side tracing has been tested - check output log. It should contain four lines of tracing of type, (sec,prim), (sec+2, prim), (sec, prim+2), (sec+2, prim+2)"));
- configIni.Clear(logger);
+ configIni.ClearL(logger);
}
if(setprimfilter)
{
@@ -1668,7 +1668,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(KGroupId);
RArray<TUint32> setsecondfilter;
@@ -1885,7 +1885,7 @@
}
}
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(KGroupId);
RArray<TUint32> setsecondfilter;
@@ -1977,7 +1977,7 @@
SetBlockResult(EFail);
INFO_PRINTF1(_L("Simple printf logging to file has been tested with kernel side tracing- check output log"));
- configIni.Clear(logger);
+ configIni.ClearL(logger);
if(setprimfilter)
{
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_tracecollectorfile.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_tracecollectorfile.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -92,7 +92,7 @@
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
_LIT8(KTextmedia,"uloggerfileplugin");
const TPtrC8 mediaptr(KTextmedia);
if(result==0||result==-11)
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_tracecollectorserial.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/src/te_tracecollectorserial.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -91,7 +91,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(KGroupId);
RArray<TUint32> setsecondfilter;
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te-integ-tracecollectorclient.script
//! @SYMScriptTestEnvironment TEF
@@ -48,3 +48,22 @@
+START_TESTCASE DT-DEBUG-TRACE-OSTv2-TraceControlCompileTimeSelector-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-OSTv2-TraceControlCompileTimeSelector-0001
+//! @SYMTestCaseDesc Test DEBUG only compile time selector using OST_TRACE_CATEGORY_DEBUG
+//! @SYMTestPriority Critical
+//! @SYMTestActions
+//! @SYMTestExpectedResults Verify that the errors returned are as expected
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ2390
+//! @SYMREQ
+
+PRINT Run OstTrace with OST_TRACE_CATEGORY_DEBUG compile time Macro
+START_TEST_BLOCK 20000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
+ CREATE_OBJECT OstTraceTestWrapper OstTraceTestWrapper
+ COMMAND OstTraceTestWrapper TestOstCompileTimeMacro
+END_TEST_BLOCK
+END_TESTCASE DT-DEBUG-TRACE-OSTv2-TraceControlCompileTimeSelector-0001
+
+
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient_disabled.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient_disabled.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -14,7 +14,7 @@
//
-//! @File
+//! @file
//! @SYMTestSuiteName te-integ-tracecollectorclient_disabled.script
//! @SYMScriptTestEnvironment TEF
@@ -31,7 +31,7 @@
//! @SYMTestActions Run a combination of single and multiple group ID filter set() methods and check the contents of the get() methods on server return the filters as expected
//! @SYMTestExpectedResults Verify that the values returned by get methods match those expected from settings (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975
START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -48,7 +48,7 @@
//! @SYMTestActions Run a combination of single and multiple component ID filter set() methods and check the contents of the get() methods on server return the filters as expected
//! @SYMTestExpectedResults Verify that the values returned by get methods match those expected from settings (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975
START_TEST_BLOCK 20000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -65,7 +65,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument user-side trace points accordingly for positive, begative and multiple setting tests
//! @SYMTestExpectedResults Verify that no returned trace data and no output trace log files accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975 12823 12824 12825 12128 12974 12975
START_TEST_BLOCK 20000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -82,7 +82,7 @@
//! @SYMTestActions Run a combination of single and multiple group ID filter and filtering set() methods and check the contents of the get() methods on server return the filters as expected
//! @SYMTestExpectedResults Verify that the values returned by get methods match those expected from settings (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975
START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -105,7 +105,7 @@
//! @SYMTestActions Run a combination of single and multiple component ID filter and filtering set() methods and check the contents of the get() methods on server return the filters as expected
//! @SYMTestExpectedResults Verify that the values returned by get methods match those expected from settings (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975
START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -128,7 +128,7 @@
//! @SYMTestActions Run a combination of buffer resizing methods and run over various stress testing trace instrumentations. Check the contents of the output file is as expected
//! @SYMTestExpectedResults Verify that output file contains no #traces as expected
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12152
START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -145,7 +145,7 @@
//! @SYMTestActions Run a combination of buffer mode change methods and run over various stress testing trace instrumentations. check the contents of the output file is as expected
//! @SYMTestExpectedResults Verify that output file contains no
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12152
START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -163,7 +163,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument kernel-side trace points accordingly for positive, negative and multiple setting tests
//! @SYMTestExpectedResults Verify that no returned trace data and no output trace log files accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975 12823 12824 12825 12128 12974 12975
// START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -180,7 +180,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument user-side trace printf-style points accordingly for positive, negative and multiple setting tests
//! @SYMTestExpectedResults Verify that no returned trace data and no output trace log files accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975 12823 12824 12825 12128 12974 12975
START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -198,7 +198,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument kernel-side trace printf-style points accordingly for positive, negative and multiple setting tests
//! @SYMTestExpectedResults Verify that no returned trace data and no output trace log files accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975 12823 12824 12825 12128 12974 12975
// START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -218,7 +218,7 @@
//! @SYMTestActions Run a combination of plugin configuration methods for the file plugin and log over trace instrumentation
//! @SYMTestExpectedResults Verify that the trace data is not output as expected to the file plugin
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12129 12153
START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -235,7 +235,7 @@
//! @SYMTestActions Run a combination of plugin configuration methods for the serial plugin and log over trace instrumentation
//! @SYMTestExpectedResults Verify that trace data is not output as expected to the serial plugin
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12129 12153 12147
START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -252,7 +252,7 @@
//! @SYMTestActions Run a combination of plugin configuration methods for the file plugin and test on the return errors
//! @SYMTestExpectedResults Verify that the errors returned are as expected
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12129 12153 12147
START_TEST_BLOCK 1000 te_ostv2integsuite_disabled \testdata\configs\te_integ_tracecollectorclient.ini
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient_enabled.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorclient_enabled.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -14,7 +14,7 @@
//
-//! @File
+//! @file
//! @SYMTestSuiteName te-integ-tracecollectorclient_enabled.script
//! @SYMScriptTestEnvironment TEF
@@ -31,7 +31,7 @@
//! @SYMTestActions Run a combination of single and multiple group ID filter set() methods and check the contents of the get() methods on server return the filters as expected
//! @SYMTestExpectedResults Verify that the values returned by get methods match those expected from settings (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975
START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -48,7 +48,7 @@
//! @SYMTestActions Run a combination of single and multiple component ID filter set() methods and check the contents of the get() methods on server return the filters as expected
//! @SYMTestExpectedResults Verify that the values returned by get methods match those expected from settings (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975
START_TEST_BLOCK 20000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -65,7 +65,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument user-side trace points accordingly for positive, negative and multiple setting tests
//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the settings in the TraceControl accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975 12823 12824 12825 12128 12974 12975
START_TEST_BLOCK 20000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -82,7 +82,7 @@
//! @SYMTestActions Run a combination of single and multiple group ID filter and filtering set() methods and check the contents of the get() methods on server return the filters as expected
//! @SYMTestExpectedResults Verify that the values returned by get methods match those expected from settings (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975
START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -105,7 +105,7 @@
//! @SYMTestActions Run a combination of single and multiple component ID filter and filtering set() methods and check the contents of the get() methods on server return the filters as expected
//! @SYMTestExpectedResults Verify that the values returned by get methods match those expected from settings (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975
START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -128,7 +128,7 @@
//! @SYMTestActions Run a combination of buffer resizing methods and run over various stress testing trace instrumentations. check the contents of the output file is as expected
//! @SYMTestExpectedResults Verify that output file contains #traces as expected
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12152
START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -145,7 +145,7 @@
//! @SYMTestActions Run a combination of buffer mode change methods and run over various stress testing trace instrumentations. check the contents of the output file is as expected
//! @SYMTestExpectedResults Verify that output file contains a trace pattern as expected from buffer mode type
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12152
START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -163,7 +163,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument kernel-side trace points accordingly for positive, negative and multiple setting tests
//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the settings in the TraceControl accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975 12823 12824 12825 12128 12974 12975
// START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -180,7 +180,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument user-side trace printf-style points accordingly for positive, negative and multiple setting tests
//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the settings in the TraceControl accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975 12823 12824 12825 12128 12974 12975
START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -198,7 +198,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument kernel-side trace printf-style points accordingly for positive, negative and multiple setting tests
//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the settings in the TraceControl accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12974 12975 12823 12824 12825 12128 12974 12975
// START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -218,7 +218,7 @@
//! @SYMTestActions Run a combination of plugin configuration methods for the file plugin and log over trace instrumentation
//! @SYMTestExpectedResults Verify that the trace data is output as expected to the file plugin
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12129 12153
START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -235,7 +235,7 @@
//! @SYMTestActions Run a combination of plugin configuration methods for the serial plugin and log over trace instrumentation
//! @SYMTestExpectedResults Verify that the trace data is output as expected to the serial plugin
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12129 12153 12147
START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
@@ -252,7 +252,7 @@
//! @SYMTestActions Run a combination of plugin configuration methods for the file plugin and test on the return errors
//! @SYMTestExpectedResults Verify that the errors returned are as expected
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12129 12153 12147
START_TEST_BLOCK 1000 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorclient.ini
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorconfigfile.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorconfigfile.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,5 +1,5 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -14,7 +14,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_integ_tracecollectorconfigfile.script
//! @SYMScriptTestEnvironment TEF
@@ -39,7 +39,7 @@
//! @SYMTestActions Compare the settings in the TraceControl server with that specified in the test config file in \testdata\configs\configfiletracecontrolconfig.ini
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12129
START_TEST_BLOCK 100 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorconfigfile.ini
@@ -63,7 +63,7 @@
//! @SYMTestActions Having deleted c:\ulogger\uloggerconfig.ini in the public path, now compare the settings in the TraceControl server with that specified by default in the private path
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12129
START_TEST_BLOCK 100 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorconfigfile.ini
@@ -88,7 +88,7 @@
//! @SYMTestActions Having reinstated a config file on the public path, now compare the settings in the TraceControl server with that specified in the public path
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12129
START_TEST_BLOCK 100 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorconfigfile.ini
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorconfigfile_winscw.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorconfigfile_winscw.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -14,7 +14,7 @@
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_integ_tracecollectorconfigfile_winscw.script
//! @SYMScriptTestEnvironment TEF
@@ -36,7 +36,7 @@
//! @SYMTestActions Compare the settings in the TraceControl server with that specified in the test config file in \testdata\configs\configfiletracecontrolconfig.ini
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12129
START_TEST_BLOCK 100 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorconfigfile_winscw.ini
@@ -60,7 +60,7 @@
//! @SYMTestActions Having deleted c:\ulogger\uloggerconfig.ini in the public path, now compare the settings in the TraceControl server with that specified by default in the private path
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12129
START_TEST_BLOCK 100 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorconfigfile_winscw.ini
@@ -83,7 +83,7 @@
//! @SYMTestActions Having reinstated a config file on the public path, now compare the settings in the TraceControl server with that specified in the public path
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12128 12129
START_TEST_BLOCK 100 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorconfigfile_winscw.ini
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorsysstart.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_functional/testdata/scripts/te_integ_tracecollectorsysstart.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -14,7 +14,7 @@
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_integ_tracecollectorsysstart.script
//! @SYMScriptTestEnvironment TEF
@@ -32,7 +32,7 @@
//! @SYMTestActions Compile a rom with uloggersysstart.exe compiled into startup sequence and uncomment #define sysstart in TCMLogging datawrapper. Run test step.
//! @SYMTestExpectedResults Verify that the output log contains btrace output from boot sequence as well as trace points enabled in TCMLogging datawrapper
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12825 12976 12978
START_TEST_BLOCK 100 te_ostv2integsuite_enabled \testdata\configs\te_integ_tracecollectorsysstart.ini
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/sanity/te_perfsanitytimer.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/sanity/te_perfsanitytimer.h Tue Aug 31 16:57:14 2010 +0300
@@ -43,17 +43,17 @@
};
public:
- TBool TestUserTimer(TUint32& aTestTime);
- TBool TestUserLongTimer(TUint32& aTestTime);
- TBool TestKernelTimer(TUint32& aTestTime);
- TBool TestKernelLongTimer(TUint32& aTestTime);
- TBool TestUTraceUserTimer(TUint32& aTestTime);
- TBool TestUTraceKernelTimer(TUint32& aTestTime);
+ TBool TestUserTimerL(TUint32& aTestTime);
+ TBool TestUserLongTimerL(TUint32& aTestTime);
+ TBool TestKernelTimerL(TUint32& aTestTime);
+ TBool TestKernelLongTimerL(TUint32& aTestTime);
+ TBool TestUTraceUserTimerL(TUint32& aTestTime);
+ TBool TestUTraceKernelTimerL(TUint32& aTestTime);
TUint32 Count(){return iCount;}
private:
TBool VerifyTime(TUint32 aTime);
TBool DoTestUTraceTimer(const TInt aApi, TUint32& aTestTime);
- TBool DoTestTrace(const TTestMethodType aMethod, TUint32& aTestTime);
+ TBool DoTestTraceL(const TTestMethodType aMethod, TUint32& aTestTime);
private:
#ifndef __KERNEL_MODE__
CUptTimer iTimer;
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perf.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perf.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -14,14 +14,15 @@
//
-
/**
@file te_perf.h
@internalTechnology
*/
+
#if (!defined TE_ULOGGERMCLPERFSTEP_H)
#define TE_ULOGGERMCLPERFSTEP_H
-#include <datawrapper.h>
+
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <hal.h>
#include <uloggerclient.h>
@@ -53,8 +54,8 @@
private:
//private run config members
+ };
- };
class CTCMPerformanceWrapper : public CTe_MCLSuiteBaseWrapper
{
@@ -69,17 +70,14 @@
private:
CTCMPerformanceWrapper();
void ConstructL();
- TVerdict DoApiTests(const TTEFSectionName& aSection);
- TVerdict DoPluginTests(const TInt& aPluginOnly, const TTEFSectionName& aSection); //tried TBool - didn't work for some reason
+ TVerdict DoApiTestsL(const TTEFSectionName& aSection);
+ TVerdict DoPluginTestsL(const TInt& aPluginOnly, const TTEFSectionName& aSection); //tried TBool - didn't work for some reason
TVerdict DoBufferSizeTests();//to be implemented
TVerdict DoBufferModeTests();//to be implemented
TApiRunConfig iApiRunConfig;
CPluginRunConfig* iPluginRunConfig;
};
-
-
-
_LIT(KTCMPerformanceWrapper,"TCMPerformance");
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perfapicall.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perfapicall.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -15,7 +15,6 @@
//
-
/**
@file te_perfapicall.h
@internalTechnology
@@ -34,8 +33,6 @@
#include "te_apirunconfig.h"
-
-
class CApiCallTest: public CBase
{
public:
@@ -43,9 +40,9 @@
~CApiCallTest();
//could get rid of this now if you want...
TInt DoTestL(const TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult);
- TInt CachedTraceTime(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult);
- TInt NonCachedTraceTime(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult);
- TInt StackUsage(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult);
+ TInt CachedTraceTimeL(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult);
+ TInt NonCachedTraceTimeL(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult);
+ TInt StackUsageL(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult);
TInt Test();
private:
@@ -59,12 +56,12 @@
//TInt TraceBaselineTime(const TApiRunConfig& aApiRunConfig, TUint64& aBaselineTime, TBool aDoTrace);
//TInt TraceTime(const TApiRunConfig& aApiRunConfig, TUint64& aTime, const TUint64& aBaselineTime, TBool aDoTrace);
- TInt CachedTraceBaselineTime(TApiRunConfig& aApiRunConfig, TInt32& aMinimumExecutionBaselineTime);
- TInt CachedTraceTime(TApiRunConfig& aApiRunConfig, TInt32& aMinimumExecutionTime, TInt32& aMinimumExecutionBaselineTime);
- TInt NonCachedTraceBaselineTime(TApiRunConfig& aApiRunConfig, TInt32& aTypicalExecutionBaselineTime);
- TInt NonCachedTraceTime(TApiRunConfig& aApiRunConfig, TInt32& aTypicalExecutionTime, TInt32& aTypicalExecutionBaselineTime);
+ TInt CachedTraceBaselineTimeL(TApiRunConfig& aApiRunConfig, TInt32& aMinimumExecutionBaselineTime);
+ TInt CachedTraceTimeL(TApiRunConfig& aApiRunConfig, TInt32& aMinimumExecutionTime, TInt32& aMinimumExecutionBaselineTime);
+ TInt NonCachedTraceBaselineTimeL(TApiRunConfig& aApiRunConfig, TInt32& aTypicalExecutionBaselineTime);
+ TInt NonCachedTraceTimeL(TApiRunConfig& aApiRunConfig, TInt32& aTypicalExecutionTime, TInt32& aTypicalExecutionBaselineTime);
- TInt StackUsage(TApiRunConfig& aApiRunConfig, TInt& aApiStackUsage);
+ TInt StackUsageL(TApiRunConfig& aApiRunConfig, TInt& aApiStackUsage);
TInt HeapUsage(TInt& aApiHeapUsage);
TInt DoTheApiCall();
@@ -77,5 +74,3 @@
};
#endif
-
-
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perfcsvgenerator.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perfcsvgenerator.h Tue Aug 31 16:57:14 2010 +0300
@@ -47,15 +47,15 @@
CUptCsvGenerator();
~CUptCsvGenerator();
- TInt Open(const TDesC& aFileName, const TBool& aAppend);
+ TInt OpenL(const TDesC& aFileName, const TBool& aAppend);
TInt Close();
void WriteL(const RArray<TInt64>& aPerformanceData);
void WriteL(const RArray<TPtrC8>& aPerformanceConfig);
void WriteApiNameL(const TInt aApiEnum);
- TInt WriteNewLine();
- TInt WriteHeader(const TInt& aTestType);
+ TInt WriteNewLineL();
+ TInt WriteHeaderL(const TInt& aTestType);
- TInt Test();
+ TInt TestL();
private:
//Private helper method for sanity tests
TInt FillReferenceBuffer(RBuf8& aBufferName, const TInt& aAppendCount, const RArray<TInt64>& aDataName, const TInt& aData1Count, const RArray<TInt64>& aData2Name, const TInt& aData2Count);
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perfoutputsanity.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perfoutputsanity.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined TE_OUTPUTSANITYTEST_H)
#define TE_OUTPUTSANITYTEST_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
@@ -42,9 +42,9 @@
private:
COutputCSVSanityWrapper();
void ConstructL();
- TVerdict TestBaselineCsv();
- TInt ReadCsvFile(const TDesC& aFilename, RBuf8& aBuffer);
- TInt CsvFileSize(const TDesC& aFilename, TInt& aSize);
+ TVerdict TestBaselineCsvL();
+ TInt ReadCsvFileL(const TDesC& aFilename, RBuf8& aBuffer);
+ TInt CsvFileSizeL(const TDesC& aFilename, TInt& aSize);
};
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perfsanity.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perfsanity.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#if (!defined TE_PERFORMANCESANITYTEST_H)
#define TE_PERFORMANCESANITYTEST_H
-#include <datawrapper.h>
+#include <test/datawrapper.h>
#include "te_ostv2integsuite_basewrapper.h"
#include <e32base.h>
#include <e32math.h>
@@ -42,8 +42,8 @@
private:
CPerformanceSanityWrapper();
void ConstructL();
- TVerdict TestTimer();
- TBool SanityTestTimedUtrace();
+ TVerdict TestTimerL();
+ TBool SanityTestTimedUtraceL();
};
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perftracetester.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/inc/te_perftracetester.h Tue Aug 31 16:57:14 2010 +0300
@@ -56,13 +56,13 @@
* Makes a trace call to either kernel or user side
* and returns the time in the parameter aApiRunConfig.iApiTraceTime
*/
- TInt TimeTraceCall(const TApiRunConfig& aApiRunConfig, TApiRunResults& aApiRunResults);
+ TInt TimeTraceCallL(const TApiRunConfig& aApiRunConfig, TApiRunResults& aApiRunResults);
/**
* Makes a call to user side, returning the time in the
* parameter aApiRunConfig.iApiTraceTime
*/
- TInt TimeUsersideTraceCalls(const TApiRunConfig& aApiRunConfig, TApiRunResults& aApiRunResults);
+ TInt TimeUsersideTraceCallsL(const TApiRunConfig& aApiRunConfig, TApiRunResults& aApiRunResults);
/**
*/
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/sanity/te_perfsanitytimer.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/sanity/te_perfsanitytimer.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -30,39 +30,39 @@
#endif
#include "te_dataparameters.h"
-TBool TTestTimer::TestUserTimer(TUint32& aTestTime)
+TBool TTestTimer::TestUserTimerL(TUint32& aTestTime)
{
- return DoTestTrace(ESanityFoo, aTestTime);
+ return DoTestTraceL(ESanityFoo, aTestTime);
}
-TBool TTestTimer::TestUserLongTimer(TUint32& aTestTime)
+TBool TTestTimer::TestUserLongTimerL(TUint32& aTestTime)
{
- return DoTestTrace(ESanityFooLong, aTestTime);
+ return DoTestTraceL(ESanityFooLong, aTestTime);
}
-TBool TTestTimer::TestKernelTimer(TUint32& aTestTime)
+TBool TTestTimer::TestKernelTimerL(TUint32& aTestTime)
{
- return DoTestTrace(ESanityFoo, aTestTime);
+ return DoTestTraceL(ESanityFoo, aTestTime);
}
-TBool TTestTimer::TestKernelLongTimer(TUint32& aTestTime)
+TBool TTestTimer::TestKernelLongTimerL(TUint32& aTestTime)
{
- return DoTestTrace(ESanityFooLong, aTestTime);
+ return DoTestTraceL(ESanityFooLong, aTestTime);
}
-TBool TTestTimer::TestUTraceUserTimer(TUint32& aTestTime)
+TBool TTestTimer::TestUTraceUserTimerL(TUint32& aTestTime)
{
- return DoTestTrace(EUtraceUsr, aTestTime);
+ return DoTestTraceL(EUtraceUsr, aTestTime);
}
-TBool TTestTimer::TestUTraceKernelTimer(TUint32& aTestTime)
+TBool TTestTimer::TestUTraceKernelTimerL(TUint32& aTestTime)
{
- return DoTestTrace(EUtraceKrn, aTestTime);
+ return DoTestTraceL(EUtraceKrn, aTestTime);
}
-TBool TTestTimer::DoTestTrace(const TTestMethodType aMethod, TUint32& aTestTime)
+TBool TTestTimer::DoTestTraceL(const TTestMethodType aMethod, TUint32& aTestTime)
{
aTestTime = 0;
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perf.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perf.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -71,7 +71,6 @@
*/
{
TRunConfigurer::Init(iApiRunConfig);
- iPluginRunConfig = new(ELeave) CPluginRunConfig;
}
@@ -92,6 +91,7 @@
void CTCMPerformanceWrapper::ConstructL()
{
+ iPluginRunConfig = new(ELeave) CPluginRunConfig;
}
TAny* CTCMPerformanceWrapper::GetObject()
@@ -125,18 +125,18 @@
TInt pluginOnlyTests=0;
//run api tests
if(doapicalltests)
- SetBlockResult(DoApiTests(aSection));
+ SetBlockResult(DoApiTestsL(aSection));
if(dooutputplugintests)
{
pluginOnlyTests=1;
- SetBlockResult(DoPluginTests(pluginOnlyTests, aSection));
+ SetBlockResult(DoPluginTestsL(pluginOnlyTests, aSection));
}
if(dothroughputtests)
{
pluginOnlyTests=2;
- SetBlockResult(DoPluginTests(pluginOnlyTests, aSection));
+ SetBlockResult(DoPluginTestsL(pluginOnlyTests, aSection));
}
/*
@@ -155,7 +155,7 @@
return ETrue;
}
-TVerdict CTCMPerformanceWrapper::DoApiTests(const TTEFSectionName& aSection)
+TVerdict CTCMPerformanceWrapper::DoApiTestsL(const TTEFSectionName& aSection)
{
//initialize and create test run parameters
//*******this is quite ugly and could be tidied up into a new routine so isnt in main test step
@@ -327,7 +327,7 @@
}
}
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
//put in test over API CALLS
testtype=0;
@@ -373,22 +373,22 @@
//do the test
INFO_PRINTF2(_L("Testing API %d"), iApiRunConfig.iApiId);
- error = apitest.CachedTraceTime(iApiRunConfig, apitestresult);
+ error = apitest.CachedTraceTimeL(iApiRunConfig, apitestresult);
if(error)
{
- INFO_PRINTF2(_L("ERROR: CachedTraceTime failed, error %d"), error);
+ INFO_PRINTF2(_L("ERROR: CachedTraceTimeL failed, error %d"), error);
SetBlockResult(EFail);
}
- error = apitest.NonCachedTraceTime(iApiRunConfig, apitestresult);
+ error = apitest.NonCachedTraceTimeL(iApiRunConfig, apitestresult);
if(error)
{
- INFO_PRINTF2(_L("ERROR: NonCachedTraceTime failed, error %d"), error);
+ INFO_PRINTF2(_L("ERROR: NonCachedTraceTimeL failed, error %d"), error);
SetBlockResult(EFail);
}
- error = apitest.StackUsage(iApiRunConfig, apitestresult);
+ error = apitest.StackUsageL(iApiRunConfig, apitestresult);
if(error)
{
- INFO_PRINTF2(_L("ERROR: StackUsage failed, error %d"), error);
+ INFO_PRINTF2(_L("ERROR: StackUsageL failed, error %d"), error);
SetBlockResult(EFail);
}
@@ -437,7 +437,7 @@
}
}
}
- configIni.Clear(logger);
+ configIni.ClearL(logger);
}
//put in all the error returns
//put in test step result returns
@@ -445,7 +445,7 @@
return BlockResult();
}
-TVerdict CTCMPerformanceWrapper::DoPluginTests(const TInt& aPluginOnly, const TTEFSectionName& aSection)
+TVerdict CTCMPerformanceWrapper::DoPluginTestsL(const TInt& aPluginOnly, const TTEFSectionName& aSection)
{
//define default plugin configurations
_LIT(KDefaultPlugin,"uloggerfileplugin");
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfapicall.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfapicall.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -75,7 +75,7 @@
return error;
}
-TInt CApiCallTest::CachedTraceTime(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult)
+TInt CApiCallTest::CachedTraceTimeL(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult)
{
TInt error = KErrNotSupported;
//create a dummy time variable to be used for the baseline measurement
@@ -85,17 +85,17 @@
__TEST_LOG("about to carry out cache trace");
if(aApiRunConfig.iDoMinExecution)
{
- CachedTraceBaselineTime(aApiRunConfig, baselinetime);
+ CachedTraceBaselineTimeL(aApiRunConfig, baselinetime);
__TEST_LOG("cache baseline");
__TEST_LOGNUM(baselinetime);
- error = CachedTraceTime(aApiRunConfig, aApiTestResult.iMinimumExecutionTime, baselinetime);
+ error = CachedTraceTimeL(aApiRunConfig, aApiTestResult.iMinimumExecutionTime, baselinetime);
__TEST_LOG("cache");
__TEST_LOGNUM(aApiTestResult.iMinimumExecutionTime);
}
return error;
}
-TInt CApiCallTest::NonCachedTraceTime(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult)
+TInt CApiCallTest::NonCachedTraceTimeL(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult)
{
TInt error = KErrNotSupported;
//create a dummy time variable to be used for the baseline measurement
@@ -103,20 +103,20 @@
__TEST_LOG("about to carry out non cache trace");
if(aApiRunConfig.iDoTypicalExecution)
{
- NonCachedTraceBaselineTime(aApiRunConfig, baselinetime);
+ NonCachedTraceBaselineTimeL(aApiRunConfig, baselinetime);
__TEST_LOG("noncache baseline");
__TEST_LOGNUM(baselinetime);
- error = NonCachedTraceTime(aApiRunConfig, aApiTestResult.iTypicalExecutionTime, baselinetime);
+ error = NonCachedTraceTimeL(aApiRunConfig, aApiTestResult.iTypicalExecutionTime, baselinetime);
__TEST_LOG("noncache");
__TEST_LOGNUM(aApiTestResult.iTypicalExecutionTime);
}
return error;
}
-TInt CApiCallTest::StackUsage(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult)
+TInt CApiCallTest::StackUsageL(TApiRunConfig& aApiRunConfig, TApiTestResult& aApiTestResult)
{
__TEST_LOG("about to carry out stack usage trace");
- TInt error = StackUsage(aApiRunConfig, aApiTestResult.iRunResults.iApiStackUsage);
+ TInt error = StackUsageL(aApiRunConfig, aApiTestResult.iRunResults.iApiStackUsage);
if(aApiTestResult.iRunResults.iApiStackUsage == KErrNotSupported && !error)
error = KErrNotSupported;
return error;
@@ -141,7 +141,7 @@
@param aMinimumExecutionBaselineTime is the minimum execution baseline time taken for the commented API call, calculated in nanoseconds
@return KErrNone if command was prepared correctly and a system wide error code otherwise.
*/
-TInt CApiCallTest::CachedTraceBaselineTime(TApiRunConfig& aApiRunConfig, TInt32& aMinimumExecutionBaselineTime)
+TInt CApiCallTest::CachedTraceBaselineTimeL(TApiRunConfig& aApiRunConfig, TInt32& aMinimumExecutionBaselineTime)
{
//****NB: update this routine to something more maintainable
TUptTraceTester timer;
@@ -171,7 +171,7 @@
@param aMinimumExecutionBaselineTime is the minimum execution baseline time taken for commented API call, calculated in nanoseconds
@return KErrNone if command was prepared correctly and a system wide error code otherwise.
*/
-TInt CApiCallTest::CachedTraceTime(TApiRunConfig& aApiRunConfig, TInt32& aMinimumExecutionTime, TInt32& aMinimumExecutionBaselineTime)
+TInt CApiCallTest::CachedTraceTimeL(TApiRunConfig& aApiRunConfig, TInt32& aMinimumExecutionTime, TInt32& aMinimumExecutionBaselineTime)
{
//NB!!! any changes to this routine and you have to update the baseline calculation as well
TUptTraceTester timer;
@@ -194,7 +194,7 @@
@param aTypicalExecutionBaselineTime is the typical execution baseline time taken for the API call, calculated in nanoseconds
@return KErrNone if command was prepared correctly and a system wide error code otherwise.
*/
-TInt CApiCallTest::NonCachedTraceBaselineTime(TApiRunConfig& aApiRunConfig, TInt32& aTypicalExecutionBaselineTime)
+TInt CApiCallTest::NonCachedTraceBaselineTimeL(TApiRunConfig& aApiRunConfig, TInt32& aTypicalExecutionBaselineTime)
{
//****NB: update this routine to something more maintainable
TUptTraceTester timer;
@@ -223,7 +223,7 @@
@param aTypicalExecutionTime is the typical execution time taken for the API call, calculated in nanoseconds
@return KErrNone if command was prepared correctly and a system wide error code otherwise.
*/
-TInt CApiCallTest::NonCachedTraceTime(TApiRunConfig& aApiRunConfig, TInt32& aTypicalExecutionTime, TInt32& aTypicalExecutionBaselineTime)
+TInt CApiCallTest::NonCachedTraceTimeL(TApiRunConfig& aApiRunConfig, TInt32& aTypicalExecutionTime, TInt32& aTypicalExecutionBaselineTime)
{
TUptTraceTester timer;
@@ -259,7 +259,7 @@
*
* @return KErrNone if command was prepared correctly and a system wide error code otherwise.
*/
-TInt CApiCallTest::StackUsage(TApiRunConfig& aApiRunConfig, TInt& aApiStackUsage)
+TInt CApiCallTest::StackUsageL(TApiRunConfig& aApiRunConfig, TInt& aApiStackUsage)
{
/*
PSEUDOCODE
@@ -311,7 +311,7 @@
return err;
}
-/** This sanity test method is executed in Test() to verify that UPT StackUsage() method in
+/** This sanity test method is executed in Test() to verify that UPT StackUsageL() method in
this class are stable before any of the stack size performance tests are carried out
@return KErrNone if command was prepared correctly and system wide error code otherwise.
*/
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfcsvgenerator.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfcsvgenerator.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -48,7 +48,7 @@
ETrue=Append, EFalse=Overwrite
@return KErrNone if command was prepared correctly and a system wide error code otherwise.
*/
-TInt CUptCsvGenerator::Open(const TDesC& aFileName, const TBool& aAppend)
+TInt CUptCsvGenerator::OpenL(const TDesC& aFileName, const TBool& aAppend)
{
iCsvFileSession.Connect();
@@ -89,7 +89,7 @@
appends a newline character.
@return KErrNone if command was prepared correctly and a system wide error code otherwise.
*/
-TInt CUptCsvGenerator::WriteNewLine()
+TInt CUptCsvGenerator::WriteNewLineL()
{
TInt filesize;
@@ -211,7 +211,7 @@
@param aTestType is the enum identifier for the test in question
@return KErrNone if command was prepared correctly and a system wide error code otherwise.
*/
-TInt CUptCsvGenerator::WriteHeader(const TInt& aTestType)
+TInt CUptCsvGenerator::WriteHeaderL(const TInt& aTestType)
{
RBuf8 buf;
CleanupClosePushL(buf);
@@ -294,7 +294,7 @@
@return KErrNone if command was prepared correctly and system wide error code otherwise.
*/
-TInt CUptCsvGenerator::Test()
+TInt CUptCsvGenerator::TestL()
{
//define filepaths for the test csv files according to the test platform.
#ifdef __WINSCW__
@@ -338,11 +338,11 @@
TInt appendcount=3;
for(TInt i=0; i!=appendcount;i++)
{
- Open(KTestFileAppend, ETrue);
+ OpenL(KTestFileAppend, ETrue);
WriteL(atestdata1);
- WriteNewLine();
+ WriteNewLineL();
WriteL(atestdata2);
- WriteNewLine();
+ WriteNewLineL();
Close();
}
@@ -352,11 +352,11 @@
// 0, 1000, 2000, 3000, 4000, 5000, 6000, 7000, 8000, 9000, 10000, 11000
for(TInt i=0; i!=appendcount;i++)
{
- Open(KTestFileOverwrite, EFalse);
+ OpenL(KTestFileOverwrite, EFalse);
WriteL(atestdata1);
- WriteNewLine();
+ WriteNewLineL();
WriteL(atestdata2);
- WriteNewLine();
+ WriteNewLineL();
Close();
}
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfoutputsanity.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfoutputsanity.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -71,7 +71,7 @@
if(BlockResult()==EPass)
{
- SetBlockResult(TestBaselineCsv());
+ SetBlockResult(TestBaselineCsvL());
}
return ETrue;
@@ -79,7 +79,7 @@
-TVerdict COutputCSVSanityWrapper::TestBaselineCsv()
+TVerdict COutputCSVSanityWrapper::TestBaselineCsvL()
{
//read a sanity test file
@@ -91,14 +91,14 @@
TInt size = 0;
//get the size of the reference file
#ifdef __WINSCW__
- TInt error = CsvFileSize(KReferenceWinscwCsvFile, size);
+ TInt error = CsvFileSizeL(KReferenceWinscwCsvFile, size);
#else
- TInt error = CsvFileSize(KReferenceCsvFile, size);
+ TInt error = CsvFileSizeL(KReferenceCsvFile, size);
#endif
if(error)
{
SetBlockResult(EFail);
- INFO_PRINTF2(_L("TestBaselineCsv, KReferenceCsvFile, test failed on with error code %d"), error);
+ INFO_PRINTF2(_L("TestBaselineCsvL, KReferenceCsvFile, test failed on with error code %d"), error);
}
//Set the size of the RBuf
csvReference.Create(size);
@@ -106,32 +106,32 @@
//Create csvGenerated
CCsvReader csvGenerated;
//get the size of the generated file
- error = CsvFileSize(KApiCSVFile, size);
+ error = CsvFileSizeL(KApiCSVFile, size);
if(error)
{
SetBlockResult(EFail);
- INFO_PRINTF2(_L("TestBaselineCsv, KApiCSVFile, test failed on with error code %d"), error);
+ INFO_PRINTF2(_L("TestBaselineCsvL, KApiCSVFile, test failed on with error code %d"), error);
}
//create the RBuf
csvGenerated.Create(size);
//Read the reference file into the RBuf
#ifdef __WINSCW__
- error = ReadCsvFile(KReferenceWinscwCsvFile, csvReference.Buffer());
+ error = ReadCsvFileL(KReferenceWinscwCsvFile, csvReference.Buffer());
#else
- error = ReadCsvFile(KReferenceCsvFile, csvReference.Buffer());
+ error = ReadCsvFileL(KReferenceCsvFile, csvReference.Buffer());
#endif
if(error)
{
SetBlockResult(EFail);
- INFO_PRINTF2(_L("TestBaselineCsv, ReadCsvFile(KReferenceCsvFile) failed on with error code %d"), error);
+ INFO_PRINTF2(_L("TestBaselineCsvL, ReadCsvFileL(KReferenceCsvFile) failed on with error code %d"), error);
}
//Read the generated file into the RBuf
- error = ReadCsvFile(KApiCSVFile, csvGenerated.Buffer());
+ error = ReadCsvFileL(KApiCSVFile, csvGenerated.Buffer());
if(error)
{
SetBlockResult(EFail);
- INFO_PRINTF2(_L("TestBaselineCsv, ReadCsvFile(KApiCSVFile) failed on with error code %d"), error);
+ INFO_PRINTF2(_L("TestBaselineCsvL, ReadCsvFileL(KApiCSVFile) failed on with error code %d"), error);
}
//compare the two files
@@ -164,7 +164,7 @@
}
-TInt COutputCSVSanityWrapper::CsvFileSize(const TDesC& aFilename, TInt& aSize)
+TInt COutputCSVSanityWrapper::CsvFileSizeL(const TDesC& aFilename, TInt& aSize)
{
RFs fsSession;
CleanupClosePushL(fsSession);
@@ -189,7 +189,7 @@
* The caller of the method owns the buffer
* Ie. this method allocates the buffer but the caller is responsible for destroying it.
*/
-TInt COutputCSVSanityWrapper::ReadCsvFile(const TDesC& aFilename, RBuf8& aBuffer)
+TInt COutputCSVSanityWrapper::ReadCsvFileL(const TDesC& aFilename, RBuf8& aBuffer)
{
RFs fsSession;
CleanupClosePushL(fsSession);
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfplugin.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfplugin.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -73,7 +73,7 @@
CPluginTests::CPluginTests()
{
/*Constructor*/
- iPluginTestResult = new(ELeave) CPluginTestResult;
+
__CREATE_LOG(false);
}
@@ -102,7 +102,10 @@
//const COutputPluginTestResult* COutputPluginTests::DoTestL(const TPtrC8& aPluginName, const TPluginConfiguration& aPluginSetting, const TInt& aTestDataSize, const TInt& aTestIteration)
{
//TTraceTester tracecall;
-
+ if (iPluginTestResult == NULL)
+ {
+ iPluginTestResult = new(ELeave) CPluginTestResult;
+ }
TInt numberOfTraces=aPluginRunConfig.iDataSize/16; //update magic number to a size of (trace)/bytes
//do a baseline to remove loop effects for throughput tests?????
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfresultscollector.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfresultscollector.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -85,10 +85,10 @@
//create a csvgenerator class
CUptCsvGenerator csvgenerator;
- csvgenerator.Open(aFileName,aAppend);
+ csvgenerator.OpenL(aFileName,aAppend);
//call writeheader to write the relevent test column header for the csv file,
- csvgenerator.WriteHeader(aTestType);
+ csvgenerator.WriteHeaderL(aTestType);
if(aTestType==0)
{
@@ -125,7 +125,7 @@
// __TEST_LOGNUM(iApiTest.Count());
//call write newline to write a new line in preparation for the next test object
- csvgenerator.WriteNewLine();
+ csvgenerator.WriteNewLineL();
//clear out the RArray object in preparation for the next test result object
testdataarray.Reset();
@@ -161,7 +161,7 @@
//call write newline to write a new line in preparation for the next test object
- csvgenerator.WriteNewLine();
+ csvgenerator.WriteNewLineL();
//clear out the RArray objects in preparation for the next test result object
initialpluginarray.Reset();
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfsanity.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perfsanity.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -102,7 +102,7 @@
if(BlockResult()==EPass)
{
- SetBlockResult(TestTimer());
+ SetBlockResult(TestTimerL());
}
//run this no matter if its failed or not..., just to get some statistics out.
@@ -110,14 +110,14 @@
//temporarily tagged out this test as it is causing a test timeout
//can be reinstated as soon as the device driver has been fully implemented
- //SanityTestTimedUtrace();
+ //SanityTestTimedUtraceL();
return ETrue;
}
-TVerdict CPerformanceSanityWrapper::TestTimer()
+TVerdict CPerformanceSanityWrapper::TestTimerL()
{
INFO_PRINTF1(_L("Testing User side timer functions"));
TBool passed = EFalse;
@@ -128,7 +128,7 @@
//test CUptTimer class
TTestTimer timer;
TUint32 userTime = 0;
- passed = timer.TestUserTimer(userTime);
+ passed = timer.TestUserTimerL(userTime);
INFO_PRINTF1(_L("Testing User side timer functions #2"));
if(!passed)
@@ -186,16 +186,16 @@
return BlockResult();
}
-TBool CPerformanceSanityWrapper::SanityTestTimedUtrace()
+TBool CPerformanceSanityWrapper::SanityTestTimedUtraceL()
{
TTestTimer timer;
TUint32 userSanityTime = 0;
TUint32 userSanityLongTime = 0;
TUint32 userUtraceTime = 0;
- timer.TestUserTimer(userSanityTime);
- timer.TestUserLongTimer(userSanityLongTime);
- timer.TestUTraceUserTimer(userUtraceTime);
+ timer.TestUserTimerL(userSanityTime);
+ timer.TestUserLongTimerL(userSanityLongTime);
+ timer.TestUTraceUserTimerL(userUtraceTime);
TUint32 kernelSanityTime = 0;
// TUint32 kernelSanityLongTime = 0;
@@ -226,8 +226,8 @@
//I want to find out what the variation is, is it static 0.5us, or is it 10% variable, or what?
for(TInt i = 0; i < iters; i++)
{
- timer.TestUserTimer(user[i]);
- timer.TestUserLongTimer(ulong[i]);
+ timer.TestUserTimerL(user[i]);
+ timer.TestUserLongTimerL(ulong[i]);
utracedriver.SanityTestTimer(kernel[i]);
//utracedriver.SanityTestLongTimer(klong[i]);
}
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perftracetester.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/src/te_perftracetester.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -66,7 +66,7 @@
TUint32 callResults[KNumberOfTraceCallIterations];
for(TInt i = 0; i < KNumberOfTraceCallIterations; i++)
{
- error = TimeTraceCall(aApiRunConfig, aApiRunResults);
+ error = TimeTraceCallL(aApiRunConfig, aApiRunResults);
callResults[i] = aApiRunResults.iApiTraceTime;
}
TUint32 total = 0;
@@ -76,7 +76,7 @@
return error;
}
-TInt TUptTraceTester::TimeTraceCall(const TApiRunConfig& aApiRunConfig, TApiRunResults& aApiRunResults)
+TInt TUptTraceTester::TimeTraceCallL(const TApiRunConfig& aApiRunConfig, TApiRunResults& aApiRunResults)
{
TInt error = KErrNone;
if(TUptTraceCalls::IsKernelTrace(aApiRunConfig.iApiId))
@@ -91,13 +91,13 @@
}
else
{
- error = TimeUsersideTraceCalls(aApiRunConfig, aApiRunResults);
+ error = TimeUsersideTraceCallsL(aApiRunConfig, aApiRunResults);
}
return error;
}
-TInt TUptTraceTester::TimeUsersideTraceCalls(const TApiRunConfig& aApiRunConfig, TApiRunResults& aApiRunResults) //pass the configuration here
+TInt TUptTraceTester::TimeUsersideTraceCallsL(const TApiRunConfig& aApiRunConfig, TApiRunResults& aApiRunResults) //pass the configuration here
{
aApiRunResults.iTimeCount = 0;
CUptTimer timer;
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_default.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_default.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_perf_default.script
//! @SYMScriptTestEnvironment TEF
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_perf_guidelines.script
//! @SYMScriptTestEnvironment TEF
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines_disabled.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines_disabled.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_perf_guidelines_disabled.script
//! @SYMScriptTestEnvironment TEF
@@ -38,7 +38,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled out, GroupID filtering on, Component ID Filtering on, GroupID filter matches trace point, Component ID filter matches trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes..
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_disabled \testdata\configs\te_perf_gon_con_gmatch_cmatch.ini
@@ -63,7 +63,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled out, GroupID filtering on, Component ID Filtering on, GroupID filter matches trace point, Component ID filter doesn't match trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_disabled \testdata\configs\te_perf_gon_con_gmatch_cmismatch.ini
@@ -88,7 +88,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled out, GroupID filtering on, Component ID Filtering on, GroupID filter doesn't match trace point, Component ID filter matches trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_disabled \testdata\configs\te_perf_gon_con_gmismatch_cmatch.ini
@@ -113,7 +113,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled out, GroupID filtering on, Component ID Filtering off, GroupID filter matches trace point, Component ID filter doesn't match trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_disabled \testdata\configs\te_perf_gon_coff_gmatch_cmismatch.ini
@@ -138,7 +138,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled out, GroupID filtering on, Component ID Filtering off, GroupID filter doesn't match trace point, Component ID filter matches trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_disabled \testdata\configs\te_perf_gon_coff_gmismatch_cmatch.ini
@@ -163,7 +163,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled out, GroupID filtering off, Component ID Filtering on, GroupID filter doesn't match trace point, Component ID filter matches trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_disabled \testdata\configs\te_perf_goff_con_gmismatch_cmatch.ini
@@ -188,7 +188,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled out, GroupID filtering off, Component ID Filtering on, GroupID filter matches trace point, Component ID filter doesn't match trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_disabled \testdata\configs\te_perf_goff_con_gmatch_cmismatch.ini
@@ -213,7 +213,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled out, GroupID filtering off, Component ID Filtering off, GroupID filter matches trace point, Component ID filter doesn't match trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_disabled \testdata\configs\te_perf_goff_coff_gmatch_cmatch.ini
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines_enabled.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_guidelines_enabled.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_perf_guidelines_enabled.script
//! @SYMScriptTestEnvironment TEF
@@ -38,7 +38,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled in, GroupID filtering on, Component ID Filtering on, GroupID filter matches trace point, Component ID filter matches trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes..
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_enabled \testdata\configs\te_perf_gon_con_gmatch_cmatch.ini
@@ -63,7 +63,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled in, GroupID filtering on, Component ID Filtering on, GroupID filter matches trace point, Component ID filter doesn't match trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_enabled \testdata\configs\te_perf_gon_con_gmatch_cmismatch.ini
@@ -88,7 +88,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled in, GroupID filtering on, Component ID Filtering on, GroupID filter doesn't match trace point, Component ID filter matches trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_enabled \testdata\configs\te_perf_gon_con_gmismatch_cmatch.ini
@@ -113,7 +113,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled in, GroupID filtering on, Component ID Filtering off, GroupID filter matches trace point, Component ID filter doesn't match trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_enabled \testdata\configs\te_perf_gon_coff_gmatch_cmismatch.ini
@@ -138,7 +138,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled in, GroupID filtering on, Component ID Filtering off, GroupID filter doesn't match trace point, Component ID filter matches trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_enabled \testdata\configs\te_perf_gon_coff_gmismatch_cmatch.ini
@@ -163,7 +163,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled in, GroupID filtering off, Component ID Filtering on, GroupID filter doesn't match trace point, Component ID filter matches trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_enabled \testdata\configs\te_perf_goff_con_gmismatch_cmatch.ini
@@ -188,7 +188,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled in, GroupID filtering off, Component ID Filtering on, GroupID filter matches trace point, Component ID filter doesn't match trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_enabled \testdata\configs\te_perf_goff_con_gmatch_cmismatch.ini
@@ -213,7 +213,7 @@
//! @SYMTestActions Calculate the typical and minimum times taken for trace APIs (compiled in, GroupID filtering off, Component ID Filtering off, GroupID filter matches trace point, Component ID filter doesn't match trace point) and run configs specified in the te_perf_default.ini config file. Output to te_apitestresults.csv along with its stack usage.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs, other than expected by source code changes.
//! @SYMTestType ST
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 10000 te_ostv2integsuite_enabled \testdata\configs\te_perf_goff_coff_gmatch_cmatch.ini
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_outputcsvsanity.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_outputcsvsanity.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_perf_outputcsvsanity.script
//! @SYMScriptTestEnvironment TEF
@@ -35,7 +35,7 @@
//! @SYMTestActions Compares a baseline.csv file included in the reference subfolder of the integration tests with that output from a default performance test ru n and return a fail if any of the column elements>10% from that expected. All elements compared and reported back with associated discrepancy
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs.
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 100 te_ostv2integsuite_enabled \testdata\configs\te_perf_outputcsvsanity.ini
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_perf_sanity.script
//! @SYMScriptTestEnvironment TEF
@@ -29,7 +29,7 @@
//! @SYMTestActions Compares lauterbach measured time for foo() with that generated in the returns a fail it is>10% from that expected.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the timer resolution figures from hardware measurement.
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12122 12761
START_TEST_BLOCK 100 te_ostv2integsuite_enabled \testdata\configs\te_perf_sanity.ini
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity_disabled.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity_disabled.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_perf_sanity_disabled.script
//! @SYMScriptTestEnvironment TEF
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity_enabled.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_sanity_enabled.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_perf_sanity_enabled.script
//! @SYMScriptTestEnvironment TEF
--- a/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_sanityloop.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/te_ostv2integsuite_performance/testdata/scripts/te_perf_sanityloop.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName te_perf_sanityloop.script
//! @SYMScriptTestEnvironment TEF
--- a/traceservices/tracefw/integ_test/ost/TEF/tracecontroltestplugin/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/tracecontroltestplugin/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -13,18 +13,11 @@
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
PRJ_PLATFORMS
DEFAULT
-PRJ_EXPORTS
-
PRJ_TESTEXPORTS
-//iby's
-te_tracecontrol_testplugin.iby /epoc32/rom/include/te_tracecontrol_testplugin.iby
+te_tracecontrol_testplugin.iby /epoc32/rom/include/te_tracecontrol_testplugin.iby
PRJ_TESTMMPFILES
-te_tracecontrol_testplugin.mmp
+te_tracecontrol_testplugin.mmp manual
--- a/traceservices/tracefw/integ_test/ost/TEF/tracecontroltestplugin/group/te_tracecontrol_testplugin.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/tracecontroltestplugin/group/te_tracecontrol_testplugin.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -14,19 +14,15 @@
// Te_tracecontrol_FilePlugin.dll ULogger & Framework File Test plug-in
//
-
-
-/**
- @file te_tracecontroltestplugin.mmp
- @internalTechnology
-*/
-
TARGET te_tracecontrol_testplugin.dll
TARGETTYPE PLUGIN
UID 0x10009D8D 0x10287231
VENDORID 0x70000001
+CAPABILITY CommDD NetworkControl LocalServices ProtServ NetworkServices
-CAPABILITY CommDD NetworkControl LocalServices ProtServ NetworkServices
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc/
SOURCEPATH ../src/
SOURCE te_tracecontroltestplugin.cpp
@@ -36,12 +32,10 @@
TARGET te_tracecontrol_testplugin.rsc
end
-
-USERINCLUDE ../inc/
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/ecom
-SYSTEMINCLUDE /epoc32/include/platform
-
-LIBRARY euser.lib efsrv.lib c32.lib ecom.lib
+LIBRARY euser.lib
+LIBRARY efsrv.lib
+LIBRARY c32.lib
+LIBRARY ecom.lib
SMPSAFE
+epocallowdlldata
--- a/traceservices/tracefw/integ_test/ost/TEF/tracecontroltestplugin/resource/10287231.rss Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/tracecontroltestplugin/resource/10287231.rss Tue Aug 31 16:57:14 2010 +0300
@@ -14,7 +14,7 @@
// 10287231.RSS -- for outfrwkinterface definitions
//
-#include "registryinfo.rh"
+#include <ecom/registryinfo.rh>
RESOURCE REGISTRY_INFO r_registry
{
--- a/traceservices/tracefw/integ_test/ost/TEF/tracecontroltestplugin/src/te_tracecontroltestplugin.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/tracecontroltestplugin/src/te_tracecontroltestplugin.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -22,7 +22,8 @@
#include <e32std.h>
#include <e32debug.h>
-#include <implementationproxy.h>
+#include <ecom/implementationproxy.h>
+
#include "te_tracecontroltestplugin.h"
#if defined(__TEST_LIGHTLOGGER_ENABLED)
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/integ_test/ost/TEF/traces/OstTraceDefinitions.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,7 @@
+#ifndef __OSTTRACEDEFINITIONS_H__
+#define __OSTTRACEDEFINITIONS_H__
+// OST_TRACE_COMPILER_IN_USE flag has been added by Trace Compiler
+// REMOVE BEFORE CHECK-IN TO VERSION CONTROL
+//#define OST_TRACE_COMPILER_IN_USE
+#include <opensystemtrace.h>
+#endif
--- a/traceservices/tracefw/integ_test/ost/TEF/traces/fixed_id.definitions Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/traces/fixed_id.definitions Tue Aug 31 16:57:14 2010 +0300
@@ -1,18 +1,22 @@
#Fixed group and trace id definitions. If this file is removed, the identifiers are rebuilt.
[GROUP]TEST_GROUP=0xde
-[GROUP]TRACE_DEBUG=0x89
[GROUP]TRACE_DUMP=0x89
[GROUP]TRACE_FATAL=0x81
[GROUP]TRACE_FLOW=0x8a
+[GROUP]TRACE_NORMAL=0x86
[GROUP]TRACE_PERFORMANCE=0x8b
[GROUP]TRACE_STATE=0x87
[GROUP]USER_DEFINED_GID_1=0xdf
[GROUP]USER_DEFINED_GID_2=0xe0
[TRACE]TEST_GROUP[0xDE]_OstTesting=0x1
-[TRACE]TRACE_DEBUG[0x89]_TEST_OSTTRACEWRAPPER2=0x1
-[TRACE]TRACE_DEBUG[0x89]_TEST_OSTTRACEWRAPPER5=0x2
-[TRACE]TRACE_DUMP[0x89]_TEST_OSTTRACEWRAPPER3=0x1
-[TRACE]TRACE_DUMP[0x89]_TEST_OSTTRACEWRAPPER6=0x2
+[TRACE]TRACE_DUMP[0x89]_TEST_OSTTRACEWRAPPER2=0x1
+[TRACE]TRACE_DUMP[0x89]_TEST_OSTTRACEWRAPPER2w=0x5
+[TRACE]TRACE_DUMP[0x89]_TEST_OSTTRACEWRAPPER3=0x2
+[TRACE]TRACE_DUMP[0x89]_TEST_OSTTRACEWRAPPER3w=0x6
+[TRACE]TRACE_DUMP[0x89]_TEST_OSTTRACEWRAPPER5=0x3
+[TRACE]TRACE_DUMP[0x89]_TEST_OSTTRACEWRAPPER5w=0x7
+[TRACE]TRACE_DUMP[0x89]_TEST_OSTTRACEWRAPPER6=0x4
+[TRACE]TRACE_DUMP[0x89]_TEST_OSTTRACEWRAPPER6w=0x8
[TRACE]TRACE_FATAL[0x81]_TEST_OSTTRACE0=0x9
[TRACE]TRACE_FATAL[0x81]_TEST_OSTTRACE1=0xa
[TRACE]TRACE_FATAL[0x81]_TEST_OSTTRACEDATA=0xb
@@ -24,7 +28,9 @@
[TRACE]TRACE_FATAL[0x81]_TEST_OSTTRACEEXT4=0xf
[TRACE]TRACE_FATAL[0x81]_TEST_OSTTRACEEXT5=0x10
[TRACE]TRACE_FATAL[0x81]_TEST_OSTTRACEWRAPPER1=0x13
+[TRACE]TRACE_FATAL[0x81]_TEST_OSTTRACEWRAPPER1w=0x15
[TRACE]TRACE_FATAL[0x81]_TEST_OSTTRACEWRAPPER4=0x14
+[TRACE]TRACE_FATAL[0x81]_TEST_OSTTRACEWRAPPER4w=0x16
[TRACE]TRACE_FATAL[0x81]_TEST_OstTraceDef0=0x1
[TRACE]TRACE_FATAL[0x81]_TEST_OstTraceDef1=0x2
[TRACE]TRACE_FATAL[0x81]_TEST_OstTraceDefData=0x3
@@ -33,16 +39,29 @@
[TRACE]TRACE_FATAL[0x81]_TEST_OstTraceDefExt3=0x6
[TRACE]TRACE_FATAL[0x81]_TEST_OstTraceDefExt4=0x7
[TRACE]TRACE_FATAL[0x81]_TEST_OstTraceDefExt5=0x8
-[TRACE]TRACE_FLOW[0x8A]_TEST_OSTTRACEFUNCTIONEXIT1=0x5
-[TRACE]TRACE_FLOW[0x8A]_TEST_OSTTRACEFUNCTIONEXITEXT=0x6
-[TRACE]TRACE_FLOW[0x8A]_TEST_OSTTraceFunctionalityEntry0=0x1
-[TRACE]TRACE_FLOW[0x8A]_TEST_OSTTraceFunctionalityEntry1=0x2
-[TRACE]TRACE_FLOW[0x8A]_TEST_OSTTraceFunctionalityExt=0x3
-[TRACE]TRACE_FLOW[0x8A]_TEST_OstTraceFunctionExit0=0x4
+[TRACE]TRACE_FLOW[0x8A]_CTESTCTOR_INITLIST_TRACE=0x1
+[TRACE]TRACE_FLOW[0x8A]_CTESTCTOR_NO_INITLIST_TRACE=0x2
+[TRACE]TRACE_FLOW[0x8A]_TEST_OSTTRACEFUNCTIONEXIT1=0x7
+[TRACE]TRACE_FLOW[0x8A]_TEST_OSTTRACEFUNCTIONEXITEXT=0x8
+[TRACE]TRACE_FLOW[0x8A]_TEST_OSTTraceFunctionalityEntry0=0x3
+[TRACE]TRACE_FLOW[0x8A]_TEST_OSTTraceFunctionalityEntry1=0x4
+[TRACE]TRACE_FLOW[0x8A]_TEST_OSTTraceFunctionalityExt=0x5
+[TRACE]TRACE_FLOW[0x8A]_TEST_OstTraceFunctionExit0=0x6
+[TRACE]TRACE_NORMAL[0x86]_TEST_OSTTRACEWRAPPER1m=0x1
+[TRACE]TRACE_NORMAL[0x86]_TEST_OSTTRACEWRAPPER2m=0x2
+[TRACE]TRACE_NORMAL[0x86]_TEST_OSTTRACEWRAPPER3m=0x3
+[TRACE]TRACE_NORMAL[0x86]_TEST_OSTTRACEWRAPPER4m=0x4
+[TRACE]TRACE_NORMAL[0x86]_TEST_OSTTRACEWRAPPER5m=0x5
+[TRACE]TRACE_NORMAL[0x86]_TEST_OSTTRACEWRAPPER6m=0x6
+[TRACE]TRACE_NORMAL[0x86]_TEST_OSTTRACEWRAPPER7m=0x7
+[TRACE]TRACE_NORMAL[0x86]_TEST_OSTTRACEWRAPPER8m=0x8
+[TRACE]TRACE_NORMAL[0x86]_TEST_OSTTRACEWRAPPER9m=0x9
[TRACE]TRACE_PERFORMANCE[0x8B]_TEST_OSTTRACEEVENTSTART0=0x1
[TRACE]TRACE_PERFORMANCE[0x8B]_TEST_OSTTRACEEVENTSTART1=0x2
[TRACE]TRACE_PERFORMANCE[0x8B]_TEST_OSTTRACEEVENTSTOP=0x3
[TRACE]TRACE_STATE[0x87]_TEST_OSTTRACESTATE0=0x1
[TRACE]TRACE_STATE[0x87]_TEST_OSTTRACESTATE1=0x2
[TRACE]USER_DEFINED_GID_1[0xDF]_TEST_OSTTRACEWRAPPER7=0x1
+[TRACE]USER_DEFINED_GID_1[0xDF]_TEST_OSTTRACEWRAPPER7w=0x2
[TRACE]USER_DEFINED_GID_2[0xE0]_TEST_OSTTRACEWRAPPER8=0x1
+[TRACE]USER_DEFINED_GID_2[0xE0]_TEST_OSTTRACEWRAPPER8w=0x2
--- a/traceservices/tracefw/integ_test/ost/TEF/traces/te_advancedfilteringTraces.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/traces/te_advancedfilteringTraces.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Created by TraceCompiler 1.3.1
+// Created by TraceCompiler 2.1.4
// DO NOT EDIT, CHANGES WILL BE LOST
#ifndef __TE_ADVANCEDFILTERINGTRACES_H__
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/integ_test/ost/TEF/traces/te_ctorTraces.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,90 @@
+// Created by TraceCompiler 2.1.4
+// DO NOT EDIT, CHANGES WILL BE LOST
+
+#ifndef __TE_CTORTRACES_H__
+#define __TE_CTORTRACES_H__
+
+#define KOstTraceComponentID 0x1028722e
+
+#define CTESTCTOR_INITLIST_TRACE 0x8a0001, ( TUint )( aArg1 ), ( TUint )( aArg2 )
+#define CTESTCTOR_NO_INITLIST_TRACE 0x8a0002, ( TUint )( aArg1 )
+
+
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint aParam1, TUint aParam2, TUint aParam3 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 12 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam3;
+ ptr += sizeof ( TUint );
+ ptr -= 12;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
+ }
+ return retval;
+ }
+
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint32 aParam1, TUint32 aParam2, TUint32 aParam3 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 12 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam3;
+ ptr += sizeof ( TUint );
+ ptr -= 12;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
+ }
+ return retval;
+ }
+
+
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint aParam1, TUint aParam2 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 8 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ ptr -= 8;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
+ }
+ return retval;
+ }
+
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint32 aParam1, TUint32 aParam2 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 8 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ ptr -= 8;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
+ }
+ return retval;
+ }
+
+
+#endif
+
+// End of file
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/integ_test/ost/TEF/traces/te_ctor_disabledTraces.h Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,90 @@
+// Created by TraceCompiler 2.1.4
+// DO NOT EDIT, CHANGES WILL BE LOST
+
+#ifndef __TE_CTOR_DISABLEDTRACES_H__
+#define __TE_CTOR_DISABLEDTRACES_H__
+
+#define KOstTraceComponentID 0x1028722f
+
+#define CTESTCTOR_INITLIST_TRACE 0x8a0001, ( TUint )( aArg1 ), ( TUint )( aArg2 )
+#define CTESTCTOR_NO_INITLIST_TRACE 0x8a0002, ( TUint )( aArg1 )
+
+
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint aParam1, TUint aParam2, TUint aParam3 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 12 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam3;
+ ptr += sizeof ( TUint );
+ ptr -= 12;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
+ }
+ return retval;
+ }
+
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint32 aParam1, TUint32 aParam2, TUint32 aParam3 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 12 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam3;
+ ptr += sizeof ( TUint );
+ ptr -= 12;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
+ }
+ return retval;
+ }
+
+
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint aParam1, TUint aParam2 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 8 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ ptr -= 8;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
+ }
+ return retval;
+ }
+
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint32 aParam1, TUint32 aParam2 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 8 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ ptr -= 8;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
+ }
+ return retval;
+ }
+
+
+#endif
+
+// End of file
+
--- a/traceservices/tracefw/integ_test/ost/TEF/traces/te_instrumentationpoints_disabledTraces.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/traces/te_instrumentationpoints_disabledTraces.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Created by TraceCompiler 1.3.1
+// Created by TraceCompiler 2.1.4
// DO NOT EDIT, CHANGES WILL BE LOST
#ifndef __TE_INSTRUMENTATIONPOINTS_DISABLEDTRACES_H__
@@ -6,6 +6,12 @@
#define KOstTraceComponentID 0x1028722f
+#define TEST_OSTTraceFunctionalityEntry0 0x8a0003
+#define TEST_OSTTraceFunctionalityEntry1 0x8a0004
+#define TEST_OSTTraceFunctionalityExt 0x8a0005, ( TUint )&( aApiRunConfig ), ( TUint )&( aApiRunResults )
+#define TEST_OstTraceFunctionExit0 0x8a0006
+#define TEST_OSTTRACEFUNCTIONEXIT1 0x8a0007
+#define TEST_OSTTRACEFUNCTIONEXITEXT 0x8a0008
#define TEST_OstTraceDef0 0x810001
#define TEST_OstTraceDef1 0x810002
#define TEST_OstTraceDefData 0x810003
@@ -24,12 +30,6 @@
#define TEST_OSTTRACEEXT5 0x810010
#define TEST_OSTTRACEDATA96 0x810011
#define TEST_OSTTRACEDATA1000 0x810012
-#define TEST_OSTTraceFunctionalityEntry0 0x8a0001
-#define TEST_OSTTraceFunctionalityEntry1 0x8a0002
-#define TEST_OSTTraceFunctionalityExt 0x8a0003, ( TUint )&( aApiRunConfig ), ( TUint )&( aApiRunResults )
-#define TEST_OstTraceFunctionExit0 0x8a0004
-#define TEST_OSTTRACEFUNCTIONEXIT1 0x8a0005
-#define TEST_OSTTRACEFUNCTIONEXITEXT 0x8a0006
#define TEST_OSTTRACEEVENTSTART0 0x8b0001
#define TEST_OSTTRACEEVENTSTART1 0x8b0002
#define TEST_OSTTRACEEVENTSTOP 0x8b0003
@@ -37,6 +37,80 @@
#define TEST_OSTTRACESTATE1 0x870002
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint aParam1, TUint aParam2, TUint aParam3 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 12 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam3;
+ ptr += sizeof ( TUint );
+ ptr -= 12;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
+ }
+ return retval;
+ }
+
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint32 aParam1, TUint32 aParam2, TUint32 aParam3 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 12 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam3;
+ ptr += sizeof ( TUint );
+ ptr -= 12;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
+ }
+ return retval;
+ }
+
+
+inline TBool OstTraceGen2( TUint32 aTraceID, TUint aParam1, TInt aParam2 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 8 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TInt* )ptr ) = aParam2;
+ ptr += sizeof ( TInt );
+ ptr -= 8;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
+ }
+ return retval;
+ }
+
+inline TBool OstTraceGen2( TUint32 aTraceID, TUint32 aParam1, TInt32 aParam2 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 8 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TInt* )ptr ) = aParam2;
+ ptr += sizeof ( TInt );
+ ptr -= 8;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
+ }
+ return retval;
+ }
+
+
inline TBool OstTraceGen1( TUint32 aTraceID, const TDesC8& aParam1 )
{
TBool retval;
@@ -259,80 +333,6 @@
}
-inline TBool OstTraceGenExt( TUint32 aTraceID, TUint aParam1, TUint aParam2, TUint aParam3 )
- {
- TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
- if ( retval )
- {
- TUint8 data[ 12 ];
- TUint8* ptr = data;
- *( ( TUint* )ptr ) = aParam1;
- ptr += sizeof ( TUint );
- *( ( TUint* )ptr ) = aParam2;
- ptr += sizeof ( TUint );
- *( ( TUint* )ptr ) = aParam3;
- ptr += sizeof ( TUint );
- ptr -= 12;
- retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
- }
- return retval;
- }
-
-inline TBool OstTraceGenExt( TUint32 aTraceID, TUint32 aParam1, TUint32 aParam2, TUint32 aParam3 )
- {
- TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
- if ( retval )
- {
- TUint8 data[ 12 ];
- TUint8* ptr = data;
- *( ( TUint* )ptr ) = aParam1;
- ptr += sizeof ( TUint );
- *( ( TUint* )ptr ) = aParam2;
- ptr += sizeof ( TUint );
- *( ( TUint* )ptr ) = aParam3;
- ptr += sizeof ( TUint );
- ptr -= 12;
- retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
- }
- return retval;
- }
-
-
-inline TBool OstTraceGen2( TUint32 aTraceID, TUint aParam1, TInt aParam2 )
- {
- TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
- if ( retval )
- {
- TUint8 data[ 8 ];
- TUint8* ptr = data;
- *( ( TUint* )ptr ) = aParam1;
- ptr += sizeof ( TUint );
- *( ( TInt* )ptr ) = aParam2;
- ptr += sizeof ( TInt );
- ptr -= 8;
- retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
- }
- return retval;
- }
-
-inline TBool OstTraceGen2( TUint32 aTraceID, TUint32 aParam1, TInt32 aParam2 )
- {
- TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
- if ( retval )
- {
- TUint8 data[ 8 ];
- TUint8* ptr = data;
- *( ( TUint* )ptr ) = aParam1;
- ptr += sizeof ( TUint );
- *( ( TInt* )ptr ) = aParam2;
- ptr += sizeof ( TInt );
- ptr -= 8;
- retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
- }
- return retval;
- }
-
-
inline TBool OstTraceGen2( TUint32 aTraceID, TInt aParam1, TUint aParam2 )
{
TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
--- a/traceservices/tracefw/integ_test/ost/TEF/traces/te_instrumentationpoints_enabledTraces.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/traces/te_instrumentationpoints_enabledTraces.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Created by TraceCompiler 1.3.1
+// Created by TraceCompiler 2.1.4
// DO NOT EDIT, CHANGES WILL BE LOST
#ifndef __TE_INSTRUMENTATIONPOINTS_ENABLEDTRACES_H__
@@ -6,6 +6,12 @@
#define KOstTraceComponentID 0x1028722e
+#define TEST_OSTTraceFunctionalityEntry0 0x8a0003
+#define TEST_OSTTraceFunctionalityEntry1 0x8a0004
+#define TEST_OSTTraceFunctionalityExt 0x8a0005, ( TUint )&( aApiRunConfig ), ( TUint )&( aApiRunResults )
+#define TEST_OstTraceFunctionExit0 0x8a0006
+#define TEST_OSTTRACEFUNCTIONEXIT1 0x8a0007
+#define TEST_OSTTRACEFUNCTIONEXITEXT 0x8a0008
#define TEST_OstTraceDef0 0x810001
#define TEST_OstTraceDef1 0x810002
#define TEST_OstTraceDefData 0x810003
@@ -24,12 +30,6 @@
#define TEST_OSTTRACEEXT5 0x810010
#define TEST_OSTTRACEDATA96 0x810011
#define TEST_OSTTRACEDATA1000 0x810012
-#define TEST_OSTTraceFunctionalityEntry0 0x8a0001
-#define TEST_OSTTraceFunctionalityEntry1 0x8a0002
-#define TEST_OSTTraceFunctionalityExt 0x8a0003, ( TUint )&( aApiRunConfig ), ( TUint )&( aApiRunResults )
-#define TEST_OstTraceFunctionExit0 0x8a0004
-#define TEST_OSTTRACEFUNCTIONEXIT1 0x8a0005
-#define TEST_OSTTRACEFUNCTIONEXITEXT 0x8a0006
#define TEST_OSTTRACEEVENTSTART0 0x8b0001
#define TEST_OSTTRACEEVENTSTART1 0x8b0002
#define TEST_OSTTRACEEVENTSTOP 0x8b0003
@@ -37,6 +37,80 @@
#define TEST_OSTTRACESTATE1 0x870002
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint aParam1, TUint aParam2, TUint aParam3 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 12 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam3;
+ ptr += sizeof ( TUint );
+ ptr -= 12;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
+ }
+ return retval;
+ }
+
+inline TBool OstTraceGenExt( TUint32 aTraceID, TUint32 aParam1, TUint32 aParam2, TUint32 aParam3 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 12 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam2;
+ ptr += sizeof ( TUint );
+ *( ( TUint* )ptr ) = aParam3;
+ ptr += sizeof ( TUint );
+ ptr -= 12;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
+ }
+ return retval;
+ }
+
+
+inline TBool OstTraceGen2( TUint32 aTraceID, TUint aParam1, TInt aParam2 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 8 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TInt* )ptr ) = aParam2;
+ ptr += sizeof ( TInt );
+ ptr -= 8;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
+ }
+ return retval;
+ }
+
+inline TBool OstTraceGen2( TUint32 aTraceID, TUint32 aParam1, TInt32 aParam2 )
+ {
+ TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
+ if ( retval )
+ {
+ TUint8 data[ 8 ];
+ TUint8* ptr = data;
+ *( ( TUint* )ptr ) = aParam1;
+ ptr += sizeof ( TUint );
+ *( ( TInt* )ptr ) = aParam2;
+ ptr += sizeof ( TInt );
+ ptr -= 8;
+ retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
+ }
+ return retval;
+ }
+
+
inline TBool OstTraceGen1( TUint32 aTraceID, const TDesC8& aParam1 )
{
TBool retval;
@@ -259,80 +333,6 @@
}
-inline TBool OstTraceGenExt( TUint32 aTraceID, TUint aParam1, TUint aParam2, TUint aParam3 )
- {
- TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
- if ( retval )
- {
- TUint8 data[ 12 ];
- TUint8* ptr = data;
- *( ( TUint* )ptr ) = aParam1;
- ptr += sizeof ( TUint );
- *( ( TUint* )ptr ) = aParam2;
- ptr += sizeof ( TUint );
- *( ( TUint* )ptr ) = aParam3;
- ptr += sizeof ( TUint );
- ptr -= 12;
- retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
- }
- return retval;
- }
-
-inline TBool OstTraceGenExt( TUint32 aTraceID, TUint32 aParam1, TUint32 aParam2, TUint32 aParam3 )
- {
- TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
- if ( retval )
- {
- TUint8 data[ 12 ];
- TUint8* ptr = data;
- *( ( TUint* )ptr ) = aParam1;
- ptr += sizeof ( TUint );
- *( ( TUint* )ptr ) = aParam2;
- ptr += sizeof ( TUint );
- *( ( TUint* )ptr ) = aParam3;
- ptr += sizeof ( TUint );
- ptr -= 12;
- retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 12 );
- }
- return retval;
- }
-
-
-inline TBool OstTraceGen2( TUint32 aTraceID, TUint aParam1, TInt aParam2 )
- {
- TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
- if ( retval )
- {
- TUint8 data[ 8 ];
- TUint8* ptr = data;
- *( ( TUint* )ptr ) = aParam1;
- ptr += sizeof ( TUint );
- *( ( TInt* )ptr ) = aParam2;
- ptr += sizeof ( TInt );
- ptr -= 8;
- retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
- }
- return retval;
- }
-
-inline TBool OstTraceGen2( TUint32 aTraceID, TUint32 aParam1, TInt32 aParam2 )
- {
- TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
- if ( retval )
- {
- TUint8 data[ 8 ];
- TUint8* ptr = data;
- *( ( TUint* )ptr ) = aParam1;
- ptr += sizeof ( TUint );
- *( ( TInt* )ptr ) = aParam2;
- ptr += sizeof ( TInt );
- ptr -= 8;
- retval = OstSendNBytes( EXTRACT_GROUP_ID(aTraceID), EOstTrace, KOstTraceComponentID, aTraceID, ptr, 8 );
- }
- return retval;
- }
-
-
inline TBool OstTraceGen2( TUint32 aTraceID, TInt aParam1, TUint aParam2 )
{
TBool retval = BTraceFiltered8( EXTRACT_GROUP_ID(aTraceID), EOstTraceActivationQuery, KOstTraceComponentID, aTraceID );
--- a/traceservices/tracefw/integ_test/ost/TEF/traces/te_ostv2tracetestwrapperTraces.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ost/TEF/traces/te_ostv2tracetestwrapperTraces.h Tue Aug 31 16:57:14 2010 +0300
@@ -1,10 +1,10 @@
-// Created by TraceCompiler 2.1.0
+// Created by TraceCompiler 2.1.4
// DO NOT EDIT, CHANGES WILL BE LOST
#ifndef __TE_OSTV2TRACETESTWRAPPERTRACES_H__
#define __TE_OSTV2TRACETESTWRAPPERTRACES_H__
-#define KOstTraceComponentID 0x1028722e
+#define KOstTraceComponentID 0x1028722f
#define TEST_OSTTRACEWRAPPER1 0x810013
#define TEST_OSTTRACEWRAPPER4 0x810014
@@ -22,6 +22,15 @@
#define TEST_OSTTRACEWRAPPER7w 0xdf0002
#define TEST_OSTTRACEWRAPPER8 0xe00001
#define TEST_OSTTRACEWRAPPER8w 0xe00002
+#define TEST_OSTTRACEWRAPPER1m 0x860001
+#define TEST_OSTTRACEWRAPPER2m 0x860002
+#define TEST_OSTTRACEWRAPPER3m 0x860003
+#define TEST_OSTTRACEWRAPPER4m 0x860004
+#define TEST_OSTTRACEWRAPPER5m 0x860005
+#define TEST_OSTTRACEWRAPPER6m 0x860006
+#define TEST_OSTTRACEWRAPPER7m 0x860007
+#define TEST_OSTTRACEWRAPPER8m 0x860008
+#define TEST_OSTTRACEWRAPPER9m 0x860009
#endif
--- a/traceservices/tracefw/integ_test/ulogger/TEF/device-driver/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/device-driver/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -12,10 +12,6 @@
//
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
PRJ_TESTMMPFILES
//usbc.mmp
--- a/traceservices/tracefw/integ_test/ulogger/TEF/device-driver/group/usbc.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/device-driver/group/usbc.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -17,22 +17,24 @@
#include "../../kernel/kern_ext.mmh"
-systeminclude ../../include/drivers
-systeminclude \epoc32\include\ulogger_integrationtest
+target usbc.ldd
+targettype ldd
+uid 0 0x101F8928
+VENDORID 0x70000001
+capability all
+
+OS_LAYER_SYSTEMINCLUDE
-target usbc.ldd
-targettype ldd
-source d_usbc.cpp usbdma.cpp //te_utracecmds.cpp#
-sourcepath \epoc32\include\ulogger_integrationtest
-source te_utracecmds.cpp
-library ekern.lib usbcc.lib
-epocallowdlldata
+sourcepath ..\src
+source d_usbc.cpp
+source usbdma.cpp
+
+sourcepath ..\..\te_ulogger\src
+source te_utracecmds.cpp
+
+library ekern.lib
+library usbcc.lib
MACRO SYMBIAN_TRACE_ENABLE
-
-uid 0 0x101F8928
-VENDORID 0x70000001
-capability all
-
SMPSAFE
--- a/traceservices/tracefw/integ_test/ulogger/TEF/device-driver/src/d_usbc.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/device-driver/src/d_usbc.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -278,9 +278,9 @@
}
if (id < 0)
{
- // DoRequest
+ // DoRequestL
TRequestStatus* pS = (TRequestStatus*) m.Ptr0();
- DoRequest(~id, pS, m.Ptr1(), m.Ptr2());
+ DoRequestL(~id, pS, m.Ptr1(), m.Ptr2());
m.Complete(KErrNone, ETrue);
}
else
@@ -314,10 +314,10 @@
}
// Asynchronous requests - overriding pure virtual
//
-void DLddUsbcChannel::DoRequest(TInt aReqNo, TRequestStatus* aStatus, TAny* a1, TAny* a2)
+void DLddUsbcChannel::DoRequestL(TInt aReqNo, TRequestStatus* aStatus, TAny* a1, TAny* a2)
{
// Check on request status
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest 0x%08x", aReqNo));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL 0x%08x", aReqNo));
if (aReqNo <= KUsbcMaxRequests)
{
TInt r = KErrNone;
@@ -442,7 +442,7 @@
// ep0 requests
if (!(iValidInterface || iOwnsDeviceControl))
{
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest rejected: not configured (Ep0)"));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL rejected: not configured (Ep0)"));
r = KErrUsbInterfaceNotReady;
goto exit;
}
@@ -454,7 +454,7 @@
iDeviceState == EUsbcDeviceStateSuspended))
)
{
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest rejected not configured (Ep %d)", aEndpointNum));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL rejected not configured (Ep %d)", aEndpointNum));
r = KErrUsbInterfaceNotReady;
goto exit;
}
@@ -462,7 +462,7 @@
if (!ValidEndpoint(aEndpointNum))
{
- //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequest Read: in error complete"));
+ //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequestL Read: in error complete"));
r = KErrUsbEpNotInInterface;
goto exit;
}
@@ -481,13 +481,13 @@
pEndpoint = iEndpoint[aEndpointNum];
if (!pEndpoint)
{
- //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequest Read: in error complete"));
+ //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequestL Read: in error complete"));
r = KErrUsbEpNotInInterface;
goto exit;
}
pEndpointInfo = pEndpoint->EndpointInfo();
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest %d", aEndpointNum));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL %d", aEndpointNum));
switch (pTfr->iTransferType)
{
@@ -497,7 +497,7 @@
case ETransferTypeReadUntilShort:
case ETransferTypeReadOneOrMore:
{
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest Read"));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL Read"));
if (pEndpoint->iDmaBuffers->RxIsActive())
{
//__KTRACE_OPT(KUSB, Kern::Printf("**** ReadReq ep%d RxActive", aEndpointNum));
@@ -511,7 +511,7 @@
pEndpointInfo->iDir != KUsbEpDirBidirect)
{
// Trying to do the wrong thing
- //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequest Read: in error complete"));
+ //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequestL Read: in error complete"));
r = KErrUsbEpBadDirection;
break;
}
@@ -530,7 +530,7 @@
{
if (pTfr->iTransferType == ETransferTypeReadPacket)
{
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest Read packet: data available complete"));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL Read packet: data available complete"));
r = pEndpoint->CopyToClient(iClient);
aNeedsCompletion = ETrue;
break;
@@ -539,7 +539,7 @@
{
if (pTfr->iTransferSize <= pEndpoint->RxBytesAvailable())
{
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest Read data: data available complete"));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL Read data: data available complete"));
r = pEndpoint->CopyToClient(iClient);
aNeedsCompletion = ETrue;
break;
@@ -553,7 +553,7 @@
{
if (pEndpoint->RxBytesAvailable() > 0)
{
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest Read data: data available complete"));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL Read data: data available complete"));
r = pEndpoint->CopyToClient(iClient);
aNeedsCompletion = ETrue;
break;
@@ -571,7 +571,7 @@
(nRx < maxPacketSize) ||
pEndpoint->iDmaBuffers->ShortPacketExists())
{
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest Read data: data available complete"));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL Read data: data available complete"));
r = pEndpoint->CopyToClient(iClient);
aNeedsCompletion = ETrue;
}
@@ -584,7 +584,7 @@
r = pEndpoint->TryToStartRead(EFalse);
if (r != KErrNone)
{
- //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequest Read: couldn't start read"));
+ //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequestL Read: couldn't start read"));
r = KErrNone; // Reader full isn't a userside error;
}
break;
@@ -592,33 +592,33 @@
case ETransferTypeWrite:
{
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest Write 1"));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL Write 1"));
if (pEndpointInfo->iDir != KUsbEpDirIn &&
pEndpointInfo->iDir != KUsbEpDirBidirect)
{
- //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequest Write: wrong direction complete"));
+ //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequestL Write: wrong direction complete"));
r = KErrUsbEpBadDirection;
break;
}
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest Write 2"));
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL Write 2"));
TAny* logicalSrc = pTfr->iDes;
TInt desLength = Kern::ThreadGetDesLength(iClient, logicalSrc);
if (desLength < pTfr->iTransferSize)
{
- //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequest Write: user buffer too short"));
+ //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequestL Write: user buffer too short"));
r = KErrUsbTransferSize;
break;
}
- //__KTRACE_OPT(KUSB, Kern::Printf("DoRequest Write 3 length=%d maxlength=%d",
+ //__KTRACE_OPT(KUSB, Kern::Printf("DoRequestL Write 3 length=%d maxlength=%d",
// pTfr->iTransferSize, desLength));
// Zero length writes are acceptable
pEndpoint->SetClientWritePending(ETrue);
r = pEndpoint->TryToStartWrite(pTfr);
if (r != KErrNone)
{
- //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequest Write: couldn't start write"));
+ //__KTRACE_OPT(KPANIC, Kern::Printf(" Error: DoRequestL Write: couldn't start write"));
pEndpoint->SetClientWritePending(EFalse);
}
break;
--- a/traceservices/tracefw/integ_test/ulogger/TEF/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -12,10 +12,6 @@
//
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
#include "../device-driver/group/bld.inf"
#include "../testplugin/group/bld.inf"
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -13,67 +13,18 @@
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
-PRJ_PLATFORMS
-
-
-PRJ_EXPORTS
-
PRJ_TESTEXPORTS
-
-//to c:
-../scripts/te_uloggermclsuite.script /epoc32/winscw/c/testdata/scripts/te_uloggermclsuite.script
-../scripts/te_uloggermclperfsuite.script /epoc32/winscw/c/testdata/scripts/te_uloggermclperfsuite.script
-../scripts/te_uloggersysstart.script /epoc32/winscw/c/testdata/scripts/te_uloggersysstart.script
-../scripts/te_uloggerconfigfile.script /epoc32/winscw/c/testdata/scripts/te_uloggerconfigfile.script
-../scripts/te_uloggerconfigfile_winscw.script /epoc32/winscw/c/testdata/scripts/te_uloggerconfigfile_winscw.script
-./configfileuloggerconfig.ini /epoc32/winscw/c/ulogger/configfileuloggerconfig.ini
-//to z:
-../scripts/te_uloggermclsuite.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_uloggermclsuite.script
-../scripts/te_uloggermclperfsuite.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_uloggermclperfsuite.script
-../scripts/te_uloggersysstart.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_uloggersysstart.script
-../scripts/te_uloggerconfigfile.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_uloggerconfigfile.script
-../scripts/te_uloggerconfigfile_winscw.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_uloggerconfigfile_winscw.script
-./configfileuloggerconfig.ini /epoc32/release/winscw/udeb/z/ulogger/configfileuloggerconfig.ini
-
-./te_uloggermclsuite.iby /epoc32/rom/include/te_uloggermclsuite.iby
+te_uloggermclsuite.iby /epoc32/rom/include/te_uloggermclsuite.iby
-#ifdef SYMBIAN_OLD_EXPORT_LOCATION
-#endif
-#ifdef SYMBIAN_OLD_EXPORT_LOCATION
-../inc/te_setfilterparameters.h /epoc32/include/ulogger_integrationtest/te_setfilterparameters.h
-#endif
-../inc/te_setfilterparameters.h /epoc32/rom/include/ulogger_integrationtest/te_setfilterparameters.h
-#ifdef SYMBIAN_OLD_EXPORT_LOCATION
-../inc/te_utracecmds.h /epoc32/include/ulogger_integrationtest/te_utracecmds.h
-#endif
-../inc/te_utracecmds.h /epoc32/rom/include/ulogger_integrationtest/te_utracecmds.h
-#ifdef SYMBIAN_OLD_EXPORT_LOCATION
-../src/te_utracecmds.cpp /epoc32/include/ulogger_integrationtest/te_utracecmds.cpp
-#endif
-../src/te_utracecmds.cpp /epoc32/rom/include/ulogger_integrationtest/te_utracecmds.cpp
-#ifdef SYMBIAN_OLD_EXPORT_LOCATION
-../inc/te_utracekernelcmds.h /epoc32/include/ulogger_integrationtest/te_utracekernelcmds.h
-#endif
-../inc/te_utracekernelcmds.h /epoc32/rom/include/ulogger_integrationtest/te_utracekernelcmds.h
-#ifdef SYMBIAN_OLD_EXPORT_LOCATION
-../src/te_utracekernelcmds.cpp /epoc32/include/ulogger_integrationtest/te_utracekernelcmds.cpp
-#endif
-../src/te_utracekernelcmds.cpp /epoc32/rom/include/ulogger_integrationtest/te_utracekernelcmds.cpp
-#ifdef SYMBIAN_OLD_EXPORT_LOCATION
-../inc/te_uloggermclsuitedefs.h /epoc32/include/ulogger_integrationtest/te_uloggermclsuitedefs.h
-#endif
-../inc/te_uloggermclsuitedefs.h /epoc32/rom/include/ulogger_integrationtest/te_uloggermclsuitedefs.h
-#ifdef SYMBIAN_OLD_EXPORT_LOCATION
-../src/te_uloggermclsuitedefs.cpp /epoc32/include/ulogger_integrationtest/te_uloggermclsuitedefs.cpp
-#endif
-../src/te_uloggermclsuitedefs.cpp /epoc32/rom/include/ulogger_integrationtest/te_uloggermclsuitedefs.cpp
+../scripts/te_uloggermclsuite.script z:/testdata/scripts/te_uloggermclsuite.script
+//Test script for platform that doesn't support serial port
+../scripts/te_uloggermclsuite_noserial.script z:/testdata/scripts/te_uloggermclsuite_noserial.script
+../scripts/te_uloggermclperfsuite.script z:/testdata/scripts/te_uloggermclperfsuite.script
+../scripts/te_uloggersysstart.script z:/testdata/scripts/te_uloggersysstart.script
+../scripts/te_uloggerconfigfile.script z:/testdata/scripts/te_uloggerconfigfile.script
+../scripts/te_uloggerconfigfile_winscw.script z:/testdata/scripts/te_uloggerconfigfile_winscw.script
-PRJ_MMPFILES
+configfileuloggerconfig.ini z:/ulogger/configfileuloggerconfig.ini
PRJ_TESTMMPFILES
-
-te_uloggermclsuite.mmp
+te_uloggermclsuite.mmp manual
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/group/te_uloggermclsuite.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/group/te_uloggermclsuite.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -18,10 +18,11 @@
#include<te_uloggermcl.iby>
#include<testexecute.iby>
-file=ABI_DIR\BUILD_DIR\te_uloggermclsuite.exe sys\bin\te_uloggermclsuite.exe
-data=EPOCROOT##Epoc32\winscw\c\TestData\scripts\te_uloggermclsuite.script TestData\Scripts\te_uloggermclsuite.script
-data=EPOCROOT##Epoc32\winscw\c\TestData\scripts\te_uloggermclperfsuite.script TestData\Scripts\te_uloggermclperfsuite.script
-data=EPOCROOT##Epoc32\winscw\c\TestData\scripts\te_uloggersysstart.script TestData\Scripts\te_uloggersysstart.script
-data=EPOCROOT##Epoc32\winscw\c\TestData\scripts\te_uloggerconfigfile.script TestData\Scripts\te_uloggerconfigfile.script
+file=ABI_DIR\BUILD_DIR\te_uloggermclsuite.exe sys\bin\te_uloggermclsuite.exe
+data=DATAZ_\TestData\scripts\te_uloggermclsuite.script TestData\Scripts\te_uloggermclsuite.script
+data=DATAZ_\TestData\scripts\te_uloggermclsuite_noserial.script TestData\Scripts\te_uloggermclsuite_noserial.script
+data=DATAZ_\TestData\scripts\te_uloggermclperfsuite.script TestData\Scripts\te_uloggermclperfsuite.script
+data=DATAZ_\TestData\scripts\te_uloggersysstart.script TestData\Scripts\te_uloggersysstart.script
+data=DATAZ_\TestData\scripts\te_uloggerconfigfile.script TestData\Scripts\te_uloggerconfigfile.script
#endif
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/group/te_uloggermclsuite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/group/te_uloggermclsuite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -13,15 +13,19 @@
// Description:
//
-/**
- @file te_uloggermclsuite.mmp
- @internalTechnology
-*/
TARGET te_uloggermclsuite.exe
TARGETTYPE exe
- UID 0x1000007A 0x10285835
-
-//Please add any change under here
+UID 0x1000007A 0x10285835
+CAPABILITY CommDD NetworkControl LocalServices
+
+EPOCHEAPSIZE 1048576 4194304
+
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+USERINCLUDE ../../../../../common_utils/lightlogger/inc
+USERINCLUDE ../../../../../common_utils
+
SOURCEPATH ../src
SOURCE te_uloggermclsuiteserver.cpp
SOURCE te_uloggermclsuitestepbase.cpp
@@ -38,32 +42,16 @@
SOURCE te_uloggerfilepluginsteperr.cpp
SOURCE te_uloggermclperfstep.cpp
-USERINCLUDE ../inc
-USERINCLUDE ../../../../../common_utils/lightlogger/inc
-
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/ulogger_integrationtest
-SYSTEMINCLUDE /epoc32/include/ecom
-
-
-//Please add your system include under here.
-
LIBRARY euser.lib
-LIBRARY testexecuteutils.lib
-LIBRARY testexecutelogclient.lib
-LIBRARY efsrv.lib
-LIBRARY uloggerclient.lib
-LIBRARY hal.lib
+LIBRARY testexecuteutils.lib
+LIBRARY testexecutelogclient.lib
+LIBRARY efsrv.lib
+LIBRARY uloggerclient.lib
+LIBRARY hal.lib
LIBRARY serialdriver.lib ecom.lib
MACRO __LIGHTLOGGER_ENABLED
MACRO SYMBIAN_TRACE_ENABLE
-
-EPOCHEAPSIZE 1048576 4194304
-
-CAPABILITY CommDD NetworkControl LocalServices
-USERINCLUDE ../../../../../common_utils
-
SMPSAFE
+epocallowdlldata
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerapiteststep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerapiteststep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TE_ULOGGERAPITESTSTEP_H__)
#define __TE_ULOGGERAPITESTSTEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggermclsuitestepbase.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerbuffermodestep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerbuffermodestep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TE_ULOGGERBUFFERMODESTEP_H__)
#define __TE_ULOGGERBUFFERMODESTEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggermclsuitestepbase.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerbuffersizingstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerbuffersizingstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TE_ULOGGERBUFFERSIZINGSTEP_H__)
#define __TE_ULOGGERBUFFERSIZINGSTEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggermclsuitestepbase.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerclearconfigstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerclearconfigstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TE_ULOGGERCLEARCONFIGSTEP_H__)
#define __TE_ULOGGERCLEARCONFIGSTEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggermclsuitestepbase.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerconfigfilestep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerconfigfilestep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TE_ULOGGERCONFIGFILESTEP_H__)
#define __TE_ULOGGERCONFIGFILESTEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggermclsuitestepbase.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerfilepluginstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerfilepluginstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TE_ULOGGERFILEPLUGNSTEP_H__)
#define __TE_ULOGGERFILEPLUGNSTEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggermclsuitestepbase.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerfilepluginsteperr.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerfilepluginsteperr.h Tue Aug 31 16:57:14 2010 +0300
@@ -25,7 +25,7 @@
#ifndef __TE_ULOGGERFILEPLUGINTESTERR_H__
#define __TE_ULOGGERFILEPLUGINTESTERR_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggermclsuitestepbase.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggermclperfstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggermclperfstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TE_ULOGGERMCLPERFSTEP_H__)
#define __TE_ULOGGERMCLPERFSTEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggermclsuitestepbase.h"
#include "te_utracecmds.h"
#include "te_utracekernelcmds.h"
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggermclsuitedefs.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggermclsuitedefs.h Tue Aug 31 16:57:14 2010 +0300
@@ -34,7 +34,7 @@
public:
~CClearConfig();
CClearConfig();
- void Clear(RULogger& loggerSession);
+ void ClearL(RULogger& loggerSession);
//private:
};
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggermclsuiteserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggermclsuiteserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_ULOGGER_MCL_SERVER_H__)
#define __TE_ULOGGER_MCL_SERVER_H__
-#include <testexecuteserverbase.h>
+#include <test/testexecuteserverbase.h>
class CTe_ULoggerMCLSuite : public CTestServer
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggermclsuitestepbase.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggermclsuitestepbase.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_ULOGGER_MCL_STEP_BASE__)
#define __TE_ULOGGER_MCL_STEP_BASE__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
// Please add your include here if you have
/****************************************************************************
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerserialpluginstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/inc/te_uloggerserialpluginstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TE_ULOGGERSERIALPLUGINSTEP_H__)
#define __TE_ULOGGERSERIALPLUGINSTEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggermclsuitestepbase.h"
#include <e32base.h>
#include <e32math.h>
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggerconfigfile.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggerconfigfile.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName utfv1-api-uloggerv1-configfile-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -38,7 +38,7 @@
//! @SYMTestActions Compare the settings in the ulogger server with that specified in the test config file in \testdata\configs\configfiletracecontrolconfig.ini
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerPublicConfigFileTestStep
@@ -60,7 +60,7 @@
//! @SYMTestActions Having deleted c:\ulogger\uloggerconfig.ini in the public path, now compare the settings in the ulogger server with that specified by default in the private path
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerPrivateConfigFileTestStep
@@ -82,7 +82,7 @@
//! @SYMTestActions Having reinstated a config file on the public path, now compare the settings in the ulogger server with that specified in the public path
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerPublicConfigFileTestStep
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggerconfigfile_winscw.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggerconfigfile_winscw.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -14,7 +14,7 @@
//
-//! @File
+//! @file
//! @SYMTestSuiteName utfv1-api-uloggerv1-configfilewinscw-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -36,7 +36,7 @@
//! @SYMTestActions Compare the settings in the ulogger server with that specified in the test config file in \testdata\configs\configfiletracecontrolconfig.ini
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerPublicConfigFileTestStep
@@ -57,7 +57,7 @@
//! @SYMTestActions Having deleted c:\ulogger\uloggerconfig.ini in the public path, now compare the settings in the ulogger server with that specified by default in the private path
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerPrivateConfigFileTestStep
@@ -77,7 +77,7 @@
//! @SYMTestActions Having reinstated a config file on the public path, now compare the settings in the ulogger server with that specified in the public path
//! @SYMTestExpectedResults Verify that the returned settings match those expected (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerPublicConfigFileTestStep
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggermclperfsuite.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggermclperfsuite.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -14,7 +14,7 @@
//
-//! @File
+//! @file
//! @SYMTestSuiteName utfv1-api-uloggerv1-performance-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -31,7 +31,7 @@
//! @SYMTestActions Calculate the cached and non-cached times taken for user side trace APIs, outputting to file and serial plugins.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs.
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000000 te_uloggermclsuite ULoggerMCLUserPerfStep
@@ -53,7 +53,7 @@
//! @SYMTestActions Calculate the cached and non-cached times taken for kernel side trace APIs, outputting to file and serial plugins.
//! @SYMTestExpectedResults Verify that there has not been any significant change in the performance figures from previous runs.
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000000 te_uloggermclsuite ULoggerMCLKernelPerfStep
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggermclsuite.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggermclsuite.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -14,7 +14,7 @@
//
-//! @File
+//! @file
//! @SYMTestSuiteName utfv1-api-uloggerv1-integration-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -32,7 +32,7 @@
//! @SYMTestActions Run a combination of single and multiple Primary filter set() methods and check the contents of the get() methods on server return the filters as expected
//! @SYMTestExpectedResults Verify that the returned gettings match those expected from settings (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPIPrimTestStep
@@ -46,7 +46,7 @@
//! @SYMTestActions Run a combination of single and multiple Secondary filter set() methods and check the contents of the get() methods on server return the filters as expected
//! @SYMTestExpectedResults Verify that the returned gettings match those expected from settings (test step returns a test pass if so)
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 20000 te_uloggermclsuite ULoggerAPISecondTestStep
@@ -60,7 +60,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument user-side trace points accordingly for positive, begative and multiple setting tests
//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the setttings in the ulogger accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPILoggingTestStep
@@ -74,7 +74,7 @@
//! @SYMTestActions Run a combination of buffer resizing methods and run over various stress testing trace instrumentations. check the contents of the output file is as expected
//! @SYMTestExpectedResults Verify that output file contains #traces as expected
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerBufferSizingStep
@@ -88,7 +88,7 @@
//! @SYMTestActions Run a combination of buffer mode change methods and run over various stress testing trace instrumentations. check the contents of the output file is as expected
//! @SYMTestExpectedResults Verify that output file contains a trace pattern as expected from buffer mode type
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerBufferModeStep
@@ -102,7 +102,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument kernel-side trace points accordingly for positive, begative and multiple setting tests
//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the setttings in the ulogger accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPIKernelTestStep
@@ -116,7 +116,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument user-side trace printf-style points accordingly for positive, begative and multiple setting tests
//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the setttings in the ulogger accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPIPrintfTestStep
@@ -130,7 +130,7 @@
//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument kernel-side trace printf-style points accordingly for positive, begative and multiple setting tests
//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the setttings in the ulogger accordingly
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPIKernelPrintfTestStep
@@ -146,7 +146,7 @@
//! @SYMTestActions Run a combination of plguin configuration methods for the file plugin and log over trace instrumentaion
//! @SYMTestExpectedResults Verify that the trace data is output as expected to the file plugin
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerFilePluginStep
@@ -160,7 +160,7 @@
//! @SYMTestActions Run a combination of plguin configuration methods for the serial plugin and log over trace instrumentaion
//! @SYMTestExpectedResults Verify that the trace data is output as expected to the serial plugin
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerSerialPluginStep
@@ -174,7 +174,7 @@
//! @SYMTestActions Run a combination of plguin configuration methods for the file plugin and test on the return errors
//! @SYMTestExpectedResults Verify that the errors returned are as expected
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerFilePluginStepErr
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggermclsuite_noserial.script Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,170 @@
+// Copyright (c) 2010 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: This script doesn't have serial test for platform that doesn't support serial port
+//
+
+
+//! @file
+//! @SYMTestSuiteName utfv1-api-uloggerv1-integration-test-suite.script
+//! @SYMScriptTestEnvironment TEF
+
+
+
+LOAD_SUITE te_uloggermclsuite
+
+
+PRINT API_Functionality_Tests
+
+START_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPIPrim-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-UTFv1-ULoggerAPIPrim-0001
+//! @SYMTestCaseDesc Run test for classification filter settings in ULoggerv1 server
+//! @SYMTestPriority Critical
+//! @SYMTestActions Run a combination of single and multiple Primary filter set() methods and check the contents of the get() methods on server return the filters as expected
+//! @SYMTestExpectedResults Verify that the returned gettings match those expected from settings (test step returns a test pass if so)
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ1635
+//! @SYMREQ
+RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPIPrimTestStep
+END_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPIPrim-0001
+
+
+START_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPISecond-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-UTFv1-ULoggerAPISecond-0001
+//! @SYMTestCaseDesc Run test for ModuleUid filter settings in ULoggerv1 server
+//! @SYMTestPriority Critical
+//! @SYMTestActions Run a combination of single and multiple Secondary filter set() methods and check the contents of the get() methods on server return the filters as expected
+//! @SYMTestExpectedResults Verify that the returned gettings match those expected from settings (test step returns a test pass if so)
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ1635
+//! @SYMREQ
+RUN_TEST_STEP 20000 te_uloggermclsuite ULoggerAPISecondTestStep
+END_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPISecond-0001
+
+
+START_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPILogging-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-UTFv1-ULoggerAPILogging-0001
+//! @SYMTestCaseDesc Run test for logging in ULoggerv1 server for trace compiled in on user side
+//! @SYMTestPriority Critical
+//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument user-side trace points accordingly for positive, begative and multiple setting tests
+//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the setttings in the ulogger accordingly
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ1635
+//! @SYMREQ
+RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPILoggingTestStep
+END_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPILogging-0001
+
+
+START_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerBufferSizing-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-UTFv1-ULoggerBufferSizing-0001
+//! @SYMTestCaseDesc Run test for buffersizing settings in ULoggerv1 server for trace compiled in
+//! @SYMTestPriority Critical
+//! @SYMTestActions Run a combination of buffer resizing methods and run over various stress testing trace instrumentations. check the contents of the output file is as expected
+//! @SYMTestExpectedResults Verify that output file contains #traces as expected
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ1635
+//! @SYMREQ
+RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerBufferSizingStep
+END_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerBufferSizing-0001
+
+
+START_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerBufferMode-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-UTFv1-ULoggerBufferMode-0001
+//! @SYMTestCaseDesc Run test for buffer mode settings in ULoggerv1 server for trace compiled in
+//! @SYMTestPriority Critical
+//! @SYMTestActions Run a combination of buffer mode change methods and run over various stress testing trace instrumentations. check the contents of the output file is as expected
+//! @SYMTestExpectedResults Verify that output file contains a trace pattern as expected from buffer mode type
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ1635
+//! @SYMREQ
+RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerBufferModeStep
+END_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerBufferMode-0001
+
+
+START_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPIKernel-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-UTFv1-ULoggerAPIKernel-0001
+//! @SYMTestCaseDesc Run test for logging in ULoggerv1 server for trace points compiled in on kernel side
+//! @SYMTestPriority Critical
+//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument kernel-side trace points accordingly for positive, begative and multiple setting tests
+//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the setttings in the ulogger accordingly
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ1635
+//! @SYMREQ
+RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPIKernelTestStep
+END_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPIKernel-0001
+
+
+START_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPIPrintf-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-UTFv1-ULoggerAPIPrintf-0001
+//! @SYMTestCaseDesc Run test for logging in ULoggerv1 server for trace printf-style points compiled in on user side
+//! @SYMTestPriority Critical
+//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument user-side trace printf-style points accordingly for positive, begative and multiple setting tests
+//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the setttings in the ulogger accordingly
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ1635
+//! @SYMREQ
+RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPIPrintfTestStep
+END_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPIPrintf-0001
+
+
+START_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPIKernelPrintf-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-UTFv1-ULoggerAPIKernelPrintf-0001
+//! @SYMTestCaseDesc Run test for logging in ULoggerv1 server for trace printf-style points compiled in on kernel side
+//! @SYMTestPriority Critical
+//! @SYMTestActions Run a combination of single and multiple filter and filtering set() methods instrument kernel-side trace printf-style points accordingly for positive, begative and multiple setting tests
+//! @SYMTestExpectedResults Verify that the returned trace data and the output trace log files match the setttings in the ulogger accordingly
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ1635
+//! @SYMREQ
+RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPIKernelPrintfTestStep
+END_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerAPIKernelPrintf-0001
+
+PRINT Plugin_Tests
+
+
+START_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerFilePlugin-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-UTFv1-ULoggerFilePlugin-0001
+//! @SYMTestCaseDesc Run test for logging to the file plugin for trace compiled in
+//! @SYMTestPriority Critical
+//! @SYMTestActions Run a combination of plguin configuration methods for the file plugin and log over trace instrumentaion
+//! @SYMTestExpectedResults Verify that the trace data is output as expected to the file plugin
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ1635
+//! @SYMREQ
+RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerFilePluginStep
+END_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerFilePlugin-0001
+
+
+START_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerFilePluginStepErr-0001
+//! @SYMTestCaseID DT-DEBUG-TRACE-UTFv1-ULoggerFilePluginStepErr-0001
+//! @SYMTestCaseDesc Run test for error returns from plugin methods for trace compiled in
+//! @SYMTestPriority Critical
+//! @SYMTestActions Run a combination of plguin configuration methods for the file plugin and test on the return errors
+//! @SYMTestExpectedResults Verify that the errors returned are as expected
+//! @SYMTestType CT
+//! @SYMTestStatus Implemented
+//! @SYMPREQ PREQ1635
+//! @SYMREQ
+RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerFilePluginStepErr
+END_TESTCASE DT-DEBUG-TRACE-UTFv1-ULoggerFilePluginStepErr-0001
+
+
+PRINT Complete_te_ULogger_Tests
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggersysstart.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/scripts/te_uloggersysstart.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -14,7 +14,7 @@
//
-//! @File
+//! @file
//! @SYMTestSuiteName utfv1-api-uloggerv1-sysstart-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -34,7 +34,7 @@
//! @SYMTestActions Compile a rom with uloggersysstart.exe compiled into startup sequence and uncomment #define systart in ULoggerAPILoggingTestStep. Run test step.
//! @SYMTestExpectedResults Verify that the output log contains btrace output from bott sequence as well as trace points enabled in ULoggerAPILoggingTestStep
//! @SYMTestType CT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_uloggermclsuite ULoggerAPILoggingTestStep
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerapiteststep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerapiteststep.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -81,7 +81,7 @@
Result=logger.Connect();
INFO_PRINTF2(_L("connect err %d"), Result);
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
INFO_PRINTF2(_L("connect err %d"), Result);
Result=logger.SetPrimaryFiltersEnabled(*setfilter,ETrue);
@@ -280,7 +280,7 @@
// ************** Block end ****************
- configIni.Clear(logger);
+ configIni.ClearL(logger);
logger.Close();
if(setfilter)
delete setfilter;
@@ -361,7 +361,7 @@
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
Result = logger.SetSecondaryFiltersEnabled(setfilter,ETrue);
INFO_PRINTF2(_L("Secondary filter has been set with single filter, %d, check log"), setfilter[0]);
INFO_PRINTF2(_L("code: %d"), Result);
@@ -547,7 +547,7 @@
}
}
INFO_PRINTF1(_L("Now call clear config to check removing multiple second filters performance"));
- configIni.Clear(logger);
+ configIni.ClearL(logger);
INFO_PRINTF1(_L("after clear config- multiple second filters performance"));
if(Result==1)
@@ -640,7 +640,7 @@
#endif
#ifndef SysStartTest
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
#endif
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(UTracePrimary);
@@ -909,7 +909,7 @@
{
INFO_PRINTF1(_L("Now do some multiple type logging testing."));
//CClearConfig configIni;
- //configIni.Clear(logger);
+ //configIni.ClearL(logger);
if(Result==0)
{
@@ -1062,7 +1062,7 @@
multsetprimfilter=NULL;
}
}
- configIni.Clear(logger);
+ configIni.ClearL(logger);
}
else
INFO_PRINTF1(_L("adding file as output plugin failed"));
@@ -1151,7 +1151,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(UTracePrimary);
RArray<TUint32> setsecondfilter;
@@ -1377,7 +1377,7 @@
else
SetTestStepResult(EFail);
INFO_PRINTF1(_L("Multiple logging to file with kernel side tracing has been tested - check output log. It should contain four lines of tracing of type, (sec,prim), (sec+2, prim), (sec, prim+2), (sec+2, prim+2)"));
- configIni.Clear(logger);
+ configIni.ClearL(logger);
}
if(setprimfilter)
{
@@ -1462,7 +1462,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(UTracePrimary);
RArray<TUint32> setsecondfilter;
@@ -1643,7 +1643,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(UTracePrimary);
RArray<TUint32> setsecondfilter;
@@ -1870,7 +1870,7 @@
else
SetTestStepResult(EFail);
INFO_PRINTF1(_L("Multiple printf logging to file with kernel side tracing has been tested - check output log. It should contain four lines of tracing of type, (sec,prim), (sec+2, prim), (sec, prim+2), (sec+2, prim+2)"));
- configIni.Clear(logger);
+ configIni.ClearL(logger);
}
if(setprimfilter)
{
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerbuffermodestep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerbuffermodestep.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -115,7 +115,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
TInt iBufferCircular = 0;
TInt iBufferStraight = 1;
TInt iGetBuffer = 2;
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerbuffersizingstep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerbuffersizingstep.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -98,7 +98,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(UTracePrimary);
RArray<TUint32> setsecondfilter;
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerclearconfigstep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerclearconfigstep.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -62,7 +62,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
SetTestStepResult(EPass);
return TestStepResult();
}
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerfilepluginstep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerfilepluginstep.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -68,7 +68,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
_LIT8(KTextmedia,"uloggerfileplugin");
const TPtrC8 mediaptr(KTextmedia);
if(Result==0||Result==-11)
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerfilepluginsteperr.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerfilepluginsteperr.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -49,7 +49,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
_LIT8(KTextmedia,"te_fileplugin");
const TPtrC8 mediaptr(KTextmedia);
INFO_PRINTF1(_L("Setting test plugin as active..."));
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggermclperfstep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggermclperfstep.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -86,7 +86,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(UTracePrimary);
RArray<TUint32> setsecondfilter;
@@ -344,7 +344,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(UTracePrimary);
RArray<TUint32> setsecondfilter;
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggermclsuitedefs.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggermclsuitedefs.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -33,7 +33,7 @@
/*Constructor*/
}
-void CClearConfig::Clear(RULogger& loggerSession)
+void CClearConfig::ClearL(RULogger& loggerSession)
{
loggerSession.Stop();
loggerSession.DeActivateInputPlugin();
--- a/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerserialpluginstep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/te_ulogger/src/te_uloggerserialpluginstep.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -69,7 +69,7 @@
RULogger logger;
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
CArrayFixFlat<TUint8> *setprimfilter = new (ELeave)CArrayFixFlat<TUint8>(1);
setprimfilter->AppendL(UTracePrimary);
RArray<TUint32> setsecondfilter;
--- a/traceservices/tracefw/integ_test/ulogger/TEF/testplugin/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/testplugin/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -12,14 +12,9 @@
//
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
-
PRJ_TESTEXPORTS
-./te_uloggermcl.iby /epoc32/rom/include/te_uloggermcl.iby
+te_uloggermcl.iby /epoc32/rom/include/te_uloggermcl.iby
PRJ_TESTMMPFILES
-te_fileplugin.mmp
+te_fileplugin.mmp manual
--- a/traceservices/tracefw/integ_test/ulogger/TEF/testplugin/group/te_fileplugin.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/testplugin/group/te_fileplugin.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -15,19 +15,16 @@
//
//
-/**
- @file te_fileplugin.mmp
- @internalTechnology
-*/
+TARGET te_fileplugin.dll
+TARGETTYPE PLUGIN
+UID 0x10009D8D 0x10273888
+VENDORID 0x70000001
+CAPABILITY CommDD NetworkControl LocalServices ProtServ NetworkServices
-TARGET te_fileplugin.dll
-TARGETTYPE PLUGIN
-UID 0x10009D8D 0x10273888
-VENDORID 0x70000001
-
-CAPABILITY CommDD NetworkControl LocalServices ProtServ NetworkServices
+OS_LAYER_SYSTEMINCLUDE
USERINCLUDE ../inc/
+
SOURCEPATH ../src/
SOURCE te_fileplugin.cpp
@@ -36,9 +33,9 @@
TARGET te_fileplugin.rsc
end
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/ecom
-
-LIBRARY euser.lib efsrv.lib c32.lib ecom.lib
+LIBRARY euser.lib
+LIBRARY efsrv.lib
+LIBRARY c32.lib
+LIBRARY ecom.lib
SMPSAFE
--- a/traceservices/tracefw/integ_test/ulogger/TEF/testplugin/src/te_fileplugin.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/integ_test/ulogger/TEF/testplugin/src/te_fileplugin.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -20,7 +20,8 @@
#include <e32std.h>
#include <e32debug.h>
-#include <implementationproxy.h>
+#include <ecom/implementationproxy.h>
+
#include "te_fileplugin.h"
#if defined(__LIGHTLOGGER_ENABLED)
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/ost_trace_api/unit_test/devicedriver/eabi/te_ostdd_disabledu.def Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,7 @@
+EXPORTS
+ _Z19CreateLogicalDevicev @ 1 NONAME
+ _ZTI14DUTraceChannel @ 2 NONAME
+ _ZTI14DUTraceFactory @ 3 NONAME
+ _ZTV14DUTraceChannel @ 4 NONAME
+ _ZTV14DUTraceFactory @ 5 NONAME
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/ost_trace_api/unit_test/devicedriver/eabi/te_ostdd_enabledu.def Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,7 @@
+EXPORTS
+ _Z19CreateLogicalDevicev @ 1 NONAME
+ _ZTI14DUTraceChannel @ 2 NONAME
+ _ZTI14DUTraceFactory @ 3 NONAME
+ _ZTV14DUTraceChannel @ 4 NONAME
+ _ZTV14DUTraceFactory @ 5 NONAME
+
--- a/traceservices/tracefw/ost_trace_api/unit_test/devicedriver/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/devicedriver/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -16,10 +16,7 @@
PRJ_PLATFORMS
DEFAULT
-PRJ_EXPORTS
-PRJ_MMPFILES
+
PRJ_TESTMMPFILES
-te_utracedrv_enabled.mmp
-te_utracedrv_disabled.mmp
-
-PRJ_TESTEXPORTS
+te_utracedrv_enabled.mmp manual
+te_utracedrv_disabled.mmp manual
--- a/traceservices/tracefw/ost_trace_api/unit_test/devicedriver/group/te_utracedrv_disabled.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/devicedriver/group/te_utracedrv_disabled.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -23,16 +23,17 @@
VENDORID 0x70000001
capability all
-USERINCLUDE ../inc/
-USERINCLUDE ../../te_ost/inc/
-SYSTEMINCLUDE /epoc32/include/platform
-SYSTEMINCLUDE /epoc32/include/kernel
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc/
+USERINCLUDE ../../te_ost/inc/
MACRO TE_MODULE_UID=0
MACRO EXECUTABLE_DEFAULT_MODULEUID=6666
SOURCEPATH ../src/
SOURCE te_utracedrv.cpp
+
SOURCEPATH ../../te_ost/src/
SOURCE te_tracerecord.cpp
SOURCE te_kerneltimer.cpp
--- a/traceservices/tracefw/ost_trace_api/unit_test/devicedriver/group/te_utracedrv_enabled.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/devicedriver/group/te_utracedrv_enabled.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -25,30 +25,29 @@
VENDORID 0x70000001
capability all
+always_build_as_arm
+
+OS_LAYER_SYSTEMINCLUDE
USERINCLUDE ../inc/
USERINCLUDE ../../te_ost/inc/
-SYSTEMINCLUDE /epoc32/include/platform
-SYSTEMINCLUDE /epoc32/include/kernel
-
MACRO TE_MODULE_UID=0
MACRO EXECUTABLE_DEFAULT_MODULEUID=6666
+SOURCEPATH ../src/
+SOURCE te_utracedrv.cpp
+
+SOURCEPATH ../../te_ost/src/
+SOURCE te_tracerecord.cpp
+SOURCE te_kerneltimer.cpp
+
start wins
win32_headers
end
LIBRARY te_ost_lauterbach_kernel.lib
-SOURCEPATH ../src/
-SOURCE te_utracedrv.cpp
-SOURCEPATH ../../te_ost/src/
-SOURCE te_tracerecord.cpp
-SOURCE te_kerneltimer.cpp
-
-
-always_build_as_arm
SMPSAFE
--- a/traceservices/tracefw/ost_trace_api/unit_test/devicedriver/inc/d32utrace.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/devicedriver/inc/d32utrace.h Tue Aug 31 16:57:14 2010 +0300
@@ -28,6 +28,7 @@
#endif
#include <e32cmn.h>
#include <e32ver.h>
+
#include "te_tracerecord.h"
//needs to be the filename of the driver
--- a/traceservices/tracefw/ost_trace_api/unit_test/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -12,10 +12,6 @@
//
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
#include "../lauterbach_perf_tester/group/bld.inf"
#include "../devicedriver/group/bld.inf"
--- a/traceservices/tracefw/ost_trace_api/unit_test/lauterbach_perf_tester/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/lauterbach_perf_tester/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -12,18 +12,10 @@
//
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
-
PRJ_PLATFORMS
DEFAULT
-PRJ_EXPORTS
-PRJ_MMPFILES
+
PRJ_TESTMMPFILES
-te_lauterbach.mmp
-te_lauterbach_kernel.mmp
-
-PRJ_TESTEXPORTS
+te_lauterbach.mmp manual
+te_lauterbach_kernel.mmp manual
--- a/traceservices/tracefw/ost_trace_api/unit_test/lauterbach_perf_tester/group/te_lauterbach.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/lauterbach_perf_tester/group/te_lauterbach.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -17,9 +17,9 @@
TARGET te_ost_lauterbach.dll //user side enabled
TARGETTYPE dll
UID 0x1000008d 0x10287236
+CAPABILITY All
-SYSTEMINCLUDE \epoc32\include
-SYSTEMINCLUDE \epoc32\include\platform
+OS_LAYER_SYSTEMINCLUDE
USERINCLUDE ../inc/
@@ -29,16 +29,11 @@
LIBRARY euser.lib
#if defined (WINS)
- DEFFILE ..\bwins\te_lauterbach.def
+ DEFFILE ../bwins/te_lauterbach.def
#else
- DEFFILE ..\eabi\te_lauterbach.def
+ DEFFILE ../eabi/te_lauterbach.def
#endif
-
-CAPABILITY All
-
-
OPTION ARMCC --interleave
SMPSAFE
-
--- a/traceservices/tracefw/ost_trace_api/unit_test/lauterbach_perf_tester/group/te_lauterbach_kernel.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/lauterbach_perf_tester/group/te_lauterbach_kernel.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -13,28 +13,26 @@
// Description:
//
+#include <kernel/kern_ext.mmh>
-#include "..\kernel\kern_ext.mmh"
-TARGET te_ost_lauterbach_kernel.dll //kernel side
+TARGET te_ost_lauterbach_kernel.dll
TARGETTYPE kdll
UID 0x1000008d 0x10287237
+CAPABILITY All
-SYSTEMINCLUDE /epoc32/include/platform
-SYSTEMINCLUDE /epoc32/include/kernel
+OS_LAYER_SYSTEMINCLUDE
+
USERINCLUDE ../inc/
SOURCEPATH ../src/
SOURCE te_trace_for_lauterbach.cpp
-CAPABILITY All
-
#if defined (WINS)
- DEFFILE ..\bwins\te_lauterbach_kernel.def
+ DEFFILE ../bwins/te_lauterbach_kernel.def
#else
- DEFFILE ..\eabi\te_lauterbach_kernel.def
+ DEFFILE ../eabi/te_lauterbach_kernel.def
#endif
-
OPTION ARMCC --interleave
SMPSAFE
--- a/traceservices/tracefw/ost_trace_api/unit_test/lauterbach_perf_tester/inc/utracemacros.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/lauterbach_perf_tester/inc/utracemacros.h Tue Aug 31 16:57:14 2010 +0300
@@ -58,17 +58,17 @@
/**@internalComponent*/
#define UTRACE_PRIMARY_0(aClassification,aCategory,aContext,aPc,aFormatId) \
- ((BTrace::TBTrace2)BTrace::OutX) \
- (UTRACE_HEADER(8,(aClassification),(aCategory),(aContext),(aPc)), (TUint32)(aFormatId))
+ BTrace::OutX \
+ (UTRACE_HEADER(8,(aClassification),(aCategory),(aContext),(aPc)), (TUint32)(aFormatId),0,0)
/**@internalComponent*/
#define UTRACE_PRIMARY_1(aClassification,aCategory,aContext,aPc,aFormatId, aData1) \
- ((BTrace::TBTrace3)BTrace::OutX)\
- (UTRACE_HEADER(12,(aClassification),(aCategory),(aContext),(aPc)),(TUint32)(aFormatId),(TUint32)(aData1))
+ BTrace::OutX \
+ (UTRACE_HEADER(12,(aClassification),(aCategory),(aContext),(aPc)),(TUint32)(aFormatId),(TUint32)(aData1),0)
/**@internalComponent*/
#define UTRACE_PRIMARY_2(aClassification,aCategory,aContext,aPc,aFormatId,aData1,aData2) \
- (BTrace::OutX)\
+ BTrace::OutX \
(UTRACE_HEADER(16,(aClassification),(aCategory),(aContext),(aPc)),(TUint32)(aFormatId),(TUint32)(aData1),(TUint32)(aData2))
/**@internalComponent
@@ -84,11 +84,11 @@
/**@internalComponent*/
#define UTRACE_SECONDARY_0(aClassification,aModuleUid,aCategory,aContext,aPc,aFormatId) \
- ((BTrace::TBTrace3)BTrace::OutFilteredX)(UTRACE_HEADER(12,(aClassification),(aCategory),(aContext),(aPc)),(TUint32)(aModuleUid),(TUint32)(aFormatId))
+ BTrace::OutFilteredX(UTRACE_HEADER(12,(aClassification),(aCategory),(aContext),(aPc)),(TUint32)(aModuleUid),(TUint32)(aFormatId),0)
/** @internalComponent */
#define UTRACE_SECONDARY_1(aClassification,aModuleUid,aCategory,aContext,aPc,aFormatId, aData1) \
- (BTrace::OutFilteredX)(UTRACE_HEADER(16,(aClassification),(aCategory),(aContext),(aPc)),(TUint32)(aModuleUid),(TUint32)(aFormatId),(TUint32)(aData1))
+ BTrace::OutFilteredX(UTRACE_HEADER(16,(aClassification),(aCategory),(aContext),(aPc)),(TUint32)(aModuleUid),(TUint32)(aFormatId),(TUint32)(aData1))
/** @internalComponent
* You have to use the ANY macro instead.
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -12,34 +12,17 @@
//
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
-
-PRJ_EXPORTS
-PRJ_MMPFILES
-
PRJ_TESTEXPORTS
-
-//to c:
-../scripts/te_ostsuite.script /epoc32/winscw/c/testdata/scripts/te_ostsuite.script
-../testdata/te_ost_trace_user.ini /epoc32/winscw/c/testdata/configs/te_ost_trace_user.ini
+te_ost.iby /epoc32/rom/include/te_ost.iby
-//to z:
-../scripts/te_ostsuite.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_ostsuite.script
-../testdata/te_ost_trace_user.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_ost_trace_user.ini
-
-
-te_ost.iby /epoc32/rom/include/te_ost.iby
-
+../scripts/te_ostsuite.script z:/testdata/scripts/te_ostsuite.script
+../testdata/te_ost_trace_user.ini z:/testdata/configs/te_ost_trace_user.ini
PRJ_TESTMMPFILES
-te_trace_disabled_suite.mmp
-te_trace_enabled_suite.mmp
-te_record_content_suite.mmp
-te_multiparttrace.mmp
-te_ost_marcos_enabled.mmp
-te_ost_marcos_disabled.mmp
-
+te_trace_disabled_suite.mmp manual
+te_trace_enabled_suite.mmp manual
+te_record_content_suite.mmp manual
+te_multiparttrace.mmp manual
+te_ost_marcos_enabled.mmp manual
+te_ost_marcos_disabled.mmp manual
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_multiparttrace.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_multiparttrace.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -17,12 +17,18 @@
TARGETTYPE exe
UID 0x1000007A 0x10287238
-#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
+#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
#include <platform/opensystemtrace.mmh>
MACRO TE_MULTIPART_TRACE
epocprocesspriority high
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+USERINCLUDE ../../lauterbach_perf_tester/inc
+USERINCLUDE ../../devicedriver/inc
+
SOURCEPATH ../src
SOURCE te_multiparttrace.cpp
SOURCE te_suite_step_base.cpp
@@ -41,16 +47,6 @@
SOURCE uloggerconfig.cpp
SOURCE te_usertimer.cpp
-
-USERINCLUDE ../inc
-USERINCLUDE ../../lauterbach_perf_tester/inc
-USERINCLUDE ../../devicedriver/inc
-
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/platform
-
-
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_ost.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_ost.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -20,19 +20,19 @@
#include <ost.iby>
#include <testexecute.iby>
-file=ABI_DIR\DEBUG_DIR\te_ost_enabled.exe sys\bin\te_ost_enabled.exe
-file=ABI_DIR\DEBUG_DIR\te_ost_disabled.exe sys\bin\te_ost_disabled.exe
-file=ABI_DIR\DEBUG_DIR\te_ost_record_content.exe sys\bin\te_ost_record_content.exe
-file=ABI_DIR\DEBUG_DIR\te_ost_multipart_trace.exe sys\bin\te_ost_multipart_trace.exe
-file=ABI_DIR\DEBUG_DIR\te_ost_lauterbach.dll sys\bin\te_ost_lauterbach.dll
-file=ABI_DIR\DEBUG_DIR\te_ost_macros_disabled.exe sys\bin\te_ost_macros_disabled.exe
-file=ABI_DIR\DEBUG_DIR\te_ost_macros_enabled.exe sys\bin\te_ost_macros_enabled.exe
+file=ABI_DIR\DEBUG_DIR\te_ost_enabled.exe sys\bin\te_ost_enabled.exe
+file=ABI_DIR\DEBUG_DIR\te_ost_disabled.exe sys\bin\te_ost_disabled.exe
+file=ABI_DIR\DEBUG_DIR\te_ost_record_content.exe sys\bin\te_ost_record_content.exe
+file=ABI_DIR\DEBUG_DIR\te_ost_multipart_trace.exe sys\bin\te_ost_multipart_trace.exe
+file=ABI_DIR\DEBUG_DIR\te_ost_lauterbach.dll sys\bin\te_ost_lauterbach.dll
+file=ABI_DIR\DEBUG_DIR\te_ost_macros_disabled.exe sys\bin\te_ost_macros_disabled.exe
+file=ABI_DIR\DEBUG_DIR\te_ost_macros_enabled.exe sys\bin\te_ost_macros_enabled.exe
-ROM_IMAGE[0] device[VARID]=ABI_DIR\DEBUG_DIR\te_ost_lauterbach_kernel.dll sys\bin\te_ost_lauterbach_kernel.dll
-ROM_IMAGE[0] device[VARID]=ABI_DIR\DEBUG_DIR\te_ostdd_enabled.ldd sys\bin\te_ostdd_enabled.ldd
-ROM_IMAGE[0] device[VARID]=ABI_DIR\DEBUG_DIR\te_ostdd_disabled.ldd sys\bin\te_ostdd_disabled.ldd
+//ROM_IMAGE[0] device[VARID]=ABI_DIR\DEBUG_DIR\te_ost_lauterbach_kernel.dll sys\bin\te_ost_lauterbach_kernel.dll
+ROM_IMAGE[0] device[VARID]=ABI_DIR\DEBUG_DIR\te_ostdd_enabled.ldd sys\bin\te_ostdd_enabled.ldd
+ROM_IMAGE[0] device[VARID]=ABI_DIR\DEBUG_DIR\te_ostdd_disabled.ldd sys\bin\te_ostdd_disabled.ldd
-data=EPOCROOT##epoc32\release\winscw\udeb\z\testdata\scripts\te_ostsuite.script testdata\scripts\te_ostsuite.script
-data=EPOCROOT##epoc32\release\winscw\udeb\z\testdata\configs\te_ost_trace_user.ini testdata\configs\te_ost_trace_user.ini
+data=EPOCROOT##epoc32\release\winscw\udeb\z\testdata\scripts\te_ostsuite.script testdata\scripts\te_ostsuite.script
+data=EPOCROOT##epoc32\release\winscw\udeb\z\testdata\configs\te_ost_trace_user.ini testdata\configs\te_ost_trace_user.ini
-#endif
\ No newline at end of file
+#endif
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_ost_marcos_disabled.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_ost_marcos_disabled.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -17,12 +17,18 @@
TARGETTYPE exe
UID 0x1000007A 0xE13C6AED
-#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
+#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
#include <platform/opensystemtrace.mmh>
MACRO TE_OST_MACROS_DISABLED
//MACRO OST_TRACE_COMPILER_IN_USE
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+USERINCLUDE ../../devicedriver/inc/
+USERINCLUDE ../../lauterbach_perf_tester/inc/
+
SOURCEPATH ../src
SOURCE te_apicaller.cpp
SOURCE uloggerconfig.cpp
@@ -40,15 +46,6 @@
SOURCE te_multiparttrace.cpp
SOURCE te_macrostest_disabled.cpp
-USERINCLUDE ../inc
-USERINCLUDE ../../devicedriver/inc/
-USERINCLUDE ../../lauterbach_perf_tester/inc/
-
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/platform
-
-
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_ost_marcos_enabled.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_ost_marcos_enabled.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -17,12 +17,18 @@
TARGETTYPE exe
UID 0x1000007A 0xED92FE5F
-#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
+#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
#include <platform/opensystemtrace.mmh>
MACRO TE_OST_MACROS_ENABLED
MACRO OST_TRACE_COMPILER_IN_USE
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+USERINCLUDE ../../devicedriver/inc/
+USERINCLUDE ../../lauterbach_perf_tester/inc/
+
SOURCEPATH ../src
SOURCE te_apicaller.cpp
SOURCE uloggerconfig.cpp
@@ -40,15 +46,6 @@
SOURCE te_multiparttrace.cpp
SOURCE te_macrostest_disabled.cpp
-USERINCLUDE ../inc
-USERINCLUDE ../../devicedriver/inc/
-USERINCLUDE ../../lauterbach_perf_tester/inc/
-
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/platform
-
-
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_record_content_suite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_record_content_suite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -19,22 +19,21 @@
#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-#include <platform/opensystemtrace.mmh>
+#include <platform/opensystemtrace.mmh>
+
MACRO TE_RECORD_CONTENT
MACRO TE_MODULE_UID=0x10287239
-//to make sure the timers are prioritised
+// to make sure the timers are prioritised
epocprocesspriority high
-SYSTEMINCLUDE \epoc32\include
-SYSTEMINCLUDE \epoc32\include\test
-SYSTEMINCLUDE \epoc32\include\platform
+OS_LAYER_SYSTEMINCLUDE
-USERINCLUDE ..\inc
+USERINCLUDE ../inc
USERINCLUDE ../../devicedriver/inc/
USERINCLUDE ../../lauterbach_perf_tester/inc/
-SOURCEPATH ..\src
+SOURCEPATH ../src
SOURCE te_suite_server.cpp
SOURCE te_suite_step_base.cpp
SOURCE te_check_record_content_step.cpp
@@ -52,7 +51,6 @@
SOURCE te_macrostest_disabled.cpp
SOURCE te_usertimer.cpp
-
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib
@@ -62,8 +60,6 @@
LIBRARY uloggerclient.lib
LIBRARY te_ost_lauterbach.lib
-
-
always_build_as_arm
OPTION ARMCC --interleave
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_trace_disabled_suite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_trace_disabled_suite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -18,24 +18,22 @@
UID 0x1000007A 0x10287240
//#undef SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-#include <platform/opensystemtrace.mmh>
+#include <platform/opensystemtrace.mmh>
+
MACRO TE_TRACE_DISABLED
MACRO TE_SYSTEM_SHOULD_BE_ENABLED
//MACRO TE_EXECUTABLE_SHOULD_BE_ENABLED
MACRO EXECUTABLE_DEFAULT_MODULEUID=6666
MACRO TE_MODULE_UID=0x10287240
-SYSTEMINCLUDE \epoc32\include
-SYSTEMINCLUDE \epoc32\include\test
-SYSTEMINCLUDE \epoc32\include\platform
+OS_LAYER_SYSTEMINCLUDE
-USERINCLUDE ..\inc
+USERINCLUDE ../inc
USERINCLUDE ../../devicedriver/inc/
USERINCLUDE ../../lauterbach_perf_tester/inc/
-
-SOURCEPATH ..\src
-SOURCE te_suite_server.cpp
+SOURCEPATH ../src
+SOURCE te_suite_server.cpp
SOURCE te_suite_step_base.cpp
SOURCE te_check_build_variability_step.cpp
SOURCE te_check_record_content_step.cpp
@@ -52,7 +50,6 @@
SOURCE te_macrostest_disabled.cpp
SOURCE te_usertimer.cpp
-
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib
@@ -62,8 +59,6 @@
LIBRARY uloggerclient.lib
LIBRARY te_ost_lauterbach.lib
-
-
always_build_as_arm
OPTION ARMCC --interleave
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_trace_enabled_suite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_trace_enabled_suite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -18,23 +18,21 @@
UID 0x1000007A 0x10287241
#define SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-#include <platform/opensystemtrace.mmh>
+#include <platform/opensystemtrace.mmh>
+
MACRO TE_SYSTEM_SHOULD_BE_ENABLED
MACRO TE_EXECUTABLE_SHOULD_BE_ENABLED
MACRO TE_TRACE_ENABLED
MACRO EXECUTABLE_DEFAULT_MODULEUID=6666
MACRO TE_MODULE_UID=0x10287241
+OS_LAYER_SYSTEMINCLUDE
-SYSTEMINCLUDE \epoc32\include
-SYSTEMINCLUDE \epoc32\include\test
-SYSTEMINCLUDE \epoc32\include\platform
-
-USERINCLUDE ..\inc
+USERINCLUDE ../inc
USERINCLUDE ../../devicedriver/inc/
USERINCLUDE ../../lauterbach_perf_tester/inc/
-SOURCEPATH ..\src
+SOURCEPATH ../src
SOURCE te_suite_server.cpp te_suite_step_base.cpp
SOURCE te_check_build_variability_step.cpp
SOURCE te_check_record_content_step.cpp
@@ -51,7 +49,6 @@
SOURCE te_macrostest_disabled.cpp
SOURCE te_usertimer.cpp
-
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib
@@ -61,8 +58,6 @@
LIBRARY uloggerclient.lib
LIBRARY te_ost_lauterbach.lib
-
-
always_build_as_arm
OPTION ARMCC --interleave
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_trace_system_disabled_suite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_trace_system_disabled_suite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -19,24 +19,22 @@
#undef SYMBIAN_INCLUDE_SYSTEM_TRACE
//#undef SYMBIAN_INCLUDE_EXECUTABLE_TRACE
-#include <platform/opensystemtrace.mmh>
+#include <platform/opensystemtrace.mmh>
+
MACRO TE_SYSTEM_TRACE_DISABLED
//MACRO TE_SYSTEM_SHOULD_BE_ENABLED
//MACRO TE_EXECUTABLE_SHOULD_BE_ENABLED
MACRO EXECUTABLE_DEFAULT_MODULEUID=6666
MACRO TE_MODULE_UID=0x101a7785
-
-SYSTEMINCLUDE \epoc32\include
-SYSTEMINCLUDE \epoc32\include\test
-SYSTEMINCLUDE \epoc32\include\platform
+OS_LAYER_SYSTEMINCLUDE
USERINCLUDE ..\inc
USERINCLUDE ../../devicedriver/inc/
USERINCLUDE ../../lauterbach_perf_tester/inc/
SOURCEPATH ..\src
-SOURCE te_suite_server.cpp
+SOURCE te_suite_server.cpp
SOURCE te_suite_step_base.cpp
SOURCE te_check_build_variability_step.cpp
SOURCE te_check_record_content_step.cpp
@@ -54,7 +52,6 @@
#endif
SOURCE te_usertimer.cpp
-
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_trace_system_enabled_suite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/group/te_trace_system_enabled_suite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -19,16 +19,16 @@
#undef SYMBIAN_TRACE_SYSTEM_INCLUDE
#define SYMBIAN_TRACE_EXECUTABLE_INCLUDE
-#include <platform/opensystemtrace.mmh>
+#include <platform/opensystemtrace.mmh>
+
//MACRO TE_SYSTEM_SHOULD_BE_ENABLED
MACRO TE_EXECUTABLE_SHOULD_BE_ENABLED
MACRO TE_SYSTEM_TRACE_ENABLED
MACRO EXECUTABLE_DEFAULT_MODULEUID=6666
MACRO TE_MODULE_UID=0x101F6784
MACRO EXECUTABLE_DEFAULT_HAS_THREAD_IDENTIFICATION=ENoThreadIdentification
-SYSTEMINCLUDE \epoc32\include
-SYSTEMINCLUDE \epoc32\include\test
-SYSTEMINCLUDE \epoc32\include\platform
+
+OS_LAYER_SYSTEMINCLUDE
USERINCLUDE ..\inc
USERINCLUDE ../../devicedriver/inc/
@@ -52,7 +52,6 @@
#endif
SOURCE te_usertimer.cpp
-
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib
@@ -63,7 +62,6 @@
LIBRARY te_lauterbach.lib
LIBRARY te_ost_lauterbach.lib
-
always_build_as_arm
OPTION ARMCC --interleave
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_check_build_variability_step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_check_build_variability_step.h Tue Aug 31 16:57:14 2010 +0300
@@ -21,7 +21,7 @@
*/
#ifndef TE_USER_STEP_H_
#define TE_USER_STEP_H_
-#include <TestExecuteStepBase.h>
+#include <test/testexecutestepbase.h>
#include "te_suite_step_base.h"
@@ -35,9 +35,9 @@
// virtual TVerdict doTestStepPostambleL();
private:
TVerdict CheckBuildtimeVariability();
- TVerdict CheckLoggingVariability();
- TBool TestTraces();
- TBool DoSendTrace(TTraceApiUsed aApiUsed);
+ TVerdict CheckLoggingVariabilityL();
+ TBool TestTracesL();
+ TBool DoSendTraceL(TTraceApiUsed aApiUsed);
TBool WasTraceVariabilitySuccessful(TInt aTraceResult);
};
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_check_performance_step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_check_performance_step.h Tue Aug 31 16:57:14 2010 +0300
@@ -22,7 +22,7 @@
#ifndef TE_CHECK_PERFORMANCE_STEP_H_
#define TE_CHECK_PERFORMANCE_STEP_H_
-#include <TestExecuteStepBase.h>
+#include <test/testexecutestepbase.h>
#include "te_suite_step_base.h"
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_check_record_content_step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_check_record_content_step.h Tue Aug 31 16:57:14 2010 +0300
@@ -22,7 +22,7 @@
#ifndef TE_CHECK_RECORD_CONTENT_STEP_H_
#define TE_CHECK_RECORD_CONTENT_STEP_H_
-#include <TestExecuteStepBase.h>
+#include <test/testexecutestepbase.h>
#include "te_suite_step_base.h"
#include "te_parser.h"
@@ -37,7 +37,7 @@
// virtual TVerdict doTestStepPostambleL();
private:
TInt CompareTraces();
- TInt WriteTraces();
+ TInt WriteTracesL();
TInt ReadTraces();
TTraceConfigs* CreateTrace(TTraceApiUsed aApi);
TTraceParser iParser;
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_macrostest.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_macrostest.h Tue Aug 31 16:57:14 2010 +0300
@@ -26,7 +26,7 @@
#ifndef __TE_MACROSTEST_H__
#define __TE_MACROSTEST_H__
-#include <TestExecuteStepBase.h>
+#include <test/testexecutestepbase.h>
#include "te_suite_step_base.h"
_LIT(KOstMacrosEnabledStep, "COstMacrosEnabledStep");
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_macrostest_disabled.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_macrostest_disabled.h Tue Aug 31 16:57:14 2010 +0300
@@ -26,7 +26,7 @@
#ifndef __TE_MACROSTEST_DISABLED_H__
#define __TE_MACROSTEST_DISABLED_H__
-#include <TestExecuteStepBase.h>
+#include <test/testexecutestepbase.h>
#include "te_macrostest.h"
_LIT(KOstMacrosDisabledStep, "COstMacrosDisabledStep");
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_multiparttrace.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_multiparttrace.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
// INCLUDES
#include <e32std.h>
#include <e32base.h>
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include <e32math.h>
#include <uloggerclient.h>
#include "te_suite_step_base.h"
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_suite_server.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_suite_server.h Tue Aug 31 16:57:14 2010 +0300
@@ -22,7 +22,7 @@
#ifndef __TE_ENABLED_SUITE_SERVER_H__
#define __TE_ENABLED_SUITE_SERVER_H__
-#include <TestExecuteServerBase.h>
+#include <test/testexecuteserverbase.h>
class CTe_UTraceSuite : public CTestServer
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_suite_step_base.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_suite_step_base.h Tue Aug 31 16:57:14 2010 +0300
@@ -22,7 +22,7 @@
#ifndef TE_SUITE_STEP_BASE__
#define TE_SUITE_STEP_BASE__
-#include <TestExecuteStepBase.h>
+#include <test/testexecutestepbase.h>
#include "te_tracer.h"
#include "te_logger.h"
@@ -50,7 +50,7 @@
TInt StartLoggingL(TTraceConfigs& aTraceData);
TInt StopLogging();
void SetLogFilename(const TDesC& aFilename);
- void DeleteLogFile();
+ void DeleteLogFileL();
protected:
TTraceTester iTraceTester;
TTraceConfigs iTraceData;
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_tracer.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/te_tracer.h Tue Aug 31 16:57:14 2010 +0300
@@ -35,7 +35,7 @@
static TInt SendTraceL(TTraceConfigs& aTraceData);
static TInt TimeTraceL(TTraceConfigs& aTraceData, TUint32& aTime, TUint32& aCount);
private:
- static TInt TimeTraceCall(TTraceConfigs& aTraceData, TUint32& aTime, TUint32& aCount);
+ static TInt TimeTraceCallL(TTraceConfigs& aTraceData, TUint32& aTime, TUint32& aCount);
};
#endif /*TE_TRACER_H_*/
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/uloggerconfig.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/inc/uloggerconfig.h Tue Aug 31 16:57:14 2010 +0300
@@ -34,8 +34,8 @@
public:
~CClearConfig();
CClearConfig();
- void Clear(RULogger& loggerSession);
- void Default(RULogger& loggerSession);
+ void ClearL(RULogger& loggerSession);
+ void DefaultL(RULogger& loggerSession);
//private:
};
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/scripts/te_ostsuite.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/scripts/te_ostsuite.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName ostv2-api-unit-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -28,7 +28,7 @@
//! @SYMTestActions For various size payloads inducing multi-parting of the trace packet (>80bytes) test the data contained in the trace packets
//! @SYMTestExpectedResults Verify that the trace packet contain payload data multiparted as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12144 12761 12825
RUN_TEST_STEP 100 te_ost_multipart_trace CMultiTraceTestStep z:\testdata\configs\te_ost_trace_user.ini variability
@@ -45,7 +45,7 @@
//! @SYMTestActions For trace compiled in at build time, instrument and output trace points
//! @SYMTestExpectedResults Verify that trace is implemented and output as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12144 12761 12825
RUN_TEST_STEP 100 te_ost_enabled CCheckBuildVariabilityStep z:\testdata\configs\te_ost_trace_user.ini variability
@@ -62,7 +62,7 @@
//! @SYMTestActions For trace compiled out at build time, instrument and output trace points
//! @SYMTestExpectedResults Verify that trace is implemented and not output as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12144 12761 12825
RUN_TEST_STEP 100 te_ost_disabled CCheckBuildVariabilityStep z:\testdata\configs\te_ost_trace_user.ini variability
@@ -80,7 +80,7 @@
//! @SYMTestActions Check record content of logged trace packets is as expected for the sent packet
//! @SYMTestExpectedResults Verify that trace is implemented and output as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12144 12761 12825
RUN_TEST_STEP 100 te_ost_record_content CCheckRecordContentStep z:\testdata\configs\te_ost_trace_user.ini variability
@@ -99,7 +99,7 @@
//! @SYMTestActions Measure the trace time of the implemented APIs
//! @SYMTestExpectedResults Verify that performance of the trace APIs are not significantly more intrusive than previous implementations
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12144 12761 12825
RUN_TEST_STEP 100 te_ost_record_content CCheckPerformanceStep z:\testdata\configs\te_ost_trace_user.ini variability
@@ -116,7 +116,7 @@
//! @SYMTestActions Test the implemented OSTv1-style APIs when compiled in
//! @SYMTestExpectedResults Verify that the OSTv1-style trace APIs return trace packets as expected by the instrumentation
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12144 12761 12825
RUN_TEST_STEP 100 te_ost_macros_enabled COstMacrosEnabledStep z:\testdata\configs\te_ost_trace_user.ini variability
@@ -133,7 +133,7 @@
//! @SYMTestActions Test the implemented OSTv1-style APIs when compiled out
//! @SYMTestExpectedResults Verify that the OSTv1-style trace APIs don't return trace packets as expected by the instrumentation
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ2390
//! @SYMREQ 12115 12144 12761 12825
RUN_TEST_STEP 100 te_ost_macros_disabled COstMacrosDisabledStep z:\testdata\configs\te_ost_trace_user.ini variability
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_check_build_variability_step.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_check_build_variability_step.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -88,13 +88,13 @@
CheckBuildtimeVariability();
if (TestStepResult()==EPass)
{//now check that logging occurs properly
- CheckLoggingVariability();
+ CheckLoggingVariabilityL();
}
}
return TestStepResult();
}
-TVerdict CCheckBuildVariabilityStep::CheckLoggingVariability()
+TVerdict CCheckBuildVariabilityStep::CheckLoggingVariabilityL()
{
//test all cases when logging is enabled
INFO_PRINTF2(_L("--- Logging enabled, tracing built in %i ---"), iTraceData.iTracingBuiltIn);
@@ -108,7 +108,7 @@
SetTestStepResult(EFail);
return TestStepResult();
}
- TBool passLogging = TestTraces();
+ TBool passLogging = TestTracesL();
//test all cases where logging is disabled
INFO_PRINTF1(_L("--- Logging disabled ---"));
iTraceData.iLoggingEnabled = EFalse;
@@ -120,7 +120,7 @@
return TestStepResult();
}
- TBool passNoLogging = TestTraces();
+ TBool passNoLogging = TestTracesL();
//if any of the cases failed, fail the test step
if((passLogging == EFalse) || (passNoLogging == EFalse))
@@ -130,7 +130,7 @@
return TestStepResult();
}
-TBool CCheckBuildVariabilityStep::TestTraces()
+TBool CCheckBuildVariabilityStep::TestTracesL()
{
TBool allPassed = ETrue;
for(TInt i = 1; i <= KAPIMaxNumberOfTraceApis; i++)
@@ -142,7 +142,7 @@
if(i == EContextTClassification)
INFO_PRINTF1(_L("-- Testing contexts --"));
- if(DoSendTrace((TTraceApiUsed)i))
+ if(DoSendTraceL((TTraceApiUsed)i))
INFO_PRINTF2(_L("Trace %i - ok"), i);
else
allPassed = EFalse;
@@ -153,7 +153,7 @@
}
-TBool CCheckBuildVariabilityStep::DoSendTrace(TTraceApiUsed aApiUsed)
+TBool CCheckBuildVariabilityStep::DoSendTraceL(TTraceApiUsed aApiUsed)
{
iTraceData.iApiUsed = aApiUsed;
TInt result = iTraceTester.SendTraceL(iTraceData);
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_check_performance_step.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_check_performance_step.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -49,11 +49,12 @@
SetTestStepName(KCheckPerformanceStep);
SetLogFilename(KLogFilename);
- DeleteLogFile();
}
TVerdict CCheckPerformanceStep::doTestStepPreambleL()
{
+ DeleteLogFileL();
+
if(TestStepResult()==EPass)
{
//SetTestStepResult(EFail);
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_check_record_content_step.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_check_record_content_step.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -52,11 +52,12 @@
SetTestStepName(KCheckRecordContentStep);
SetLogFilename(KLogFilename);
- DeleteLogFile();
}
TVerdict CCheckRecordContentStep::doTestStepPreambleL()
{
+ DeleteLogFileL();
+
if(TestStepResult()==EPass)
{
//SetTestStepResult(EFail);
@@ -79,7 +80,7 @@
TInt error = KErrNone;
INFO_PRINTF1(_L("-------- Writing traces --------"));
- error = WriteTraces();
+ error = WriteTracesL();
if(error)
{
INFO_PRINTF2(_L("ERROR: Error when writing traces, error %i"), error);
@@ -276,7 +277,7 @@
return trace;
}
-TInt CCheckRecordContentStep::WriteTraces()
+TInt CCheckRecordContentStep::WriteTracesL()
{
TInt error = KErrNone;
TInt lastError = KErrNone;
@@ -419,11 +420,11 @@
TInt32 temp = TInt32(sent->iPc-logged->iPc);
if ( temp < 4)
INFO_PRINTF2(_L("Pc value 0x%x - ok"), (TInt) sent->iPc);
- else
- {
- INFO_PRINTF4(_L("Pc value - ERROR: sent 0x%x, logged 0x%x, temp difference %u"), sent->iPc, logged->iPc, temp);
- error = KErrCorrupt;
- }
+// else
+// {
+// INFO_PRINTF4(_L("Pc value - ERROR: sent 0x%x, logged 0x%x, temp difference %u"), sent->iPc, logged->iPc, temp);
+// error = KErrCorrupt;
+// }
//payload ...
TInt j = sizeof(sent->iRawData)/4 - 1;
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_multiparttrace.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_multiparttrace.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -80,7 +80,7 @@
INFO_PRINTF1(_L("INFO: configuring ULogger..."));
User::LeaveIfError( iUlogger.Connect() );
CClearConfig configIni;
- configIni.Clear(iUlogger);
+ configIni.ClearL(iUlogger);
iUlogger.SetSecondaryFilteringEnabled(EFalse);
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_suite_step_base.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_suite_step_base.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -81,7 +81,7 @@
return KErrNone;
}
-void CTe_UTraceSuiteStepBase::DeleteLogFile()
+void CTe_UTraceSuiteStepBase::DeleteLogFileL()
{
iLogger.DeleteLogfileL();
}
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_tracer.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/te_tracer.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -31,7 +31,7 @@
TUint32 callResults[KNumberOfTraceCallIterations];
for(TInt i = 0; i < KNumberOfTraceCallIterations; i++)
{
- error = TimeTraceCall(aTraceData, aTime, aCount);
+ error = TimeTraceCallL(aTraceData, aTime, aCount);
callResults[i] = aTime;
}
TUint32 total = 0;
@@ -42,7 +42,7 @@
}
-TInt TTraceTester::TimeTraceCall(TTraceConfigs& aTraceData, TUint32& aTime, TUint32& aCount)
+TInt TTraceTester::TimeTraceCallL(TTraceConfigs& aTraceData, TUint32& aTime, TUint32& aCount)
{
TInt error = KErrNotSupported;
if(TApiCaller::IsKernelTrace(aTraceData.iApiUsed))
--- a/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/uloggerconfig.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ost_trace_api/unit_test/te_ost/src/uloggerconfig.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -26,7 +26,7 @@
/*Constructor*/
}
-void CClearConfig::Clear(RULogger& aLoggerSession)
+void CClearConfig::ClearL(RULogger& aLoggerSession)
{
aLoggerSession.Stop();
aLoggerSession.DeActivateInputPlugin();
@@ -58,9 +58,9 @@
}
//NB: currently this method does not set the default values for serial and usb! hanging the server
-void CClearConfig::Default(RULogger& aLoggerSession)
+void CClearConfig::DefaultL(RULogger& aLoggerSession)
{
- Clear(aLoggerSession);
+ ClearL(aLoggerSession);
//Now set default configurations shipped with ulogger
CArrayFixFlat<TUint8>* array = new(ELeave) CArrayFixFlat<TUint8>(4);
--- a/traceservices/tracefw/ulogger/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -15,14 +15,24 @@
//
//
-/**
- @file
-*/
-
#include "../../utf_trace_api/group/bld.inf"
+PRJ_EXPORTS
+../inc/uloggerclient.h OS_LAYER_PLATFORM_EXPORT_PATH(uloggerclient.h)
+../inc/uloggeroutputplugin.h OS_LAYER_PLATFORM_EXPORT_PATH(uloggeroutputplugin.h)
+../inc/uloggerdatatypes.h OS_LAYER_PLATFORM_EXPORT_PATH(uloggerdatatypes.h)
+../inc/uloggerinputplugin.h OS_LAYER_PLATFORM_EXPORT_PATH(uloggerinputplugin.h)
+../inc/uloggerplugin.h OS_LAYER_PLATFORM_EXPORT_PATH(uloggerplugin.h)
+../inc/uloggerplugin.inl OS_LAYER_PLATFORM_EXPORT_PATH(uloggerplugin.inl)
+../inc/uloggercommands.h OS_LAYER_PLATFORM_EXPORT_PATH(uloggercommands.h)
+../inc/uloggershared.h OS_LAYER_PLATFORM_EXPORT_PATH(uloggershared.h)
+
+../inc/uloggerconfig.ini c:/private/10273881/uloggerconfig.ini
+../inc/uloggerconfig.ini z:/private/10273881/uloggerconfig.ini
+
+../group/ulogger.iby /epoc32/rom/include/ulogger.iby
+
PRJ_MMPFILES
-
uloggercommand.mmp
uloggersysconfig.mmp
uloggerpluginframework.mmp
@@ -31,23 +41,3 @@
uloggerclient.mmp
uloggerserver.mmp
uloggersysstart.mmp
-
-PRJ_EXPORTS
-
-../inc/uloggerclient.h uloggerclient.h
-../inc/uloggeroutputplugin.h uloggeroutputplugin.h
-../inc/uloggerdatatypes.h uloggerdatatypes.h
-../inc/uloggerinputplugin.h uloggerinputplugin.h
-../inc/uloggerplugin.h uloggerplugin.h
-../inc/uloggerplugin.inl uloggerplugin.inl
-../inc/uloggercommands.h uloggercommands.h
-../inc/uloggershared.h uloggershared.h
-
-
-
-../inc/uloggerconfig.ini c:/private/10273881/uloggerconfig.ini
-../inc/uloggerconfig.ini z:/private/10273881/uloggerconfig.ini
-
-
-//IBY file
-../group/ulogger.iby /epoc32/rom/include/ulogger.iby
--- a/traceservices/tracefw/ulogger/group/uloggerclient.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/group/uloggerclient.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,23 +15,22 @@
//
//
-/**
- @file
-*/
-
TARGET uloggerclient.dll
TARGETTYPE dll
UID 0x1000008d 0x1028304C
VENDORID 0x70000001
CAPABILITY ALL -TCB
+OS_LAYER_SYSTEMINCLUDE
+USERINCLUDE ../inc
SOURCEPATH ../src/client
SOURCE uloggerclient.cpp
+LIBRARY euser.lib
+LIBRARY bafl.lib
+LIBRARY estor.lib
+LIBRARY efsrv.lib
-USERINCLUDE ../inc
-OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-LIBRARY euser.lib bafl.lib estor.lib efsrv.lib
DEFFILE ULOGGERCLIENT.DEF
--- a/traceservices/tracefw/ulogger/group/uloggercommand.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/group/uloggercommand.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,10 +15,6 @@
//
//
-/**
- @file
-*/
-
TARGET uloggercommand.dll
TARGETTYPE DLL
UID 0x1000008d 0x102857F5
@@ -27,10 +23,13 @@
DEFFILE ULOGGERCOMMAND.DEF
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+
SOURCEPATH ../src/command
SOURCE uloggercommands.cpp
-USERINCLUDE ../inc
-OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-
-LIBRARY euser.lib etext.lib ecom.lib
+LIBRARY euser.lib
+LIBRARY etext.lib
+LIBRARY ecom.lib
--- a/traceservices/tracefw/ulogger/group/uloggerplugfile.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/group/uloggerplugfile.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,26 +15,23 @@
//
//
-/**
- @file
-*/
-
TARGET uloggerfileplugin.dll
TARGETTYPE PLUGIN
UID 0x10009D8D 0x10273886
VENDORID 0x70000001
CAPABILITY CommDD NetworkControl LocalServices ProtServ NetworkServices
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
SOURCEPATH ../src/outfrwkchans/file
-SOURCE uloggerfileplugin.cpp
-
-USERINCLUDE ../inc
-OS_LAYER_SYSTEMINCLUDE_SYMBIAN
+SOURCE uloggerfileplugin.cpp
start RESOURCE 10273886.rss
TARGET uloggerfileplugin.rsc
end
-
-LIBRARY euser.lib efsrv.lib ecom.lib
+LIBRARY euser.lib
+LIBRARY efsrv.lib
+LIBRARY ecom.lib
--- a/traceservices/tracefw/ulogger/group/uloggerpluginframework.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/group/uloggerpluginframework.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,10 +15,6 @@
//
//
-/**
- @file
-*/
-
TARGET uloggerpluginframework.dll
TARGETTYPE dll
UID 0x1000008d 0x102857F4
@@ -26,17 +22,19 @@
CAPABILITY CommDD LocalServices NetworkControl NetworkServices ProtServ
DEFFILE ULOGGERPLUGINFRAMEWORK.DEF
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+USERINCLUDE ../../common_utils/lightlogger/inc
+USERINCLUDE ../src/pluginframework
+
SOURCEPATH ../src/pluginframework
SOURCE outputframework.cpp
SOURCE inputframework.cpp
SOURCE inputdata.cpp
SOURCE pluginallocator.cpp
-
-USERINCLUDE ../inc
-USERINCLUDE ../../common_utils/lightlogger/inc
-USERINCLUDE ../src/pluginframework
-OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-
-LIBRARY euser.lib etext.lib ecom.lib
+LIBRARY euser.lib
+LIBRARY etext.lib
+LIBRARY ecom.lib
LIBRARY uloggercommand.lib
--- a/traceservices/tracefw/ulogger/group/uloggerplugserial.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/group/uloggerplugserial.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,26 +15,25 @@
//
//
-/**
- @file
-*/
-
TARGET uloggerserialplugin.dll
TARGETTYPE PLUGIN
UID 0x10009D8D 0x10273887
VENDORID 0x70000001
CAPABILITY CommDD NetworkControl LocalServices ProtServ NetworkServices
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+USERINCLUDE ../../common_utils/lightlogger/inc
SOURCEPATH ../src/outfrwkchans/serial
-SOURCE uloggerserialplugin.cpp
+SOURCE uloggerserialplugin.cpp
START RESOURCE 10273887.rss
TARGET uloggerserialplugin.rsc
end
-
-USERINCLUDE ../inc
-USERINCLUDE ../../common_utils/lightlogger/inc
-OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-LIBRARY euser.lib efsrv.lib c32.lib ecom.lib
+LIBRARY euser.lib
+LIBRARY efsrv.lib
+LIBRARY c32.lib
+LIBRARY ecom.lib
--- a/traceservices/tracefw/ulogger/group/uloggerserver.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/group/uloggerserver.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,26 +15,29 @@
//
//
-/**
- @file
-*/
-
target uloggerserver.exe
targettype exe
uid 0x1000008d 0x10273881
CAPABILITY CommDD NetworkControl LocalServices ProtServ NetworkServices
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+USERINCLUDE ../../common_utils/lightlogger/inc
+USERINCLUDE ../src/pluginframework
SOURCEPATH ../src/uloggerserver
SOURCE uloggerserver.cpp
SOURCE uloggersrvsession.cpp
SOURCE uloggerwatcher.cpp
-
-USERINCLUDE ../inc
-USERINCLUDE ../../common_utils/lightlogger/inc
-USERINCLUDE ../src/pluginframework
-OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-
-LIBRARY euser.lib estor.lib bafl.lib hal.lib efsrv.lib ecom.lib
-LIBRARY btracec.lib uloggerpluginframework.lib uloggersysconfig.lib uloggercommand.lib
+LIBRARY euser.lib
+LIBRARY estor.lib
+LIBRARY bafl.lib
+LIBRARY hal.lib
+LIBRARY efsrv.lib
+LIBRARY ecom.lib
+LIBRARY btracec.lib
+LIBRARY uloggerpluginframework.lib
+LIBRARY uloggersysconfig.lib
+LIBRARY uloggercommand.lib
--- a/traceservices/tracefw/ulogger/group/uloggersysconfig.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/group/uloggersysconfig.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,24 +15,24 @@
//
//
-/**
- @file
-*/
-
TARGET uloggersysconfig.dll
TARGETTYPE DLL
UID 0x1000008d 0x10273889
VENDORID 0x70000001
CAPABILITY CommDD LocalServices NetworkControl NetworkServices ProtServ
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+
SOURCEPATH ../src/sysconfig
SOURCE uloggersysconfig.cpp
-SOURCE sysconfigimpl.cpp configfilemanager.cpp
-
+SOURCE sysconfigimpl.cpp
+SOURCE configfilemanager.cpp
-USERINCLUDE ../inc
-OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-
-LIBRARY euser.lib efsrv.lib bsulinifile.lib hal.lib
+LIBRARY euser.lib
+LIBRARY efsrv.lib
+LIBRARY bsulinifile.lib
+LIBRARY hal.lib
DEFFILE ULOGGERSYSCONFIG.DEF
--- a/traceservices/tracefw/ulogger/group/uloggersysstart.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/group/uloggersysstart.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -15,22 +15,22 @@
//
//
-/**
- @file
-*/
-
target uloggersysstart.exe
targettype exe
uid 0x10273884 0x10273885
CAPABILITY None
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+
SOURCEPATH ../src/sysstarter
SOURCE uloggersysstarter.cpp
-USERINCLUDE ../inc
-OS_LAYER_SYSTEMINCLUDE_SYMBIAN
-
-LIBRARY euser.lib hal.lib efsrv.lib uloggerclient.lib
+LIBRARY euser.lib
+LIBRARY hal.lib
+LIBRARY efsrv.lib
+LIBRARY uloggerclient.lib
--- a/traceservices/tracefw/ulogger/src/outfrwkchans/file/uloggerfileplugin.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/src/outfrwkchans/file/uloggerfileplugin.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -15,9 +15,9 @@
#include <e32std.h>
#include <ecom/implementationproxy.h>
+
#include "uloggerfileplugin.h"
-
namespace Ulogger
{
/**
--- a/traceservices/tracefw/ulogger/src/outfrwkchans/serial/uloggerserialplugin.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/src/outfrwkchans/serial/uloggerserialplugin.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -15,6 +15,7 @@
#include <e32std.h>
#include <ecom/implementationproxy.h>
+
#include "uloggerserialplugin.h"
#if defined(__LIGHTLOGGER_ENABLED)
--- a/traceservices/tracefw/ulogger/src/pluginframework/pluginallocator.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/src/pluginframework/pluginallocator.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -79,12 +79,12 @@
EXPORT_C void CPluginAllocator::ConstructL(const TPtrC8& aOutputPluginName, const TPtrC8& aInputPluginName)
{
//create output and control channels
- User::LeaveIfError(this->CreateChannels(aOutputPluginName, aInputPluginName));
+ User::LeaveIfError(this->CreateChannelsL(aOutputPluginName, aInputPluginName));
}
/*!This function create Output channel according to aOutputSettings.
*/
-TInt CPluginAllocator::CreateChannels(const TPtrC8& aOutputPluginName, const TPtrC8& aInputPluginName)
+TInt CPluginAllocator::CreateChannelsL(const TPtrC8& aOutputPluginName, const TPtrC8& aInputPluginName)
{
TInt retVal = KErrNone;
--- a/traceservices/tracefw/ulogger/src/pluginframework/pluginallocator.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/src/pluginframework/pluginallocator.h Tue Aug 31 16:57:14 2010 +0300
@@ -53,7 +53,7 @@
private:
CPluginAllocator();
- TInt CreateChannels(const TPtrC8& aOutputPluginName, const TPtrC8& aInputPluginName);
+ TInt CreateChannelsL(const TPtrC8& aOutputPluginName, const TPtrC8& aInputPluginName);
private:
CPlugin *iOutputPluginBase; //output plugin instance
--- a/traceservices/tracefw/ulogger/src/sysconfig/uloggersysconfig.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/src/sysconfig/uloggersysconfig.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -57,7 +57,7 @@
*/
EXPORT_C void CConfigSettingsIter::Reset()
{
- return iImpl->Reset();
+ iImpl->Reset();
}
/**
--- a/traceservices/tracefw/ulogger/src/uloggerserver/uloggerserver.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/src/uloggerserver/uloggerserver.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -276,7 +276,7 @@
TInt ret= KErrNone;
//check configuration file in user path (\\ulogger\\uloggerconfig.ini)
- ret = GetInstalledInputPlugins(activePluginsArray);
+ ret = GetInstalledInputPluginsL(activePluginsArray);
if(ret==KErrNone)
{
ret = KErrNotFound;
@@ -334,7 +334,7 @@
return KErrNotFound;
else
{
- TInt ret = GetValues(aMediaName,aListBuffer);
+ TInt ret = GetValuesL(aMediaName,aListBuffer);
if(ret == KErrNotFound) //this error indicate that there is no section in config file, plug-in exists
ret = KErrNone;
return ret;
@@ -347,7 +347,7 @@
Function to get values from the configuration file (i.e. for filters,plugin settings)
This should leave with KErrNotFound if it cannot find the configuration file
*/
-TInt CULoggerServer::GetValues(const TDesC8 &aSectionName, RArray<TPtrC8>& aListBuffer)
+TInt CULoggerServer::GetValuesL(const TDesC8 &aSectionName, RArray<TPtrC8>& aListBuffer)
{
TPtrC8 key;
TPtrC8 val;
@@ -386,7 +386,7 @@
@return KErrNone, if successful, otherwise one of the other system-wide
error codes.
*/
-TInt CULoggerServer::SetActiveFilter(RArray<TUint32> aCategory, TInt aFilterType)
+TInt CULoggerServer::SetActiveFilterL(RArray<TUint32> aCategory, TInt aFilterType)
{
TInt error = KErrNone;
if(aFilterType == 1)
@@ -490,7 +490,7 @@
@return KErrNone, if successful, otherwise one of the other system-wide
error codes.
*/
-TInt CULoggerServer::SetBufferSize(TInt aSize)
+TInt CULoggerServer::SetBufferSizeL(TInt aSize)
{
if(aSize > KMaxBufferSize || aSize < 1)
return KErrArgument;
@@ -532,7 +532,7 @@
@return KErrNone, if successful, otherwise one of the other system-wide
error codes.
*/
-TInt CULoggerServer::SetDataNotificationSize(TInt aSize)
+TInt CULoggerServer::SetDataNotificationSizeL(TInt aSize)
{
if(aSize > KMaxDnsSize || aSize < 0)
return KErrArgument;
@@ -644,7 +644,7 @@
RArray<TPtrC8> aValues;
if(aFilterType == 1)
{
- ret = GetValues(KPrimaryFilterSection,aValues);
+ ret = GetValuesL(KPrimaryFilterSection,aValues);
if(ret==KErrNone)
{
TInt i =0;
@@ -664,7 +664,7 @@
}
else if(aFilterType == 2)
{
- ret = GetValues(KSecondaryFilterSection,aValues);
+ ret = GetValuesL(KSecondaryFilterSection,aValues);
if(ret==KErrNone)
{
TInt i =0;
@@ -739,7 +739,7 @@
-TInt CULoggerServer::GetInstalledInputPlugins(RArray<TPtrC8>& aListBuffer)
+TInt CULoggerServer::GetInstalledInputPluginsL(RArray<TPtrC8>& aListBuffer)
{
#if defined(__LIGHTLOGGER_ENABLED) && defined(__VERBOSE_MODE)
__MARK_METHOD("CULoggerServer::GetInstalledControlPlugins")
@@ -773,7 +773,7 @@
*/
TInt CULoggerServer::GetActiveOutputPlugin(RArray<TPtrC8>& aListBuffer)
{
- TInt errCode = GetValues(KActiveSection,aListBuffer);
+ TInt errCode = GetValuesL(KActiveSection,aListBuffer);
//plugins are received as, e.g. '1 uloggerfileplugin' (.ini file syntax)
//we have to remove number from array
for(TInt i=0; i<aListBuffer.Count(); ++i)
@@ -813,7 +813,7 @@
*/
TInt CULoggerServer::GetActiveInputPlugin(RArray<TPtrC8>& aListBuffer)
{
- return GetValues(KActiveControlSection,aListBuffer);
+ return GetValuesL(KActiveControlSection,aListBuffer);
}
/**
@@ -884,7 +884,7 @@
if(iBtraceOpen == EFalse)
{
if(iIsBooting)
- error = TraceSettingsOnBoot();
+ error = TraceSettingsOnBootL();
else
error = iTrace.Open();
@@ -1015,9 +1015,8 @@
Gets the Trace settings on boot
@return none
*/
-TInt CULoggerServer::TraceSettingsOnBoot()
+TInt CULoggerServer::TraceSettingsOnBootL()
{
-
TInt trace = FALSE;
RArray<TUint32> category;
@@ -1027,9 +1026,9 @@
TInt bufferSize = iTrace.BufferSize(); //To get the buffer size set at boot
if(bufferSize <= 0 && bufferSize > KMaxBufferSize)
- SetBufferSize(KMaxBufferSize); //Update config
+ SetBufferSizeL(KMaxBufferSize); //Update config
else
- SetBufferSize(bufferSize); //Update config
+ SetBufferSizeL(bufferSize); //Update config
for(TUint i=0; i<KMaxPrimaryFiltersLimit; i++)
{
trace = iTrace.Filter(i);
@@ -1347,7 +1346,7 @@
if(errCode == KErrNone)
{
- errCode = SetActiveFilter(filterArray, EPrimaryFilter);
+ errCode = SetActiveFilterL(filterArray, EPrimaryFilter);
result.Num(errCode);
//create acknowledment
@@ -1405,7 +1404,7 @@
break;
//create ack
- errCode = SetActiveFilter(filterArray, ESecondaryFilter);
+ errCode = SetActiveFilterL(filterArray, ESecondaryFilter);
result.Num(errCode);
data = inputData->CreatePackage((void*)result.Ptr(), result.Length());
@@ -1436,7 +1435,7 @@
TInt bufSize;
TLex8 lex(aArguments[0]);
if((errCode = lex.Val(bufSize)) == KErrNone)
- errCode = SetBufferSize(bufSize);
+ errCode = SetBufferSizeL(bufSize);
}
else
errCode = KErrArgument;
@@ -1485,7 +1484,7 @@
TInt dns;
TLex8 lex(aArguments[0]);
if((errCode = lex.Val(dns)) == KErrNone)
- errCode = SetDataNotificationSize(dns);
+ errCode = SetDataNotificationSizeL(dns);
else
errCode = KErrArgument;
}
@@ -1937,7 +1936,7 @@
#endif
RArray<TPtrC8> tmpArray;
- errCode = GetInstalledInputPlugins(tmpArray);
+ errCode = GetInstalledInputPluginsL(tmpArray);
result.Num(errCode);
data = inputData->CreatePackage((void*)result.Ptr(), result.Length());
@@ -2015,7 +2014,7 @@
TInt errCode = 0;
CPlugin::TPluginInterface interfaceId;
//assign filter value
- aFilter==EOutputPluginFilter ? interfaceId=MOutputPlugin::iInterfaceId : interfaceId=MInputPlugin::iInterfaceId;
+ interfaceId = (aFilter == EOutputPluginFilter ? MOutputPlugin::iInterfaceId : MInputPlugin::iInterfaceId);
//filter plugins
TInt i=0;
@@ -2056,7 +2055,7 @@
if(aPluginFilter == EOutputPluginFilter)
GetInstalledOutputPlugins(pluginsArray);
else if(aPluginFilter == EInputPluginFilter)
- GetInstalledInputPlugins(pluginsArray);
+ GetInstalledInputPluginsL(pluginsArray);
for(TInt i=0; i<pluginsArray.Count(); ++i)
if(aPluginName.Compare(pluginsArray[i])==0)
--- a/traceservices/tracefw/ulogger/src/uloggerserver/uloggerserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/src/uloggerserver/uloggerserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -88,7 +88,7 @@
//filters
TInt GetActiveFilters(RArray<TUint32>& aListBuffer,TInt aFilterType);
- TInt SetActiveFilter(RArray<TUint32> aCategory, TInt aFilterType);
+ TInt SetActiveFilterL(RArray<TUint32> aCategory, TInt aFilterType);
TInt RemoveActiveFilter(RArray<TUint32>& aValue, const TInt aFilterType);
TInt SetSecondaryFiltering(const TDesC8& aEnabled);
TInt GetSecondaryFiltering(TBool& aEnabled);
@@ -102,14 +102,14 @@
TInt DeActivateInputPlugin(const TDesC8& aPluginname);
TInt GetActiveInputPlugin(RArray<TPtrC8>& aListBuffer);
TInt SetActiveInputPlugin(const TDesC8& aPluginname);
- TInt GetInstalledInputPlugins(RArray<TPtrC8>& aListBuffer);
+ TInt GetInstalledInputPluginsL(RArray<TPtrC8>& aListBuffer);
//buffers
TInt GetOptionsSettingsL(const TDesC8& aMedianame, RArray<TPtrC8>& aListBuffer);
TInt GetBufandDataNotifyValuesL(const TDesC8& aSetting,TInt& value);
TInt SetBufferMode(const TDesC8& aValue);
- TInt SetBufferSize(TInt aSize);
- TInt SetDataNotificationSize(TInt aSize);
+ TInt SetBufferSizeL(TInt aSize);
+ TInt SetDataNotificationSizeL(TInt aSize);
private:
//server related stuff
@@ -124,7 +124,7 @@
CSession2* NewSessionL(const TVersion& aVersion,const RMessage2& aMessage) const;
//on boot things
- TInt TraceSettingsOnBoot();
+ TInt TraceSettingsOnBootL();
TInt ResetBtracePrimaryFilters(RBTrace& aBTrace);
//action related things
@@ -153,7 +153,7 @@
//filter related stuff
ControlData* SetPrimaryFilters(RArray<TPtrC8> &aArguments);
- TInt GetValues(const TDesC8& aSectionName, RArray<TPtrC8>& aListBuffer);
+ TInt GetValuesL(const TDesC8& aSectionName, RArray<TPtrC8>& aListBuffer);
private:
//data
TInt iRunAsService;
--- a/traceservices/tracefw/ulogger/src/uloggerserver/uloggersession.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/src/uloggerserver/uloggersession.h Tue Aug 31 16:57:14 2010 +0300
@@ -45,7 +45,7 @@
CULoggerSession(RThread& aClient, CULoggerServer& aServer);
void ConstructL();
- void SendInteger(const RMessage2& aMessage, TUint32 aInt);
+ void SendIntegerL(const RMessage2& aMessage, TUint32 aInt);
//void PanicClient(TInt aPanic) const;
//data
--- a/traceservices/tracefw/ulogger/src/uloggerserver/uloggersrvsession.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/src/uloggerserver/uloggersrvsession.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -141,7 +141,7 @@
filterArray.Append((TUint32)array->At(i));
}
- error = iServer.SetActiveFilter(filterArray, EPrimaryFilter);
+ error = iServer.SetActiveFilterL(filterArray, EPrimaryFilter);
CleanupStack::PopAndDestroy(2,desData); //array, desData
filterArray.Close();
@@ -218,7 +218,7 @@
TUint32 tmp=1;
InternalizeFromBufL(readPtr, filterArray, tmp);
- error = iServer.SetActiveFilter(filterArray,ESecondaryFilter);
+ error = iServer.SetActiveFilterL(filterArray,ESecondaryFilter);
CleanupStack::PopAndDestroy(); //desData
filterArray.Close();
@@ -285,7 +285,7 @@
{
TBool enabled = EFalse;
iServer.GetSecondaryFiltering(enabled);
- SendInteger(aMessage, (TInt)enabled);
+ SendIntegerL(aMessage, (TInt)enabled);
}
break;
@@ -452,7 +452,7 @@
{
//Get the installed plugins
RArray<TPtrC8> tmpArray;
- error = iServer.GetInstalledInputPlugins(tmpArray);
+ error = iServer.GetInstalledInputPluginsL(tmpArray);
if(!error)
{
//<rewrite array and add separator to each record>
@@ -547,7 +547,7 @@
{
//Resize buffer size
TInt bufferSize = aMessage.Int0();
- error = iServer.SetBufferSize(bufferSize);
+ error = iServer.SetBufferSizeL(bufferSize);
}
break;
@@ -556,7 +556,7 @@
//Get buffer size
TInt bufferSize = 0;
error = iServer.GetBufandDataNotifyValuesL(KBuffer,bufferSize);
- SendInteger(aMessage, bufferSize);
+ SendIntegerL(aMessage, bufferSize);
}
break;
@@ -577,7 +577,7 @@
//Get buffer size
TInt bufferMode = 3;
error = iServer.GetBufandDataNotifyValuesL(KBufferMode,bufferMode);
- SendInteger(aMessage, bufferMode);
+ SendIntegerL(aMessage, bufferMode);
}
break;
@@ -585,7 +585,7 @@
{
//Set data notification size
TInt dataNotification = aMessage.Int0();
- error = iServer.SetDataNotificationSize(dataNotification);
+ error = iServer.SetDataNotificationSizeL(dataNotification);
}
break;
@@ -594,7 +594,7 @@
//Get Data Notification size
TInt dataNotification = 0;
error = iServer.GetBufandDataNotifyValuesL(KDataNotification,dataNotification);
- SendInteger(aMessage, dataNotification);
+ SendIntegerL(aMessage, dataNotification);
}
break;
@@ -607,7 +607,7 @@
aMessage.Complete(error);
}
-void CULoggerSession::SendInteger(const RMessage2& aMessage, TUint32 aInt)
+void CULoggerSession::SendIntegerL(const RMessage2& aMessage, TUint32 aInt)
{
HBufC8* size = HBufC8::NewLC(32);
size->Des().Num(aInt);
--- a/traceservices/tracefw/ulogger/unit_test/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -12,65 +12,57 @@
//
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
-PRJ_PLATFORMS
-WINSCW
-ARMV5
PRJ_TESTEXPORTS
-
//te_outfrwk files
-te_outfrwk.iby /epoc32/rom/include/te_outfrwk.iby
-../scripts/te_outfrwk.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_outfrwk.script
-
+te_outfrwk.iby /epoc32/rom/include/te_outfrwk.iby
+../scripts/te_outfrwk.script z:/testdata/scripts/te_outfrwk.script
//te_sysconfig
-te_sysconfig.iby /epoc32/rom/include/te_sysconfig.iby
-../scripts/te_sysconfig.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_sysconfig.script
-
+te_sysconfig.iby /epoc32/rom/include/te_sysconfig.iby
+../scripts/te_sysconfig.script z:/testdata/scripts/te_sysconfig.script
//te_outfrwkchans/te_file
-te_file.iby /epoc32/rom/include/te_file.iby
-../scripts/te_file.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_file.script
+te_file.iby /epoc32/rom/include/te_file.iby
+../scripts/te_file.script z:/testdata/scripts/te_file.script
//te_outfrwkchans/te_serial
-te_serial.iby /epoc32/rom/include/te_serial.iby
-../scripts/te_serial.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_serial.script
+te_serial.iby /epoc32/rom/include/te_serial.iby
+../scripts/te_serial.script z:/testdata/scripts/te_serial.script
//te_server
-te_server.iby /epoc32/rom/include/te_server.iby
-../scripts/te_server.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_server.script
+te_server.iby /epoc32/rom/include/te_server.iby
+../scripts/te_server.script z:/testdata/scripts/te_server.script
//te_client
-te_client.iby /epoc32/rom/include/te_client.iby
-../scripts/te_client.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_client.script
+te_client.iby /epoc32/rom/include/te_client.iby
+../scripts/te_client.script z:/testdata/scripts/te_client.script
//to run all script files at once.
-te_unittestsuite.iby /epoc32/rom/include/te_unittestsuite.iby
-../scripts/te_unittestsuite.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_unittestsuite.script
+te_unittestsuite.iby /epoc32/rom/include/te_unittestsuite.iby
+../scripts/te_unittestsuite.script z:/testdata/scripts/te_unittestsuite.script
//to run automated script files at once
-te_automatedsuite.iby /epoc32/rom/include/te_automatedsuite.iby
-../scripts/te_automatedsuite.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_automatedsuite.script
+te_automatedsuite.iby /epoc32/rom/include/te_automatedsuite.iby
+../scripts/te_automatedsuite.script z:/testdata/scripts/te_automatedsuite.script
+//Test script for platform that doesn't support serial port
+../scripts/te_automatedsuite_noserial.script z:/testdata/scripts/te_automatedsuite_noserial.script
//te_createconfig
-te_createconfig.iby /epoc32/rom/include/te_createconfig.iby
+te_createconfig.iby /epoc32/rom/include/te_createconfig.iby
//te_sysstart
-te_sysstart.iby /epoc32/rom/include/te_sysstart.iby
-../scripts/te_sysstart.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_sysstart.script
+te_sysstart.iby /epoc32/rom/include/te_sysstart.iby
+../scripts/te_sysstart.script z:/testdata/scripts/te_sysstart.script
PRJ_TESTMMPFILES
-te_outfrwk.mmp
-te_createconfig.mmp
-te_sysconfig.mmp
-te_file.mmp
-te_serial.mmp
-te_server.mmp
-te_client.mmp
-te_sysstart.mmp
+te_outfrwk.mmp manual
+te_createconfig.mmp manual
+te_sysconfig.mmp manual
+te_file.mmp manual
+te_serial.mmp manual
+te_server.mmp manual
+te_client.mmp manual
+te_sysstart.mmp manual
--- a/traceservices/tracefw/ulogger/unit_test/group/te_automatedsuite.iby Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/group/te_automatedsuite.iby Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -28,7 +28,6 @@
#include <te_createconfig.iby>
-file=ABI_DIR\DEBUG_DIR\RUNTESTS.EXE System\Programs\RUNTESTS.EXE
-
data=EPOCROOT##epoc32\release\winscw\udeb\z\testdata\scripts\te_automatedsuite.script testData\scripts\te_automatedsuite.script
+data=EPOCROOT##epoc32\release\winscw\udeb\z\testdata\scripts\te_automatedsuite_noserial.script testData\scripts\te_automatedsuite_noserial.script
#endif
--- a/traceservices/tracefw/ulogger/unit_test/group/te_client.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/group/te_client.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -20,7 +20,10 @@
UID 0x1000007A 0x101F7784
CAPABILITY NONE
-//Please add any change under here
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../../inc
+
SOURCEPATH ../te-client
SOURCE te_uloggerclientsuiteserver.cpp
SOURCE te_uloggerclientsuitestepbase.cpp
@@ -41,12 +44,6 @@
SOURCE testdeactivateoutputpluginstep.cpp
SOURCE testruloggerapi_ext.cpp
-USERINCLUDE ../../inc
-
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-
-//Please add your system include under here.
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
--- a/traceservices/tracefw/ulogger/unit_test/group/te_createconfig.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/group/te_createconfig.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -19,19 +19,15 @@
TARGETTYPE exe
UID 0x1000007A 0x101F7784
+OS_LAYER_SYSTEMINCLUDE
-//Please add any change under here
+USERINCLUDE ../../inc
+
SOURCEPATH ../te-createconfig
SOURCE te_createconfigserver.cpp
SOURCE te_clearconfig.cpp
SOURCE te_createconfigemptystep.cpp
SOURCE te_createconfigfullstep.cpp
-USERINCLUDE ../../inc
-
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-
-//Please add your system include under here.
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
--- a/traceservices/tracefw/ulogger/unit_test/group/te_file.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/group/te_file.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -21,24 +21,16 @@
CAPABILITY NONE
VENDORID 0x70000001
-//---------------------------------------
-// Specific files for TEFUnit
-//---------------------------------------
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/libc
-SYSTEMINCLUDE /epoc32/include/ecom
+OS_LAYER_SYSTEMINCLUDE
USERINCLUDE ../te-outfrwkchans/te-file
USERINCLUDE ../../inc
USERINCLUDE ../../src/outfrwkchans/file
+userinclude ../../src/pluginframework
SOURCEPATH ../../src/outfrwkchans/file
SOURCE uloggerfileplugin.cpp
-userinclude ../../src/pluginframework
-
-
SOURCEPATH ../te-outfrwkchans/te-file
SOURCE uloggerfileplugintest.cpp
SOURCE te_filesuiteserver.cpp
--- a/traceservices/tracefw/ulogger/unit_test/group/te_outfrwk.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/group/te_outfrwk.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -15,29 +15,21 @@
//
//
-/**
- @file
-*/
-
-
TARGET uloggeroutfrmwkserver.exe
TARGETTYPE EXE
uid 0x1000008d 0x10273889
CAPABILITY CommDD NetworkControl LocalServices ProtServ
VENDORID 0x70000001
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../../inc
+USERINCLUDE ../../src/pluginframework
SOURCEPATH ../te-outfrwk
SOURCE te_outfrwk_testserver.cpp
SOURCE te_outfrwk_teststep.cpp
-USERINCLUDE ../../inc
-
-USERINCLUDE ../../src/pluginframework
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/ecom
-
LIBRARY bafl.lib
LIBRARY euser.lib
LIBRARY testexecutelogclient.lib
--- a/traceservices/tracefw/ulogger/unit_test/group/te_serial.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/group/te_serial.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -21,24 +21,16 @@
CAPABILITY CommDD NetworkControl LocalServices ProtServ
VENDORID 0x70000001
-//---------------------------------------
-// Specific files for TEFUnit
-//---------------------------------------
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/libc
-SYSTEMINCLUDE /epoc32/include/ecom
+OS_LAYER_SYSTEMINCLUDE
USERINCLUDE ../te-outfrwkchans/te-serial
USERINCLUDE ../../inc
USERINCLUDE ../../src/outfrwkchans/serial
+USERINCLUDE ../../src/pluginframework
SOURCEPATH ../../src/outfrwkchans/serial
SOURCE uloggerserialplugin.cpp
-USERINCLUDE ../../src/pluginframework
-
-
SOURCEPATH ../te-outfrwkchans/te-serial
SOURCE uloggerserialplugintest.cpp
SOURCE te_serialsuiteserver.cpp
@@ -60,4 +52,3 @@
#endif
SMPSAFE
-
--- a/traceservices/tracefw/ulogger/unit_test/group/te_server.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/group/te_server.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -17,13 +17,18 @@
TARGET te_uloggerservertestsuite.exe
TARGETTYPE exe
-UID 0x1000007A 0x10273881
-//0x101F7784
-CAPABILITY CommDD NetworkControl LocalServices ProtServ
+UID 0x1000007A 0x10273881
+CAPABILITY CommDD NetworkControl LocalServices ProtServ
MACRO __ULOGGER_SERVER_UNIT_TEST
-//Please add any change under here
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../te-server
+USERINCLUDE ../../inc
+USERINCLUDE ../../src/pluginframework
+USERINCLUDE ../../src/uloggerserver
+
SOURCEPATH ../te-server
SOURCE te_uloggerservertestsuiteserver.cpp
SOURCE te_uloggerservertestsuitestepbase.cpp
@@ -40,9 +45,6 @@
SOURCE uloggersrvsession.cpp
SOURCE uloggerserver.cpp
-SMPSAFE
-
-
SOURCEPATH ../../src/pluginframework
SOURCE pluginallocator.cpp
SOURCE inputframework.cpp
@@ -52,19 +54,14 @@
SOURCEPATH ../../src/command
SOURCE uloggercommands.cpp
-USERINCLUDE ../te-server
-USERINCLUDE ../../inc
-USERINCLUDE ../../src/pluginframework
-USERINCLUDE ../../src/uloggerserver
-
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-SYSTEMINCLUDE /epoc32/include/ecom
-
-
-
-LIBRARY euser.lib estor.lib bafl.lib hal.lib efsrv.lib btracec.lib uloggersysconfig.lib
+LIBRARY euser.lib
+LIBRARY estor.lib
+LIBRARY bafl.lib
+LIBRARY hal.lib
+LIBRARY efsrv.lib
+LIBRARY btracec.lib
+LIBRARY uloggersysconfig.lib
LIBRARY testexecuteutils.lib
LIBRARY testexecutelogclient.lib ecom.lib
-
+SMPSAFE
--- a/traceservices/tracefw/ulogger/unit_test/group/te_sysconfig.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/group/te_sysconfig.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -15,20 +15,20 @@
//
//
-/**
- @file
-*/
-
-
TARGET te_syscfg.exe
TARGETTYPE exe
-
-VENDORID 0x70000001
-UID 0x1000008d 0x10273881
-CAPABILITY NONE
+VENDORID 0x70000001
+UID 0x1000008d 0x10273881
+CAPABILITY NONE
MACRO SYSCONFIG_COMTEST
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../../src/sysconfig
+USERINCLUDE ../../inc
+USERINCLUDE ../../src/pluginframework
+
SOURCEPATH ../te-sysconfig
SOURCE te_test_syscfgserver.cpp
SOURCE te_test_syscfgstep.cpp
@@ -37,13 +37,6 @@
source uloggersysconfig.cpp
source sysconfigimpl.cpp
-userinclude ../../src/sysconfig
-userinclude ../../inc
-userinclude ../../src/pluginframework
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/ecom
-SYSTEMINCLUDE /epoc32/include/test
-
LIBRARY euser.lib
LIBRARY testexecutelogclient.lib
LIBRARY testexecuteutils.lib
@@ -54,4 +47,3 @@
LIBRARY ecom.lib
SMPSAFE
-
--- a/traceservices/tracefw/ulogger/unit_test/group/te_sysstart.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/group/te_sysstart.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -21,10 +21,7 @@
VENDORID 0x70000001
MACRO __ULOGGER_SYSTEMSTART_UNIT_TEST
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
-
-
+OS_LAYER_SYSTEMINCLUDE
USERINCLUDE ../te-sysstart
USERINCLUDE ../../inc
@@ -33,7 +30,6 @@
SOURCEPATH ../../src/sysstarter
SOURCE uloggersysstarter.cpp
-
SOURCEPATH ../te-sysstart
SOURCE uloggersysstarttest.cpp
SOURCE te_sysstartersuiteserver.cpp
@@ -47,11 +43,8 @@
LIBRARY rfileloggerclient.lib
LIBRARY uloggerclient.lib
-
-
#if (!defined WINS)
LIBRARY estlib.lib
#endif
SMPSAFE
-
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/ulogger/unit_test/scripts/te_automatedsuite_noserial.script Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,33 @@
+// Copyright (c) 2010 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:
+// This script doesn't have serial test for platform that doesn't support serial port
+//
+
+PRINT ****RUNNING ALL ULOGGER UNIT TESTS****
+PRINT
+PRINT CLIENT API UNIT TESTS
+RUN_SCRIPT z:\testdata\scripts\te_client.script
+PRINT SERVER UNIT TESTS
+RUN_SCRIPT z:\testdata\scripts\te_server.script
+PRINT SYSTEM CONFIG TESTS
+RUN_SCRIPT z:\testdata\scripts\te_sysconfig.script
+PRINT FILE PLUG-IN TESTS
+RUN_SCRIPT z:\testdata\scripts\te_file.script
+PRINT **completed all ULogger Unit Tests**
+PRINT SERIAL PLUG-IN TESTS
+RUN_SCRIPT z:\testdata\scripts\te_outfrwk.script
+PRINT SYSTEM STARTER TESTS
+RUN_SCRIPT z:\testdata\scripts\te_sysstart.script
+PRINT
+PRINT ****COMPLETED ALL ULOGGER UNIT TESTS EXCEPT FOR CLT****
\ No newline at end of file
--- a/traceservices/tracefw/ulogger/unit_test/scripts/te_client.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/scripts/te_client.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -14,7 +14,7 @@
//
//
-//! @File
+//! @file
//! @SYMTestSuiteName uloggerv1-client-unit-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -39,7 +39,7 @@
//! @SYMTestActions Connect to ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestConnectStep
@@ -55,7 +55,7 @@
//! @SYMTestActions Set Primary Filter in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestSetPrimaryFltStep
@@ -71,7 +71,7 @@
//! @SYMTestActions Start ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestStartStep
@@ -87,7 +87,7 @@
//! @SYMTestActions Stop ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestStopStep
@@ -103,7 +103,7 @@
//! @SYMTestActions Get Primeay Filter in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestGetPrimaryFiltersLStep
@@ -119,7 +119,7 @@
//! @SYMTestActions Get secondary Filter in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestGetSecondaryFiltersLStep
@@ -135,7 +135,7 @@
//! @SYMTestActions Get buffer size in ulogger client
//! @SYMTestExpectedResults error return/buffer size as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestGetTraceBufferSizeStep
@@ -150,7 +150,7 @@
//! @SYMTestActions Remove Primeay Filter in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP -1 UloggerClientAPIServer TestRemovePrimaryFltStep
@@ -166,7 +166,7 @@
//! @SYMTestActions Resize buffer size in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestResizeTraceBufferSizeStep
@@ -183,7 +183,7 @@
//! @SYMTestActions Set DNS in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestSetDataNotificationSizeStep
@@ -199,7 +199,7 @@
//! @SYMTestActions Set all secondary Filtesr in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestSetSecondaryFilterAllStep
@@ -214,7 +214,7 @@
//! @SYMTestActions Set one secondary Filtesr in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestSetSecondaryFltStep
@@ -231,7 +231,7 @@
//! @SYMTestActions Get version in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestVersionStep
@@ -247,7 +247,7 @@
//! @SYMTestActions Deactivate output plugin in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerClientAPIServer TestDeactivateOutputPluginStep
@@ -263,7 +263,7 @@
//! @SYMTestActions Call RULogger API in ulogger client
//! @SYMTestExpectedResults error return as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 2000 UloggerClientAPIServer TestRULoggerAPIStep
--- a/traceservices/tracefw/ulogger/unit_test/scripts/te_file.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/scripts/te_file.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName uloggerv1-file-unit-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -32,7 +32,7 @@
//! @SYMTestActions Set and configure file plugin
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 uloggerplugfiletest file0Step
--- a/traceservices/tracefw/ulogger/unit_test/scripts/te_outfrwk.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/scripts/te_outfrwk.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName uloggerv1-outfrwk-unit-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -34,7 +34,7 @@
//! @SYMTestActions Set and configure output framework server
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 UloggerOutfrmwkServer TextMessageTeststep
@@ -48,7 +48,7 @@
//! @SYMTestActions Set and configure output framework server with OOM
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP !OOM 100 UloggerOutfrmwkServer TextMessageTeststep
--- a/traceservices/tracefw/ulogger/unit_test/scripts/te_serial.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/scripts/te_serial.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName uloggerv1-serial-unit-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -34,7 +34,7 @@
//! @SYMTestActions Set and configure serial plugin
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 uloggerplugserialtest serial0Step
--- a/traceservices/tracefw/ulogger/unit_test/scripts/te_server.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/scripts/te_server.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName uloggerv1-server-unit-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -39,7 +39,7 @@
//! @SYMTestActions STart and Stop watching in the server
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 te_UloggerServerTestSuite UloggerServerTest0Step
@@ -52,7 +52,7 @@
//! @SYMTestActions Call all possibly get/set/configure ulogger command methods in the server
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_UloggerServerTestSuite UloggerServerTest1Step
@@ -65,7 +65,7 @@
//! @SYMTestActions Call NewL and NewLC to create new server sessions
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 te_UloggerServerTestSuite UloggerServerTest2Step
@@ -78,7 +78,7 @@
//! @SYMTestActions Call NewL and NewLC to create new plugin allocations under various conditions
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 te_UloggerServerTestSuite UloggerServerTest3Step
@@ -91,7 +91,7 @@
//! @SYMTestActions Start/Stop reading and test functionality of passing and translating commands for server control framework
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 1000 te_UloggerServerTestSuite UloggerServerTest4Step
@@ -104,7 +104,7 @@
//! @SYMTestActions Call methods to change settings of server channels
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 te_UloggerServerTestSuite UloggerServerTest5Step
@@ -117,7 +117,7 @@
//! @SYMTestActions Call methods to pass data to/fro server
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 te_UloggerServerTestSuite UloggerServerTest6Step
--- a/traceservices/tracefw/ulogger/unit_test/scripts/te_sysconfig.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/scripts/te_sysconfig.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName uloggerv1-sysconfig-unit-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -38,7 +38,7 @@
//! @SYMTestActions Call Set/Get/Activate configuration methods for channels and plugins
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 Te_SysCfg SysCfgTeststep1
@@ -51,7 +51,7 @@
//! @SYMTestActions Call Set/Get/Remove configuration methods for sections and plugins
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 Te_SysCfg SysCfgTeststep2
@@ -64,7 +64,7 @@
//! @SYMTestActions Call Set/Get/Remove configuration methods for filters and buffer
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 Te_SysCfg SysCfgTeststep3
@@ -77,7 +77,7 @@
//! @SYMTestActions Call AddPlugin, RemoveChannel with various error cases
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 Te_SysCfg SysCfgTeststep4
--- a/traceservices/tracefw/ulogger/unit_test/scripts/te_sysstart.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/scripts/te_sysstart.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName uloggerv1-sysstart-unit-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -32,7 +32,7 @@
//! @SYMTestActions Call available start/configuration methods for ulogger systart
//! @SYMTestExpectedResults error returns as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 uloggersysstarttest sysStart0Step
--- a/traceservices/tracefw/ulogger/unit_test/te-client/te_uloggerclientsuiteserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/te_uloggerclientsuiteserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_ULOGGERCLIENT_SERVER_H__)
#define __TE_ULOGGERCLIENT_SERVER_H__
-#include <testexecuteserverbase.h>
+#include <test/testexecuteserverbase.h>
class CTestUloggerClientApi : public CTestServer
--- a/traceservices/tracefw/ulogger/unit_test/te-client/te_uloggerclientsuitestepbase.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/te_uloggerclientsuitestepbase.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_ULOGGERCLIENT_STEP_BASE__)
#define __TE_ULOGGERCLIENT_STEP_BASE__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "uloggerclient.h"
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testconnectstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testconnectstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTCONNECT_STEP_H__)
#define __TESTCONNECT_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestConnectStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testdeactivateoutputpluginstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testdeactivateoutputpluginstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTDEACTIVATEOUTPUTPLUGIN_STEP_H__)
#define __TESTDEACTIVATEOUTPUTPLUGIN_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestDeactivateOutputPluginStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testgetprimaryfilterslstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testgetprimaryfilterslstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTGETPRIMARYFILTERSL_STEP_H__)
#define __TESTGETPRIMARYFILTERSL_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestGetPrimaryFiltersLStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testgetsecondaryfilterslstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testgetsecondaryfilterslstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTGETSECONDARYFILTERSL_STEP_H__)
#define __TESTGETSECONDARYFILTERSL_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestGetSecondaryFiltersLStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testgettracebuffersizestep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testgettracebuffersizestep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTGETTRACEBUFFERSIZE_STEP_H__)
#define __TESTGETTRACEBUFFERSIZE_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestGetTraceBufferSizeStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testremoveprimaryfltstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testremoveprimaryfltstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTREMOVEPRIMARYFLT_STEP_H__)
#define __TESTREMOVEPRIMARYFLT_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testresizetracebuffersizestep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testresizetracebuffersizestep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTRESIZETRACEBUFFERSIZE_STEP_H__)
#define __TESTRESIZETRACEBUFFERSIZE_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestResizeTraceBufferSizeStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testruloggerapi_ext.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testruloggerapi_ext.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTRULOGGERAPI_EXT_H__)
#define __TESTRULOGGERAPI_EXT_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
#include <uloggerclient.h>
using namespace Ulogger;
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testsetdatanotificationsizestep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testsetdatanotificationsizestep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTSETDATANOTIFICATIONSIZE_STEP_H__)
#define __TESTSETDATANOTIFICATIONSIZE_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestSetDataNotificationSizeStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testsetoutputpluginsettingsstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testsetoutputpluginsettingsstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTSETOUTPUTPLUGINSETTINGS_STEP_H__)
#define __TESTSETOUTPUTPLUGINSETTINGS_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestSetOutputPluginSettingsStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testsetprimaryfltstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testsetprimaryfltstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TESTSETPRIMARYFLT_STEP_H__)
#define __TESTSETPRIMARYFLT_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestSetPrimaryFltStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testsetsecondaryfilterallstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testsetsecondaryfilterallstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTSETSECONDARYFILTERALL_STEP_H__)
#define __TESTSETSECONDARYFILTERALL_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestSetSecondaryFilterAllStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testsetsecondaryfltstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testsetsecondaryfltstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTSETSECONDARYFLT_STEP_H__)
#define __TESTSETSECONDARYFLT_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestSetSecondaryFltStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/teststartstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/teststartstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTSTART_STEP_H__)
#define __TESTSTART_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestStartStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/teststopstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/teststopstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTSTOP_STEP_H__)
#define __TESTSTOP_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestStopStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testtracebuffermodestep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testtracebuffermodestep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTRESIZETRACEBUFFERSIZE_STEP_H__)
#define __TESTRESIZETRACEBUFFERSIZE_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestTraceBufferModeStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-client/testversionstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-client/testversionstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __TESTVERSION_STEP_H__)
#define __TESTVERSION_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerclientsuitestepbase.h"
class CTestVersionStep : public CTestUloggerClientApiStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_clearconfig.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_clearconfig.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -35,7 +35,7 @@
}
-void CClearConfig::Clear(RULogger& loggerSession)
+void CClearConfig::ClearL(RULogger& loggerSession)
{
// CArrayPtrFlat<HBufC8> *activeplugins = new (ELeave)CArrayPtrFlat<HBufC8>(1);
// CleanupStack::PushL(activeplugins);
--- a/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_clearconfig.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_clearconfig.h Tue Aug 31 16:57:14 2010 +0300
@@ -34,7 +34,7 @@
public:
~CClearConfig();
CClearConfig();
- void Clear(RULogger& loggerSession);
+ void ClearL(RULogger& loggerSession);
//private:
};
--- a/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_createconfigemptystep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_createconfigemptystep.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -74,7 +74,7 @@
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
logger.SetSecondaryFilteringEnabled(EFalse);
--- a/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_createconfigemptystep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_createconfigemptystep.h Tue Aug 31 16:57:14 2010 +0300
@@ -25,7 +25,7 @@
#ifndef TE_CREATECONFIGEMPTYSTEP_H
#define TE_CREATECONFIGEMPTYSTEP_H
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
//Test Sysconfig of Ulogger
class CCreateConfigEmptyTestStep : public CTestStep
--- a/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_createconfigfullstep.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_createconfigfullstep.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -72,7 +72,7 @@
logger.Connect();
CClearConfig configIni;
- configIni.Clear(logger);
+ configIni.ClearL(logger);
_LIT8(KTextplugin,"uloggerfileplugin");
logger.ActivateOutputPlugin(KTextplugin);
--- a/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_createconfigfullstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_createconfigfullstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -25,7 +25,7 @@
#ifndef TE_CREATECONFIGFULLSTEP_H
#define TE_CREATECONFIGFULLSTEP_H
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
//Test Sysconfig of Ulogger
class CCreateConfigFUllTestStep : public CTestStep
--- a/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_createconfigserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-createconfig/te_createconfigserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -16,7 +16,7 @@
#ifndef TE_CREATECONFIG_SERVER_H
#define TE_CREATECONFIG_SERVER_H
-#include<testexecuteserverbase.h>
+#include <test/testexecuteserverbase.h>
/*
* Derived class of the CTestServer
--- a/traceservices/tracefw/ulogger/unit_test/te-outfrwk/te_outfrwk_testserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-outfrwk/te_outfrwk_testserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -16,7 +16,7 @@
#ifndef T_OUTFRWK_SERVER_H
#define T_OUTFRWK_SERVER_H
-#include<testexecuteserverbase.h>
+#include <test/testexecuteserverbase.h>
/*
* Derived class of the CTestServer
--- a/traceservices/tracefw/ulogger/unit_test/te-outfrwk/te_outfrwk_teststep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-outfrwk/te_outfrwk_teststep.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
#ifndef T_OUTFRWK_TESTSTEP_H
#define T_OUTFRWK_TESTSTEP_H
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include <e32base.h> // CBase
#include <e32test.h>
#include <f32file.h> // RFs, RFile
--- a/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-file/te_filesuiteserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-file/te_filesuiteserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_FILE_SERVER_H__)
#define __TE_FILE_SERVER_H__
-#include <testexecuteserverbase.h>
+#include <test/testexecuteserverbase.h>
class CTe_fileSuite : public CTestServer
--- a/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-file/te_filesuitestepbase.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-file/te_filesuitestepbase.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_FILE_STEP_BASE__)
#define __TE_FILE_STEP_BASE__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include <uloggerclient.h>
using namespace Ulogger;
--- a/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-file/uloggerfileplugintest.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-file/uloggerfileplugintest.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -36,7 +36,7 @@
delete fileWriter;
}
/*
- * TestUnlockResources: Test that the CloseOutputPlugin method ???
+ * TestUnlockResourcesL: Test that the CloseOutputPlugin method ???
*
* Expected Verdict: PASS/FAIL/PANIC
*
@@ -45,7 +45,7 @@
* Description: Retrieve and print some data from an external ini data file
*
*/
-void CFile0Step::TestUnlockResources()
+void CFile0Step::TestUnlockResourcesL()
{
CFileWriter* fileWriter = CFileWriter::NewL();
INFO_PRINTF1(_L("Invoking CFileWriter::CloseOutputPlugin(). CloseOutputPlugin() is supposed to do nothing."));
@@ -55,7 +55,7 @@
}
/*
- * TestSettings: Test that the Settings method ???
+ * TestSettingsL: Test that the Settings method ???
*
* Expected Verdict: PASS/FAIL/PANIC
*
@@ -64,7 +64,7 @@
* Description: Retrieve and print some data from an external ini data file
*
*/
-void CFile0Step::TestSettings()
+void CFile0Step::TestSettingsL()
{
CFileWriter* fileWriter = CFileWriter::NewL();
INFO_PRINTF1(_L("Passing empty RPointerArray to CFileWriter::ConfigureOutputPlugin()"));
@@ -75,7 +75,7 @@
}
/*
- * TestWrite: Test that the Write method ???
+ * TestWriteL: Test that the Write method ???
*
* Expected Verdict: PASS/FAIL/PANIC
*
@@ -86,7 +86,7 @@
*
*/
// The implementation for this is not working correctly! Check this
-void CFile0Step::TestWrite()
+void CFile0Step::TestWriteL()
{
INFO_PRINTF1(_L("Checking that CFileWriter::Write(const TDesC8&) writes a String correctly to C:\\logs\\log.txt"));
@@ -136,9 +136,9 @@
if (TestStepResult()==EPass)
{
TestNewL();
- TestUnlockResources();
- TestSettings();
- TestWrite();
+ TestUnlockResourcesL();
+ TestSettingsL();
+ TestWriteL();
if(iErrors == 0)
SetTestStepResult(EPass);
--- a/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-file/uloggerfileplugintest.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-file/uloggerfileplugintest.h Tue Aug 31 16:57:14 2010 +0300
@@ -20,7 +20,8 @@
#ifndef __ULOGGERFILEPLUGINTEST_H__
#define __ULOGGERFILEPLUGINTEST_H__
-#include <tefunit.h>
+#include <test/tefunit.h>
+
#include "uloggerfileplugin.h"
#include "te_filesuitestepbase.h"
@@ -37,9 +38,9 @@
private:
// Tests
void TestNewL();
- void TestUnlockResources();
- void TestSettings();
- void TestWrite();
+ void TestUnlockResourcesL();
+ void TestSettingsL();
+ void TestWriteL();
RFs iFileServer;
};
--- a/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-serial/te_serialsuiteserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-serial/te_serialsuiteserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_SERIAL_SERVER_H__)
#define __TE_SERIAL_SERVER_H__
-#include <testexecuteserverbase.h>
+#include <test/testexecuteserverbase.h>
class CTe_serialSuite : public CTestServer
--- a/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-serial/te_serialsuitestepbase.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-serial/te_serialsuitestepbase.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_SERIAL_STEP_BASE__)
#define __TE_SERIAL_STEP_BASE__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include <uloggerclient.h>
using namespace Ulogger;
--- a/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-serial/uloggerserialplugintest.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-serial/uloggerserialplugintest.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -47,7 +47,7 @@
* Description: Retrieve and print some data from an external ini data file
*
*/
-void CSerial0Step::TestUnlockResources()
+void CSerial0Step::TestUnlockResourcesL()
{
Ulogger::CSerialWriter* serialWriter = Ulogger::CSerialWriter::NewL();
INFO_PRINTF1(_L("Invoking CSerialWriter::CloseOutputPlugin(). CloseOutputPlugin() is supposed to do nothing."));
@@ -66,7 +66,7 @@
* Description: Retrieve and print some data from an external ini data file
*
*/
-void CSerial0Step::TestSettings()
+void CSerial0Step::TestSettingsL()
{
Ulogger::CSerialWriter* serialWriter = Ulogger::CSerialWriter::NewL();
INFO_PRINTF1(_L("Passing empty RPointerArray to CSerialWriter::ConfigureOutputPlugin()"));
@@ -92,7 +92,7 @@
*
*/
// The implementation for this is not working correctly! Check this
-void CSerial0Step::TestWrite()
+void CSerial0Step::TestWriteL()
{
INFO_PRINTF1(_L("Checking that CSerialWriter::Write(const TDesC8&) writes a string correctly to the serial port"));
@@ -148,9 +148,9 @@
if (TestStepResult()==EPass)
{
TestNewL();
- TestUnlockResources();
- TestSettings();
- TestWrite();
+ TestUnlockResourcesL();
+ TestSettingsL();
+ TestWriteL();
if(iErrors == 0)
SetTestStepResult(EPass);
--- a/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-serial/uloggerserialplugintest.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-outfrwkchans/te-serial/uloggerserialplugintest.h Tue Aug 31 16:57:14 2010 +0300
@@ -22,7 +22,8 @@
#ifndef __ULOGGERSERIALPLUGINTEST_H__
#define __ULOGGERSERIALPLUGINTEST_H__
-#include <tefunit.h>
+#include <test/tefunit.h>
+
#include "uloggerserialplugin.h"
#include "te_serialsuitestepbase.h"
@@ -38,9 +39,9 @@
private:
// Tests
void TestNewL();
- void TestUnlockResources();
- void TestSettings();
- void TestWrite();
+ void TestUnlockResourcesL();
+ void TestSettingsL();
+ void TestWriteL();
RFs iFileServer;
};
--- a/traceservices/tracefw/ulogger/unit_test/te-server/te_uloggerservertestsuiteserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-server/te_uloggerservertestsuiteserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_ULOGGERSERVERTEST_SERVER_H__)
#define __TE_ULOGGERSERVERTEST_SERVER_H__
-#include <testexecuteserverbase.h>
+#include <test/testexecuteserverbase.h>
class CTe_UloggerServerTestSuite : public CTestServer
--- a/traceservices/tracefw/ulogger/unit_test/te-server/te_uloggerservertestsuitestepbase.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-server/te_uloggerservertestsuitestepbase.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_ULOGGERSERVERTEST_STEP_BASE__)
#define __TE_ULOGGERSERVERTEST_STEP_BASE__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
// Please add your include here if you have
/****************************************************************************
--- a/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest0step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest0step.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __ULOGGERSERVERTEST0_STEP_H__)
#define __ULOGGERSERVERTEST0_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerservertestsuitestepbase.h"
#include "uloggerwatcher.h"
--- a/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest1step.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest1step.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -78,8 +78,8 @@
iErrors += Test15L();//CULoggerServer::GetInstalledPlugins
iMediaCount = 0;
iErrors += Test16L();//CULoggerServer::GetOutputPluginSettingsL
- iErrors += Test18L();//CULoggerServer::SetBufferSize
- iErrors += Test19L();//CULoggerServer::SetDataNotificationSize
+ iErrors += Test18L();//CULoggerServer::SetBufferSizeL
+ iErrors += Test19L();//CULoggerServer::SetDataNotificationSizeL
iErrors += Test20L();//CULoggerServer::GetBufferSize
iErrors += Test21L();// CULoggerServer::GetDataNotificationSize
iErrors += Test22L();//CULoggerServer::SetGlobalSecondaryFilters
@@ -315,7 +315,7 @@
aCategory.Append(194);
TInt e = KErrNone;
- e = server->SetActiveFilter(aCategory,EPrimaryFilter);
+ e = server->SetActiveFilterL(aCategory,EPrimaryFilter);
TBuf<128> buf;
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
@@ -340,7 +340,7 @@
{
RArray<TUint32> array;
array.Append(34);
- TInt e = server->SetActiveFilter(array,ESecondaryFilter);
+ TInt e = server->SetActiveFilterL(array,ESecondaryFilter);
TBuf<128> buf;
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
@@ -536,9 +536,9 @@
TInt CUloggerServerTest1Step::Test18L()
-{//CULoggerServer::SetBufferSize
+{//CULoggerServer::SetBufferSizeL
TInt errors = 0;
- INFO_PRINTF1(_L("Testing - CULoggerServer::SetBufferSize method"));
+ INFO_PRINTF1(_L("Testing - CULoggerServer::SetBufferSizeL method"));
CULoggerServer *server = NULL;
server = CULoggerServer::NewLC(EPriorityBackground);
if(server == NULL)
@@ -550,38 +550,38 @@
{
TInt e;
INFO_PRINTF1(_L("testing value: -1"));
- e = server->SetBufferSize(-1);
+ e = server->SetBufferSizeL(-1);
TBuf<128> buf;
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 0"));
- e = server->SetBufferSize(0);
+ e = server->SetBufferSizeL(0);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 100"));
- e = server->SetBufferSize(100);
+ e = server->SetBufferSizeL(100);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 65535"));
- e = server->SetBufferSize(65535);
+ e = server->SetBufferSizeL(65535);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 65536"));
- e = server->SetBufferSize(65536);
+ e = server->SetBufferSizeL(65536);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 165537"));
- e = server->SetBufferSize(165537);
+ e = server->SetBufferSizeL(165537);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
@@ -592,9 +592,9 @@
TInt CUloggerServerTest1Step::Test19L()
-{//CULoggerServer::SetDataNotificationSize
+{//CULoggerServer::SetDataNotificationSizeL
TInt errors = 0;
- INFO_PRINTF1(_L("Testing - CULoggerServer::SetDataNotificationSize method"));
+ INFO_PRINTF1(_L("Testing - CULoggerServer::SetDataNotificationSizeL method"));
CULoggerServer *server = NULL;
server = CULoggerServer::NewLC(EPriorityBackground);
if(server == NULL)
@@ -606,44 +606,44 @@
{
TInt e;
INFO_PRINTF1(_L("testing value: -1"));
- e = server->SetDataNotificationSize(-1);
+ e = server->SetDataNotificationSizeL(-1);
TBuf<128> buf;
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 0"));
- e = server->SetDataNotificationSize(0);
+ e = server->SetDataNotificationSizeL(0);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 100"));
- e = server->SetDataNotificationSize(100);
+ e = server->SetDataNotificationSizeL(100);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 65535"));
- e = server->SetDataNotificationSize(65535);
+ e = server->SetDataNotificationSizeL(65535);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 65536"));
- e = server->SetDataNotificationSize(65536);
+ e = server->SetDataNotificationSizeL(65536);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 85536"));
- e = server->SetDataNotificationSize(85536);
+ e = server->SetDataNotificationSizeL(85536);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
INFO_PRINTF1(_L("testing value: 165538"));
- e = server->SetDataNotificationSize(165538);
+ e = server->SetDataNotificationSizeL(165538);
buf.AppendFormat(_L("Code returned from method - %d"), e);
INFO_PRINTF1(buf);
buf.Zero();
@@ -914,10 +914,10 @@
}
-TInt CUloggerServerTest1Step::Test29L()//CULoggerServer::GetInstalledInputPlugins
+TInt CUloggerServerTest1Step::Test29L()//CULoggerServer::GetInstalledInputPluginsL
{
TInt errors = 0;
- INFO_PRINTF1(_L("Testing - CULoggerServer::GetInstalledInputPlugins method"));
+ INFO_PRINTF1(_L("Testing - CULoggerServer::GetInstalledInputPluginsL method"));
CULoggerServer *server = NULL;
server = CULoggerServer::NewLC(EPriorityBackground);
if(server == NULL)
@@ -928,7 +928,7 @@
else
{
RArray<TPtrC8> list;
- server->GetInstalledInputPlugins(list);
+ server->GetInstalledInputPluginsL(list);
list.Close();
CleanupStack::PopAndDestroy(); //server
}
--- a/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest1step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest1step.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __ULOGGERSERVERTEST1_STEP_H__)
#define __ULOGGERSERVERTEST1_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerservertestsuitestepbase.h"
@@ -55,8 +55,8 @@
TInt Test15L();//CULoggerServer::GetInstalledPlugins
TInt Test16L();//CULoggerServer::GetOutputPluginSettingsL
TInt Test17L();//CULoggerServer::GetOutputChannelL
- TInt Test18L();//CULoggerServer::SetBufferSize
- TInt Test19L();//CULoggerServer::SetDataNotificationSize
+ TInt Test18L();//CULoggerServer::SetBufferSizeL
+ TInt Test19L();//CULoggerServer::SetDataNotificationSizeL
TInt Test20L();//CULoggerServer::GetBufferSize
TInt Test21L();// CULoggerServer::GetDataNotificationSize
TInt Test22L();//CULoggerServer::SetGlobalSecondaryFilters
--- a/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest2step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest2step.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __ULOGGERSERVERTEST2_STEP_H__)
#define __ULOGGERSERVERTEST2_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerservertestsuitestepbase.h"
class CUloggerServerTest2Step : public CTe_UloggerServerTestSuiteStepBase
--- a/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest3step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest3step.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __ULOGGERSERVERTEST3_STEP_H__)
#define __ULOGGERSERVERTEST3_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerservertestsuitestepbase.h"
#include "uloggerwatcher.h"
--- a/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest4step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest4step.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __ULOGGERSERVERTEST4_STEP_H__)
#define __ULOGGERSERVERTEST4_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerservertestsuitestepbase.h"
#include "pluginallocator.h"
#include "inputframework.h"
--- a/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest5step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest5step.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __ULOGGERSERVERTEST5_STEP_H__)
#define __ULOGGERSERVERTEST5_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerservertestsuitestepbase.h"
--- a/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest6step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-server/uloggerservertest6step.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __ULOGGERSERVERTEST6_STEP_H__)
#define __ULOGGERSERVERTEST6_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_uloggerservertestsuitestepbase.h"
#include "inputdata.h"
--- a/traceservices/tracefw/ulogger/unit_test/te-sysconfig/te_test_syscfgserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-sysconfig/te_test_syscfgserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -16,7 +16,7 @@
#ifndef TE_SYSCFG_SERVER_H
#define TE_SYSCFG_SERVER_H
-#include<testexecuteserverbase.h>
+#include <test/testexecuteserverbase.h>
/*
* Derived class of the CTestServer
--- a/traceservices/tracefw/ulogger/unit_test/te-sysconfig/te_test_syscfgstep.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-sysconfig/te_test_syscfgstep.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#ifndef TE_SYSCFG_TESTSTEP_H
#define TE_SYSCFG_TESTSTEP_H
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include <e32base.h> // cbase
#include <e32test.h>
#include <f32file.h> // rfs, rfile
--- a/traceservices/tracefw/ulogger/unit_test/te-sysstart/te_sysstartersuiteserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-sysstart/te_sysstartersuiteserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_SYSSTARTER_SERVER_H__)
#define __TE_SYSSTARTER_SERVER_H__
-#include <testexecuteserverbase.h>
+#include <test/testexecuteserverbase.h>
class CTe_sysstartSuite : public CTestServer
--- a/traceservices/tracefw/ulogger/unit_test/te-sysstart/te_sysstartersuitestepbase.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-sysstart/te_sysstartersuitestepbase.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_SYSSTART_STEP_BASE__)
#define __TE_SYSSTART_STEP_BASE__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include <uloggerclient.h>
using namespace Ulogger;
--- a/traceservices/tracefw/ulogger/unit_test/te-sysstart/uloggersysstarttest.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/ulogger/unit_test/te-sysstart/uloggersysstarttest.h Tue Aug 31 16:57:14 2010 +0300
@@ -20,7 +20,8 @@
#ifndef __ULOGGERSYSSTARTTEST_H__
#define __ULOGGERSYSSTARTTEST_H__
-#include <tefunit.h>
+#include <test/tefunit.h>
+
#include "uloggersysstarter.h"
#include "te_sysstartersuitestepbase.h"
--- a/traceservices/tracefw/utf_trace_api/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -12,15 +12,10 @@
//
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
-
PRJ_PLATFORMS
DEFAULT
PRJ_EXPORTS
-../inc/e32utrace.h SYMBIAN_OS_LAYER_PLATFORM_EXPORT_PATH(e32utrace.h)
+../inc/e32utrace.h OS_LAYER_PLATFORM_EXPORT_PATH(e32utrace.h)
--- a/traceservices/tracefw/utf_trace_api/inc/e32utrace.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/inc/e32utrace.h Tue Aug 31 16:57:14 2010 +0300
@@ -83,14 +83,14 @@
+((aSchema)<<BTrace::ESubCategoryIndex*8))
/**@internalComponent*/
#define UTracePf0(aF1,aSchema,aContext,aPc) \
- ((BTrace::TBTrace1)BTrace::OutX) \
- (UTRACE_HEADER(4,(aF1),(aSchema),(aContext),(aPc)))
+ BTrace::OutX \
+ (UTRACE_HEADER(4,(aF1),(aSchema),(aContext),(aPc)),0,0,0)
/**@internalComponent*/
#define UTracePf1(aF1,aSchema,aContext,aPc,a1) \
- ((BTrace::TBTrace2)BTrace::OutX)(UTRACE_HEADER(8,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(a1))
+ BTrace::OutX(UTRACE_HEADER(8,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(a1),0,0)
/**@internalComponent*/
#define UTracePf2(aF1,aSchema,aContext,aPc,a1,a2) \
- ((BTrace::TBTrace3)BTrace::OutX)(UTRACE_HEADER(12,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(a1),(TUint32)(a2))
+ BTrace::OutX(UTRACE_HEADER(12,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(a1),(TUint32)(a2),0)
/**@internalComponent*/
#define UTracePf3(aF1,aSchema,aContext,aPc,a1,a2,a3) \
BTrace::OutX(UTRACE_HEADER(16,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(a1),(TUint32)(a2),(TUint32)(a3))
@@ -99,10 +99,10 @@
BTrace::OutBig(UTRACE_HEADER(8,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(a1),aData,(TInt)(aDataSize))
/**@internalComponent*/
#define UTraceSf0(aF1,aF2,aSchema,aContext,aPc) \
- ((BTrace::TBTrace2)BTrace::OutFilteredX)(UTRACE_HEADER(8,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(aF2))
+ BTrace::OutFilteredX(UTRACE_HEADER(8,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(aF2),0,0)
/** @internalComponent */
#define UTraceSf1(aF1,aF2,aSchema,aContext,aPc,a1) \
- ((BTrace::TBTrace3)BTrace::OutFilteredX)(UTRACE_HEADER(12,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(aF2),(TUint32)(a1))
+ BTrace::OutFilteredX(UTRACE_HEADER(12,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(aF2),(TUint32)(a1),0)
/** @internalComponent */
#define UTraceSf2(aF1,aF2,aSchema,aContext,aPc,a1,a2) \
BTrace::OutFilteredX(UTRACE_HEADER(16,(aF1),(aSchema),(aContext),(aPc)),(TUint32)(aF2),(TUint32)(a1),(TUint32)(a2))
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/bwins/utraceu.def Tue Aug 31 16:57:14 2010 +0300
@@ -0,0 +1,3 @@
+EXPORTS
+ ?CreateLogicalDevice@@YAPAVDLogicalDevice@@XZ @ 1 NONAME ; class DLogicalDevice * CreateLogicalDevice(void)
+
--- a/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/eabi/utraceu.def Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/eabi/utraceu.def Tue Aug 31 16:57:14 2010 +0300
@@ -1,3 +1,7 @@
EXPORTS
_Z19CreateLogicalDevicev @ 1 NONAME
+ _ZTI14DUTraceChannel @ 2 NONAME
+ _ZTI14DUTraceFactory @ 3 NONAME
+ _ZTV14DUTraceChannel @ 4 NONAME
+ _ZTV14DUTraceFactory @ 5 NONAME
--- a/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2006-2010 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"
@@ -12,24 +12,11 @@
//
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
-
PRJ_PLATFORMS
DEFAULT
-PRJ_EXPORTS
-#ifdef SYMBIAN_OLD_EXPORT_LOCATION
-../inc/d32utrace.h /epoc32/include/d32utrace.h
-#endif
-
-PRJ_MMPFILES
-utraceusr.mmp
-utracedrv.mmp
-utracedrv_lib.mmp
-
PRJ_TESTMMPFILES
-PRJ_TESTEXPORTS
+utraceusr.mmp manual
+utracedrv.mmp manual
+utracedrv_lib.mmp manual
--- a/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/group/utracedrv.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/group/utracedrv.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2007-2010 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"
@@ -15,15 +15,18 @@
//
//
-
-systeminclude /epoc32/include/drivers
-systeminclude /epoc32/include/kernel
-
#define NO_EKERN_LIB
#include "kernel/kern_ext.mmh"
target utrace.ldd
targettype ldd
+UID 0x100000af
+VENDORID 0x70000001
+capability all
+
+deffile utrace.def
+
+OS_LAYER_SYSTEMINCLUDE_SYMBIAN
userinclude ../inc/
@@ -32,15 +35,10 @@
library ekern.lib
-UID 0x100000af
-VENDORID 0x70000001
-
start wins
win32_headers
end
-capability all
-
MACRO SYMBIAN_TRACE_ENABLE
SMPSAFE
--- a/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/group/utracedrv_lib.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/group/utracedrv_lib.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -18,6 +18,5 @@
target utrace.lib
targettype implib
linkas utrace.ldd
-//deffile ../../~/ldd.def
SMPSAFE
--- a/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/group/utraceusr.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/group/utraceusr.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -15,13 +15,13 @@
//
//
-systeminclude /epoc32/include/
-userinclude ./ /epoc32/include/
-
-
target utrace.dll
targettype dll
deffile utracedll.def
+vendorid 0x70000001
+capability all
+
+OS_LAYER_SYSTEMINCLUDE
userinclude ../inc/
@@ -30,7 +30,4 @@
library euser.lib
-vendorid 0x70000001
-capability all
-
SMPSAFE
--- a/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/inc/d32utrace.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/inc/d32utrace.h Tue Aug 31 16:57:14 2010 +0300
@@ -18,16 +18,14 @@
#ifndef D32UTRACE_H
#define D32UTRACE_H
-/*#include <e32cmn.h>
+#include <e32cmn.h>
#include <e32ver.h>
-*/
#ifndef __KERNEL_MODE__
-//#include <e32std.h>
+#include <e32std.h>
#endif
-
/**
Interface to the utrace api.
--- a/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/src/utracedrv.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/src/utracedrv.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2005-2010 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"
@@ -15,9 +15,9 @@
//
//
-#include <kern_priv.h>
+#include <kernel/kern_priv.h>
#include <platform.h>
-#include <d32utrace.h>
+#include "d32utrace.h"
#include <e32utrace.h>
--- a/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/src/utraceusr.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/devicedriver/src/utraceusr.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -16,7 +16,7 @@
//
#include <e32std.h>
-#include <d32utrace.h>
+#include "d32utrace.h"
#include <e32svr.h>
--- a/traceservices/tracefw/utf_trace_api/unit_test/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -12,11 +12,6 @@
//
// Description:
//
-/**
- @file bld.inf
- @internalTechnology
-*/
-
#include "../devicedriver/group/bld.inf"
#include "../te-utrace/group/bld.inf"
--- a/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/group/bld.inf Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/group/bld.inf Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -15,27 +15,14 @@
//
//
-
-//PRJ_EXPORTS
-
-PRJ_TESTEXPORTS
-//to c:
-../scripts/te_utracesuite.script /epoc32/winscw/c/testdata/scripts/te_utracesuite.script
-../testdata/te_utracesuite.ini /epoc32/winscw/c/testdata/configs/te_utracesuite.ini
-//to z:
-../scripts/te_utracesuite.script /epoc32/release/winscw/udeb/z/testdata/scripts/te_utracesuite.script
-../testdata/te_utracesuite.ini /epoc32/release/winscw/udeb/z/testdata/configs/te_utracesuite.ini
-
-./te_utracesuite.iby /epoc32/rom/include/te_utracesuite.iby
-
-
-PRJ_MMPFILES
-
-
-PRJ_TESTMMPFILES
-te_utracesuite.mmp
-
PRJ_PLATFORMS
DEFAULT
+PRJ_TESTEXPORTS
+te_utracesuite.iby /epoc32/rom/include/te_utracesuite.iby
+../scripts/te_utracesuite.script z:/testdata/scripts/te_utracesuite.script
+../testdata/te_utracesuite.ini z:/testdata/configs/te_utracesuite.ini
+
+PRJ_TESTMMPFILES
+te_utracesuite.mmp manual
--- a/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/group/te_utracesuite.mmp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/group/te_utracesuite.mmp Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2002-2010 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"
@@ -17,19 +17,19 @@
TARGETTYPE exe
UID 0x1000007A 0x101F7784
+OS_LAYER_SYSTEMINCLUDE
+
+USERINCLUDE ../inc
+USERINCLUDE ../../devicedriver/inc
+
SOURCEPATH ../src
SOURCE te_utracesuiteserver.cpp
SOURCE te_utracesuitestepbase.cpp
SOURCE cutrace_nonstatic_step.cpp
SOURCE cutrace_static_step.cpp
SOURCE cutrace_user_performance_step.cpp
-SOURCE te_btracecmds.cpp cutrace_kernperf_step.cpp
-
-
-USERINCLUDE ../inc
-
-SYSTEMINCLUDE /epoc32/include
-SYSTEMINCLUDE /epoc32/include/test
+SOURCE te_btracecmds.cpp
+SOURCE cutrace_kernperf_step.cpp
LIBRARY euser.lib
LIBRARY testexecuteutils.lib
--- a/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/cutrace_kernperf_step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/cutrace_kernperf_step.h Tue Aug 31 16:57:14 2010 +0300
@@ -25,7 +25,7 @@
#define CUTRACE_KERNPERF_STEP_H_
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_utracesuitestepbase.h"
--- a/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/cutrace_nonstatic_step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/cutrace_nonstatic_step.h Tue Aug 31 16:57:14 2010 +0300
@@ -23,7 +23,7 @@
*/
#if (!defined __CUTRACE_PRINTF_CHAR_STEP_H__)
#define __CUTRACE_PRINTF_CHAR_STEP_H__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_utracesuitestepbase.h"
--- a/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/cutrace_static_step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/cutrace_static_step.h Tue Aug 31 16:57:14 2010 +0300
@@ -26,7 +26,7 @@
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_utracesuitestepbase.h"
class CUTrace_Static_Step : public CTe_UTraceSuiteStepBase
--- a/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/cutrace_user_performance_step.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/cutrace_user_performance_step.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
*/
#ifndef CUTRACE_PERFORMANCE_STEP_H_
#define CUTRACE_PERFORMANCE_STEP_H_
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include "te_utracesuitestepbase.h"
--- a/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/te_utracesuiteserver.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/te_utracesuiteserver.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_UTRACE_SERVER_H__)
#define __TE_UTRACE_SERVER_H__
-#include <testexecuteserverbase.h>
+#include <test/testexecuteserverbase.h>
class CTe_UTraceSuite : public CTestServer
--- a/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/te_utracesuitestepbase.h Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/inc/te_utracesuitestepbase.h Tue Aug 31 16:57:14 2010 +0300
@@ -24,7 +24,7 @@
#if (!defined __TE_UTRACE_STEP_BASE__)
#define __TE_UTRACE_STEP_BASE__
-#include <testexecutestepbase.h>
+#include <test/testexecutestepbase.h>
#include <e32utrace.h>
#include "te_btracecmds.h"
// Please add your include here if you have
--- a/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/scripts/te_utracesuite.script Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/scripts/te_utracesuite.script Tue Aug 31 16:57:14 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+// Copyright (c) 2008-2010 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"
@@ -13,7 +13,7 @@
// Description:
//
-//! @File
+//! @file
//! @SYMTestSuiteName utfv1-unit-test-suite.script
//! @SYMScriptTestEnvironment TEF
@@ -31,7 +31,7 @@
//! @SYMTestActions Measure the trace time of the implemented user-side API
//! @SYMTestExpectedResults Verify that performance of the trace APIs are not significantly more intrusive than previous implementations
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 300 te_UTraceSuite CUTrace_User_Performance_Step c:\testdata\configs\te_utracesuite.ini Performance
@@ -45,7 +45,7 @@
//! @SYMTestActions Test the implementation of nonstatic APIs
//! @SYMTestExpectedResults Verify that traces generated as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 te_UTraceSuite CUTrace_nonStatic_Step c:\testdata\configs\te_utracesuite.ini General
@@ -59,7 +59,7 @@
//! @SYMTestActions Test the implementation of static APIs
//! @SYMTestExpectedResults Verify that traces generated as expected
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
RUN_TEST_STEP 100 te_UTraceSuite CUTrace_Static_Step c:\testdata\configs\te_utracesuite.ini General
@@ -74,7 +74,7 @@
//! @SYMTestActions Measure the trace time of the implemented kernel-side API
//! @SYMTestExpectedResults Verify that performance of the trace APIs are not significantly more intrusive than previous implementations
//! @SYMTestType UT
-//! @SYMTESTSTATUS Implemented
+//! @SYMTestStatus Implemented
//! @SYMPREQ PREQ1635
//! @SYMREQ
//RUN_TEST_STEP 100 te_UTraceSuite CUTrace_KernPerf_Step c:\testdata\configs\te_utracesuite.ini General
--- a/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/src/cutrace_kernperf_step.cpp Thu Aug 19 11:36:21 2010 +0300
+++ b/traceservices/tracefw/utf_trace_api/unit_test/te-utrace/src/cutrace_kernperf_step.cpp Tue Aug 31 16:57:14 2010 +0300
@@ -16,14 +16,13 @@
//
/**
- @file CUTrace_Performance_Step.cpp
+ @file
@internalTechnology
*/
+#include "d32utrace.h"
+
#include "cutrace_kernperf_step.h"
#include "te_utracesuitedefs.h"
-#include <d32utrace.h>
-
-
CUTrace_KernPerf_Step::~CUTrace_KernPerf_Step()