Commit eb8a25a6 by Marcus Winter

examples: fixed printf format specifier in network and opencl examples

parent 0f1ae441
...@@ -88,7 +88,7 @@ void RunMTAPI_C_Network() { ...@@ -88,7 +88,7 @@ void RunMTAPI_C_Network() {
for (int ii = 0; ii < kElements; ii++) { for (int ii = 0; ii < kElements; ii++) {
if (results[ii] != ii * 2 + 1) { if (results[ii] != ii * 2 + 1) {
printf("result %d was expected to be %d but was %d.\n", printf("result %d was expected to be %d but was %f.\n",
ii, ii * 2 + 1, results[ii]); ii, ii * 2 + 1, results[ii]);
exit(MTAPI_ERR_UNKNOWN); exit(MTAPI_ERR_UNKNOWN);
} }
......
...@@ -84,7 +84,7 @@ void RunMTAPI_C_OpenCL() { ...@@ -84,7 +84,7 @@ void RunMTAPI_C_OpenCL() {
for (int ii = 0; ii < kElements; ii++) { for (int ii = 0; ii < kElements; ii++) {
if (results[ii] != ii * 2 + 1) { if (results[ii] != ii * 2 + 1) {
printf("result %d was expected to be %d but was %d.\n", printf("result %d was expected to be %d but was %f.\n",
ii, ii * 2 + 1, results[ii]); ii, ii * 2 + 1, results[ii]);
exit(MTAPI_ERR_UNKNOWN); exit(MTAPI_ERR_UNKNOWN);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment