Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed issues found by PVS-Studio #1373

Merged
merged 2 commits into from
Sep 18, 2023

Conversation

stilettk
Copy link
Contributor

@stilettk stilettk commented Sep 17, 2023

I have performed a quick check with PVS-Studio - static analyzer for C, C++, C#, and Java code.

Found two issues, listed below. Other issues were either not critical, false positive or already known (e.g. disabled with #pragma).

V3038 The argument was passed to method several times. It is possible that other argument should be passed instead.

This seems like a typo: state5 was passed instead of state6:

ExpectedSessionState6(m_logger, Id, state1, state2, state3, state4, state5, state5, m_state);

V3114 IDisposable object 'store' is not disposed before method returns.

The store was not neither disposed nor closed (it implements IDisposable since .NET Framework 4.6)

Signed-off-by: Nickolay Batov <[email protected]>
Signed-off-by: Nickolay Batov <[email protected]>
@bgrainger bgrainger merged commit 5ce15fb into mysql-net:master Sep 18, 2023
23 of 24 checks passed
@stilettk stilettk deleted the static-analysis-fixes branch September 18, 2023 17:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants