mirror of
https://github.com/tesseract-ocr/tesseract.git
synced 2024-11-28 05:39:35 +08:00
opencl: Fix wrong implementation of function getNumDeviceWithEmptyScore
gcc report: opencl_device_selection.h: In function 'ds_status getNumDeviceWithEmptyScore(ds_profile*, unsigned int*)': opencl_device_selection.h:589:13: warning: value computed is not used [-Wunused-value] *num++; ^ This is caused by a buggy implementation which increases the value of num instead of *num. Signed-off-by: Stefan Weil <sw@weilnetz.de>
This commit is contained in:
parent
8972c0e916
commit
90dad1f2ae
@ -586,7 +586,7 @@ static ds_status getNumDeviceWithEmptyScore(ds_profile* profile,
|
||||
*num=0;
|
||||
for (i = 0; i < profile->numDevices; i++) {
|
||||
if (profile->devices[i].score == NULL) {
|
||||
*num++;
|
||||
(*num)++;
|
||||
}
|
||||
}
|
||||
return DS_SUCCESS;
|
||||
|
Loading…
Reference in New Issue
Block a user