fix an issue on 64bit

This commit is contained in:
Max Lv
2014-11-26 13:13:11 +08:00
parent 7e8dad5c76
commit bf207eb9b8
+2 -3
View File
@@ -32,9 +32,6 @@ jstring Java_com_github_shadowsocks_system_getabi(JNIEnv *env, jobject thiz) {
void Java_com_github_shadowsocks_system_exec(JNIEnv *env, jobject thiz, jstring cmd) {
const char *str = env->GetStringUTFChars(cmd, 0);
setenv("LD_LIBRARY_PATH", "/vendor/lib:/system/lib", 1);
setegid(getgid());
seteuid(getuid());
system(str);
env->ReleaseStringUTFChars(cmd, str);
}
@@ -48,6 +45,8 @@ static JNINativeMethod method_table[] = {
(void*) Java_com_github_shadowsocks_system_getabi }
};
/*
* Register several native methods for one class.
*/