<feed xmlns='http://www.w3.org/2005/Atom'>
<title>apt/apt-pkg, branch 1.3</title>
<subtitle>Debians commandline package manager</subtitle>
<id>https://git.kalnischkies.de/apt/atom?h=1.3</id>
<link rel='self' href='https://git.kalnischkies.de/apt/atom?h=1.3'/>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/'/>
<updated>2016-09-18T12:17:17Z</updated>
<entry>
<title>VersionHash: Do not skip too long dependency lines</title>
<updated>2016-09-18T12:17:17Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>jak@debian.org</email>
</author>
<published>2016-09-18T11:24:35Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=708e2f1fe99e6f067292bc909f03f12c181e4798'/>
<id>urn:sha1:708e2f1fe99e6f067292bc909f03f12c181e4798</id>
<content type='text'>
If the dependency line does not contain spaces in the repository
but does in the dpkg status file (because dpkg normalized the
dependency list), the dpkg line might be longer than the line
in the repository. If it now happens to be longer than 1024
characters, it would be skipped, causing the hashes to be
out of date.

Note that we have to bump the minor cache version again as
this changes the format slightly, and we might get mismatches
with an older src cache otherwise.

Fixes Debian/apt#23
</content>
</entry>
<entry>
<title>Coverage: Do not print messages from gcov</title>
<updated>2016-09-11T15:44:17Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>jak@debian.org</email>
</author>
<published>2016-09-11T11:58:40Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=bccb344412a0e97afdf0aaaf41a31124c84f6eaa'/>
<id>urn:sha1:bccb344412a0e97afdf0aaaf41a31124c84f6eaa</id>
<content type='text'>
We need to ignore messages from gcov. All those messages
start with profiling: and are printed using vfprintf(), so
the only thing we can do is add a library overriding those
functions and linking apt-pkg to it.
</content>
</entry>
<entry>
<title>edsp: try 2 to read responses even if writing failed</title>
<updated>2016-09-07T08:21:01Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2016-09-07T08:21:01Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=12b201da7c1d5e2beceae796151e4ebedc5bae97'/>
<id>urn:sha1:12b201da7c1d5e2beceae796151e4ebedc5bae97</id>
<content type='text'>
Commit b60c8a89c281f2bb945d426d2215cbf8f5760738 improved the situation,
but due to inconsistency mostly for planners, not for solvers. As the
idea of hiding errors if we show another error is a bit scary (as the
extern error might be a followup of our intern error, rather than the
reason for our intern error as it is at the moment) we don't discard the
errors, but if we got an extern error we show them directly removing
them from the error list at the end of the run – that list will contain
the extern error which hopefully gives us the best of both worlds.

The problem itself is the same as before: The externals exiting before
apt is done talking to them.

Reported-By: Johannes 'josch' Schauer on IRC
</content>
</entry>
<entry>
<title>acquire: Use priority queues and a 3 stage pipeline design</title>
<updated>2016-09-02T15:16:36Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>jak@debian.org</email>
</author>
<published>2016-06-15T21:13:43Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=2a440328ea19e9646a93f847dd9eff21e03ad16d'/>
<id>urn:sha1:2a440328ea19e9646a93f847dd9eff21e03ad16d</id>
<content type='text'>
Employ a priority queue instead of a normal queue to hold
the items; and only add items to the running pipeline if
their priority is the same or higher than the priority
of items in the queue.

The priorities are designed for a 3 stage pipeline system:

In stage 1, all Release files and .diff/Index files are fetched. This
allows us to determine what files remain to be fetched, and thus
ensures a usable progress reporting.

In stage 2, all Pdiff patches are fetched, so we can apply them
in parallel with fetching other files in stage 3.

In stage 3, all other files are fetched (complete index files
such as Contents, Packages).

Performance improvements, mainly from fetching the pdiff patches
before complete files, so they can be applied in parallel:

For the 01 Sep 2016 03:35:23 UTC -&gt; 02 Sep 2016 09:25:37 update
of Debian unstable and testing with Contents and appstream for
amd64 and i386, update time reduced from 37 seconds to 24-28
seconds.

