vpnengine/vpncleaner/src/vpncleanerexe.cpp
branchRCL_3
changeset 24 e06095241a65
parent 23 473321461bba
--- a/vpnengine/vpncleaner/src/vpncleanerexe.cpp	Tue Aug 31 16:14:16 2010 +0300
+++ b/vpnengine/vpncleaner/src/vpncleanerexe.cpp	Wed Sep 01 12:23:21 2010 +0100
@@ -17,10 +17,13 @@
 
 #include <e32base.h>
 #include <f32file.h>
+#include <centralrepository.h> // link against centralrepository.lib
+#include <settingsinternalcrkeys.h>
 
 #include "vpncleaner.h"
 
 
+LOCAL_C void  setKeysL();
 LOCAL_C TBool vpnOnRom();
 
 
@@ -35,6 +38,8 @@
         {
         TVpnCleaner vpnc;
         vpnc.Clean();
+
+        TRAP_IGNORE( setKeysL() );
         }
 
     delete cleanup;
@@ -44,6 +49,19 @@
     }
 
 
+LOCAL_C void setKeysL()
+    {
+    // Connecting and initialization:
+    CRepository* repository = CRepository::NewL(
+        KCRUidCommunicationSettings );
+
+    repository->Set( KSettingsVPNSupported, 0 );
+    repository->Delete( KSettingsVPNImplementation );
+
+    delete repository;
+    }
+
+
 LOCAL_C TBool vpnOnRom()
     {
     TBool ret = EFalse;