Skip to content

Instantly share code, notes, and snippets.

@M4GNV5
Created July 1, 2018 21:33
Show Gist options
  • Save M4GNV5/6e5bdf64f2a9d55c02bba09d05d77672 to your computer and use it in GitHub Desktop.
Save M4GNV5/6e5bdf64f2a9d55c02bba09d05d77672 to your computer and use it in GitHub Desktop.
Mongoose MQTT Crash
Remote debugging using /dev/ttyUSB0
0x40094624 in invoke_abort () at /home/jakob/git/Open-Vehicle-Monitoring-System-3/env/esp-idf/components/esp32/panic.c:139
139 *((int *) 0) = 0;
(gdb) back
#0 0x40094624 in invoke_abort () at /home/jakob/git/Open-Vehicle-Monitoring-System-3/env/esp-idf/components/esp32/panic.c:139
#1 0x400947ee in abort () at /home/jakob/git/Open-Vehicle-Monitoring-System-3/env/esp-idf/components/esp32/panic.c:148
#2 0x4010504e in __assert_func (
file=0x3f412e80 "/home/jakob/git/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/mongoose/mongoose/mongoose.c",
line=10700, func=<optimized out>, failedexpr=0x3f41308c "nc->send_mbuf.len >= len")
at ../../../.././newlib/libc/stdlib/assert.c:63
#3 0x401001ab in mg_mqtt_prepend_header (nc=0x3f81dd04, cmd=<optimized out>, flags=<optimized out>, len=4294965548)
at /home/jakob/git/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/mongoose/mongoose/mongoose.c:10700
#4 0x4010420d in mg_mqtt_publish (nc=0x3f81dd04, topic=<optimized out>, message_id=72, flags=0, data=0x3ffc0880, len=2)
at /home/jakob/git/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/mongoose/mongoose/mongoose.c:10806
#5 0x4012cfcb in OvmsServerV3::TransmitMetric (this=0x3f81be70, metric=<optimized out>)
at /home/jakob/git/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/ovms_server_v3/src/ovms_server_v3.cpp:240
#6 0x4012d03e in OvmsServerV3::TransmitAllMetrics (this=0x3f81be70)
at /home/jakob/git/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/ovms_server_v3/src/ovms_server_v3.cpp:204
#7 0x4012e09e in OvmsServerV3::Ticker1 (this=0x3f81be70, event=..., data=0x0)
at /home/jakob/git/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/ovms_server_v3/src/ovms_server_v3.cpp:447
#8 0x4012e95f in std::_Mem_fn_base<void (OvmsServerV3::*)(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*), true>::operator()<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*, void>(OvmsServerV3*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&&, void*&&) const (
__object=<optimized out>, this=<optimized out>)
at /home/jakob/git/Open-Vehicle-Monitoring-System-3/env/xtensa-esp32-elf/xtensa-esp32-elf/include/c++/5.2.0/functional:600
#9 std::_Bind<std::_Mem_fn<void (OvmsServerV3::*)(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*)> (OvmsServerV3*, std::_Placeholder<1>, std::_Placeholder<2>)>::__call<void, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&&, void*&&, 0u, 1u, 2u>(std::tuple<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&&, void*&&>&&, std::_Index_tuple<0u, 1u, 2u>) (
__args=<unknown type in /home/jakob/git/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/build/ovms3.elf, CU 0x41d273, DIE 0x434136>, this=<optimized out>)
at /home/jakob/git/Open-Vehicle-Monitoring-System-3/env/xtensa-esp32-elf/xtensa-esp32-elf/include/c++/5.2.0/functional:1074
#10 std::_Bind<std::_Mem_fn<void (OvmsServerV3::*)(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*)> (OvmsServerV3*, std::_Placeholder<1>, std::_Placeholder<2>)>::operator()<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*, void>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&&, void*&&) (this=<optimized out>)
at /home/jakob/git/Open-Vehicle-Monitoring-System-3/env/xtensa-esp32-elf/xtensa-esp32-elf/include/c++/5.2.0/functional:1133
#11 std::_Function_handler<void (std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*), std::_Bind<std::_Mem_fn<void (OvmsServerV3::*)(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*)> (OvmsServerV3*, std::_Placeholder<1>, std::_Placeholder<2>)> >::_M_invoke(std::_Any_data const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&&, void*&&) (__functor=..., __args#0=<optimized out>, __args#1=<optimized out>)
at /home/jakob/git/Open-Vehicle-Monitoring-System-3/env/xtensa-esp32-elf/xtensa-esp32-elf/include/c++/5.2.0/functional:1871
#12 0x400efef0 in std::function<void (std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, void*)>::op---Type <return> to continue, or q <return> to quit---q
Quit
(gdb) f 4
#4 0x4010420d in mg_mqtt_publish (nc=0x3f81dd04, topic=<optimized out>, message_id=72, flags=0, data=0x3ffc0880, len=2)
at /home/jakob/git/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/mongoose/mongoose/mongoose.c:10806
warning: Source file is more recent than executable.
10806
(gdb) p old_len
$1 = 2304
(gdb) p nc->send_mbuf.len
$2 = 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment