Skip to content

Commit

Permalink
Add check if exception assigned itself to inner exception
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-ext-simba-lf committed Sep 11, 2024
1 parent 8bbcf8f commit 49beca2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Snowflake.Data/Core/HttpUtil.cs
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,8 @@ protected override async Task<HttpResponseMessage> SendAsync(HttpRequestMessage
else
{
Exception innermostException = e;
while (innermostException.InnerException != null) innermostException = innermostException.InnerException;
while (innermostException.InnerException != null && innermostException != innermostException.InnerException)
innermostException = innermostException.InnerException;

if (innermostException is AuthenticationException)
{
Expand Down

0 comments on commit 49beca2

Please sign in to comment.