ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From voze...@apache.org
Subject [12/50] ignite git commit: IGNITE-2410: .NET: Fixed JVM crash in DestroyCache() method. This closes #413.
Date Thu, 28 Jan 2016 07:37:12 GMT
IGNITE-2410: .NET: Fixed JVM crash in DestroyCache() method. This closes #413.


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/4079a65d
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/4079a65d
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/4079a65d

Branch: refs/heads/ignite-2324
Commit: 4079a65dc277b0187aa7727a0a0ce2ad1d325a74
Parents: 4d29b2d
Author: Pavel Tupitsyn <ptupitsyn@gridgain.com>
Authored: Wed Jan 20 14:59:32 2016 +0300
Committer: vozerov-gridgain <vozerov@gridgain.com>
Committed: Wed Jan 20 14:59:32 2016 +0300

----------------------------------------------------------------------
 .../dotnet/Apache.Ignite.Core.Tests/Cache/CacheAbstractTest.cs | 2 ++
 .../Impl/Unmanaged/IgniteJniNativeMethods.cs                   | 2 +-
 .../dotnet/Apache.Ignite.Core/Impl/Unmanaged/UnmanagedUtils.cs | 6 ++----
 3 files changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/4079a65d/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Cache/CacheAbstractTest.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Cache/CacheAbstractTest.cs
b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Cache/CacheAbstractTest.cs
index 0237a41..e57df6f 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Cache/CacheAbstractTest.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core.Tests/Cache/CacheAbstractTest.cs
@@ -3117,6 +3117,8 @@ namespace Apache.Ignite.Core.Tests.Cache
             var ex = Assert.Throws<ArgumentException>(() => ignite.GetCache<int,
int>(cacheName));
 
             Assert.IsTrue(ex.Message.StartsWith("Cache doesn't exist"));
+
+            Assert.Throws<InvalidOperationException>(() => cache.Get(1));
         }
 
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/4079a65d/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Unmanaged/IgniteJniNativeMethods.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Unmanaged/IgniteJniNativeMethods.cs
b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Unmanaged/IgniteJniNativeMethods.cs
index 70ad733..7a73bee 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Unmanaged/IgniteJniNativeMethods.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Unmanaged/IgniteJniNativeMethods.cs
@@ -56,7 +56,7 @@ namespace Apache.Ignite.Core.Impl.Unmanaged
         public static extern void* ProcessorGetOrCreateCache(void* ctx, void* obj, sbyte*
name);
 
         [DllImport(IgniteUtils.FileIgniteJniDll, EntryPoint = "IgniteProcessorDestroyCache")]
-        public static extern void* ProcessorDestroyCache(void* ctx, void* obj, sbyte* name);
+        public static extern void ProcessorDestroyCache(void* ctx, void* obj, sbyte* name);
 
         [DllImport(IgniteUtils.FileIgniteJniDll, EntryPoint = "IgniteProcessorAffinity")]
         public static extern void* ProcessorAffinity(void* ctx, void* obj, sbyte* name);

http://git-wip-us.apache.org/repos/asf/ignite/blob/4079a65d/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Unmanaged/UnmanagedUtils.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Unmanaged/UnmanagedUtils.cs
b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Unmanaged/UnmanagedUtils.cs
index 7b12010..f460c9f 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Unmanaged/UnmanagedUtils.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Core/Impl/Unmanaged/UnmanagedUtils.cs
@@ -163,15 +163,13 @@ namespace Apache.Ignite.Core.Impl.Unmanaged
             }
         }
 
-        internal static IUnmanagedTarget ProcessorDestroyCache(IUnmanagedTarget target, string
name)
+        internal static void ProcessorDestroyCache(IUnmanagedTarget target, string name)
         {
             sbyte* name0 = IgniteUtils.StringToUtf8Unmanaged(name);
 
             try
             {
-                void* res = JNI.ProcessorDestroyCache(target.Context, target.Target, name0);
-
-                return target.ChangeTarget(res);
+                JNI.ProcessorDestroyCache(target.Context, target.Target, name0);
             }
             finally
             {


Mime
View raw message