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 off-by-one-error in BusIn/Out #8606

Merged
merged 1 commit into from
Nov 6, 2018
Merged

Conversation

pea-pod
Copy link
Contributor

@pea-pod pea-pod commented Oct 31, 2018

Description

All three Bus implementation files (BusIn.cpp, BusOut.cpp, and BusInOut.cpp) contain off-by-one-errors in the subscript operator implementations.

Only 16 In/Outs exist in the array, but the MBED_ASSERT allows the 17th index through without assertion.

Also, regarding the CLA, I submitted it less than an hour ago, so I may not be in the list yet.

Pull request type

[x] Fix
[ ] Refactor
[ ] Target update
[ ] Functionality change
[ ] Docs update
[ ] Test update
[ ] Breaking change

@cmonr cmonr requested a review from a team November 1, 2018 01:33
@cmonr
Copy link
Contributor

cmonr commented Nov 1, 2018

Wow, nice catch! Out of curiosity, how did you come across this?

Copy link

@deepikabhavnani deepikabhavnani left a comment

Choose a reason for hiding this comment

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

@pea-pod good catch... 👍

@NirSonnenschein
Copy link
Contributor

/morph build

@pea-pod
Copy link
Contributor Author

pea-pod commented Nov 4, 2018

Well, it all began one day when my dad met my mom…
…and that’s why I won’t go near lemurs.

To be honest, I saw it a while back when I was trying to teach myself C++, and learn how the mbed ecosystem worked.

I really like the whole concept with mbed (especially the healthy use of python) and am glad to that I can contribute.

@cmonr
Copy link
Contributor

cmonr commented Nov 5, 2018

/morph build

@mbed-ci
Copy link

mbed-ci commented Nov 5, 2018

Build : SUCCESS

Build number : 3548
Build artifacts/logs : http://mbed-os.s3-website-eu-west-1.amazonaws.com/?prefix=builds/8606/

Triggering tests

/morph test
/morph export-build
/morph mbed2-build

@mbed-ci
Copy link

mbed-ci commented Nov 5, 2018

@mbed-ci
Copy link

mbed-ci commented Nov 6, 2018

@0xc0170
Copy link
Contributor

0xc0170 commented Nov 6, 2018

/morph export-build

@0xc0170
Copy link
Contributor

0xc0170 commented Nov 6, 2018

/morph mbed2-build

@mbed-ci
Copy link

mbed-ci commented Nov 6, 2018

@cmonr cmonr merged commit 5549c52 into ARMmbed:master Nov 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants