You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by GitBox <gi...@apache.org> on 2019/03/12 18:03:04 UTC

[GitHub] [incubator-mxnet] access2rohit commented on a change in pull request #14365: Fix memory leak for size-zero ndarray

access2rohit commented on a change in pull request #14365: Fix memory leak for size-zero ndarray
URL: https://github.com/apache/incubator-mxnet/pull/14365#discussion_r264813211
 
 

 ##########
 File path: include/mxnet/ndarray.h
 ##########
 @@ -986,9 +986,8 @@ class NDArray {
 #endif
         delay_alloc = false;
       } else if (shandle.size < dbytes) {
-        // free storage if necessary and alloc again
-        if (shandle.size > 0) Storage::Get()->Free(shandle);
-        // init storage
 
 Review comment:
   nit: deleted previous comment for initializing storage after freeing it.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services