Commit db0137c
committed
feat: check if the running process is of the same user
When running SafeEyes in multi-user environments (multiple users running
SafeEyes in the same machine), it refuses to start more than two
instances of SafeEyes because it is already running accoding to ps.
This patch adds a check to the running SafeEyes pid such that the
_running() function returns True only if it is running as the same user.1 parent 861fee3 commit db0137c
1 file changed
+5
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| 43 | + | |
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
| |||
54 | 55 | | |
55 | 56 | | |
56 | 57 | | |
57 | | - | |
58 | | - | |
59 | | - | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
60 | 62 | | |
61 | 63 | | |
62 | 64 | | |
| |||
0 commit comments