|
1 The strcasestr function is not available in Solaris 10, so this replaces it |
|
2 with an alternate function. This is not necessary for Solaris 12+. |
|
3 The 'uname' part is necessary because the uname() function returns a |
|
4 non-negative value. |
|
5 |
|
6 --- mozilla-esr31/widget/xpwidgets/GfxInfoX11.cpp.orig 2015-06-04 17:42:51.546213832 -0700 |
|
7 +++ mozilla-esr31/widget/xpwidgets/GfxInfoX11.cpp 2015-06-04 17:42:51.548646551 -0700 |
|
8 @@ -12,6 +12,7 @@ |
|
9 #include <sys/utsname.h> |
|
10 #include "nsCRTGlue.h" |
|
11 #include "prenv.h" |
|
12 +#include "plstr.h" |
|
13 |
|
14 #include "GfxInfoX11.h" |
|
15 |
|
16 @@ -135,7 +136,7 @@ |
|
17 // only useful for Linux kernel version check for FGLRX driver. |
|
18 // assumes X client == X server, which is sad. |
|
19 struct utsname unameobj; |
|
20 - if (!uname(&unameobj)) |
|
21 + if (uname(&unameobj) >= 0) |
|
22 { |
|
23 mOS.Assign(unameobj.sysname); |
|
24 mOSRelease.Assign(unameobj.release); |
|
25 @@ -210,13 +211,13 @@ |
|
26 // with Mesa, the version string contains "Mesa major.minor" and that's all the version information we get: |
|
27 // there is no actual driver version info. |
|
28 whereToReadVersionNumbers = Mesa_in_version_string + strlen("Mesa"); |
|
29 - if (strcasestr(mVendor.get(), "nouveau")) |
|
30 + if (PL_strcasestr(mVendor.get(), "nouveau")) |
|
31 mIsNouveau = true; |
|
32 - if (strcasestr(mRenderer.get(), "intel")) // yes, intel is in the renderer string |
|
33 + if (PL_strcasestr(mRenderer.get(), "intel")) // yes, intel is in the renderer string |
|
34 mIsIntel = true; |
|
35 - if (strcasestr(mRenderer.get(), "llvmpipe")) |
|
36 + if (PL_strcasestr(mRenderer.get(), "llvmpipe")) |
|
37 mIsLlvmpipe = true; |
|
38 - if (strcasestr(mRenderer.get(), "software rasterizer")) |
|
39 + if (PL_strcasestr(mRenderer.get(), "software rasterizer")) |
|
40 mIsOldSwrast = true; |
|
41 } else if (strstr(mVendor.get(), "NVIDIA Corporation")) { |
|
42 mIsNVIDIA = true; |