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

Potential buffer overflow in AMQueueImplP CancelTask #333

Open
MBradbury opened this issue Mar 11, 2015 · 0 comments
Open

Potential buffer overflow in AMQueueImplP CancelTask #333

MBradbury opened this issue Mar 11, 2015 · 0 comments

Comments

@MBradbury
Copy link
Contributor

I am getting the following warning in TinyOS 2.1.2 (though it looks like it is present in master).

tinyos/tos/lib/tossim/SimSchedulerBasicP.nc: In function ‘SimSchedulerBasicP$sim_scheduler_event_handle’:
tinyos/tos/system/AMQueueImplP.nc:135:76: warning: array subscript is above array bounds [-Warray-bounds]

queue has the size numClients and on line 135 there is the potential for queue to be accessed by the index "(i/8)*8 + j" where i can at most be (numClients/8) and j is between 0 and 7 inclusive.

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

No branches or pull requests

1 participant