mirror of
https://github.com/reactos/wine.git
synced 2024-11-29 14:40:56 +00:00
Message box to suggest the user not run wine as root.
This commit is contained in:
parent
bc2520b3b7
commit
97d5e1638f
@ -29,6 +29,9 @@
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <wine/debug.h>
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include "properties.h"
|
||||
#include "resource.h"
|
||||
@ -203,6 +206,10 @@ WinMain (HINSTANCE hInstance, HINSTANCE hPrev, LPSTR szCmdLine, int nShow)
|
||||
WINE_ERR("initialization failed, aborting\n");
|
||||
ExitProcess(1);
|
||||
}
|
||||
|
||||
/* is the user running as root? */
|
||||
if(getuid() == 0)
|
||||
MessageBox(NULL, "It is not advisable to run wine as root. Doing so may compromise the security of your computer. Please run wine as a normal user.", "Warning", MB_OK);
|
||||
|
||||
/*
|
||||
* The next 3 lines should be all that is needed
|
||||
|
Loading…
Reference in New Issue
Block a user