Skip to content

Commit ca28a91

Browse files
committed
Remove uncalled BestEffortCleanup methods
This allows TdsParser.netfx.cs to be deleted
1 parent cd40f4a commit ca28a91

File tree

4 files changed

+2
-78
lines changed

4 files changed

+2
-78
lines changed

src/Microsoft.Data.SqlClient/netfx/src/Microsoft.Data.SqlClient.csproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -927,7 +927,6 @@
927927
<Compile Include="Microsoft\Data\SqlClient\SqlConnectionHelper.cs" />
928928
<Compile Include="Microsoft\Data\SqlClient\SqlInternalConnectionTds.cs" />
929929
<Compile Include="Microsoft\Data\SqlClient\TdsParser.cs" />
930-
<Compile Include="Microsoft\Data\SqlClient\TdsParser.netfx.cs" />
931930
<Compile Include="Microsoft\Data\SqlClient\TdsParserStateObject.netfx.cs" />
932931
<Compile Include="Microsoft\Data\SqlClient\TdsParserStateObjectNative.cs" />
933932
</ItemGroup>

src/Microsoft.Data.SqlClient/netfx/src/Microsoft/Data/SqlClient/TdsParser.netfx.cs

Lines changed: 0 additions & 54 deletions
This file was deleted.

src/Microsoft.Data.SqlClient/src/Microsoft/Data/SqlClient/SqlBulkCopy.cs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1377,11 +1377,8 @@ private void RunParserReliably(BulkCopySimpleResultSet bulkCopyHandler = null)
13771377
internalConnection.ThreadHasParserLockForClose = true;
13781378
try
13791379
{
1380-
#if NETFRAMEWORK
1381-
_parser.RunReliably(RunBehavior.UntilDone, null, null, bulkCopyHandler, _stateObj);
1382-
#else
1383-
_parser.Run(RunBehavior.UntilDone, null, null, bulkCopyHandler, _stateObj);
1384-
#endif
1380+
// @TODO: CER Exception Handling was removed here (see GH#3581)
1381+
_parser.Run(RunBehavior.UntilDone, null, null, bulkCopyHandler, _stateObj);
13851382
}
13861383
finally
13871384
{

src/Microsoft.Data.SqlClient/src/Microsoft/Data/SqlClient/TdsParserSessionPool.cs

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -215,24 +215,6 @@ internal string TraceString()
215215
_cachedCount,
216216
_cache.Count);
217217
}
218-
219-
#if NETFRAMEWORK
220-
internal void BestEffortCleanup()
221-
{
222-
for (int i = 0; i < _cache.Count; i++)
223-
{
224-
TdsParserStateObject session = _cache[i];
225-
if (session != null)
226-
{
227-
SNIHandle sessionHandle = session.Handle;
228-
if (sessionHandle != null)
229-
{
230-
sessionHandle.Dispose();
231-
}
232-
}
233-
}
234-
}
235-
#endif
236218
}
237219
}
238220

0 commit comments

Comments
 (0)