Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ HandleGetImpersonationUserNameError()

unsafe string System.IO.Pipes.NamedPipeServerStream.HandleGetImpersonationUserNameError ( int error,
uint userNameMaxLength,
char * userName )
inlineprivate

Definition at line 431 of file NamedPipeServerStream.cs.

432 {
433 if ((error == 0 || error == 1368) && Environment.Is64BitProcess)
434 {
435 global::Interop.Kernel32.LoadLibraryEx("sspicli.dll", IntPtr.Zero, 2048);
436 if (global::Interop.Kernel32.GetNamedPipeHandleStateW(base.InternalHandle, null, null, null, null, userName, userNameMaxLength))
437 {
438 return new string(userName);
439 }
441 }
442 throw WinIOError(error);
443 }
Exception WinIOError(int errorCode)

References System.Runtime.InteropServices.Marshal.GetLastPInvokeError(), System.Environment.Is64BitProcess, System.IO.Pipes.PipeStream.WinIOError(), and System.IntPtr.Zero.

Referenced by System.IO.Pipes.NamedPipeServerStream.GetImpersonationUserName().