Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Defer creation of locking model to ActivateOptions() #95

Merged
merged 2 commits into from
Oct 24, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 1 addition & 1 deletion src/log4net/Appender/FileAppender.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1657,7 +1657,7 @@ protected static string ConvertToFullPath(string path)
/// <summary>
/// The locking model to use
/// </summary>
private FileAppender.LockingModelBase m_lockingModel = new FileAppender.ExclusiveLock();
private FileAppender.LockingModelBase m_lockingModel;

#endregion Private Instance Fields

Expand Down
15 changes: 12 additions & 3 deletions src/log4net/log4net.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
<Product>Apache log4net</Product>
<Description>
log4net is a tool to help the programmer output log statements to a variety of output targets.
In case of problems with an application, it is helpful to enable logging so that the problem
In case of problems with an application, it is helpful to enable logging so that the problem
can be located. With log4net it is possible to enable logging at runtime without modifying the
application binary. The log4net package is designed so that log statements can remain in
application binary. The log4net package is designed so that log statements can remain in
shipped code without incurring a high performance cost. It follows that the speed of logging
(or rather not logging) is crucial.

Expand Down Expand Up @@ -64,6 +64,7 @@
<OutputPath>..\..\build\$(Configuration)</OutputPath>
<PackageOutputPath>..\..\build\artifacts</PackageOutputPath>
<DocumentationFile>..\..\build\$(Configuration)\$(TargetFramework)\$(AssemblyName).xml</DocumentationFile>
<AllowedOutputExtensionsInPackageBuildOutputFolder>$(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb</AllowedOutputExtensionsInPackageBuildOutputFolder>
</PropertyGroup>
<PropertyGroup>
<BaseAddress>285212672</BaseAddress>
Expand Down Expand Up @@ -203,4 +204,12 @@
</ItemGroup>
<PropertyGroup />
<Import Project="../MonoForFramework.targets" />
</Project>
<Target Name="_ResolveCopyLocalNuGetPackagePdbsAndXml" Condition="$(CopyLocalLockFileAssemblies) == true" AfterTargets="ResolveReferences">
<!-- "Workaround" for missing '.pdb'-Files from NuGet Packages -->
<!-- https://github.com/dotnet/sdk/issues/1458#issuecomment-420456386 -->
<ItemGroup>
<ReferenceCopyLocalPaths Include="@(ReferenceCopyLocalPaths->'%(RootDir)%(Directory)%(Filename).pdb')" Condition="'%(ReferenceCopyLocalPaths.NuGetPackageId)' != '' and Exists('%(RootDir)%(Directory)%(Filename).pdb')"/>
<ReferenceCopyLocalPaths Include="@(ReferenceCopyLocalPaths->'%(RootDir)%(Directory)%(Filename).xml')" Condition="'%(ReferenceCopyLocalPaths.NuGetPackageId)' != '' and Exists('%(RootDir)%(Directory)%(Filename).xml')"/>
</ItemGroup>
</Target>
</Project>