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

Improved whitespace to fix g++ 7 warning #1138

Merged
merged 1 commit into from
Aug 14, 2017

Conversation

racko
Copy link
Contributor

@racko racko commented Aug 12, 2017

.../ros_comm/tools/rosbag_storage/src/view.cpp:249:5: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
if ((bag.getMode() & bagmode::Read) != bagmode::Read)
^~
.../ros_comm/tools/rosbag_storage/src/view.cpp:252:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
boost::function<bool(ConnectionInfo const*)> query = TrueQuery();
^~~~~

@dirk-thomas
Copy link
Member

Please limit the patch to required changes to get rid of warning but avoid all other whitespace changes. While it would improve the code style it adds unnecessary extra effort when backporting patches between different branches.

.../ros_comm/tools/rosbag_storage/src/view.cpp:249:5: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
     if ((bag.getMode() & bagmode::Read) != bagmode::Read)
     ^~
.../ros_comm/tools/rosbag_storage/src/view.cpp:252:2: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the ‘if’
  boost::function<bool(ConnectionInfo const*)> query = TrueQuery();
  ^~~~~
@racko racko force-pushed the if_does_not_guard_fix branch from 8741466 to 6369533 Compare August 14, 2017 17:35
@racko
Copy link
Contributor Author

racko commented Aug 14, 2017

Updated

@dirk-thomas
Copy link
Member

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants