Index: /trunk/src/VBox/GuestHost/OpenGL/include/cr_string.h
===================================================================
--- /trunk/src/VBox/GuestHost/OpenGL/include/cr_string.h	(revision 51654)
+++ /trunk/src/VBox/GuestHost/OpenGL/include/cr_string.h	(revision 51655)
@@ -9,4 +9,5 @@
 
 #include <iprt/cdefs.h>
+#include <iprt/types.h>
 
 RT_C_DECLS_BEGIN
@@ -61,4 +62,5 @@
 
 DECLEXPORT(int) crStrParseGlVersion(const char * ver);
+DECLEXPORT(int32_t) crStrParseI32(const char *pszStr, const int32_t defaultVal);
 RT_C_DECLS_END
 
Index: /trunk/src/VBox/GuestHost/OpenGL/util/string.c
===================================================================
--- /trunk/src/VBox/GuestHost/OpenGL/util/string.c	(revision 51654)
+++ /trunk/src/VBox/GuestHost/OpenGL/util/string.c	(revision 51655)
@@ -532,2 +532,58 @@
     return iVer;
 }
+
+int32_t crStrParseI32(const char *pszStr, const int32_t defaultVal)
+{
+    int32_t result = 0;
+    bool neg = false;
+    unsigned char iDigit = 0;
+    if (!pszStr || pszStr[0] == '\0')
+        return defaultVal;
+
+    for (;;)
+    {
+        if (pszStr[0] == '\0')
+            return defaultVal;
+
+        if (pszStr[0] == ' ' || pszStr[0] == '\t' || pszStr[0] == '\n')
+        {
+            ++pszStr;
+            continue;
+        }
+
+        if (pszStr[0] == '-')
+        {
+            if (neg)
+                return defaultVal;
+
+            neg = true;
+            ++pszStr;
+            continue;
+        }
+
+        break;
+    }
+
+    for (;;)
+    {
+        unsigned char digit;
+        if (pszStr[0] == '\0')
+        {
+            if (!iDigit)
+                return defaultVal;
+            break;
+        }
+
+        digit = pszStr[0] - '0';
+        if (digit > 9)
+            return defaultVal;
+
+        result *= 10;
+        result += digit;
+        ++iDigit;
+
+        ++pszStr;
+    }
+
+    return !neg ? result : -result;
+}
Index: /trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server.h
===================================================================
--- /trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server.h	(revision 51654)
+++ /trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server.h	(revision 51655)
@@ -371,6 +371,4 @@
 
 void crServerInitTmpCtxDispatch();
-
-int crServerVBoxParseNumerics(const char *pszStr, const int defaultVal);
 
 typedef struct CR_FBMAP
Index: /trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_config.c
===================================================================
--- /trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_config.c	(revision 51654)
+++ /trunk/src/VBox/HostServices/SharedOpenGL/crserverlib/server_config.c	(revision 51655)
@@ -56,60 +56,4 @@
 
     cr_server.pfnNotifyEventCB = NULL;
-}
-
-int crServerVBoxParseNumerics(const char *pszStr, const int defaultVal)
-{
-    int result = 0;
-    bool neg = false;
-    unsigned char iDigit = 0;
-    if (!pszStr || pszStr[0] == '\0')
-        return defaultVal;
-
-    for (;;)
-    {
-        if (pszStr[0] == '\0')
-            return defaultVal;
-
-        if (pszStr[0] == ' ' || pszStr[0] == '\t' || pszStr[0] == '\n')
-        {
-            ++pszStr;
-            continue;
-        }
-
-        if (pszStr[0] == '-')
-        {
-            if (neg)
-                return defaultVal;
-
-            neg = true;
-            ++pszStr;
-            continue;
-        }
-
-        break;
-    }
-
-    for (;;)
-    {
-        unsigned char digit;
-        if (pszStr[0] == '\0')
-        {
-            if (!iDigit)
-                return defaultVal;
-            break;
-        }
-
-        digit = pszStr[0] - '0';
-        if (digit > 9)
-            return defaultVal;
-
-        result *= 10;
-        result += digit;
-        ++iDigit;
-
-        ++pszStr;
-    }
-
-    return !neg ? result : -result;
 }
 
@@ -213,5 +157,5 @@
     if (env != NULL && env[0] != '\0')
     {
-        unsigned int bits = (unsigned int)crServerVBoxParseNumerics(env, 0);
+        unsigned int bits = (unsigned int)crStrParseI32(env, 0);
         if (bits <= CR_ALL_BITS)
             cr_server.fVisualBitsDefault = bits;
@@ -225,5 +169,5 @@
     if (env && env[0] != '\0')
     {
-        cr_server.u32Caps = crServerVBoxParseNumerics(env, 0);
+        cr_server.u32Caps = crStrParseI32(env, 0);
         cr_server.u32Caps &= CR_VBOX_CAPS_ALL;
     }
@@ -363,5 +307,5 @@
     if (env != NULL && env[0] != '\0')
     {
-        unsigned int bits = (unsigned int)crServerVBoxParseNumerics(env, 0);
+        unsigned int bits = (unsigned int)crStrParseI32(env, 0);
         if (bits <= CR_ALL_BITS)
             cr_server.fVisualBitsDefault = bits;
@@ -375,5 +319,5 @@
     if (env && env[0] != '\0')
     {
-        cr_server.u32Caps = crServerVBoxParseNumerics(env, 0);
+        cr_server.u32Caps = crStrParseI32(env, 0);
         cr_server.u32Caps &= CR_VBOX_CAPS_ALL;
     }
