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 2018/03/23 16:32:23 UTC

[GitHub] lebeg commented on a change in pull request #9400: Fixed memory leak

lebeg commented on a change in pull request #9400: Fixed memory leak
URL: https://github.com/apache/incubator-mxnet/pull/9400#discussion_r176792334
 
 

 ##########
 File path: src/operator/operator_tune-inl.h
 ##########
 @@ -616,7 +616,7 @@ class UnaryOpTune : public OperatorTune<DType> {
    */
   template<typename OP>
   static duration_t GetBlankWorkloadEx() {
-    std::unique_ptr<DType> tmp(new DType[Super::WORKLOAD_COUNT]);
+    std::unique_ptr<DType[]> tmp(new DType[Super::WORKLOAD_COUNT]);
 
 Review comment:
   This is reported as definitely lost by valgrind memcheck. Please refer to [c++ delete reference](http://en.cppreference.com/w/cpp/memory/new/operator_delete)

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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