[Aptitude-devel] Bug#1028046: aptitude: Segfault when updating package list while mirror update was running

Axel Beckert abe at debian.org
Fri Jan 6 09:19:10 GMT 2023


Package: aptitude
Version: 0.8.13-5
Severity: normal

aptitude just crashed with a segfault for me when updating the package
list while a mirror update was close to be finished on the used Debian
mirror. (Haven't seen a segfault in aptitude for quite a while, so I
assume this is either a rather seldom race condition or — probably less
likely — triggered by a recent update of apt.)

[2(1)/...] Resolving dependencies.
e: Examine  !: Apply  .: Next  ,: Previous
Ouch!  Got SIGSEGV, dying..                                          100%
[1]    20272 segmentation fault (core dumped)  aptitude -u
aptitude -u  554.84s user 35.81s system 144% cpu 6:49.49 total

Backtrace:

Reading symbols from /usr/bin/aptitude-curses...
Reading symbols from /usr/lib/debug/.build-id/7b/241a91e617342e555693ae8e22daf38a7276f9.debug...
Illegal process-id: 20272-0-0-11-1672996274-c6--usr-bin-aptitude-curses.core.
[New LWP 20272]
[New LWP 20273]
[New LWP 20274]
[New LWP 20275]
[New LWP 24174]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Core was generated by `aptitude -u'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  operator+<pkgCache::DependencyData> (m=..., p=<optimized out>) at ./obj-x86_64-linux-gnu/include/apt-pkg/pkgcache.h:104
104     ./obj-x86_64-linux-gnu/include/apt-pkg/pkgcache.h: No such file or directory.
[Current thread is 1 (Thread 0x7f9b1d2228c0 (LWP 20272))]
(gdb) bt
#0  operator+<pkgCache::DependencyData> (m=..., p=<optimized out>) at ./obj-x86_64-linux-gnu/include/apt-pkg/pkgcache.h:104
#1  pkgCache::DepIterator::operator++ (this=this at entry=0x7ffd004162b0) at ./apt-pkg/pkgcache.cc:474
#2  0x000055598034ea72 in surrounding_or (dep=..., start=..., end=..., cache=<optimized out>) at ../../../../src/generic/apt/apt.cc:813
#3  0x00005559802cd6c4 in aptitude_resolver_dep::aptitude_resolver_dep (this=0x7ffd00416470, dep=<optimized out>, _prv=<optimized out>, 
    _cache=<optimized out>) at ../../../src/generic/apt/aptitude_resolver_universe.h:422
#4  0x00005559804436a1 in aptitude_resolver_version::dep_iterator::operator* (this=0x7ffd004164f0)
    at ../../../../src/generic/apt/aptitude_resolver_universe.h:813
#5  aptitude_universe::dep_iterator::operator* (this=0x7ffd004164c0) at ../../../../src/generic/apt/aptitude_resolver_universe.h:1235
#6  generic_problem_resolver<aptitude_universe>::generic_problem_resolver (this=this at entry=0x555983f4f990, _step_score=_step_score at entry=-10, 
    _broken_score=_broken_score at entry=-100, _unfixed_soft_score=_unfixed_soft_score at entry=-200, infinity=infinity at entry=1000000, 
    _full_solution_score=_full_solution_score at entry=50, _unfixed_soft_cost=..., _future_horizon=50, _initial_state=..., _universe=...)
    at ../../../../src/generic/problemresolver/problemresolver.h:3786
#7  0x0000555980434926 in aptitude_resolver::aptitude_resolver (this=this at entry=0x555983f4f990, step_score=-10, broken_score=broken_score at entry=-100, 
    unfixed_soft_score=unfixed_soft_score at entry=-200, infinity=infinity at entry=1000000, resolution_score=resolution_score at entry=50, unfixed_soft_cost=..., 
    future_horizon=50, _cost_settings=..., initial_installations=..., cache=0x555981a4c0d0, _policy=0x5559896c0450)
    at ../../../../src/generic/apt/aptitude_resolver.cc:734
#8  0x00005559803b3b16 in resolver_manager::create_resolver (this=0x5559818227c0) at ../../../../src/generic/apt/resolver_manager.cc:968
#9  0x00005559803b4dcb in resolver_manager::maybe_create_resolver (this=0x5559818227c0, consider_policybroken=<optimized out>)
    at ../../../../src/generic/apt/resolver_manager.cc:805
#10 0x00005559803b556f in resolver_manager::maybe_create_resolver (this=0x5559818227c0) at ../../../../src/generic/apt/resolver_manager.h:474
#11 resolver_manager::resolver_manager (this=this at entry=0x5559818227c0, _cache_file=_cache_file at entry=0x555985809060, _initial_installations=...)
    at ../../../../src/generic/apt/resolver_manager.cc:195
#12 0x00005559803564eb in apt_load_cache (progress_bar=progress_bar at entry=0x555981a39d60, do_initselections=do_initselections at entry=true, 
    operation_needs_lock=operation_needs_lock at entry=true, status_fname=status_fname at entry=0x0, reset_reinstall=reset_reinstall at entry=false)
    at ../../../../src/generic/util/immset.h:258
#13 0x000055598038e098 in download_update_manager::finish (this=this at entry=0x55598d035a80, res=res at entry=pkgAcquire::Continue, progress=0x555981a39d60, 
    k=...) at ../../../../src/generic/apt/download_update_manager.cc:209
#14 0x00005559802c0c90 in ui_download_manager::done (this=0x55598d136d40, t=<optimized out>, res=pkgAcquire::Continue)
    at /usr/include/cwidget/generic/util/ref_ptr.h:159
#15 0x000055598023734c in sigc::slot2<void, download_thread*, pkgAcquire::RunResult>::operator() (_A_a2=@0x7ffd00417464: pkgAcquire::Continue, 
    _A_a1=@0x7ffd00417468: 0x55598450dca0, this=0x7ffd00417470) at /usr/include/sigc++-2.0/sigc++/functors/slot.h:798
#16 (anonymous namespace)::do_download_complete (t=<optimized out>, res=<optimized out>, continuation=...) at ../../src/download_thread.cc:220
#17 0x000055598023bcd3 in sigc::pointer_functor3<download_thread*, pkgAcquire::RunResult, safe_slot2<void, download_thread*, pkgAcquire::RunResult>, void>::operator() (this=0x555981a12b60, _A_a3=..., _A_a2=@0x555981a12b70: pkgAcquire::Continue, _A_a1=@0x555981a12b68: 0x55598450dca0)
    at /usr/include/sigc++-2.0/sigc++/functors/ptr_fun.h:185
#18 sigc::adaptor_functor<sigc::pointer_functor3<download_thread*, pkgAcquire::RunResult, safe_slot2<void, download_thread*, pkgAcquire::RunResult>, void> >::operator()<download_thread*&, pkgAcquire::RunResult&, safe_slot2<void, download_thread*, pkgAcquire::RunResult>&> (_A_arg3=..., 
    _A_arg2=@0x555981a12b70: pkgAcquire::Continue, _A_arg1=@0x555981a12b68: 0x55598450dca0, this=0x555981a12b58)
    at /usr/include/sigc++-2.0/sigc++/adaptors/adaptor_trait.h:128
#19 sigc::bind_functor<-1, sigc::pointer_functor3<download_thread*, pkgAcquire::RunResult, safe_slot2<void, download_thread*, pkgAcquire::RunResult>, void>, download_thread*, pkgAcquire::RunResult, safe_slot2<void, download_thread*, pkgAcquire::RunResult>, sigc::nil, sigc::nil, sigc::nil, sigc::nil>::operator() (
    this=0x555981a12b50) at /usr/include/sigc++-2.0/sigc++/adaptors/bind.h:1529
#20 sigc::internal::slot_call0<sigc::bind_functor<-1, sigc::pointer_functor3<download_thread*, pkgAcquire::RunResult, safe_slot2<void, download_thread*, pkgAcquire::RunResult>, void>, download_thread*, pkgAcquire::RunResult, safe_slot2<void, download_thread*, pkgAcquire::RunResult>, sigc::nil, sigc::nil, sigc::nil, sigc::nil>, void>::call_it (rep=0x555981a12b20) at /usr/include/sigc++-2.0/sigc++/functors/slot.h:136
#21 0x00005559802bc302 in sigc::slot0<void>::operator() (this=0x7ffd004174f0) at /usr/include/sigc++-2.0/sigc++/functors/slot.h:535
#22 aptitude::safe_slot_event::dispatch (this=<optimized out>) at ../../src/safe_slot_event.h:40
#23 0x00007f9b1d85e345 in cwidget::toplevel::mainloop () at ./src/cwidget/toplevel.cc:1171
#24 0x00005559802abf91 in ui_main () at ../../src/ui.cc:3147
#25 0x00005559801f3b49 in main (argc=<optimized out>, argv=<optimized out>) at ../../src/main.cc:1427

-- Package-specific info:
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: not available
URL: <http://alioth-lists.debian.net/pipermail/aptitude-devel/attachments/20230106/9ac54efb/attachment.ksh>
-------------- next part --------------

-- System Information:
Debian Release: bookworm/sid
  APT prefers unstable
  APT policy: (990, 'unstable'), (600, 'testing'), (500, 'unstable-debug'), (500, 'buildd-unstable'), (110, 'experimental'), (1, 'experimental-debug'), (1, 'buildd-experimental')
merged-usr: no
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 5.18.0-4-amd64 (SMP w/8 CPU threads; PREEMPT)
Kernel taint flags: TAINT_WARN
Locale: LANG=C.UTF-8, LC_CTYPE=C.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /bin/dash
Init: sysvinit (via /sbin/init)
LSM: AppArmor: enabled

Versions of packages aptitude depends on:
ii  aptitude-common           0.8.13-5
ii  libapt-pkg6.0             2.5.4
ii  libboost-iostreams1.74.0  1.74.0-18.1
ii  libc6                     2.36-7
ii  libcwidget4               0.5.18-6
ii  libgcc-s1                 12.2.0-13
ii  libncursesw6              6.4-1
ii  libsigc++-2.0-0v5         2.10.8-1
ii  libsqlite3-0              3.40.1-1
ii  libstdc++6                12.2.0-13
ii  libtinfo6                 6.4-1
ii  libxapian30               1.4.21-1

Versions of packages aptitude recommends:
ii  libdpkg-perl    1.21.15
ii  sensible-utils  0.0.17

Versions of packages aptitude suggests:
ii  apt-xapian-index                0.53
ii  aptitude-doc-en [aptitude-doc]  0.8.13-5
ii  debtags                         2.1.5
ii  tasksel                         3.71

-- no debconf information


More information about the Aptitude-devel mailing list