From e034a44e53f569386f43b87eec6fce22396b60f9 Mon Sep 17 00:00:00 2001 From: Liangliang He Date: Thu, 11 Jan 2018 13:52:45 +0800 Subject: [PATCH] enhance --- mace/utils/utils.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mace/utils/utils.h b/mace/utils/utils.h index 0239197f..73e1c6db 100644 --- a/mace/utils/utils.h +++ b/mace/utils/utils.h @@ -88,7 +88,8 @@ inline std::string ObfuscateSymbol(const std::string &src) { dest[i] = ch; continue; } - dest[i] = encode_dict[(idx + 37) % encode_dict.size()]; + // There is no collision if it's true for every char at every position + dest[i] = encode_dict[(idx + i + 31) % encode_dict.size()]; } return std::move(dest); } -- GitLab