Skip to content
Snippets Groups Projects

Error expressions, part 5.

Merged Elizabeth Figura requested to merge zfigura/vkd3d:mr0 into master
1 unresolved thread

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
8956 8956 {
8957 8957 if (!add_record_access_recurse(ctx, $1, $3, &@2))
8958 8958 {
8959 destroy_block($1);
8959 8960 vkd3d_free($3);
8960 8961 YYABORT;
  • Comment on lines +8959 to 8961

    It is important to free memory if we reach YYABORT? There will be a lot of other allocations in hlsl_ctx that won't be freed before the program terminates. It is good to put these to remember which memory allocations this chunk of code is responsible for?

  • We should be freeing memory on YYABORT, but it's often forgotten. And of course part of the point of this "error" effort is to get rid of YYABORTs anyway.

    That commit is kind of old; I don't remember why I decided to fix that specific leak. But it is correct, so...

  • Please register or sign in to reply
  • Francisco Casas approved this merge request

    approved this merge request

  • Henri Verbeet approved this merge request

    approved this merge request

  • Henri Verbeet added 25 commits

    added 25 commits

    • ebbb483f...ae1d62f6 - 20 commits from branch wine:master
    • 94cf4320 - vkd3d-shader/hlsl: Handle error expressions in conditions.
    • 8b98e483 - vkd3d-shader/hlsl: Handle error expressions in return statements.
    • 7905c477 - vkd3d-shader/hlsl: Handle error expressions in array sizes.
    • bb741806 - vkd3d-shader/hlsl: Return an error expression when an invalid subscript is used.
    • 390a330b - vkd3d-shader/hlsl: Avoid leaking the block in the subscript rule.

    Compare with previous version

  • Please register or sign in to reply
    Loading