[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#778557: lintian: Errors processing libelmersolver-dbg/6.1.0.svn.5396.dfsg2-4+b1



On 2015-02-16 17:32, Niels Thykier wrote:
> Package: lintian
> Version: 2.5.30+deb8u3
> Severity: normal
> 
>>From lintian.d.o's logs:
> 
> """
> N: Processing binary package libelmersolver-dbg (version 6.1.0.svn.5396.dfsg2-4+b1, arch amd64) ...
> Use of uninitialized value in pattern match (m//) at /srv/lintian.debian.org/root/checks/binaries.pm line 129.
> Use of uninitialized value in pattern match (m//) at /srv/lintian.debian.org/root/checks/binaries.pm line 129.
> Use of uninitialized value in pattern match (m//) at /srv/lintian.debian.org/root/checks/binaries.pm line 129.
> E: libelmersolver-dbg binary (6.1.0.svn.5396.dfsg2-4+b1) [amd64]: binary-with-bad-dynamic-table usr/lib/dreadelf: Error: the dynamic segment offset + size exceeds the size of the file
> [...]
> Can't use an undefined value as an ARRAY reference at /srv/lintian.debian.org/root/checks/binaries.pm line 427.
> internal error: cannot run binaries check on package binary:libelmersolver-dbg/6.1.0.svn.5396.dfsg2-4+b1/amd64
> warning: skipping check of binary:libelmersolver-dbg/6.1.0.svn.5396.dfsg2-4+b1/amd64
> N: ----
> """
> 
> ~Niels
> 

More info:

 * Only reproducible on a stable system - but it is reproducible every
   time.
 * It seems to be caused by readelf "truncating" its own output with a
   message from stderr.

I managed to extract the following "extra" message:
"""
/usr/bin/head: cannot open
`usr/lib/debug/usr/lib/elmersolver-6.1/FluxSolver.readelf: Error: the
dynamic segment offset + size exceeds the size of the file' for reading:
No such file or directory
/usr/bin/head: cannot open `usr/lib/dreadelf: Error: the dynamic segment
offset + size exceeds the size of the file' for reading: No such file or
directory
/usr/bin/head: cannot open `usr/lib/debug/usr/lreadelf: Error: the
dynamic segment offset + size exceeds the size of the file' for reading:
No such file or directory
"""

Which seems to suggest that helpers/coll/objdump-info-helper believes
that the package contains 3 files *literally* ending with:

"""<part-of-name>.readelf: Error: the dynamic segment offset + size
exceeds the size of the file"""

Note that <part-of-name> is truncated, so we cannot "just strip off the
error message".  The code triggering the above is:

"""
while (my $line = <$readelf>) {

    chomp $line;

    if ($line =~ m/^File: (.+)$/) {
        my $file = $1;
        finish_file();

        $bin = $file;
        print "Filename: $bin\n";

        if (
            spawn(
                undef, ['head', $bin],
                '|', ['grep', '-q', 'packed.*with.*UPX'])
          ) {
            print "UPX: yes\n";
        }
    [...]
"""

Which is why I suspect readelf for truncating its own output.

Thanks,
~Niels


Reply to: