mirror of
https://github.com/intel/compute-runtime.git
synced 2025-09-15 13:01:45 +08:00
Adjust error handling in the clAddCommentINTEL
Related-To: NEO-3047 Change-Id: Ic9ecfff8358c43a37a1c4ea4ccf4aec8d09acde8 Signed-off-by: Jobczyk, Lukasz <lukasz.jobczyk@intel.com>
This commit is contained in:
@ -4237,11 +4237,11 @@ cl_int CL_API_CALL clAddCommentINTEL(const char *comment) {
|
||||
auto executionEnvironment = platform()->peekExecutionEnvironment();
|
||||
auto aubCenter = executionEnvironment->aubCenter.get();
|
||||
|
||||
if (!comment || !aubCenter || !aubCenter->getAubManager()) {
|
||||
if (!comment || (aubCenter && !aubCenter->getAubManager())) {
|
||||
retVal = CL_INVALID_VALUE;
|
||||
}
|
||||
|
||||
if (retVal == CL_SUCCESS) {
|
||||
if (retVal == CL_SUCCESS && aubCenter) {
|
||||
aubCenter->getAubManager()->addComment(comment);
|
||||
}
|
||||
return retVal;
|
||||
|
Reference in New Issue
Block a user