Index: trunk/src/VBox/Debugger/DBGCCmdHlp.cpp
===================================================================
--- trunk/src/VBox/Debugger/DBGCCmdHlp.cpp	(revision 41571)
+++ trunk/src/VBox/Debugger/DBGCCmdHlp.cpp	(revision 41573)
@@ -50,4 +50,38 @@
 
     return rc;
+}
+
+
+/**
+ * Outputs a string in quotes.
+ *
+ * @returns The number of bytes formatted.
+ * @param   pfnOutput       Pointer to output function.
+ * @param   pvArgOutput     Argument for the output function.
+ * @param   chQuote         The quote character.
+ * @param   psz             The string to quote.
+ * @param   cch             The string length.
+ */
+static size_t dbgcStringOutputInQuotes(PFNRTSTROUTPUT pfnOutput, void *pvArgOutput, char chQuote, const char *psz, size_t cch)
+{
+    size_t cchOutput = pfnOutput(pvArgOutput, &chQuote, 1);
+
+    while (cch > 0)
+    {
+        char *pchQuote = (char *)memchr(psz, chQuote, cch);
+        if (!pchQuote)
+        {
+            cchOutput += pfnOutput(pvArgOutput, psz, cch);
+            break;
+        }
+        size_t cchSub = pchQuote - psz + 1;
+        cchOutput += pfnOutput(pvArgOutput, psz, cchSub);
+        cchOutput += pfnOutput(pvArgOutput, &chQuote, 1);
+        cchSub -= cchSub;
+        psz    += cchSub;
+    }
+
+    cchOutput += pfnOutput(pvArgOutput, &chQuote, 1);
+    return cchOutput;
 }
 
@@ -103,8 +137,10 @@
                 case DBGCVAR_TYPE_HC_PHYS:
                     return RTStrFormat(pfnOutput, pvArgOutput, NULL, 0, "#%%%%%RHp", pVar->u.HCPhys);
-                case DBGCVAR_TYPE_STRING:
-                    return pfnOutput(pvArgOutput, pVar->u.pszString, (size_t)pVar->u64Range);
                 case DBGCVAR_TYPE_NUMBER:
                     return RTStrFormat(pfnOutput, pvArgOutput, NULL, 0, "%llx", pVar->u.u64Number);
+                case DBGCVAR_TYPE_STRING:
+                    return dbgcStringOutputInQuotes(pfnOutput, pvArgOutput, '"', pVar->u.pszString, (size_t)pVar->u64Range);
+                case DBGCVAR_TYPE_SYMBOL:
+                    return dbgcStringOutputInQuotes(pfnOutput, pvArgOutput, '\'', pVar->u.pszString, (size_t)pVar->u64Range);
 
                 case DBGCVAR_TYPE_UNKNOWN:
@@ -149,8 +185,10 @@
                 case DBGCVAR_TYPE_HC_PHYS:
                     return RTStrFormat(pfnOutput, pvArgOutput, NULL, 0, "#%%%%%RHp%s", pVar->u.HCPhys, szRange);
-                case DBGCVAR_TYPE_STRING:
-                    return pfnOutput(pvArgOutput, pVar->u.pszString, (size_t)pVar->u64Range);
                 case DBGCVAR_TYPE_NUMBER:
                     return RTStrFormat(pfnOutput, pvArgOutput, NULL, 0, "%llx%s", pVar->u.u64Number, szRange);
+                case DBGCVAR_TYPE_STRING:
+                    return dbgcStringOutputInQuotes(pfnOutput, pvArgOutput, '"', pVar->u.pszString, (size_t)pVar->u64Range);
+                case DBGCVAR_TYPE_SYMBOL:
+                    return dbgcStringOutputInQuotes(pfnOutput, pvArgOutput, '\'', pVar->u.pszString, (size_t)pVar->u64Range);
 
                 case DBGCVAR_TYPE_UNKNOWN:
@@ -710,5 +748,4 @@
             return VINF_SUCCESS;
 
-        case DBGCVAR_TYPE_STRING:
         case DBGCVAR_TYPE_SYMBOL:
         {
@@ -720,4 +757,5 @@
         }
 
+        case DBGCVAR_TYPE_STRING:
         case DBGCVAR_TYPE_HC_FLAT:
         case DBGCVAR_TYPE_HC_PHYS:
@@ -793,4 +831,5 @@
             break;
         case DBGCVAR_TYPE_SYMBOL:
+            /** @todo try convert as symbol? */
         case DBGCVAR_TYPE_STRING:
             return VERR_DBGC_PARSE_INCORRECT_ARG_TYPE; /** @todo better error code! */
@@ -813,29 +852,18 @@
     switch (pVar->enmType)
     {
+        case DBGCVAR_TYPE_SYMBOL:
         case DBGCVAR_TYPE_STRING:
-            /** @todo add strcasecmp / stricmp wrappers to iprt/string.h. */
-            if (    !strcmp(pVar->u.pszString, "true")
-                ||  !strcmp(pVar->u.pszString, "True")
-                ||  !strcmp(pVar->u.pszString, "TRUE")
-                ||  !strcmp(pVar->u.pszString, "on")
-                ||  !strcmp(pVar->u.pszString, "On")
-                ||  !strcmp(pVar->u.pszString, "oN")
-                ||  !strcmp(pVar->u.pszString, "ON")
-                ||  !strcmp(pVar->u.pszString, "enabled")
-                ||  !strcmp(pVar->u.pszString, "Enabled")
-                ||  !strcmp(pVar->u.pszString, "DISABLED"))
+            if (    !RTStrICmp(pVar->u.pszString, "true")
+                ||  !RTStrICmp(pVar->u.pszString, "on")
+                ||  !RTStrICmp(pVar->u.pszString, "no")
+                ||  !RTStrICmp(pVar->u.pszString, "enabled"))
             {
                 *pf = true;
                 return VINF_SUCCESS;
             }
-            if (    !strcmp(pVar->u.pszString, "false")
-                ||  !strcmp(pVar->u.pszString, "False")
-                ||  !strcmp(pVar->u.pszString, "FALSE")
-                ||  !strcmp(pVar->u.pszString, "off")
-                ||  !strcmp(pVar->u.pszString, "Off")
-                ||  !strcmp(pVar->u.pszString, "OFF")
-                ||  !strcmp(pVar->u.pszString, "disabled")
-                ||  !strcmp(pVar->u.pszString, "Disabled")
-                ||  !strcmp(pVar->u.pszString, "DISABLED"))
+            if (    !RTStrICmp(pVar->u.pszString, "false")
+                ||  !RTStrICmp(pVar->u.pszString, "off")
+                ||  !RTStrICmp(pVar->u.pszString, "yes")
+                ||  !RTStrICmp(pVar->u.pszString, "disabled"))
             {
                 *pf = false;
@@ -853,5 +881,4 @@
 
         case DBGCVAR_TYPE_GC_FAR:
-        case DBGCVAR_TYPE_SYMBOL:
         default:
             return VERR_DBGC_PARSE_INCORRECT_ARG_TYPE;
