diff options
author | Robert Pösel <robyer@seznam.cz> | 2012-07-12 13:10:56 +0000 |
---|---|---|
committer | Robert Pösel <robyer@seznam.cz> | 2012-07-12 13:10:56 +0000 |
commit | ea0f78b397cc5acc88d286ef0c78e9aeafbf242d (patch) | |
tree | acbea0a18a2eb9a9a0115f8116c34ec0a0725666 /plugins/WhoUsesMyFiles/wumf.c | |
parent | f53121766f887f34a489c06669735ccbd2a859ab (diff) |
WUMF: don't block whole plugin without admin privileges, but only monitoring.
git-svn-id: http://svn.miranda-ng.org/main/trunk@921 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/WhoUsesMyFiles/wumf.c')
-rw-r--r-- | plugins/WhoUsesMyFiles/wumf.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/plugins/WhoUsesMyFiles/wumf.c b/plugins/WhoUsesMyFiles/wumf.c index 524648185e..03aa576d38 100644 --- a/plugins/WhoUsesMyFiles/wumf.c +++ b/plugins/WhoUsesMyFiles/wumf.c @@ -109,7 +109,11 @@ int CALLBACK ConnDlgProc(HWND hWnd, UINT Msg, WPARAM wParam, LPARAM lParam) ListView_InsertColumn(hList, 3, &lvc);
KillTimer(NULL, 777);
lst = cpy_list(&list);
- SetTimer(NULL, 777, TIME,(TIMERPROC) TimerProc);
+ if (IsUserAnAdmin()) {
+ SetTimer(NULL, 777, TIME,(TIMERPROC) TimerProc);
+ } else {
+ MessageBox(NULL, "Plugin WhoUsesMyFiles requires admin privileges in order to work.", "Miranda IM", MB_OK);
+ }
ShowList(lst, hList);
Utils_RestoreWindowPosition(hWnd, NULL, ModuleName,"conn");
break;
|