From 3f9906687007336de7e049c9153cab59fdc41d77 Mon Sep 17 00:00:00 2001 From: Andrii Kurdiumov Date: Thu, 1 Jul 2021 09:15:23 +0600 Subject: [PATCH] Fix typo in variable name --- .../src/System/Drawing/DrawingComWrappers.cs | 8 ++++---- src/tests/Interop/COM/ComWrappers/API/Program.cs | 12 ++++++------ .../COM/ComWrappers/GlobalInstance/GlobalInstance.cs | 12 ++++++------ 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/src/libraries/System.Drawing.Common/src/System/Drawing/DrawingComWrappers.cs b/src/libraries/System.Drawing.Common/src/System/Drawing/DrawingComWrappers.cs index 7895381853c4a..236ae1be2aa03 100644 --- a/src/libraries/System.Drawing.Common/src/System/Drawing/DrawingComWrappers.cs +++ b/src/libraries/System.Drawing.Common/src/System/Drawing/DrawingComWrappers.cs @@ -27,9 +27,9 @@ private DrawingComWrappers() { } private static ComInterfaceEntry* InitializeComInterfaceEntry() { - GetIUnknownImpl(out IntPtr fpQueryInteface, out IntPtr fpAddRef, out IntPtr fpRelease); + GetIUnknownImpl(out IntPtr fpQueryInterface, out IntPtr fpAddRef, out IntPtr fpRelease); - IntPtr iStreamVtbl = IStreamVtbl.Create(fpQueryInteface, fpAddRef, fpRelease); + IntPtr iStreamVtbl = IStreamVtbl.Create(fpQueryInterface, fpAddRef, fpRelease); ComInterfaceEntry* wrapperEntry = (ComInterfaceEntry*)RuntimeHelpers.AllocateTypeAssociatedMemory(typeof(DrawingComWrappers), sizeof(ComInterfaceEntry)); wrapperEntry->IID = IID_IStream; @@ -68,10 +68,10 @@ protected override void ReleaseObjects(IEnumerable objects) internal static class IStreamVtbl { - public static IntPtr Create(IntPtr fpQueryInteface, IntPtr fpAddRef, IntPtr fpRelease) + public static IntPtr Create(IntPtr fpQueryInterface, IntPtr fpAddRef, IntPtr fpRelease) { IntPtr* vtblRaw = (IntPtr*)RuntimeHelpers.AllocateTypeAssociatedMemory(typeof(IStreamVtbl), IntPtr.Size * 14); - vtblRaw[0] = fpQueryInteface; + vtblRaw[0] = fpQueryInterface; vtblRaw[1] = fpAddRef; vtblRaw[2] = fpRelease; vtblRaw[3] = (IntPtr)(delegate* unmanaged)&Read; diff --git a/src/tests/Interop/COM/ComWrappers/API/Program.cs b/src/tests/Interop/COM/ComWrappers/API/Program.cs index 1a779a7da6155..52da8f8d060cf 100644 --- a/src/tests/Interop/COM/ComWrappers/API/Program.cs +++ b/src/tests/Interop/COM/ComWrappers/API/Program.cs @@ -18,10 +18,10 @@ class TestComWrappers : ComWrappers { protected unsafe override ComInterfaceEntry* ComputeVtables(object obj, CreateComInterfaceFlags flags, out int count) { - IntPtr fpQueryInteface = default; + IntPtr fpQueryInterface = default; IntPtr fpAddRef = default; IntPtr fpRelease = default; - ComWrappers.GetIUnknownImpl(out fpQueryInteface, out fpAddRef, out fpRelease); + ComWrappers.GetIUnknownImpl(out fpQueryInterface, out fpAddRef, out fpRelease); ComInterfaceEntry* entryRaw = null; count = 0; @@ -31,7 +31,7 @@ class TestComWrappers : ComWrappers { IUnknownImpl = new IUnknownVtbl() { - QueryInterface = fpQueryInteface, + QueryInterface = fpQueryInterface, AddRef = fpAddRef, Release = fpRelease }, @@ -70,9 +70,9 @@ public static void ValidateIUnknownImpls() { Console.WriteLine($"Running {nameof(ValidateIUnknownImpls)}..."); - ComWrappers.GetIUnknownImpl(out IntPtr fpQueryInteface, out IntPtr fpAddRef, out IntPtr fpRelease); + ComWrappers.GetIUnknownImpl(out IntPtr fpQueryInterface, out IntPtr fpAddRef, out IntPtr fpRelease); - Assert.AreNotEqual(fpQueryInteface, IntPtr.Zero); + Assert.AreNotEqual(fpQueryInterface, IntPtr.Zero); Assert.AreNotEqual(fpAddRef, IntPtr.Zero); Assert.AreNotEqual(fpRelease, IntPtr.Zero); } @@ -198,7 +198,7 @@ static void ValidateCreateObjectCachingScenario() static void ValidateWrappersInstanceIsolation() { - Console.WriteLine($"Running {nameof(ValidateWrappersInstanceIsolation)}..."); + Console.WriteLine($"Running {nameof(ValidateWrappersInstanceIsolation)}..."); var cw1 = new TestComWrappers(); var cw2 = new TestComWrappers(); diff --git a/src/tests/Interop/COM/ComWrappers/GlobalInstance/GlobalInstance.cs b/src/tests/Interop/COM/ComWrappers/GlobalInstance/GlobalInstance.cs index 899c4f9c74a8d..7a358a972f2da 100644 --- a/src/tests/Interop/COM/ComWrappers/GlobalInstance/GlobalInstance.cs +++ b/src/tests/Interop/COM/ComWrappers/GlobalInstance/GlobalInstance.cs @@ -116,14 +116,14 @@ class GlobalComWrappers : ComWrappers } else if (string.Equals(ManagedServerTypeName, obj.GetType().Name)) { - IntPtr fpQueryInteface = default; + IntPtr fpQueryInterface = default; IntPtr fpAddRef = default; IntPtr fpRelease = default; - ComWrappers.GetIUnknownImpl(out fpQueryInteface, out fpAddRef, out fpRelease); + ComWrappers.GetIUnknownImpl(out fpQueryInterface, out fpAddRef, out fpRelease); var vtbl = new IUnknownVtbl() { - QueryInterface = fpQueryInteface, + QueryInterface = fpQueryInterface, AddRef = fpAddRef, Release = fpRelease }; @@ -176,14 +176,14 @@ protected override void ReleaseObjects(IEnumerable objects) private unsafe ComInterfaceEntry* ComputeVtablesForTestObject(Test obj, out int count) { - IntPtr fpQueryInteface = default; + IntPtr fpQueryInterface = default; IntPtr fpAddRef = default; IntPtr fpRelease = default; - ComWrappers.GetIUnknownImpl(out fpQueryInteface, out fpAddRef, out fpRelease); + ComWrappers.GetIUnknownImpl(out fpQueryInterface, out fpAddRef, out fpRelease); var iUnknownVtbl = new IUnknownVtbl() { - QueryInterface = fpQueryInteface, + QueryInterface = fpQueryInterface, AddRef = fpAddRef, Release = fpRelease };