Terraria v1.4.4.9
Terraria source code documentation
All Classes Namespaces Files Functions Variables Enumerations Enumerator Properties Events Macros

◆ Lock()

static void System.IO.Strategies.FileStreamHelpers.Lock ( SafeFileHandle handle,
bool canWrite,
long position,
long length )
inlinestaticpackage

Definition at line 262 of file FileStreamHelpers.cs.

263 {
264 int offsetLow = (int)position;
265 int offsetHigh = (int)(position >> 32);
266 int countLow = (int)length;
267 int countHigh = (int)(length >> 32);
269 {
270 throw Win32Marshal.GetExceptionForLastWin32Error(handle.Path);
271 }
272 }
static bool LockFile(SafeFileHandle handle, int offsetLow, int offsetHigh, int countLow, int countHigh)

References System.Runtime.Serialization.Dictionary, System.IO.Win32Marshal.GetExceptionForLastWin32Error(), System.handle, System.length, and Interop.Kernel32.LockFile().

Referenced by System.IO.Strategies.Net5CompatFileStreamStrategy.Lock(), and System.IO.Strategies.OSFileStreamStrategy.Lock().