Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

[v1.4.x] Tidy up storage allocation and deallocation (#14480) #14768

Merged
merged 1 commit into from
Apr 23, 2019

Conversation

yuxihu
Copy link
Member

@yuxihu yuxihu commented Apr 22, 2019

Cherry-pick memory leak fix to v1.4.x branch.

* free memory when dptr is not nullptr

* skip memory allocation when handle size is 0

* update comments

* update Alloc in naive storage manager

* address comments

* add unit test for size 0 allocation
@yuxihu yuxihu requested a review from anirudh2290 as a code owner April 22, 2019 22:50
@yuxihu
Copy link
Member Author

yuxihu commented Apr 22, 2019

@junrushao1994 @szha Please help review and merge. Thanks.

Copy link
Member

@junrushao junrushao left a comment

Choose a reason for hiding this comment

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

LGTM

@szha szha merged commit b986d06 into apache:v1.4.x Apr 23, 2019
@yuxihu yuxihu deleted the mem_fix_14x branch April 23, 2019 13:20
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants