From 8d326119082e239e17c4179de77a77911414d2df Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Thu, 24 Jan 2013 18:55:44 +0100 Subject: * apt-pkg/indexrecords.cc: - support '\r' in the Release file --- apt-pkg/indexrecords.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/indexrecords.cc b/apt-pkg/indexrecords.cc index af2639beb..649b6059d 100644 --- a/apt-pkg/indexrecords.cc +++ b/apt-pkg/indexrecords.cc @@ -173,7 +173,7 @@ bool indexRecords::parseSumData(const char *&Start, const char *End, /*{{{*/ Hash = ""; Size = 0; /* Skip over the first blank */ - while ((*Start == '\t' || *Start == ' ' || *Start == '\n') + while ((*Start == '\t' || *Start == ' ' || *Start == '\n' || *Start == '\r') && Start < End) Start++; if (Start >= End) @@ -215,7 +215,8 @@ bool indexRecords::parseSumData(const char *&Start, const char *End, /*{{{*/ EntryEnd = Start; /* Find the end of the third entry (the filename) */ - while ((*EntryEnd != '\t' && *EntryEnd != ' ' && *EntryEnd != '\n') + while ((*EntryEnd != '\t' && *EntryEnd != ' ' && + *EntryEnd != '\n' && *EntryEnd != '\r') && EntryEnd < End) EntryEnd++; -- cgit v1.2.3