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

Fix some pvs reported issues #6837

Merged

Conversation

filimonov
Copy link
Contributor

One bug found by PVS Studio + 2 cosmetics

Category (leave one):

  • Bug Fix

Detailed description (optional):
See commit messages

@filimonov filimonov added pr-bugfix Pull request with bugfix, not backported by default can be tested labels Sep 5, 2019
@filimonov filimonov closed this Sep 6, 2019
@filimonov filimonov reopened this Sep 6, 2019
@@ -1222,8 +1222,8 @@ void Context::setCurrentQueryId(const String & query_id)
} words;
} random;

random.words.a = thread_local_rng();
random.words.b = thread_local_rng();
random.words.a = thread_local_rng(); //-V656
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any description?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suppresstion. It's required by PVS-Studio to be in exactly this format.
The only way is to write an additional describing comment in a line above, but it's too cumbersome to do it for every suppression.

@alexey-milovidov alexey-milovidov merged commit c90dfc1 into ClickHouse:master Sep 6, 2019
nikitamikhaylov pushed a commit that referenced this pull request Sep 12, 2019
Fix some pvs reported issues

(cherry picked from commit c90dfc1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr-bugfix Pull request with bugfix, not backported by default
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants