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

Conversion from LONGCHAR to CHARACTER can overflow if source expression is larger than 32kb #1079

Open
stefandrissen opened this issue Oct 17, 2023 · 0 comments

Comments

@stefandrissen
Copy link

Could this be handled automatically?

DEFINE VARIABLE cresponse  AS CHARACTER   NO-UNDO.
DEFINE VARIABLE oMemptr    AS OpenEdge.Core.Memptr NO-UNDO.

oMemptr = New OpenEdge.Core.Memptr().
cresponse = oMemptr:GetString( 1, 30000 ).

The second parameter op the GetString method ensures that the result is < 32000.

@gquerret gquerret changed the title FP: Conversion from LONGCHAR to CHARACTER can overflow if source expression is larger than 32kb Conversion from LONGCHAR to CHARACTER can overflow if source expression is larger than 32kb Oct 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants