diff options
author | Daniel Hartwig <mandyke@gmail.com> | 2012-04-25 18:07:21 +0800 |
---|---|---|
committer | Daniel Hartwig <mandyke@gmail.com> | 2012-04-25 18:07:21 +0800 |
commit | 8e201150ede627335a5587de6dfea897637c702c (patch) | |
tree | d5f9a1902a27ad067d81b8df074ef6b7fec6013e | |
parent | fd0f5f392d07d0cd739b6b75e49cf9af2d3f402b (diff) | |
download | aptitude-8e201150ede627335a5587de6dfea897637c702c.tar.gz |
Check for apt_init errors in cmdline_download.cc
Closes: #670379
-rw-r--r-- | NEWS | 3 | ||||
-rw-r--r-- | src/cmdline/cmdline_download.cc | 6 |
2 files changed, 9 insertions, 0 deletions
@@ -7,6 +7,9 @@ Version 0.6.7 "I said 'Step pause turn * [cmdline]: Avoid dpkg and infinite loop in download-only mode (Closes: #629266) (LP: #975793) + * [cmdline]: Check for apt_init errors in cmdline_download.cc + (Closes: #670379) + - New translations: * Croatian (Closes: #667934) diff --git a/src/cmdline/cmdline_download.cc b/src/cmdline/cmdline_download.cc index 68329faf..655d6337 100644 --- a/src/cmdline/cmdline_download.cc +++ b/src/cmdline/cmdline_download.cc @@ -51,6 +51,12 @@ int cmdline_download(int argc, char *argv[]) shared_ptr<OpProgress> progress = make_text_progress(false, term, term, term); apt_init(progress.get(), false); + if(_error->PendingError()) + { + _error->DumpErrors(); + return -1; + } + pkgSourceList list; if(!list.ReadMainList()) { |