4#include <zypp-core/base/Logger.h>
5#include <zypp-core/base/IOStream.h>
6#include <zypp-core/Pathname.h>
7#include <zypp-core/fs/PathInfo.h>
9#include <zypp-curl/CurlConfig>
31 char *home =
getenv(
"HOME");
33 curlrcFile = std::string( home ) + std::string(
"/.curlrc" );
50 <<
"': dir/file owner: " <<
h_info.owner() <<
"/" <<
c_info.owner()
51 <<
", process uid: " <<
getuid()
78 const char *
beg =
line.c_str();
82#define ISSEP(x) (((x)=='=') || ((x) == ':') || isspace(x))
85 while (*
cur && *
cur ==
'-')
111 if (value[0] ==
'\"')
114 std::string::size_type
pos = value.rfind(
'\"');
116 pos == value.size() - 1 &&
pos > 1 && value[
pos-1] !=
'\\';
117 value = value.substr(1,
118 cut_last ? value.size() - 2 : value.size() - 1);
122 while ((
pos = value.find(
'\\',
pos)) != std::string::npos)
125 if (
pos == value.size() - 1)
127 value = value.erase(
pos, 1);
134 value = value.replace(
pos, 2,
"\t");
137 value = value.replace(
pos, 2,
"\n");
140 value = value.replace(
pos, 2,
"\r");
143 value = value.replace(
pos, 2,
"\v");
146 value = value.erase(
pos++, 1);
149 value = value.erase(
pos, 1);
170 const std::string &
option,
171 const std::string & value)
173 if (
option ==
"proxy-user")
178 DBG <<
"Ignoring option " <<
option << endl;
Reference counted access to a Tp object calling a custom Dispose function when the last AutoDispose h...
Wrapper class for stat/lstat.
Simple lineparser: Traverse each line in a file.
std::string trim(const std::string &s, const Trim trim_r)
Easy-to use interface to the ZYPP dependency resolver.