summaryrefslogtreecommitdiff
path: root/apt-pkg
diff options
context:
space:
mode:
authorMichael Vogt <egon@bottom>2006-07-26 16:13:02 +0200
committerMichael Vogt <egon@bottom>2006-07-26 16:13:02 +0200
commit961c7214468e3fce4deb432d3a0b31b2510aaafe (patch)
treed10fab8cffdf97d5efcd85a503e4906771c39c5e /apt-pkg
parentb28fffc2825b807a26513f2ac5f34cb6e064acbf (diff)
parent4577fda2b5f2b21f5400d10f4db71a8095f0df58 (diff)
* merged with mainline
Diffstat (limited to 'apt-pkg')
-rw-r--r--apt-pkg/acquire-item.cc2
-rw-r--r--apt-pkg/contrib/sha256.cc8
-rw-r--r--apt-pkg/deb/dpkgpm.cc8
3 files changed, 12 insertions, 6 deletions
diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc
index 966126255..84760a514 100644
--- a/apt-pkg/acquire-item.cc
+++ b/apt-pkg/acquire-item.cc
@@ -569,7 +569,7 @@ pkgAcqIndex::pkgAcqIndex(pkgAcquire *Owner,
if(comprExt.empty())
{
// autoselect the compression method
- if(FileExists("/usr/bin/bzip2"))
+ if(FileExists("/bin/bzip2"))
CompressionExtension = ".bz2";
else
CompressionExtension = ".gz";
diff --git a/apt-pkg/contrib/sha256.cc b/apt-pkg/contrib/sha256.cc
index ad2ddb2d3..b75ce8a84 100644
--- a/apt-pkg/contrib/sha256.cc
+++ b/apt-pkg/contrib/sha256.cc
@@ -61,10 +61,10 @@ static inline u32 Maj(u32 x, u32 y, u32 z)
static inline void LOAD_OP(int I, u32 *W, const u8 *input)
{
- W[I] = ( ((u32) input[I + 0] << 24)
- | ((u32) input[I + 1] << 16)
- | ((u32) input[I + 2] << 8)
- | ((u32) input[I + 3]));
+ W[I] = ( ((u32) input[I * 4 + 0] << 24)
+ | ((u32) input[I * 4 + 1] << 16)
+ | ((u32) input[I * 4 + 2] << 8)
+ | ((u32) input[I * 4 + 3]));
}
static inline void BLEND_OP(int I, u32 *W)
diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc
index 667db8ff2..bf0434ccc 100644
--- a/apt-pkg/deb/dpkgpm.cc
+++ b/apt-pkg/deb/dpkgpm.cc
@@ -624,7 +624,13 @@ bool pkgDPkgPM::Go(int OutStatusFd)
*/
char* list[5];
- TokSplitString(':', line, list, sizeof(list)/sizeof(list[0]));
+ if(!TokSplitString(':', line, list, sizeof(list)/sizeof(list[0])))
+ // FIXME: dpkg sends multiline error messages sometimes (see
+ // #374195 for a example. we should support this by
+ // either patching dpkg to not send multiline over the
+ // statusfd or by rewriting the code here to deal with
+ // it. for now we just ignore it and not crash
+ continue;
char *pkg = list[1];
char *action = _strstrip(list[2]);