X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/cdcc6d34b0256aa5efe159351bb24b2e28ed143b..36f610f18a9a12c02ba89c6bb84726f7ed3ba7ad:/apt-pkg/acquire-method.cc diff --git a/apt-pkg/acquire-method.cc b/apt-pkg/acquire-method.cc index 7f0119819..678b10646 100644 --- a/apt-pkg/acquire-method.cc +++ b/apt-pkg/acquire-method.cc @@ -1,6 +1,6 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: acquire-method.cc,v 1.16 1999/01/27 02:48:52 jgg Exp $ +// $Id: acquire-method.cc,v 1.18 1999/03/15 08:10:39 jgg Exp $ /* ###################################################################### Acquire Method @@ -18,6 +18,7 @@ #include #include +#include /*}}}*/ // AcqMethod::pkgAcqMethod - Constructor /*{{{*/ @@ -68,7 +69,16 @@ void pkgAcqMethod::Fail(bool Transient) // --------------------------------------------------------------------- /* */ void pkgAcqMethod::Fail(string Err,bool Transient) -{ +{ + // Strip out junk from the error messages + for (char *I = Err.begin(); I != Err.end(); I++) + { + if (*I == '\r') + *I = ' '; + if (*I == '\n') + *I = ' '; + } + char S[1024]; if (Queue != 0) { @@ -270,7 +280,8 @@ bool pkgAcqMethod::Configuration(string Message) if (End == Equals) return false; - Cnf.Set(string(I,Equals-I),string(Equals+1,End-Equals-1)); + Cnf.Set(DeQuoteString(string(I,Equals-I)), + DeQuoteString(string(Equals+1,End-Equals-1))); I = End; }