Skip to content

Fix issue 11867: Assert failure in valueFlowContainerSize()#5317

Merged
chrchr-github merged 5 commits intocppcheck-opensource:mainfrom
pfultz2:valueflow-crash-tok-init-list
Aug 13, 2023
Merged

Fix issue 11867: Assert failure in valueFlowContainerSize()#5317
chrchr-github merged 5 commits intocppcheck-opensource:mainfrom
pfultz2:valueflow-crash-tok-init-list

Conversation

@pfultz2
Copy link
Copy Markdown
Contributor

@pfultz2 pfultz2 commented Aug 12, 2023

No description provided.

Comment thread lib/astutils.cpp
if (!tok->valueType())
return false;
const Library::Container* container = tok->valueType()->container;
return container->stdStringLike;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can container be nullptr?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, need to check for that.

@chrchr-github chrchr-github merged commit 48c91ab into cppcheck-opensource:main Aug 13, 2023
@pfultz2 pfultz2 deleted the valueflow-crash-tok-init-list branch August 13, 2023 20:47
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.

3 participants