aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXavier Del Campo Romero <xavidcr@noreply.codeberg.org>2026-10-07 23:20:08 +0200
committerXavier Del Campo Romero <xavidcr@noreply.codeberg.org>2026-10-07 23:20:08 +0200
commit188feb4abd78fd668b948e7c13934f26f775ce8a (patch)
tree72cdcf00127f938ba6ccce020213e4453e0297b6
parent39fe36f8846f990d61c6c2dbef47d68e35096f19 (diff)
parentfe30c28e155783c4e1a3dc6e12ab6a940a746843 (diff)
downloadslcl-188feb4abd78fd668b948e7c13934f26f775ce8a.tar.gz
Merge pull request 'termux compile fix (1/2)' (#5) from fukiame/slcl:pr/termux_compile into master
Reviewed-on: https://codeberg.org/xavidcr/slcl/pulls/5 Reviewed-by: Xavier Del Campo Romero <xavidcr@noreply.codeberg.org>
-rwxr-xr-xconfigure3
-rw-r--r--usergen.c4
2 files changed, 4 insertions, 3 deletions
diff --git a/configure b/configure
index c967734..73c436d 100755
--- a/configure
+++ b/configure
@@ -142,7 +142,8 @@ cleanup()
rm -f $F
}
-F=/tmp/Makefile.slcl
+[ -n "$TMPDIR" ] || TMPDIR=/tmp
+F="$TMPDIR"/Makefile.slcl
trap cleanup EXIT
cat <<EOF > $F
diff --git a/usergen.c b/usergen.c
index 5a0cf3c..53d2ff2 100644
--- a/usergen.c
+++ b/usergen.c
@@ -151,7 +151,7 @@ static int checkuser(const char *const username, const cJSON *const c)
return 0;
}
-static int getpass(char *const password, const size_t n)
+static int ugetpass(char *const password, const size_t n)
{
int ret = -1;
struct termios t, ne;
@@ -508,7 +508,7 @@ int main(int argc, char *argv[])
if (getuser(username, sizeof username)
|| checkuser(username, c)
- || getpass(password, sizeof password)
+ || ugetpass(password, sizeof password)
|| getquota(&quota)
|| getmethod(method, sizeof method)
|| !(o = createobj(c, username, hexkey, method, quota)))