Skip to content
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.

fix Issue 22779 - druntime: Calling __delete with null pointer-to-struct segfaults #3745

Merged
merged 1 commit into from
Feb 16, 2022
Merged

Conversation

ibuclaw
Copy link
Member

@ibuclaw ibuclaw commented Feb 16, 2022

As per the function documentation:

Destroys and then deallocates an object.

In detail, `__delete(x)` returns with no effect if `x` is `null`. Otherwise, it
performs the following actions in sequence:

@dlang-bot
Copy link
Contributor

dlang-bot commented Feb 16, 2022

Thanks for your pull request, @ibuclaw!

Bugzilla references

Auto-close Bugzilla Severity Description
22779 critical druntime: Calling __delete with null pointer-to-struct segfaults

Testing this PR locally

If you don't have a local development environment setup, you can use Digger to test this PR:

dub run digger -- build "stable + druntime#3745"

@ibuclaw ibuclaw changed the title Issue 22779 - druntime: Calling __delete with null pointer-to-struct segfaults fix Issue 22779 - druntime: Calling __delete with null pointer-to-struct segfaults Feb 16, 2022
@dlang-bot dlang-bot added the Bug Fix Include reference to corresponding bugzilla issue label Feb 16, 2022
@dlang-bot dlang-bot merged commit cc1f526 into dlang:stable Feb 16, 2022
@ibuclaw ibuclaw deleted the issue22779 branch February 16, 2022 12:31
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug Fix Include reference to corresponding bugzilla issue Easy Review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants