Changeset 84262 in vbox
- Timestamp:
- May 11, 2020 5:17:36 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/x11/VBoxClient/display-svga-x11.cpp
r84258 r84262 654 654 } 655 655 656 /** 657 * Tries to determine if the session parenting this process is of X11. 658 */ 659 static bool isX11() 660 { 661 char* pSessionType; 662 pSessionType = getenv("XDG_SESSION_TYPE"); 663 if (pSessionType != NULL) 664 { 665 if (RTStrIStartsWith(pSessionType, "x11")) 666 return true; 667 } 668 return false; 669 } 670 656 671 static bool init() 657 672 { 673 if (!isX11()) 674 { 675 VBClLogFatalError("The parent session seems to be non-X11. Exiting...\n"); 676 VBClLogInfo("This service needs X display server for resizing and multi monitor handling to work\n"); 677 return false; 678 } 658 679 x11Connect(); 659 680 if (x11Context.pDisplay == NULL)
Note:
See TracChangeset
for help on using the changeset viewer.