CleverRaven / Cataclysm-DDA

Cataclysm - Dark Days Ahead. A turn-based survival game set in a post-apocalyptic world.
http://cataclysmdda.org
Other
10.27k stars 4.12k forks source link

Crash when trading with Hub01 #33107

Closed pjf closed 4 years ago

pjf commented 5 years ago

Describe the bug

Agreed to a sweet trading deal with Hub01. Hit 'Enter' to confirm, and received a segfault:

VERSION: 0.D-6412-g6c61426288
TYPE: Signal
MESSAGE: SIGSEGV: Segmentation fault
STACK TRACE:

    ./cataclysm-tiles(_Z21debug_write_backtraceRSo+0x23) [0xaca06a]
    ./cataclysm-tiles() [0xab7ae6]
    ./cataclysm-tiles() [0xab7754]
    /lib/x86_64-linux-gnu/libc.so.6(+0x354b0) [0x7f8584a1c4b0]
    ./cataclysm-tiles(_ZN4itemC2ERKS_+0x14) [0x9383b2]
    ./cataclysm-tiles(_ZN11npc_trading14transfer_itemsERSt6vectorI12item_pricingSaIS1_EER6playerS6_P7factionRNSt7__cxx114listIP13item_locationSaISC_EEEb+0x14e) [0xfb225e]
    ./cataclysm-tiles(_ZN11npc_trading5tradeER3npciRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE+0x9a) [0xfb4ce7]
    ./cataclysm-tiles(_ZN13talk_function11start_tradeER3npc+0x33) [0xfac974]
    ./cataclysm-tiles(_ZNK13talk_effect_t5applyER8dialogue+0x46) [0xf9052c]
    ./cataclysm-tiles(_ZN8dialogue3optER15dialogue_windowRK10talk_topic+0x876) [0xf899d2]
    ./cataclysm-tiles(_ZN3npc9talk_to_uEbb+0xa78) [0xf8809e]
    ./cataclysm-tiles(_ZN8iexamine8intercomER6playerRK8tripoint+0x6e) [0xbe8d3e]
    ./cataclysm-tiles(_ZN4game7examineERK8tripoint+0x412) [0xb8084a]
    ./cataclysm-tiles(_ZN4game7examineEv+0xfa) [0xb803b0]
    ./cataclysm-tiles(_ZN4game13handle_actionEv+0x5ea1) [0xbd5f31]
    ./cataclysm-tiles(_ZN4game7do_turnEv+0x578) [0xb69b9a]
    ./cataclysm-tiles(main+0x10b1) [0xd7f269]
    /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf0) [0x7f8584a07830]
    ./cataclysm-tiles(_start+0x29) [0x90e9c9]

    Attempting to repeat stack trace using debug symbols...
    debug_write_backtrace(std::ostream&)
    ??:?
    log_crash(char const*, char const*)
    crash.cpp:?
    signal_handler(int)
    crash.cpp:?
    ??
    ??:0
    item::item(item const&)
    ??:?
    npc_trading::transfer_items(std::vector<item_pricing, std::allocator<item_pricing> >&, player&, player&, faction*, std::__cxx11::list<item_location*, std::allocator<item_location*> >&, bool)
    ??:?
    npc_trading::trade(npc&, int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
    ??:?
    talk_function::start_trade(npc&)
    ??:?
    talk_effect_t::apply(dialogue&) const
    ??:?
    dialogue::opt(dialogue_window&, talk_topic const&)
    ??:?
    npc::talk_to_u(bool, bool)
    ??:?
    iexamine::intercom(player&, tripoint const&)
    ??:?
    game::examine(tripoint const&)
    ??:?
    game::examine()
    ??:?
    game::handle_action()
    ??:?
    game::do_turn()
    ??:?
    main
    ??:?
    __libc_start_main
    /build/glibc-Cl5G7W/glibc-2.23/csu/../csu/libc-start.c:325
    _start
    ??:?
Aborted

Steps To Reproduce

Have not yet tried to reproduce

Expected behavior

I get a new book and Hub01 gets all the junk food I'm allergic to.

Notes

Their trading list seemed to oddly contain "inactive skitterbot 3NE" (or something close to that). I didn't think much of it at the time, and it could be a red herring, but it's weird to see items with directions on them in the trade screen.

Versions and configuration

mlangsdorf commented 4 years ago

I can't reproduce this after #33126. Closing as fixed but we can re-open it if someone finds a reproducer.