mirror of
https://github.com/outbackdingo/openwrt-passwall-packages.git
synced 2026-01-27 10:19:59 +00:00
shadowsocksr-libev: fix use-after-free due to a typo (#193)
This commit is contained in:
@@ -1943,7 +1943,7 @@ main(int argc, char **argv)
|
||||
memcpy(text, protocol, strlen(protocol) - 11);
|
||||
int length = strlen(protocol) - 11;
|
||||
free(protocol);
|
||||
obfs = (char*)malloc(length);
|
||||
protocol = (char*)malloc(length);
|
||||
memset(protocol, 0x00, length);
|
||||
memcpy(protocol, text, length);
|
||||
LOGI("protocol compatible enable, %s", protocol);
|
||||
|
||||
Reference in New Issue
Block a user