From f3c11f583157b93872d2c8c1cf57dad71ba6ab05 Mon Sep 17 00:00:00 2001 From: Charlie Fenton Date: Wed, 5 Dec 2012 16:31:16 -0800 Subject: [PATCH] client: strcasestr does exist on Windows in lib/str_replace.cpp, but I just needed to #include "str_replace.h". This is preferable because it handles INTEL as well as Intel and intel --- checkin_notes | 8 ++++++++ client/gpu_opencl.cpp | 5 ++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/checkin_notes b/checkin_notes index c35e39b2a0..e22ae9561f 100644 --- a/checkin_notes +++ b/checkin_notes @@ -7310,3 +7310,11 @@ Rom 5 Dec 2012 client/ gpu_opencl.cpp + +Charlie 5 Dec 2012 + - client: strcasestr does exist on Windows in lib/str_replace.cpp, + but I just needed to #include "str_replace.h". This is + preferable because it handles INTEL as well as Intel and intel. + + client/ + gpu_opencl.cpp diff --git a/client/gpu_opencl.cpp b/client/gpu_opencl.cpp index 1169f38288..e2e8044742 100644 --- a/client/gpu_opencl.cpp +++ b/client/gpu_opencl.cpp @@ -37,6 +37,7 @@ using std::string; #include "coproc.h" #include "util.h" +#include "str_replace.h" #include "client_msgs.h" #include "gpu_detect.h" @@ -318,9 +319,7 @@ void COPROCS::get_opencl( } //////////// INTEL GPU ////////////// - if ((strstr(prop.vendor, "intel")) || - (strstr(prop.vendor, "Intel")) - ) { + if (strcasestr(prop.vendor, "intel")) { cl_device_type device_type; ciErrNum = (*__clGetDeviceInfo)(prop.device_id, CL_DEVICE_TYPE,