Change internal TimeStamp's type to IntPtr (#3528)
authorChangGyu Choi <uppletaste@gmail.com>
Fri, 10 Sep 2021 01:08:55 +0000 (10:08 +0900)
committerGitHub <noreply@github.com>
Fri, 10 Sep 2021 01:08:55 +0000 (10:08 +0900)
nint is not supported by current version.
This patch Changes TimeStamp's member attribute type
to IntPtr.

Signed-off-by: ChangGyu Choi <uppletaste@gmail.com>
src/Tizen.Applications.Common/Interop/Interop.Libc.cs
src/Tizen.Applications.Common/Tizen.Applications.Common.csproj
src/Tizen.Applications.Common/Tizen.Applications.RPCPort/Parcel.cs

index 2580f63..55d23c9 100644 (file)
@@ -30,8 +30,8 @@ internal static partial class Interop
         [StructLayout(LayoutKind.Sequential)]
         internal struct TimeStamp
         {
-            public nint sec;
-            public nint nsec;
+            public IntPtr sec;
+            public IntPtr nsec;
         }
     }
 }
index c829f98..53fd210 100755 (executable)
@@ -2,7 +2,6 @@
 
   <PropertyGroup>
     <TargetFramework>netstandard2.0</TargetFramework>
-    <LangVersion>9.0</LangVersion>
   </PropertyGroup>
 
   <ItemGroup>
index e3d0391..bdb3f47 100755 (executable)
@@ -141,7 +141,7 @@ namespace Tizen.Applications.RPCPort
             if (r != Interop.LibRPCPort.ErrorCode.None)
                 throw new InvalidIOException();
 
-            return new TimeStamp(time.sec, time.nsec);
+            return new TimeStamp(time.sec.ToInt64(), time.nsec.ToInt64());
         }
     };