diff --git a/packages/nano/build.sh b/packages/nano/build.sh index 1953a1da3..bd4d76b65 100644 --- a/packages/nano/build.sh +++ b/packages/nano/build.sh @@ -1,9 +1,9 @@ TERMUX_PKG_HOMEPAGE=https://www.nano-editor.org/ TERMUX_PKG_DESCRIPTION="Small, free and friendly text editor" _MAJOR_VERSION=2.8 -TERMUX_PKG_VERSION=${_MAJOR_VERSION}.5 +TERMUX_PKG_VERSION=${_MAJOR_VERSION}.6 TERMUX_PKG_SRCURL=https://www.nano-editor.org/dist/v${_MAJOR_VERSION}/nano-${TERMUX_PKG_VERSION}.tar.gz -TERMUX_PKG_SHA256=e2b929b24fba87f7a44285ce8d47af7170e379bee1bf2d04fbc728b7326a558a +TERMUX_PKG_SHA256=3725aa145880223b2c4d0b3fa08220e1633f2d341917f49d028e067fc12cce49 TERMUX_PKG_DEPENDS="libandroid-support, libandroid-glob, ncurses" TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" --disable-libmagic diff --git a/packages/nano/src-files.c.patch b/packages/nano/src-files.c.patch index b7d27aea2..936ed8c8e 100644 --- a/packages/nano/src-files.c.patch +++ b/packages/nano/src-files.c.patch @@ -1,7 +1,7 @@ -diff -u -r ../nano-2.8.0/src/files.c ./src/files.c ---- ../nano-2.8.0/src/files.c 2017-03-24 18:58:22.000000000 +0000 -+++ ./src/files.c 2017-04-02 08:55:48.207085424 +0000 -@@ -2362,7 +2362,7 @@ +diff -u -r ../nano-2.8.6/src/files.c ./src/files.c +--- ../nano-2.8.6/src/files.c 2017-07-21 09:44:46.000000000 +0200 ++++ ./src/files.c 2017-07-22 16:01:40.806964191 +0200 +@@ -2337,7 +2337,7 @@ get_homedir(); tilde_dir = mallocstrcpy(NULL, homedir); } else { @@ -10,12 +10,12 @@ diff -u -r ../nano-2.8.0/src/files.c ./src/files.c const struct passwd *userdata; tilde_dir = mallocstrncpy(NULL, buf, i + 1); -@@ -2473,7 +2473,7 @@ +@@ -2451,7 +2451,7 @@ *num_matches = 0; -#ifdef HAVE_PWD_H +#if defined(HAVE_PWD_H) && !defined(__ANDROID__) - const struct passwd *userdata; - while ((userdata = getpwent()) != NULL) { + if (strncmp(userdata->pw_name, buf + 1, buf_len - 1) == 0) { + /* Cool, found a match. Add it to the list. This makes a