X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/a0a4d1433a42d581697adacb1c3c095df4b23a56..d59671c9eef322c10abba22b0257fef37979dfd4:/apt-pkg/acquire.h diff --git a/apt-pkg/acquire.h b/apt-pkg/acquire.h index 0d2b21233..7044797b3 100644 --- a/apt-pkg/acquire.h +++ b/apt-pkg/acquire.h @@ -4,7 +4,7 @@ Acquire - File Acquiration - This module contians the Acquire system. It is responsible for bringing + This module contains the Acquire system. It is responsible for bringing files into the local pathname space. It deals with URIs for files and URI handlers responsible for downloading or finding the URIs. @@ -236,8 +236,15 @@ class pkgAcquire * * \param WSet The set of file descriptors that are ready for * output. + * + * \return false if there is an error condition on one of the fds */ - virtual void RunFds(fd_set *RSet,fd_set *WSet); + bool RunFdsSane(fd_set *RSet,fd_set *WSet); + + // just here for compatbility, needs to be removed on the next + // ABI/API break. RunFdsSane() is what should be used as it + // returns if there is an error condition on one of the fds + virtual void RunFds(fd_set *RSet,fd_set *WSet); /** \brief Check for idle queues with ready-to-fetch items. * @@ -303,9 +310,11 @@ class pkgAcquire /** \brief Get the head of the list of items. */ inline ItemIterator ItemsBegin() {return Items.begin();}; + inline ItemCIterator ItemsBegin() const {return Items.begin();}; /** \brief Get the end iterator of the list of items. */ inline ItemIterator ItemsEnd() {return Items.end();}; + inline ItemCIterator ItemsEnd() const {return Items.end();}; // Iterate over queued Item URIs class UriIterator; @@ -355,7 +364,7 @@ class pkgAcquire * if no lock file should be used. If set also all needed directories * will be created. */ - APT_DEPRECATED bool Setup(pkgAcquireStatus *Progress = NULL, std::string const &Lock = ""); + APT_DEPRECATED_MSG("Use constructors, .SetLog and .GetLock as needed") bool Setup(pkgAcquireStatus *Progress = NULL, std::string const &Lock = ""); void SetLog(pkgAcquireStatus *Progress) { Log = Progress; }