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

[Coverity CID :188730]Memory - corruptions in /drivers/sensor/lis2dh/lis2dh_trigger.c #10593

Closed
mandarcthorat1 opened this issue Oct 15, 2018 · 0 comments
Assignees
Labels
area: Drivers area: Sensors Sensors bug The issue is a bug, or the PR is fixing a bug Coverity A Coverity detected issue or its fix priority: medium Medium impact/importance bug

Comments

@mandarcthorat1
Copy link
Contributor

Static code scan issues seen in File: /drivers/sensor/lis2dh/lis2dh_trigger.c
Category: Memory - corruptions
Function: lis2dh_trigger_anym_set
Component: Drivers
CID: 188730
Please fix or provide comments to square it off in coverity in the link: https://scan9.coverity.com/reports.htm#v32951/p12996

@mandarcthorat1 mandarcthorat1 added area: Drivers bug The issue is a bug, or the PR is fixing a bug Coverity A Coverity detected issue or its fix labels Oct 15, 2018
@nashif nashif added the priority: medium Medium impact/importance bug label Oct 18, 2018
@galak galak added the area: Sensors Sensors label Dec 5, 2018
avisconti added a commit to avisconti/zephyr that referenced this issue Dec 5, 2018
FIX issue zephyrproject-rtos#10571 and zephyrproject-rtos#10593
atomic_xxx() functions expect the bit argument to be the
position index inside the target integer and not its
numerical representation (e. g. 5 means the 5th bit and not 32).
The original code could potentially override an adiacent variable.

Signed-off-by: Armando Visconti <armando.visconti@st.com>
andrewboie pushed a commit that referenced this issue Dec 5, 2018
FIX issue #10571 and #10593
atomic_xxx() functions expect the bit argument to be the
position index inside the target integer and not its
numerical representation (e. g. 5 means the 5th bit and not 32).
The original code could potentially override an adiacent variable.

Signed-off-by: Armando Visconti <armando.visconti@st.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Drivers area: Sensors Sensors bug The issue is a bug, or the PR is fixing a bug Coverity A Coverity detected issue or its fix priority: medium Medium impact/importance bug
Projects
None yet
Development

No branches or pull requests

5 participants