nano: update to 8.0
authorHannu Nyman <hannu.nyman@iki.fi>
Fri, 3 May 2024 13:24:09 +0000 (16:24 +0300)
committerHannu Nyman <hannu.nyman@iki.fi>
Fri, 3 May 2024 13:24:09 +0000 (16:24 +0300)
Update nano editor to version 8.0

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
utils/nano/Makefile
utils/nano/patches/0001-post80-fix-minibar-do-not-falsely-report.patch [new file with mode: 0644]

index 064a25e3d57eaa807507ba86ca31742f679878d7..e54a722425c8fc4cce740bb6e44abfa0feef112c 100644 (file)
@@ -8,12 +8,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=nano
-PKG_VERSION:=7.2
-PKG_RELEASE:=4
+PKG_VERSION:=8.0
+PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
 PKG_SOURCE_URL:=@GNU/nano
-PKG_HASH:=86f3442768bd2873cec693f83cdf80b4b444ad3cc14760b74361474fc87a4526
+PKG_HASH:=c17f43fc0e37336b33ee50a209c701d5beb808adc2d9f089ca831b40539c9ac4
 
 PKG_LICENSE:=GPL-3.0-or-later
 PKG_LICENSE_FILES:=COPYING
diff --git a/utils/nano/patches/0001-post80-fix-minibar-do-not-falsely-report.patch b/utils/nano/patches/0001-post80-fix-minibar-do-not-falsely-report.patch
new file mode 100644 (file)
index 0000000..d85720d
--- /dev/null
@@ -0,0 +1,27 @@
+From e9c7dfa99221935ffa38b5b9dbf294933e0aa7c0 Mon Sep 17 00:00:00 2001
+From: Benno Schulenberg <bensberg@telfort.nl>
+Date: Fri, 3 May 2024 12:12:09 +0200
+Subject: minibar: do not falsely report that a new, empty file is in Mac
+ format
+
+The 'openfile->fmt' element gets initialized to 'UNSPECIFIED',
+so the code has to take that possibility into account.
+
+This fixes https://savannah.gnu.org/bugs/?65676.
+
+Bug existed since version 8.0, commit fe4f74f6.
+---
+ src/winio.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/src/winio.c
++++ b/src/winio.c
+@@ -2213,7 +2213,7 @@ void minibar(void)
+               size_t count = openfile->filebot->lineno - (openfile->filebot->data[0] == '\0');
+               number_of_lines = nmalloc(49);
+-              if (openfile->fmt == NIX_FILE)
++              if (openfile->fmt == NIX_FILE || openfile->fmt == UNSPECIFIED)
+                       sprintf(number_of_lines, P_(" (%zu line)", " (%zu lines)", count), count);
+               else
+                       sprintf(number_of_lines, P_(" (%zu line, %s)", " (%zu lines, %s)", count),