Skip to content

Fix UB in descriptor_set_layout.cpp#987

Merged
marty-johnson59 merged 1 commit intoKhronosGroup:mainfrom
jherico:patch-1
Mar 21, 2024
Merged

Fix UB in descriptor_set_layout.cpp#987
marty-johnson59 merged 1 commit intoKhronosGroup:mainfrom
jherico:patch-1

Conversation

@jherico
Copy link
Copy Markdown
Contributor

@jherico jherico commented Mar 15, 2024

Description

Move the scope of an extension structure so that it has the same call as the parent structure to which it may be attached via a pNext chain.

Fixes #986

General Checklist:

Please ensure the following points are checked:

  • My code follows the coding style
  • I have reviewed file licenses
  • I have commented any added functions (in line with Doxygen)
  • I have commented any code that could be hard to understand
  • My changes do not add any new compiler warnings
  • My changes do not add any new validation layer errors or warnings
  • I have used existing framework/helper functions where possible
  • My changes do not add any regressions
  • I have tested every sample to ensure everything runs correctly
  • This PR describes the scope and expected impact of the changes I am making

Note: The Samples CI runs a number of checks including:

  • I have updated the header Copyright to reflect the current year (CI build will fail if Copyright is out of date)
  • My changes build on Windows, Linux, macOS and Android. Otherwise I have documented any exceptions

@SaschaWillems
Copy link
Copy Markdown
Collaborator

Great catch. I think the reason this never really caused much of a problem is that it only seems to be used in a single sample.

@SaschaWillems SaschaWillems self-requested a review March 16, 2024 10:58
@jherico jherico changed the title Update descriptor_set_layout.cpp Fix UB in descriptor_set_layout.cpp Mar 17, 2024
@marty-johnson59
Copy link
Copy Markdown
Contributor

Merging - 3 approvals

@marty-johnson59 marty-johnson59 merged commit 9ad2c09 into KhronosGroup:main Mar 21, 2024
jeroenbakker-atmind pushed a commit to jeroenbakker-atmind/Vulkan-Samples that referenced this pull request Mar 27, 2024
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.

reference to an out of scope variable

5 participants