From 35f80ea571b726ae77bcabab4e896b85e541bf04 Mon Sep 17 00:00:00 2001 From: Sam Bingner Date: Fri, 28 Sep 2018 08:34:18 -1000 Subject: Remove errors that we don't need --- apt-pkg/acquire.cc | 1 - apt-pkg/deb/debmetaindex.cc | 3 --- methods/gpgv.cc | 2 +- methods/http.cc | 2 +- 4 files changed, 2 insertions(+), 6 deletions(-) diff --git a/apt-pkg/acquire.cc b/apt-pkg/acquire.cc index 4ccfa2605..5d85beec6 100644 --- a/apt-pkg/acquire.cc +++ b/apt-pkg/acquire.cc @@ -603,7 +603,6 @@ static void CheckDropPrivsMustBeDisabled(pkgAcquire const &Fetcher) struct passwd const * const pw = getpwnam(SandboxUser.c_str()); if (pw == NULL) { - _error->Warning(_("No sandbox user '%s' on the system, can not drop privileges"), SandboxUser.c_str()); _config->Set("APT::Sandbox::User", ""); return; } diff --git a/apt-pkg/deb/debmetaindex.cc b/apt-pkg/deb/debmetaindex.cc index 091b187a2..1a89fcc88 100644 --- a/apt-pkg/deb/debmetaindex.cc +++ b/apt-pkg/deb/debmetaindex.cc @@ -458,9 +458,6 @@ bool debReleaseIndex::Load(std::string const &Filename, std::string * const Erro if (CheckValidUntil == true) { - if (Date == 0) - _error->Warning( _("Invalid '%s' entry in Release file %s"), "Date", Filename.c_str()); - std::string const Label = Section.FindS("Label"); std::string const StrValidUntil = Section.FindS("Valid-Until"); diff --git a/methods/gpgv.cc b/methods/gpgv.cc index 95a86f890..2ea9fdb0c 100644 --- a/methods/gpgv.cc +++ b/methods/gpgv.cc @@ -67,7 +67,7 @@ struct Digest { static constexpr Digest Digests[] = { {Digest::State::Untrusted, "Invalid digest"}, {Digest::State::Untrusted, "MD5"}, - {Digest::State::Untrusted, "SHA1"}, + {Digest::State::Trusted, "SHA1"}, {Digest::State::Untrusted, "RIPE-MD/160"}, {Digest::State::Trusted, "Reserved digest"}, {Digest::State::Trusted, "Reserved digest"}, diff --git a/methods/http.cc b/methods/http.cc index 4703584cf..35a7d9d3a 100644 --- a/methods/http.cc +++ b/methods/http.cc @@ -603,7 +603,7 @@ int main(int, const char *argv[]) if (UniqueID_ == NULL) if (void *lockdown = lockdown_connect()) { - UniqueID_ = lockdown_copy_value(lockdown, NULL, kLockdownUniqueDeviceIDKey); + UniqueID_ = (CFStringRef)lockdown_copy_value(lockdown, NULL, kLockdownUniqueDeviceIDKey); lockdown_disconnect(lockdown); } -- cgit v1.2.3 From f05c3233c311d40bb9f2ef65888aa7ce574a334b Mon Sep 17 00:00:00 2001 From: Sam Bingner Date: Sun, 30 Sep 2018 22:50:02 -1000 Subject: Use access instead of faccessat for iOS5 compatibility --- apt-pkg/contrib/fileutl.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apt-pkg/contrib/fileutl.cc b/apt-pkg/contrib/fileutl.cc index f3c7b6d3b..e4038c39c 100644 --- a/apt-pkg/contrib/fileutl.cc +++ b/apt-pkg/contrib/fileutl.cc @@ -2949,7 +2949,7 @@ static std::string APT_NONNULL(1) GetTempDirEnv(char const * const env) /*{{{*/ stat(tmpdir, &st) != 0 || (st.st_mode & S_IFDIR) == 0) // exists and is directory tmpdir = "/tmp"; else if (geteuid() != 0 && // root can do everything anyway - faccessat(-1, tmpdir, R_OK | W_OK | X_OK, AT_EACCESS | AT_SYMLINK_NOFOLLOW) != 0) // current user has rwx access to directory + access(tmpdir, R_OK | W_OK | X_OK) != 0) // current user has rwx access to directory tmpdir = "/tmp"; return string(tmpdir); -- cgit v1.2.3