On Thu, Jan 11, 2024 at 03:53:17PM +0100, Emanuele Rocca wrote: > Hi Julian, > > On 2024-01-08 10:28, Julian Andres Klode wrote: > > (in Ubuntu we have partially recovered by disabling stack clash > > protection but it crashes on invalid writes there, I suppose we need > > to rebuild some more apt dependencies without the flag...). > > The 'invalid writes' issue seems unrelated to armhf and > stack-clash-protection, > I can reproduce it on my x86 workstation. It would be interesting to see if > once these problems are fixed valgrind on armhf still segfaults. > > (sid-amd64)root@ariel:~# valgrind apt-get update > ==194196== Memcheck, a memory error detector > ==194196== Copyright (C) 2002-2022, and GNU GPL'd, by Julian Seward et al. > ==194196== Using Valgrind-3.20.0 and LibVEX; rerun with -h for copyright info > ==194196== Command: apt-get update > ==194196== > Hit:1 http://127.0.0.1:3142/debian sid InRelease > ==194196== Conditional jump or move depends on uninitialised value(s) > ==194196== at 0x4A89B3B: pkgCache::ReMap(bool const&) (in > /usr/lib/x86_64-linux-gnu/libapt-pkg.so.6.0.0) > [... more errors follow]
The uninitialized values in ReMap are actually normal and correct behavior, not errors. It happens because we need to grow the array/map without having written all bytes of it first. The same applies to uninitalized bytes passed to write from pkgCacheFile::BuildCaches(), it's writing the partially initialized memory pool to the file. And there aren't any hard errors. We could zero initialize those or add supressions to make things look nicer I suppose. -- debian developer - deb.li/jak | jak-linux.org - free software dev ubuntu core developer i speak de, en