mirror of
http://galexander.org/git/simplesshd.git
synced 2025-01-01 02:40:52 +00:00
Fix the SIGSEGV that users have been reporting - don't execute anything
that had already been registered with atexit().
This commit is contained in:
parent
cf84ff9379
commit
a3bbb0bf96
@ -184,7 +184,7 @@ regular <tt>rsa</tt> key for greatest compatibility.
|
|||||||
<h2>Change Log</h2>
|
<h2>Change Log</h2>
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li> <b>2019/08/11 Version 21:</b> Fix restarting after a crash.
|
<li> <b>2019/08/11 Version 21:</b> Fix restarting after a crash. Fix SIGSEGV on some Android 9 devices.
|
||||||
<li> <b>2019/06/16 Version 20:</b> Update SDK. Support x86_64, arm64.
|
<li> <b>2019/06/16 Version 20:</b> Update SDK. Support x86_64, arm64.
|
||||||
Fix finding support libraries. Fix colors again. Fix start-on-boot on
|
Fix finding support libraries. Fix colors again. Fix start-on-boot on
|
||||||
new Android. Update to dropbear 2019.78.
|
new Android. Update to dropbear 2019.78.
|
||||||
|
@ -116,6 +116,16 @@ from_java_string(jobject s)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* this makes sure that no previously-added atexit gets called (some users have
|
||||||
|
* an atexit registered by libGLESv2_adreno.so */
|
||||||
|
static void
|
||||||
|
null_atexit(void)
|
||||||
|
{
|
||||||
|
_Exit(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
JNIEXPORT jint JNICALL
|
JNIEXPORT jint JNICALL
|
||||||
Java_org_galexander_sshd_SimpleSSHDService_start_1sshd(JNIEnv *env_,
|
Java_org_galexander_sshd_SimpleSSHDService_start_1sshd(JNIEnv *env_,
|
||||||
jclass cl,
|
jclass cl,
|
||||||
@ -146,6 +156,8 @@ Java_org_galexander_sshd_SimpleSSHDService_start_1sshd(JNIEnv *env_,
|
|||||||
int retval;
|
int retval;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
|
atexit(null_atexit);
|
||||||
|
|
||||||
logfn = conf_path_file("dropbear.err");
|
logfn = conf_path_file("dropbear.err");
|
||||||
logfn_old = conf_path_file("dropbear.err.old");
|
logfn_old = conf_path_file("dropbear.err.old");
|
||||||
unlink(logfn_old);
|
unlink(logfn_old);
|
||||||
|
Loading…
Reference in New Issue
Block a user