File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
Provider/src/FirebirdSql.Data.FirebirdClient/Common Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -30,8 +30,8 @@ static ShutdownHelper()
3030 _pools = new ConcurrentBag < Action > ( ) ;
3131 _fbClients = new ConcurrentBag < Action > ( ) ;
3232#if ! NETSTANDARD1_6
33- AppDomain . CurrentDomain . DomainUnload += ( sender , e ) => HandleShutdown ( ) ;
34- AppDomain . CurrentDomain . ProcessExit += ( sender , e ) => HandleShutdown ( ) ;
33+ AppDomain . CurrentDomain . DomainUnload += ( sender , e ) => HandleDomainUnload ( ) ;
34+ AppDomain . CurrentDomain . ProcessExit += ( sender , e ) => HandleProcessShutdown ( ) ;
3535#endif
3636 }
3737
@@ -45,10 +45,15 @@ internal static void RegisterFbClientShutdown(Action item)
4545 _fbClients . Add ( item ) ;
4646 }
4747
48- static void HandleShutdown ( )
48+ static void HandleDomainUnload ( )
4949 {
5050 foreach ( var item in _pools )
5151 item ( ) ;
52+ }
53+
54+ static void HandleProcessShutdown ( )
55+ {
56+ HandleDomainUnload ( ) ;
5257 foreach ( var item in _fbClients )
5358 item ( ) ;
5459 }
You can’t perform that action at this time.
0 commit comments