aboutsummaryrefslogtreecommitdiffstats
path: root/package/system/opkg
diff options
context:
space:
mode:
authorJohn Crispin <john@openwrt.org>2016-03-04 08:33:41 +0000
committerJohn Crispin <john@openwrt.org>2016-03-04 08:33:41 +0000
commit1268b2e899617411919fb776d65c1cb81c760495 (patch)
tree63be86c3c58f8b916728dc8f83a6c88c4a6102c1 /package/system/opkg
parentfbb2449953526ba1a4c4c85ca62bd864d6276113 (diff)
downloadupstream-1268b2e899617411919fb776d65c1cb81c760495.tar.gz
upstream-1268b2e899617411919fb776d65c1cb81c760495.tar.bz2
upstream-1268b2e899617411919fb776d65c1cb81c760495.zip
opkg: Fix handling of sha256sums for conffiles
MD5s are shorter than SHA256, so reading buffer has to be bigger to read the whole hash. Signed-off-by: Michal Hrusecky <michal.hrusecky@nic.cz> SVN-Revision: 48917
Diffstat (limited to 'package/system/opkg')
-rw-r--r--package/system/opkg/Makefile2
-rw-r--r--package/system/opkg/patches/230-drop_md5_support.patch14
2 files changed, 15 insertions, 1 deletions
diff --git a/package/system/opkg/Makefile b/package/system/opkg/Makefile
index c09d1683fe..d8cce2a8f2 100644
--- a/package/system/opkg/Makefile
+++ b/package/system/opkg/Makefile
@@ -12,7 +12,7 @@ include $(INCLUDE_DIR)/feeds.mk
PKG_NAME:=opkg
PKG_REV:=9c97d5ecd795709c8584e972bfdf3aee3a5b846d
PKG_VERSION:=$(PKG_REV)
-PKG_RELEASE:=11
+PKG_RELEASE:=12
PKG_SOURCE_PROTO:=git
PKG_SOURCE_VERSION:=$(PKG_REV)
diff --git a/package/system/opkg/patches/230-drop_md5_support.patch b/package/system/opkg/patches/230-drop_md5_support.patch
index 3b281040b0..57546bedf1 100644
--- a/package/system/opkg/patches/230-drop_md5_support.patch
+++ b/package/system/opkg/patches/230-drop_md5_support.patch
@@ -176,3 +176,17 @@
# check for openssl
AC_ARG_ENABLE(openssl,
+--- a/libopkg/pkg_parse.c
++++ b/libopkg/pkg_parse.c
+@@ -49,9 +49,9 @@ parse_status(pkg_t *pkg, const char *sst
+ static void
+ parse_conffiles(pkg_t *pkg, const char *cstr)
+ {
+- char file_name[1024], md5sum[35];
++ char file_name[1024], md5sum[85];
+
+- if (sscanf(cstr, "%1023s %34s", file_name, md5sum) != 2) {
++ if (sscanf(cstr, "%1023s %84s", file_name, md5sum) != 2) {
+ opkg_msg(ERROR, "Failed to parse Conffiles line for %s\n",
+ pkg->name);
+ return;