diff --git a/SharpLib.csproj b/SharpLib.csproj
index 89c674e..ba0cd54 100644
--- a/SharpLib.csproj
+++ b/SharpLib.csproj
@@ -11,10 +11,14 @@
true
true
preview
+
- $(NoWarn);SYSLIB0050
+ $(NoWarn);SYSLIB0050;CS8981
diff --git a/logging/Log.cs b/logging/Log.cs
index af43dd3..0357503 100644
--- a/logging/Log.cs
+++ b/logging/Log.cs
@@ -368,8 +368,7 @@ static public class log
var timeLine = new LogEvent( LogType.Raw, $" D A T E {time.Year}/{time.Month.ToString("00")}/{time.Day.ToString("00")} T I M E {time.Hour.ToString("00")}:{time.Minute.ToString("00")}:{time.Second.ToString("00")}.{time.Millisecond.ToString("000")}{time.Microsecond.ToString("000")}", "", 0, "", "lib.time", null );
-
- writeToAll( endLine );
+ //writeToAll( endLine );
writeToAll( blankLine );
writeToAll( blankLine );
writeToAll( beginLine );
@@ -378,7 +377,6 @@ static public class log
writeToAll( blankLine );
-
while( s_running )
{
while( s_events.TryDequeue( out var evt ) )
@@ -389,12 +387,22 @@ static public class log
// TODO PERF Replace this with a semaphore/mutex
Thread.Sleep( 0 );
}
+
+ writeToAll( endLine );
+
}
- static void stop()
+ public static void stop()
{
+ if( !s_running ) return;
+
s_running = false;
+ while( s_thread.IsAlive )
+ {
+ Thread.Sleep( 0 );
+ }
+
s_writer.Close();
s_stream.Close();
@@ -500,7 +508,7 @@ static public class log
var truncatedCat = evt.Cat.Substring( 0, Math.Min( s_catWidth, evt.Cat.Length ) );
- var timeHdr = $"{evt.Time.Year}-{evt.Time.Month.ToString("00")}-{evt.Time.Day.ToString("00")} {evt.Time.Hour.ToString("00")}:{evt.Time.Minute.ToString("00")}:{evt.Time.Second.ToString("00")}.{evt.Time.Millisecond.ToString("000")}";
+ var timeHdr = $"{evt.Time.Year}-{evt.Time.Month.ToString("00")}-{evt.Time.Day.ToString("00")} {evt.Time.Hour.ToString("00")}:{evt.Time.Minute.ToString("00")}:{evt.Time.Second.ToString("00")}.{evt.Time.Millisecond.ToString("000")}{evt.Time.Microsecond.ToString("000")}";
var msgHdr = string.Format( $"{timeHdr} | {{0,-{s_catWidth}}}{{1}}| ", truncatedCat, sym );
@@ -514,7 +522,6 @@ static public class log
}
-
static public string msgPrint( LogEvent evt )
{
var msgHdr = headerPrint( evt );
diff --git a/math/AngleSingle.cs b/math/AngleSingle.cs
index 5c57cc3..fd81764 100644
--- a/math/AngleSingle.cs
+++ b/math/AngleSingle.cs
@@ -7,17 +7,17 @@
// -----------------------------------------------------------------------------
/*
* Copyright (c) 2007-2011 SlimDX Group
-*
+*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
-*
+*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
-*
+*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
@@ -771,7 +771,7 @@ namespace math
/// its value is equal to the value of the current math.Angle
/// object; otherwise, false.
///
- public override bool Equals( object obj )
+ public override bool Equals( object? obj )
{
return ( obj is AngleSingle ) && ( this == (AngleSingle)obj );
}