Previously, apt would first download new DEP11 icon tarballs
and metadata files, causing the CPU to be idle. By fetching
the diffs in stage 2, we can now patch our contents and Packages
files while we are downloading the DEP11 stuff.
</content>
</entry>
<entry>
<title>CMake: apt-pkg: Use correct ICONV_INCLUDE_DIRS variable</title>
<updated>2016-09-02T12:44:08Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>jak@debian.org</email>
</author>
<published>2016-09-02T12:44:08Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=544e1528b18025fad8318e6fb825ad296976cf24'/>
<id>urn:sha1:544e1528b18025fad8318e6fb825ad296976cf24</id>
<content type='text'>
This accidentally used ICONV_DIRECTORIES, which does not
even exist. Weird.
</content>
</entry>
<entry>
<title>try not to call memcpy with length 0 in hash calculations</title>
<updated>2016-09-01T14:13:14Z</updated>
<author>
<name>David Kalnischkies</name>
<email>david@kalnischkies.de</email>
</author>
<published>2016-08-31T08:11:07Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=644478e8db56f305601c3628a74e53de048b28c8'/>
<id>urn:sha1:644478e8db56f305601c3628a74e53de048b28c8</id>
<content type='text'>
memcpy is marked as nonnull for its input, but ignores the input anyhow
if the declared length is zero. Our SHA2 implementations do this as
well, it was "just" MD5 and SHA1 missing, so we add the length check
here as well as along the callstack as it is really pointless to do all
these method calls for "nothing".

Reported-By: gcc -fsanitize=undefined
</content>
</entry>
<entry>
<title>Base256ToNum: Fix uninitialized value</title>
<updated>2016-08-31T15:40:15Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>jak@debian.org</email>
</author>
<published>2016-08-31T15:18:07Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=cf7503d8a09ebce695423fdeb2402c456c18f3d8'/>
<id>urn:sha1:cf7503d8a09ebce695423fdeb2402c456c18f3d8</id>
<content type='text'>
If the inner Base256ToNum() returned false, it did not set
Num to a new value, causing it to be uninitialized, and thus
might have caused the function to exit despite a good result.

Also document why the Res = Num, if (Res != Num) magic is done.

Reported-By: valgrind
</content>
</entry>
<entry>
<title>TagFile: Fix off-by-one errors in comment stripping</title>
<updated>2016-08-31T15:39:06Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>jak@debian.org</email>
</author>
<published>2016-08-31T15:01:04Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=923c592ceb6014b31ec751b97b3ed659fa3e88ae'/>
<id>urn:sha1:923c592ceb6014b31ec751b97b3ed659fa3e88ae</id>
<content type='text'>
Adding 1 to the value of d-&gt;End - current makes restLength one byte
too long: If we pass memchr(current, ..., restLength) has thus
undefined behavior.

Also, reading the value of current has undefined behavior if
current &gt;= d-&gt;End, not only for current &gt; d-&gt;End:

Consider a string of length 1, that is d-&gt;End = d-&gt;Current + 1.
We can only read at d-&gt;Current + 0, but d-&gt;Current + 1 is beyond
the end of the string.

This probably caused several inexplicable build failures on hurd-i386
in the past, and just now caused a build failure on Ubuntu's amd64
builder.

Reported-By: valgrind
</content>
</entry>
<entry>
<title>Fix segfault and out-of-bounds read in Binary fields</title>
<updated>2016-08-31T10:12:56Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>jak@debian.org</email>
</author>
<published>2016-08-31T09:36:44Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=ce6cd75dc367b92f65e4fb539dd166d0f3361f8c'/>
<id>urn:sha1:ce6cd75dc367b92f65e4fb539dd166d0f3361f8c</id>
<content type='text'>
If a Binary field contains one or more spaces before a comma, the
code produced a segmentation fault, as it accidentally set a pointer
to 0 instead of the value of the pointer.

If the comma is at the beginning of the field, the code would
create a binStartNext that points one element before the start
of the string, which is undefined behavior.

We also need to check that we do not exit the string during the
replacement of spaces before commas: A string of the form " ,"
would normally exit the boundary of the Buffer:

	binStartNext = offset 1 ','
	binEnd = offset 0	' '
	isspace_ascii(*binEnd) = true =&gt; --binEnd
				      =&gt; binEnd = - 1

We get rid of the problem by only allowing spaces to be eliminated
if they are not the first character of the buffer:

        binStartNext = offset 1 ','
        binEnd = offset 0       ' '
        binEnd &gt; buffer = false, isspace_ascii(*binEnd) = true
		 =&gt; exit loop
                =&gt; binEnd remains 0
</content>
</entry>
<entry>
<title>init: Add Dir::Bin::planners default entry</title>
<updated>2016-08-29T13:04:51Z</updated>
<author>
<name>Julian Andres Klode</name>
<email>jak@debian.org</email>
</author>
<published>2016-08-29T13:04:51Z</published>
<link rel='alternate' type='text/html' href='https://git.kalnischkies.de/apt/commit/?id=06372c6a4f2bb8812f68c56788e96dc8fa69b3de'/>
<id>urn:sha1:06372c6a4f2bb8812f68c56788e96dc8fa69b3de</id>
<content type='text'>
Apparently we had no default defined for this.

Reported-By: David Kalnischkies
</content>
</entry>
</feed>
