// -*- 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
#include <apt-pkg/fileutl.h>
#include <stdio.h>
+#include <unistd.h>
/*}}}*/
// AcqMethod::pkgAcqMethod - Constructor /*{{{*/
// ---------------------------------------------------------------------
/* */
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)
{
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;
}