-
Notifications
You must be signed in to change notification settings - Fork 129
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix for warning in svm test file #239
fix for warning in svm test file #239
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In general LGTM.
tests/test_openclhpp.cpp
Outdated
} | ||
void testSVMMemoryAllocation() | ||
{ | ||
{// |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
{// | |
{ |
Something committed accidentally?
tests/test_openclhpp.cpp
Outdated
@@ -4214,10 +4214,10 @@ void clSVMFree_stubForMemoryAllocation(cl_context context, void *svm_pointer, | |||
int cmock_num_calls) | |||
{ | |||
TEST_ASSERT_EQUAL_PTR(svm_pointer, testMemory); | |||
delete svm_pointer; | |||
delete (int*) svm_pointer; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
delete (int*) svm_pointer; | |
delete[] (int*) svm_pointer; |
As testMemory
was allocated with new[]
should use delete[]
. I realise that problem existed before this PR, but touching the line made me notice it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@alycm thanks for patient!
I just repaired.
Please take a look
regards
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ship it.
fix for issue : #236