Index: /trunk/src/VBox/Main/include/MachineImpl.h
===================================================================
--- /trunk/src/VBox/Main/include/MachineImpl.h	(revision 55167)
+++ /trunk/src/VBox/Main/include/MachineImpl.h	(revision 55168)
@@ -147,5 +147,5 @@
 
             /** Session type string (for indirect sessions) */
-            Bstr mType;
+            Utf8Str mType;
 
             /** Session machine object */
Index: /trunk/src/VBox/Main/src-server/MachineImpl.cpp
===================================================================
--- /trunk/src/VBox/Main/src-server/MachineImpl.cpp	(revision 55167)
+++ /trunk/src/VBox/Main/src-server/MachineImpl.cpp	(revision 55168)
@@ -7372,5 +7372,5 @@
     if (fSeparate)
     {
-        if (mData->mSession.mState != SessionState_Unlocked && mData->mSession.mType != "headless")
+        if (mData->mSession.mState != SessionState_Unlocked && mData->mSession.mType.compare("headless", Utf8Str::CaseInsensitive))
             return setError(VBOX_E_INVALID_OBJECT_STATE,
                             tr("The machine '%s' is in a state which is incompatible with launching a separate UI process"),
