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

Annotate return_overflow in mod_write() (CID #1604620) #5437

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jejones3141
Copy link
Contributor

This is arguably another example of trying to return a value not representable in the function return type. It's highly unlikely that anyone will pass a buffer of more than SSIZE_MAX bytes, but Coverity apparently doesn't consider that.

CIDs #1604605 and #1604616 explicitly do return error values not representable as int, but a ridiculously large buffer allocation will fail long before anyone calls mod_write(), so we annotate.

This is arguably another example of trying to return a value not
representable in the function return type. It's highly unlikely that
anyone will pass a buffer of more than SSIZE_MAX bytes, but Coverity
apparently doesn't consider that.

CIDs #1604605 and #1604616 explicitly do return error values not
representable as int, but a ridiculously large buffer allocation will
fail long before anyone calls mod_write(), so we annotate.
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.

1 participant