summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/apt/apt-0.9.8.1/truncate-filename.patch
diff options
context:
space:
mode:
authorIonut Radu <ionutx.radu@intel.com>2013-06-27 13:07:13 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-07-02 22:23:46 +0100
commit70a26477ce93f0083cab98d1aeeb98ca6ec34343 (patch)
tree37de15b16e5b740ca920ada192ef32e8469d4638 /meta/recipes-devtools/apt/apt-0.9.8.1/truncate-filename.patch
parentfcea0bb9733fe5b8bd003e477a845b5612a5d960 (diff)
downloadpoky-70a26477ce93f0083cab98d1aeeb98ca6ec34343.tar.gz
apt: Updated from 0.9.8.1 to 0.9.8.2
(From OE-Core rev: 1500b4e7f6adec612efbdebad6a08a1efeeda7b6) Signed-off-by: Ionut Radu <ionutx.radu@intel.com> [sgw - fixed apt-native checksums] Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/apt/apt-0.9.8.1/truncate-filename.patch')
-rw-r--r--meta/recipes-devtools/apt/apt-0.9.8.1/truncate-filename.patch35
1 files changed, 0 insertions, 35 deletions
diff --git a/meta/recipes-devtools/apt/apt-0.9.8.1/truncate-filename.patch b/meta/recipes-devtools/apt/apt-0.9.8.1/truncate-filename.patch
deleted file mode 100644
index db1c42b66c..0000000000
--- a/meta/recipes-devtools/apt/apt-0.9.8.1/truncate-filename.patch
+++ /dev/null
@@ -1,35 +0,0 @@
1strutl.cc: the filename can't be longer than 255
2
3The URItoFileName translates the path into the filename, but the
4filename can't be longer than 255 according to
5/usr/include/linux/limits.h.
6
7Truncate it when it is longer than 240 (leave some spaces for
8".Packages" and "._Release" suffix)
9
10Upstream-Status: Pending
11Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
12---
13 apt-pkg/contrib/strutl.cc | 7 ++++++-
14 1 file changed, 6 insertions(+), 1 deletion(-)
15
16diff --git a/apt-pkg/contrib/strutl.cc b/apt-pkg/contrib/strutl.cc
17--- a/apt-pkg/contrib/strutl.cc
18+++ b/apt-pkg/contrib/strutl.cc
19@@ -399,7 +399,12 @@ string URItoFileName(const string &URI)
20 // "\x00-\x20{}|\\\\^\\[\\]<>\"\x7F-\xFF";
21 string NewURI = QuoteString(U,"\\|{}[]<>\"^~_=!@#$%^&*");
22 replace(NewURI.begin(),NewURI.end(),'/','_');
23- return NewURI;
24+
25+ // Truncate from the head when it is longer than 240
26+ if(NewURI.length() > 240)
27+ return NewURI.substr(NewURI.length() - 240, NewURI.length() - 1);
28+ else
29+ return NewURI;
30 }
31 /*}}}*/
32 // Base64Encode - Base64 Encoding routine for short strings /*{{{*/
33--
341.7.10.4
35