diff options
| author | наб <nabijaczleweli@nabijaczleweli.xyz> | 2024-11-12 19:50:56 +0100 |
|---|---|---|
| committer | наб <nabijaczleweli@nabijaczleweli.xyz> | 2024-11-12 20:36:20 +0100 |
| commit | b430a53e45b6d676142af7da78564de3bd97ef5f (patch) | |
| tree | a112059dfad3e337403fef1629ee5740efefca07 /methods/http.cc | |
| parent | 9ae21ac6043eda2ee7cb591209a29b473bef41aa (diff) | |
methods/http.cc: APT::StringView -> std::string_view
Diffstat (limited to 'methods/http.cc')
| -rw-r--r-- | methods/http.cc | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/methods/http.cc b/methods/http.cc index 0c4d82262..4d0e60d93 100644 --- a/methods/http.cc +++ b/methods/http.cc @@ -23,7 +23,6 @@ #include <apt-pkg/fileutl.h> #include <apt-pkg/hashes.h> #include <apt-pkg/proxy.h> -#include <apt-pkg/string_view.h> #include <apt-pkg/strutl.h> #include <cerrno> @@ -977,12 +976,12 @@ void HttpMethod::SendReq(FetchItem *Itm) #ifdef HAVE_SYSTEMD if (ConfigFindB("User-Agent-Non-Interactive", false)) { - using APT::operator""_sv; + using std::literals::operator""sv; char *unit = nullptr; sd_pid_get_unit(getpid(), &unit); if (unit != nullptr && *unit != '\0' && not APT::String::Startswith(unit, "user@") // user@ _is_ interactive - && "packagekit.service"_sv != unit // packagekit likely is interactive - && "dbus.service"_sv != unit) // aptdaemon and qapt don't have systemd services + && "packagekit.service"sv != unit // packagekit likely is interactive + && "dbus.service"sv != unit) // aptdaemon and qapt don't have systemd services Req << " non-interactive"; free(unit); |
