bugfix in deallocate

pull/1868/head
Konstantin Matskevich 12 years ago
parent 3ab47300ce
commit 145855767c
  1. 2
      modules/core/src/ocl.cpp

@ -2705,6 +2705,7 @@ public:
}
u->markHostCopyObsolete(false);
clReleaseMemObject((cl_mem)u->handle);
u->handle = 0;
u->currAllocator = u->prevAllocator;
if(u->data && u->copyOnMap())
fastFree(u->data);
@ -2717,6 +2718,7 @@ public:
if(u->data && u->copyOnMap())
fastFree(u->data);
clReleaseMemObject((cl_mem)u->handle);
u->handle = 0;
delete u;
}
}

Loading…
Cancel
Save