]> git.saurik.com Git - apt.git/log
apt.git
10 years agoadd flAbsPath() as a wrapper to realpath()
Michael Vogt [Mon, 28 Apr 2014 15:24:35 +0000 (17:24 +0200)] 
add flAbsPath() as a wrapper to realpath()

10 years agoMerge remote-tracking branch 'upstream/debian/sid' into debian/sid
Michael Vogt [Tue, 22 Apr 2014 14:21:05 +0000 (16:21 +0200)] 
Merge remote-tracking branch 'upstream/debian/sid' into debian/sid

10 years agoConsistently use Dpkg::Progress* in documentation
James McCoy [Mon, 21 Apr 2014 20:35:28 +0000 (16:35 -0400)] 
Consistently use Dpkg::Progress* in documentation

Closes: 745452
10 years agoUpdated Thai program translation (closes: #745120)
Theppitak Karoonboonyanan [Tue, 22 Apr 2014 13:21:38 +0000 (15:21 +0200)] 
Updated Thai program translation (closes: #745120)

10 years agoMerge remote-tracking branch 'donkult/debian/sid' into debian/sid
Michael Vogt [Tue, 22 Apr 2014 13:19:17 +0000 (15:19 +0200)] 
Merge remote-tracking branch 'donkult/debian/sid' into debian/sid

10 years agoFix option name DPkg::Progress-Fancy in apt.8 manpage (LP: #1310506)
Michael Vogt [Tue, 22 Apr 2014 13:14:03 +0000 (15:14 +0200)] 
Fix option name DPkg::Progress-Fancy in apt.8 manpage (LP: #1310506)

10 years agoapt-private/acqprogress.cc: fix output when ctrl-c is hit during apt update (LP:...
Michael Vogt [Tue, 22 Apr 2014 13:10:19 +0000 (15:10 +0200)] 
apt-private/acqprogress.cc: fix output when ctrl-c is hit during apt update (LP: #1310548, closes: #744297)

10 years agosupport dist-upgrade options in full-upgrade
David Kalnischkies [Wed, 16 Apr 2014 20:47:25 +0000 (22:47 +0200)] 
support dist-upgrade options in full-upgrade

dist-upgrade is supposed to be an alias for full-upgrade in apt, but
dist-upgrade was the only command recognized of the two in the option
and flags recognition code.

10 years agoextract travis installs from build-depends automatically
David Kalnischkies [Wed, 16 Apr 2014 20:06:22 +0000 (22:06 +0200)] 
extract travis installs from build-depends automatically

I forgot to add libgtest-dev to the list of packages to install on
travis, so this slightly hacky oneliner might prevent us from having
the same problem again if we happen to change dependencies again.

Git-Dch: Ignore

10 years agouse Google C++ Testing Framework for libapt tests
David Kalnischkies [Wed, 16 Apr 2014 15:09:37 +0000 (17:09 +0200)] 
use Google C++ Testing Framework for libapt tests

My commit 45df0ad2 from 26. Nov 2009 had a little remark:
"The commit also includes a very very simple testapp."
This was never intended to be permanent, but as usually…

The commit adds the needed make magic to compile gtest statically
as it is required and links it against a small runner. All previous
testcase binaries are reimplemented in gtest and combined in this
runner. While most code is a 1:1 translation some had to be rewritten
like compareversion_test.cc, but the coverage remains the same.

10 years agoclear HitEof flag in FileFd::Seek
David Kalnischkies [Tue, 15 Apr 2014 08:21:52 +0000 (10:21 +0200)] 
clear HitEof flag in FileFd::Seek

fseek and co do this to their eof-flags and it is more logic this way as
we will usually seek away from the end (e.g. to re-read the file).

The commit also improves the testcase further and adds a test for the
binary compressor codepath (as gz, bzip2 and xz are handled by
libraries) via the use of 'rev' as a 'compressor'.

10 years agoapt-private/acqprogress.cc: reset color in apt update
Michael Vogt [Wed, 16 Apr 2014 11:15:55 +0000 (13:15 +0200)] 
apt-private/acqprogress.cc: reset color in apt update

10 years agoforce fancy progressbar redraw on window size change
David Kalnischkies [Mon, 14 Apr 2014 15:12:09 +0000 (17:12 +0200)] 
force fancy progressbar redraw on window size change

We always reacted on the size change, but the bar is only redraw if the
precentage changes, which can take quiet a while in big upgrades, so
with a bit of refactoring we can now call for a redraw immediate to fix
this.

This refactor also helps in avoiding obscure pitfalls clangs static
analyser was complaining about (namely failure of ioctl resulting in
garbage values in the struct).

10 years agocompile with absolute paths to allow lcov use
David Kalnischkies [Sun, 13 Apr 2014 19:40:35 +0000 (21:40 +0200)] 
compile with absolute paths to allow lcov use

Instructing gcc (or clang) to prepare for capturing coverage data is
easy: Just build with: CXXFLAGS=--coverage

The hard part is that our buildsystem uses relative paths and so
confuses the hell out of lcov as it assumes this way that all our *.cc
files are in the same directory… by changing to absolute paths in the
compile rules we solve this problem.

Still not perfect as it refers to build/include files for most headers
and our forking/threading code isn't properly captured, but good enough
to see red reports for now:

CXXFLAGS=--coverage make
make test
./test/integration/run-tests -q
lcov --no-external --directory . --capture --output-file apt.info
genhtml --output-directory ./coverage/ apt.info

Git-Dch: Ignore

10 years agol10n: vi.po (624t): Update translation
Trần Ngọc Quân [Fri, 11 Apr 2014 18:19:40 +0000 (20:19 +0200)] 
l10n: vi.po (624t): Update translation

Signed-off-by: Michael Vogt <mvo@debian.org>
10 years agoMerge remote-tracking branch 'mvo/feature/helpful-apt-list' into debian/sid
Michael Vogt [Fri, 11 Apr 2014 12:40:08 +0000 (14:40 +0200)] 
Merge remote-tracking branch 'mvo/feature/helpful-apt-list' into debian/sid

Conflicts:
test/integration/test-apt-cli-list

10 years agoMerge remote-tracking branch 'mvo/bugfix/apt-list-rc-pkgs' into debian/sid
Michael Vogt [Fri, 11 Apr 2014 12:39:28 +0000 (14:39 +0200)] 
Merge remote-tracking branch 'mvo/bugfix/apt-list-rc-pkgs' into debian/sid

10 years agoconsider priorities only for downloadable pkgs in resolver
David Kalnischkies [Fri, 11 Apr 2014 11:33:31 +0000 (13:33 +0200)] 
consider priorities only for downloadable pkgs in resolver

A package which can't be downloaded anymore is very likely dropped from
a release and can therefore no longer be 'standard' (or similar). We
therefore do not grant points for them anymore and demote them to
prio:extra instead which helps other packages breaking them away even if
they have a lower priority.

The testcase was initially created by Michael Vogt and just amended.

10 years agoextend FileFd test behond basic permission tests
David Kalnischkies [Fri, 11 Apr 2014 09:29:31 +0000 (11:29 +0200)] 
extend FileFd test behond basic permission tests

We now do Open, Write and Read (the later multiple ways) for each
permission and each compressor we have configured to cover more cases
and especially ensure that compressors do not change our premissions.

This test is also to be credited for discovering the skippos-fix.

Git-Dch: Ignore

10 years agodeal with umask only if we really need to for mkstemp
David Kalnischkies [Fri, 11 Apr 2014 09:22:10 +0000 (11:22 +0200)] 
deal with umask only if we really need to for mkstemp

As the comment actually says: open() does the umask dance by itself, so
we don't need to do it for it. We have to do it after mkstemp in Atomic
though, so move it into the if.

Also removes the "micro-optimisation" "FilePermissions == 600" as it
doesn't trigger at the moment anyway as 600 != 0600.

10 years agodon't double-count seeks in FileFd::Skip for bzip/xz
David Kalnischkies [Fri, 11 Apr 2014 09:18:58 +0000 (11:18 +0200)] 
don't double-count seeks in FileFd::Skip for bzip/xz

FileFd::Read already deals with the increase of the skipposition so that
we as the caller in FileFd::Skip really shouldn't increase it, too.

10 years agodo not create an (additional) empty compressor
David Kalnischkies [Fri, 11 Apr 2014 09:16:04 +0000 (11:16 +0200)] 
do not create an (additional) empty compressor

FileFd code knows how to deal with such a compressor, so it isn't a
problem, but it is absolutely not needed as we already have an
(matching) identity compressor with '.' earlier in the list.

Git-Dch: Ignore

10 years agobe able to run abicheck from any directory
David Kalnischkies [Sun, 23 Mar 2014 13:09:12 +0000 (14:09 +0100)] 
be able to run abicheck from any directory

Git-Dch: Ignore

10 years agouse wildcard to get files in our library makefiles
David Kalnischkies [Sun, 23 Mar 2014 12:17:24 +0000 (13:17 +0100)] 
use wildcard to get files in our library makefiles

The explicit listing is a pain every time you want to add a file to the
list and serves no propose as we list all files there anyway, so this is
not only easier but also documents this fact.

Git-Dch: Ignore

10 years agofix test-failure in adt
Michael Vogt [Thu, 10 Apr 2014 11:53:28 +0000 (13:53 +0200)] 
fix test-failure in adt

10 years agoprepare 1.0.1 release 1.0.1
Michael Vogt [Thu, 10 Apr 2014 07:49:25 +0000 (09:49 +0200)] 
prepare 1.0.1 release

10 years agoapt: Minor typo in 'apt' man page (closes: #743657)
Josef Vitu [Thu, 10 Apr 2014 07:33:14 +0000 (09:33 +0200)] 
apt: Minor typo in 'apt' man page (closes: #743657)

10 years agoMerge remote-tracking branch 'mvo/bugfix/lp1304657-perms' into debian/sid
Michael Vogt [Thu, 10 Apr 2014 07:15:03 +0000 (09:15 +0200)] 
Merge remote-tracking branch 'mvo/bugfix/lp1304657-perms' into debian/sid

10 years agoMerge remote-tracking branch 'mvo/bugfix/apt-search-case' into debian/sid
Michael Vogt [Thu, 10 Apr 2014 07:14:57 +0000 (09:14 +0200)] 
Merge remote-tracking branch 'mvo/bugfix/apt-search-case' into debian/sid

10 years agoimprove umask/fchmod code readability
Michael Vogt [Thu, 10 Apr 2014 07:11:57 +0000 (09:11 +0200)] 
improve umask/fchmod code readability

10 years agoRename FileFd::Open() Perms to AccessMode
Michael Vogt [Wed, 9 Apr 2014 08:24:47 +0000 (10:24 +0200)] 
Rename FileFd::Open() Perms to AccessMode

Bug lp:#1304657 was caused by confusion around the name Perms.
The new name AccessMode should make it clear that its not the
literal file permissions but instead the AccessMode passed to
open() (i.e. the umask needs to be applied)

10 years agoFix insecure file permissions when using FileFd with OpenMode::Atomic
Michael Vogt [Wed, 9 Apr 2014 08:12:10 +0000 (10:12 +0200)] 
Fix insecure file permissions when using FileFd with OpenMode::Atomic

Commit 7335eebea6dd43581d4650a8818b06383ab89901 introduced a bug
that caused FileFd to create insecure permissions when FileFd::Atomic
is used. This commit fixes the permissions and adds a test.

The bug is most likely caused by the confusing "Perm" parameter
that is passed to Open() - its not the file permissions but intead
the "mode" part of open/creat.

10 years agoNotice the user about "apt list -a" when only a single hit if found
Michael Vogt [Wed, 9 Apr 2014 14:23:14 +0000 (16:23 +0200)] 
Notice the user about "apt list -a" when only a single hit if found

If the user is using "apt list pattern" and there is only a single
hit, notice about "--all-versions" as this is what the user may
be interessted in

10 years agoFix possible race when stunnel/aptwebserver create their PID files
Michael Vogt [Wed, 9 Apr 2014 13:28:00 +0000 (15:28 +0200)] 
Fix possible race when stunnel/aptwebserver create their PID files

This patch should fix spurious test failures in jenkins or travis
that are caused by a race condition in the {stunnel,aptwebserver}.pid
file creation

10 years agofix apt list output for pkgs in dpkg ^rc state
Michael Vogt [Tue, 8 Apr 2014 07:04:15 +0000 (09:04 +0200)] 
fix apt list output for pkgs in dpkg ^rc state

Packages in the "deinstall ok config-file" have no candidate or
instaleld version. So they must be special cased in the apt list
generation.

10 years agoMerge branch 'bugfix/apt-search-case' into debian/sid
Michael Vogt [Tue, 8 Apr 2014 06:31:14 +0000 (08:31 +0200)] 
Merge branch 'bugfix/apt-search-case' into debian/sid

10 years agomake apt search case-insensitive by default
Michael Vogt [Mon, 7 Apr 2014 14:40:12 +0000 (16:40 +0200)] 
make apt search case-insensitive by default

10 years agoAdd versioned openjdk-6-jdk breaks
Julian Andres Klode [Mon, 7 Apr 2014 09:11:06 +0000 (11:11 +0200)] 
Add versioned openjdk-6-jdk breaks

This helps if people did unclean upgrades from squeeze, namely to
jessie directly.

10 years agoVersion the Breaks/Replaces for sun-java{5,6}-jdk (LP: #1302736)
Julian Andres Klode [Mon, 7 Apr 2014 09:01:07 +0000 (11:01 +0200)] 
Version the Breaks/Replaces for sun-java{5,6}-jdk (LP: #1302736)

This is a *hack* to work around unofficial packages for Java 7
and 8 that wrongly provide the Java 5 and 6 packages.

Closes: #743616
10 years agoFix crash in "apt list" when a sources.list file is unreable
Michael Vogt [Fri, 4 Apr 2014 10:16:22 +0000 (12:16 +0200)] 
Fix crash in "apt list" when a sources.list file is unreable

Closes: 743413
10 years agoreleasing package apt version 1.0 1.0
Michael Vogt [Tue, 1 Apr 2014 13:50:00 +0000 (15:50 +0200)] 
releasing package apt version 1.0

10 years agoadd sun-java{5,6}-jdk to breaks/replaces as that provided a "apt" binary as well
Michael Vogt [Tue, 1 Apr 2014 13:37:23 +0000 (15:37 +0200)] 
add sun-java{5,6}-jdk to breaks/replaces as that provided a "apt" binary as well

10 years agoinstall "apt" binary by default
Michael Vogt [Tue, 1 Apr 2014 12:44:24 +0000 (14:44 +0200)] 
install "apt" binary by default

10 years agoprepare release
Michael Vogt [Tue, 1 Apr 2014 12:25:33 +0000 (14:25 +0200)] 
prepare release

10 years agoremove no longer needed apt.7 page
Michael Vogt [Tue, 1 Apr 2014 12:24:17 +0000 (14:24 +0200)] 
remove no longer needed apt.7 page

10 years agofix small apt.8.xml issues
Michael Vogt [Tue, 1 Apr 2014 12:10:34 +0000 (14:10 +0200)] 
fix small apt.8.xml issues

10 years agorefresh po/pot and unfuzzy apt-extracttemplate change
Michael Vogt [Tue, 1 Apr 2014 12:02:16 +0000 (14:02 +0200)] 
refresh po/pot and unfuzzy apt-extracttemplate change

10 years agodebian: Add default compress option to xz
Trần Ngọc Quân [Fri, 28 Mar 2014 07:52:34 +0000 (14:52 +0700)] 
debian: Add default compress option to xz

Signed-off-by: Trần Ngọc Quân <vnwildman@gmail.com>
10 years agol10n: vi.po (623t): Update Vietnamese translation
Trần Ngọc Quân [Fri, 28 Mar 2014 07:50:29 +0000 (14:50 +0700)] 
l10n: vi.po (623t): Update Vietnamese translation

Signed-off-by: Trần Ngọc Quân <vnwildman@gmail.com>
10 years agoMerge remote-tracking branch 'mvo/feature/apt-manpage' into debian/sid
Michael Vogt [Tue, 1 Apr 2014 10:44:08 +0000 (12:44 +0200)] 
Merge remote-tracking branch 'mvo/feature/apt-manpage' into debian/sid

Conflicts:
cmdline/apt.cc

10 years agoadd "full-upgrade" to the apt.5.xml documentation
Michael Vogt [Tue, 1 Apr 2014 10:33:00 +0000 (12:33 +0200)] 
add "full-upgrade" to the apt.5.xml documentation

10 years agoMerge remote-tracking branch 'upstream/debian/sid' into feature/apt-manpage
Michael Vogt [Tue, 1 Apr 2014 10:28:56 +0000 (12:28 +0200)] 
Merge remote-tracking branch 'upstream/debian/sid' into feature/apt-manpage

Conflicts:
cmdline/apt.cc

10 years agoMerge remote-tracking branch 'mvo/feature/more-fancy-progress' into debian/sid
Michael Vogt [Tue, 1 Apr 2014 10:21:46 +0000 (12:21 +0200)] 
Merge remote-tracking branch 'mvo/feature/more-fancy-progress' into debian/sid

10 years agoenable DPkg::Progress-Fancy by default
Michael Vogt [Tue, 1 Apr 2014 10:21:34 +0000 (12:21 +0200)] 
enable DPkg::Progress-Fancy by default

10 years agoMerge remote-tracking branch 'mvo/debian/sid' into debian/sid
Michael Vogt [Tue, 1 Apr 2014 10:21:10 +0000 (12:21 +0200)] 
Merge remote-tracking branch 'mvo/debian/sid' into debian/sid

10 years agodo not crash on SIGPIPE in pkgDPkgPM::RunScriptsWithPkgs()
Michael Vogt [Tue, 1 Apr 2014 10:17:17 +0000 (12:17 +0200)] 
do not crash on SIGPIPE in pkgDPkgPM::RunScriptsWithPkgs()

If a external command closes the PIPE unexpectedly, do not crash
in pkgDPkgPM::RunScriptsWithPkgs but ignore the SIGPIPE.

10 years agoAdd new Debug::RunScripts option
Michael Vogt [Tue, 1 Apr 2014 09:30:00 +0000 (11:30 +0200)] 
Add new Debug::RunScripts option

This debug option will display all scripts that are run
by apts RunScripts and RunScriptsWithPkgs helpers.

10 years agoMerge branch 'debian/sid' into feature/more-fancy-progress
Michael Vogt [Thu, 27 Mar 2014 14:20:49 +0000 (15:20 +0100)] 
Merge branch 'debian/sid' into feature/more-fancy-progress

10 years agoMerge remote-tracking branch 'upstream/debian/sid' into debian/sid
Michael Vogt [Thu, 27 Mar 2014 14:19:29 +0000 (15:19 +0100)] 
Merge remote-tracking branch 'upstream/debian/sid' into debian/sid

10 years agoUse mkstemp() in apt-extracttemplaes (closes: #741627)
Michael Vogt [Thu, 27 Mar 2014 09:14:30 +0000 (10:14 +0100)] 
Use mkstemp() in apt-extracttemplaes (closes: #741627)

Use mkstemp() in apt-extractemplates and add a integrationtest
for apt-extracttemplates too. Thanks to Steve Kemp for the report.

10 years agofix documentation for APT::Periodic::MaxSize "0" (closes: #740551)
Michael Vogt [Thu, 27 Mar 2014 07:42:25 +0000 (08:42 +0100)] 
fix documentation for APT::Periodic::MaxSize "0" (closes: #740551)

10 years agoAdd progressbar to "Dpkg::Progress-Fancy"
Michael Vogt [Thu, 27 Mar 2014 06:56:42 +0000 (07:56 +0100)] 
Add progressbar to "Dpkg::Progress-Fancy"

A text progressbar is now displayed in the Dpkg::Progress-Fancy
mode. It can be turned off via the apt option
Dpkg::Progress-Fancy::Progress-Bar=false

10 years agomake fancy-progress fg/bg color configurable
Michael Vogt [Thu, 27 Mar 2014 05:48:57 +0000 (06:48 +0100)] 
make fancy-progress fg/bg color configurable

Add two new options: Dpkg::Progress-Fancy::Progress-{fg,bg} that
allows customizing the colors in the dpkg fancy progress output.

10 years agodiscard candidates via IsInstallOk to allow override
David Kalnischkies [Tue, 11 Mar 2014 09:31:44 +0000 (10:31 +0100)] 
discard candidates via IsInstallOk to allow override

In commit 446551c8 I changed MarkInstall to discard the candidate if the
candidate can't satisfy the dependency. This breaks interactive solvers
like aptitude which can change the candidate on-the-fly later.

In commit df77d8a5 I introduced this 'early' loop-breaking to begin with
which can't be that helpful for interactive solvers as well, but makes
perfect sense for non-interactives to stop them from exploring trees
which can't be satisfied, but it isn't perfect as ideally we would check
this before auto-installing the first dependency.

This commit therefore moves the loop into its own IsInstallOk hook so
that frontends can override this check if they want to and in exchange
removes the loop-breaking from MarkInstall itself and does it before any
dependency is installed.

Closes: 740750
10 years agodo IsInstallOk call in MarkInstall unconditionally
David Kalnischkies [Tue, 11 Mar 2014 14:32:40 +0000 (15:32 +0100)] 
do IsInstallOk call in MarkInstall unconditionally

Hooked checks could be influenced by AutoInst as a lot can happen
between a call without and one with this bit set. The real cache-hit
check is above this call already. Individual hooked checks can then
inspect the state if they want to cache. Calling them multiple times
shouldn't be a problem either way.

10 years agoupdate symbols file to include new symbols from 0.9.16
David Kalnischkies [Sat, 22 Mar 2014 23:50:05 +0000 (00:50 +0100)] 
update symbols file to include new symbols from 0.9.16

10 years agoensure proper teardown in dpkg error cases
David Kalnischkies [Sat, 22 Mar 2014 20:35:57 +0000 (21:35 +0100)] 
ensure proper teardown in dpkg error cases

We have to properly close our pseudo terminals even in error cases
before we call post-invoke scripts. This is done now by breaking from
the dpkg calling loop instead of copying the handling, which did it in
the wrong order before.

This also ensures that our state file is written in error cases to
record autobit and co as this was forgotten before.

Closes: 738969
10 years agomark optional (private) symbols as hidden
David Kalnischkies [Fri, 21 Mar 2014 15:26:01 +0000 (16:26 +0100)] 
mark optional (private) symbols as hidden

This methods should not be used by anyone expect the library itself as
they are helpers for the specific class and therefore perfect candidates
for hidding.

Git-Dch: Ignore

10 years agoenable fvisibility=hidden for our private library
David Kalnischkies [Fri, 21 Mar 2014 14:54:15 +0000 (15:54 +0100)] 
enable fvisibility=hidden for our private library

While it is a huge undertaking to enable it for our public libraries as
basically everything we exported so far could be seen as public
interface our private library is new and under our full control, so we
can do whatever we like with it. The benefits are not that big in return
of course, but it reduces the size a bit, so thats great nontheless.

Git-Dch: ignore

10 years agoadd testcase for APT::Architectures "arch1,arch2"
David Kalnischkies [Fri, 21 Mar 2014 12:31:34 +0000 (13:31 +0100)] 
add testcase for APT::Architectures "arch1,arch2"

Git-Dch: Ignore

10 years agoJapanese programs translation update
Kenshi Muto [Fri, 21 Mar 2014 11:50:29 +0000 (12:50 +0100)] 
Japanese programs translation update

Closes: 742255
10 years agocorrect some reported typos in /etc/cron.daily/apt
David Kalnischkies [Fri, 21 Mar 2014 11:11:27 +0000 (12:11 +0100)] 
correct some reported typos in /etc/cron.daily/apt

Closes: 702016
Reported-By: Mason Loring Bliss <mason@blisses.org>,
 Jakub Wilk <jwilk@debian.org>

10 years agoItalian manpages translation update
Beatrice Torracca [Fri, 21 Mar 2014 11:03:34 +0000 (12:03 +0100)] 
Italian manpages translation update

Closes: 741867
10 years agoonly consider versioned kernel packages in autoremove
David Kalnischkies [Fri, 21 Mar 2014 10:47:56 +0000 (11:47 +0100)] 
only consider versioned kernel packages in autoremove

Metapackages like "linux-image-amd64" are otherwise matched by our
extraction as well, which later on can't be successfully compared via
dpkg --compare-versions as the 'amd64' bit isn't a version number.
(Luckily none of our architectures starts with a digit.)

This was broken by me in 0.9.16 as I moved a shell-glob matcher to a
regex-based one which has slightly different semantics regarding '*'.

Closes: 741962
10 years agocontinue reading in xz even if it outputs nothing
David Kalnischkies [Fri, 21 Mar 2014 10:04:26 +0000 (11:04 +0100)] 
continue reading in xz even if it outputs nothing

It can happen that content in our buffer is not enough to produce a
meaningful output in which case no output is created by liblzma, but
still reports that everything is okay and we should go on.

The code assumes it has reached the end through if it encounters a null
read, so this commit makes it so that it looks like this read was
interrupted just like the lowlevel read() on uncompressed files could.

It subsequently fixes the issue with that as well as until now our loop
would still break even if we wanted it to continue on.

(This bug triggers our usual "Hash sum mismatch" error)

Reported-By: Stefan Lippers-Hollmann <s.L-H@gmx.de>
10 years agoapt-inst: Do not try to create a substring of an empty string in error reporting
Julian Andres Klode [Mon, 17 Mar 2014 12:43:12 +0000 (13:43 +0100)] 
apt-inst: Do not try to create a substring of an empty string in error reporting

One of our compressors (the empty one) has an empty extension. Calling substr
on it fails.

10 years agoRelease 0.9.16.1 0.9.16.1
Julian Andres Klode [Sat, 15 Mar 2014 17:12:54 +0000 (18:12 +0100)] 
Release 0.9.16.1

10 years agoFix handling of autoclosing for compressed files (Closes: #741685)
Julian Andres Klode [Sat, 15 Mar 2014 16:59:47 +0000 (17:59 +0100)] 
Fix handling of autoclosing for compressed files (Closes: #741685)

AutoClose is both an argument in OpenDescriptor() and an enum. In
commit 84baaae93badc2da7c1f4f356456762895cef278 code using the AutoClose
parameter was moved to OpenDescriptorInternal(). In that function,
AutoClose meant the enum value, so the check was always false.

10 years agoUpdated German doc translation
Chris Leick [Sat, 15 Mar 2014 12:04:15 +0000 (13:04 +0100)] 
Updated German doc translation

10 years agoprepare 0.9.16 release 0.9.16
Michael Vogt [Fri, 14 Mar 2014 08:42:46 +0000 (09:42 +0100)] 
prepare 0.9.16 release

10 years agoadd debian/apt.install to gitignore
Michael Vogt [Fri, 14 Mar 2014 08:42:41 +0000 (09:42 +0100)] 
add debian/apt.install to gitignore

10 years agofix test/integration/test-apt-helper
Michael Vogt [Fri, 14 Mar 2014 08:02:44 +0000 (09:02 +0100)] 
fix test/integration/test-apt-helper

10 years agoMerge branch 'debian/sid' of ssh://git.debian.org/git/apt/apt into debian/sid
Michael Vogt [Thu, 13 Mar 2014 17:28:42 +0000 (18:28 +0100)] 
Merge branch 'debian/sid' of ssh://git.debian.org/git/apt/apt into debian/sid

10 years agouse the pretty fullname of a pkg as download desciption
David Kalnischkies [Thu, 13 Mar 2014 00:27:34 +0000 (01:27 +0100)] 
use the pretty fullname of a pkg as download desciption

Otherwise the "WARNING: The following packages cannot be authenticated!"
messages does not include the architecture of the package, so it would
be slightly misinformative.

10 years agorefactor FileFd to hide some #ifdefs
David Kalnischkies [Wed, 12 Mar 2014 15:16:14 +0000 (16:16 +0100)] 
refactor FileFd to hide some #ifdefs

They tend to be ugly to look at, so hide them.

Git-Dch: Ignore

10 years agouse liblzma-dev to provide xz/lzma support
David Kalnischkies [Wed, 12 Mar 2014 13:39:18 +0000 (14:39 +0100)] 
use liblzma-dev to provide xz/lzma support

We have xz/lzma support for a while, but only via an external binary
provided by xz-utils. Now that the Debian archive provides xz by default
and dpkg pre-depends on the library provided by liblzma-dev we can switch
now to use this library as well to avoid requiring an external binary.
For now the binary is in a prio:required package, but this might change
in the future.

API wise it is quiet similar to bz2 code expect that it doesn't provide
file I/O methods, so we piece this together on our own.

10 years agoadd a config option to switch uncompress methods to compress
David Kalnischkies [Wed, 12 Mar 2014 13:24:41 +0000 (14:24 +0100)] 
add a config option to switch uncompress methods to compress

Not very useful in the normal operation of work, but handy for tests.

Git-Dch: Ignore

10 years agoensure that gz compression test is run with gz
David Kalnischkies [Wed, 12 Mar 2014 12:36:08 +0000 (13:36 +0100)] 
ensure that gz compression test is run with gz

The framework can be configured to use different compression algorithms
to test different ones, but a testcase testing for gz support should
always be run with gz, regardless of what compressions are configured
otherwise.

Git-Dch: Ignore

10 years agofactor out getting list of architectures from comma list
David Kalnischkies [Wed, 12 Mar 2014 12:31:41 +0000 (13:31 +0100)] 
factor out getting list of architectures from comma list

Beside fixing this minor code duplication it also resolves the problem
of messing up vim syntax-highlighting.

Git-Dch: Ignore

10 years agorefactor setup of file opening via zlib/bz2 lib
David Kalnischkies [Sun, 9 Jun 2013 12:32:48 +0000 (14:32 +0200)] 
refactor setup of file opening via zlib/bz2 lib

Git-Dch: Ignore

10 years agomove fd duplication closer to the gz/bz2 open calls
David Kalnischkies [Fri, 31 May 2013 17:27:57 +0000 (19:27 +0200)] 
move fd duplication closer to the gz/bz2 open calls

Git-Dch: Ignore

10 years agoabstract version hash comparison a bit
David Kalnischkies [Wed, 12 Mar 2014 16:55:08 +0000 (17:55 +0100)] 
abstract version hash comparison a bit

In #737085 we see that apt can be confused if informations about
versions only differ slightly. This commit adds a way of at least adding
a few more data points with the next abi break to help a bit with it.

Git-Dch: Ignore

10 years agofactor out parsing of MultiArch flag
David Kalnischkies [Wed, 12 Mar 2014 15:53:44 +0000 (16:53 +0100)] 
factor out parsing of MultiArch flag

Git-Dch: Ignore

10 years agocorrect LD_LIBRARY_PATH and config loading for apt-helper
David Kalnischkies [Mon, 10 Mar 2014 21:31:00 +0000 (22:31 +0100)] 
correct LD_LIBRARY_PATH and config loading for apt-helper

Mostly ensures that we use the build methods and not the system
provided methods in the tests (if we don't want it that way).

Git-Dch: Ignore

10 years agoensure that a dot is a dot in the hook
David Kalnischkies [Mon, 10 Mar 2014 20:31:35 +0000 (21:31 +0100)] 
ensure that a dot is a dot in the hook

As we deal with regex matchers here the dots are treated as wildcards if
we don't take care of escaping them. Not very likely that this could be
a real-world problem, but just to be sure.

10 years agoadd ".*-{kernel,modules}-$KERVER" matcher for hook
David Kalnischkies [Mon, 10 Mar 2014 20:12:59 +0000 (21:12 +0100)] 
add ".*-{kernel,modules}-$KERVER" matcher for hook

Pre-build kernel modules (like those build with module-assistent) are
commonly named in this way and it should be ungeneric enough to be added
by default for everyone.

10 years agosupport kfreebsd and hurd in the kernel hook
David Kalnischkies [Mon, 10 Mar 2014 19:57:07 +0000 (20:57 +0100)] 
support kfreebsd and hurd in the kernel hook

kfreebsd as well as hurd kernel packages call the postinst script as
well so we just need to enable the correct parsing for installed
packages and disable the "protect every version" hammer for them.

10 years agouse a configurable list of versioned kernel packages
David Kalnischkies [Mon, 10 Mar 2014 16:53:22 +0000 (17:53 +0100)] 
use a configurable list of versioned kernel packages

With APT::VersionedKernelPackages users have the option of adding
packages like pre-build out-of-tree modules to the list of automatically
protected from being autoremoved.

10 years agocmdline parsing: apt-config is not apt-cdrom
David Kalnischkies [Mon, 10 Mar 2014 14:12:11 +0000 (15:12 +0100)] 
cmdline parsing: apt-config is not apt-cdrom

10 years agoimprove debug output in case downloadfile fails
David Kalnischkies [Mon, 10 Mar 2014 13:15:45 +0000 (14:15 +0100)] 
improve debug output in case downloadfile fails

Git-Dch: Ignore