From 95c9e2f9af2ba7611586f45a740e0b753b769d99 Mon Sep 17 00:00:00 2001 From: foreman Date: Mon, 15 Jun 2015 11:16:34 -0400 Subject: [PATCH] P4 to Git Change 1161448 by jatang@jatang-opencl-hsa-stg1 on 2015/06/15 11:08:17 EPR #419656 - Fix a double free. The double free is showing up when running a GEHC script that runs 6 OCL app simultanously. We'll later need to look at why elfOut_->hasError() is true. Affected files ... ... //depot/stg/opencl/drivers/opencl/runtime/device/device.cpp#180 edit --- rocclr/runtime/device/device.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/rocclr/runtime/device/device.cpp b/rocclr/runtime/device/device.cpp index 8246e2072d..f69726e36c 100644 --- a/rocclr/runtime/device/device.cpp +++ b/rocclr/runtime/device/device.cpp @@ -1550,6 +1550,7 @@ bool ClBinary::setElfOut(unsigned char eclass, const char* outFile) if ( (elfOut_ == NULL) || elfOut_->hasError() ) { if (elfOut_) { delete elfOut_; + elfOut_ = NULL; } LogError("Creating ouput ELF object failed"); return false;