termux-packages/packages/dropbear/loginrec.c.patch
2021-12-19 11:56:50 +02:00

15 lines
331 B
Diff

--- a/loginrec.c
+++ b/loginrec.c
@@ -275,7 +275,11 @@
if (username) {
strlcpy(li->username, username, sizeof(li->username));
+#ifdef __ANDROID__
+ pw = getpwuid(getuid());
+#else
pw = getpwnam(li->username);
+#endif
if (pw == NULL)
dropbear_exit("login_init_entry: Cannot find user \"%s\"",
li->username);