Don't crash for hipEventDestroy(NULL)
Change-Id: I3f4de1ad2712dbe8af81e10c5d3bef16d468c582
이 커밋은 다음에 포함됨:
+8
-5
@@ -164,13 +164,16 @@ hipError_t hipEventDestroy(hipEvent_t event)
|
||||
{
|
||||
HIP_INIT_API(event);
|
||||
|
||||
event->_state = hipEventStatusUnitialized;
|
||||
if (event) {
|
||||
event->_state = hipEventStatusUnitialized;
|
||||
|
||||
delete event;
|
||||
event = NULL;
|
||||
delete event;
|
||||
event = NULL;
|
||||
|
||||
// TODO - examine return additional error codes
|
||||
return ihipLogStatus(hipSuccess);
|
||||
return ihipLogStatus(hipSuccess);
|
||||
} else {
|
||||
return ihipLogStatus(hipErrorInvalidResourceHandle);
|
||||
}
|
||||
}
|
||||
|
||||
hipError_t hipEventSynchronize(hipEvent_t event)
|
||||
|
||||
새 이슈에서 참조
사용자 차단