forked from nhibernate/nhibernate-core
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
nhibernateGH-3530: The Sybase SqlAnywhere DotNet4 driver does not imp…
…lement DbDataReader.GetChar and incorrectly uses Convert without specifying an IFormatProvider. Wrap the Sybase SqlAnywhere DotNet4 DbDataReader in a SqlAnywhereDbDataReader to correct these issues.
- Loading branch information
David Ellingsworth
authored and
David Ellingsworth
committed
Jun 14, 2024
1 parent
2b8c35e
commit dff6329
Showing
2 changed files
with
42 additions
and
3 deletions.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
src/NHibernate/Async/Driver/SybaseSQLAnywhereDotNet4Driver.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
//------------------------------------------------------------------------------ | ||
// <auto-generated> | ||
// This code was generated by AsyncGenerator. | ||
// | ||
// Changes to this file may cause incorrect behavior and will be lost if | ||
// the code is regenerated. | ||
// </auto-generated> | ||
//------------------------------------------------------------------------------ | ||
|
||
|
||
using System.Data.Common; | ||
using NHibernate.AdoNet; | ||
|
||
namespace NHibernate.Driver | ||
{ | ||
using System.Threading.Tasks; | ||
using System.Threading; | ||
public partial class SybaseSQLAnywhereDotNet4Driver : ReflectionBasedDriver | ||
{ | ||
|
||
public override async Task<DbDataReader> ExecuteReaderAsync(DbCommand command, CancellationToken cancellationToken) | ||
{ | ||
cancellationToken.ThrowIfCancellationRequested(); | ||
var reader = await (command.ExecuteReaderAsync(cancellationToken)).ConfigureAwait(false); | ||
|
||
return new SqlAnywhereDbDataReader(reader); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters