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 misleading indentation warning in group_sync_read.c #91

Merged
merged 1 commit into from
Jul 11, 2017

Conversation

de-vri-es
Copy link
Contributor

GCC 6 warns about misleading indentation: code that appears to be guarded by an if-statement based on indentation, but actually isn't. That caused the warning below to appear with GCC 6. This PR adjust the indentation to fix the warning.

gcc -O2 -O3 -DLINUX -D_GNU_SOURCE -Wall -c -I../../include -m64 -fPIC -g -c ../../src/dynamixel_sdk/group_sync_read.c -o .objects/group_sync_read.o
../../src/dynamixel_sdk/group_sync_read.c: In function ‘groupSyncReadRxPacket’:
../../src/dynamixel_sdk/group_sync_read.c:257:5: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation]
     if (groupData[group_num].data_list[data_num].id == NOT_USED_ID)
     ^~
../../src/dynamixel_sdk/group_sync_read.c:260:7: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the ‘if’
       packetData[port_num].data_read

@de-vri-es de-vri-es force-pushed the fix-misleading-indent branch from a73fb79 to cfeed19 Compare May 24, 2017 19:20
@de-vri-es de-vri-es changed the title Fix misleading indentation wawrning in group_sync_read.c Fix misleading indentation warning in group_sync_read.c May 24, 2017
@LeonJung LeonJung changed the base branch from master to develop-mid July 11, 2017 01:38
@LeonJung LeonJung merged commit 2f3e671 into ROBOTIS-GIT:develop-mid Jul 11, 2017
@LeonJung
Copy link
Contributor

Thank you

@de-vri-es
Copy link
Contributor Author

Awesome, 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