Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Apply suggestions from code review
Co-authored-by: Stephen Toub <[email protected]>
  • Loading branch information
adamsitnik and stephentoub authored Jul 10, 2021
commit af8ffdd7b64675145ad6a6e60a586bc9d4677bde
Original file line number Diff line number Diff line change
Expand Up @@ -290,9 +290,9 @@ private static Version GetICUVersion()

public static bool IsNet5CompatFileStreamEnabled => _net5CompatFileStream.Value;

private static readonly Lazy<bool> _fileLockingDisabled = new Lazy<bool>(() => GetStaticNonPublicBooleanPropertyValue("Microsoft.Win32.SafeHandles.SafeFileHandle", "DisableFileLocking"));
private static readonly Lazy<bool> s_fileLockingDisabled = new Lazy<bool>(() => GetStaticNonPublicBooleanPropertyValue("Microsoft.Win32.SafeHandles.SafeFileHandle", "DisableFileLocking"));

public static bool IsFileLockingEnabled => IsWindows || !_fileLockingDisabled.Value;
public static bool IsFileLockingEnabled => IsWindows || !s_fileLockingDisabled.Value;

private static bool GetIsInContainer()
{
Expand Down