apt-extracttemplates crashed with SIGABRT in __gnu_cxx::__verbose_terminate_handler()

Bug #1288718 reported by Patrick Kennedy on 2014-03-06
This bug affects 7 people
Affects Status Importance Assigned to Milestone
apt (Debian)
Fix Committed
apt (Ubuntu)
Michael Vogt

Bug Description

The installation was just about to begin through aptitude when the crash occured whilst apt-extracttemplate was running

ProblemType: Crash
DistroRelease: Ubuntu 14.04
Package: apt-utils
ProcVersionSignature: Ubuntu 3.13.0-15.35-generic 3.13.5
Uname: Linux 3.13.0-15-generic x86_64
ApportVersion: 2.13.2-0ubuntu5
Architecture: amd64
Date: Thu Mar 6 23:41:52 2014
ExecutablePath: /usr/bin/apt-extracttemplates
InstallationDate: Installed on 2014-03-05 (1 days ago)
InstallationMedia: Ubuntu 14.04 LTS "Trusty Tahr" - Alpha amd64 (20131227)
 PATH=(custom, no user)
Signal: 6
SourcePackage: apt
 __gnu_cxx::__verbose_terminate_handler() () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
 ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
 std::terminate() () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
 __cxa_throw () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
 std::__throw_out_of_range(char const*) () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
Title: apt-extracttemplates crashed with SIGABRT in __gnu_cxx::__verbose_terminate_handler()
UpgradeStatus: No upgrade log present (probably fresh install)

 __gnu_cxx::__verbose_terminate_handler () at ../../../../src/libstdc++-v3/libsupc++/vterminate.cc:95
 __cxxabiv1::__terminate (handler=<optimized out>) at ../../../../src/libstdc++-v3/libsupc++/eh_terminate.cc:38
 std::terminate () at ../../../../src/libstdc++-v3/libsupc++/eh_terminate.cc:48
 __cxxabiv1::__cxa_throw (obj=0x1b37730, tinfo=0x7f49d9d8a1d0 <typeinfo for std::out_of_range>, dest=0x7f49d9b14a50 <std::out_of_range::~out_of_range()>) at ../../../../src/libstdc++-v3/libsupc++/eh_throw.cc:87
 std::__throw_out_of_range (__s=<optimized out>) at ../../../../../src/libstdc++-v3/src/c++11/functexcept.cc:80

Changed in apt (Ubuntu):
importance: Undecided → Medium
tags: removed: need-amd64-retrace
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in apt (Ubuntu):
status: New → Confirmed
information type: Private → Public
Changed in apt (Ubuntu):
importance: Medium → High
Julian Andres Klode (juliank) wrote :

This bug has been fixed upstream in commit b68ce88357daf362e60d7f8f131041289c8db690


commit b68ce88357daf362e60d7f8f131041289c8db690
Author: Julian Andres Klode <email address hidden>
Date: Mon Mar 17 13:43:12 2014 +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.

diff --git a/apt-inst/deb/debfile.cc b/apt-inst/deb/debfile.cc
index 3803329..a63cb67 100644
--- a/apt-inst/deb/debfile.cc
+++ b/apt-inst/deb/debfile.cc
@@ -124,8 +124,10 @@ bool debDebFile::ExtractTarMember(pkgDirStream &Stream,const char *Name)
       std::string ext = std::string(Name) + ".{";
       for (std::vector<APT::Configuration::Compressor>::const_iterator c = compressor.begin();
- c != compressor.end(); ++c)
- ext.append(c->Extension.substr(1));
+ c != compressor.end(); ++c) {
+ if (!c->Extension.empty())
+ ext.append(c->Extension.substr(1));
+ }
       return _error->Error(_("Internal error, could not locate member %s"), ext.c_str());

Julian Andres Klode (juliank) wrote :

I think you want to backport this to the APT version in trusty.

Changed in apt (Debian):
status: New → Fix Committed
Changed in apt (Ubuntu):
status: Confirmed → Triaged
Michael Vogt (mvo) on 2014-04-01
Changed in apt (Ubuntu):
assignee: nobody → Michael Vogt (mvo)
status: Triaged → In Progress
Michael Vogt (mvo) on 2014-04-02
Changed in apt (Ubuntu):
status: In Progress → Fix Committed
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package apt -

apt ( trusty; urgency=low

  * cherry pick git commit b68ce88357daf36 to fix crash in
    apt-extracttemplates (LP: #1288718)
 -- Michael Vogt <email address hidden> Wed, 02 Apr 2014 15:00:11 +0200

Changed in apt (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers