Commit 293a8edc authored by Marc Gravell's avatar Marc Gravell

Issue 106: wrap Cancel attempt in try/catch

parent 4fb305b2
...@@ -833,7 +833,8 @@ private static IEnumerable<T> QueryInternal<T>(this IDbConnection cnn, string sq ...@@ -833,7 +833,8 @@ private static IEnumerable<T> QueryInternal<T>(this IDbConnection cnn, string sq
{ {
if (reader != null) if (reader != null)
{ {
if (!reader.IsClosed) cmd.Cancel(); if (!reader.IsClosed) try { cmd.Cancel(); }
catch { /* don't spol the existing exception */ }
reader.Dispose(); reader.Dispose();
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment