Randomize service names

Fix Aniplex Game detections.
Close #502, close #513
This commit is contained in:
topjohnwu
2018-09-08 23:15:58 -04:00
parent 2d7c1da741
commit 6f41d9855b
3 changed files with 25 additions and 28 deletions

View File

@@ -373,7 +373,7 @@ void wait_till_exists(const char *target) {
}
void gen_rand_str(char *buf, int len) {
const char base[] = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_.";
const char base[] = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
int urandom;
if (access("/dev/urandom", R_OK) == 0) {
urandom = xopen("/dev/urandom", O_RDONLY | O_CLOEXEC);