Skip to content

Instantly share code, notes, and snippets.

@ccxcz
Created June 5, 2019 12:22
Show Gist options
  • Save ccxcz/a18585f87508d8d0b92ab08edcb85a10 to your computer and use it in GitHub Desktop.
Save ccxcz/a18585f87508d8d0b92ab08edcb85a10 to your computer and use it in GitHub Desktop.
Profanity assertion failure 2019-06-04
profanity ▷ git rev-parse HEAD
bfa4a2ef1fdee2ae6ae017e8a97ac968509c3ca5
libmesode ▷ git rev-parse HEAD
4eb3642ae6576ea87dc16d3b92852019c0101369
Breakpoint 1, __GI_abort () at abort.c:49
49 abort.c: No such file or directory.
(gdb) bt
#0 __GI_abort () at abort.c:49
#1 0x00007fd2305b64ea in __assert_fail_base (fmt=0x7fd23071bf18 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x55ab783e9af4 "roster != NULL",
file=file@entry=0x55ab783e9add "src/xmpp/roster_list.c", line=line@entry=158, function=function@entry=0x55ab783e9d80 <__PRETTY_FUNCTION__.12922> "roster_get_contact")
at assert.c:92
#2 0x00007fd2305b656a in __GI___assert_fail (assertion=assertion@entry=0x55ab783e9af4 "roster != NULL", file=file@entry=0x55ab783e9add "src/xmpp/roster_list.c",
line=line@entry=158, function=function@entry=0x55ab783e9d80 <__PRETTY_FUNCTION__.12922> "roster_get_contact") at assert.c:101
#3 0x000055ab7834698d in roster_get_contact (barejid=<optimized out>) at src/xmpp/roster_list.c:158
#4 0x000055ab78361f2a in _display_name (tab=0x55ab7d91d8a0) at src/ui/statusbar.c:523
#5 0x000055ab7836224d in _tabs_width () at src/ui/statusbar.c:481
#6 0x000055ab7836256e in status_bar_draw () at src/ui/statusbar.c:265
#7 0x000055ab7835e754 in ui_update () at src/ui/core.c:140
#8 0x000055ab7834438f in prof_run (log_level=<optimized out>, account_name=<optimized out>) at src/profanity.c:129
#9 0x000055ab783a9ccb in main (argc=<optimized out>, argv=<optimized out>) at src/main.c:170
(gdb) i
44 in abort.c
#0 __GI_abort () at abort.c:49
49 in abort.c
No arguments.
act = {__sigaction_handler = {sa_handler = 0x55ab79debeb0, sa_sigaction = 0x55ab79debeb0}, sa_mask = {__val = {0, 140540734934112, 0, 0, 140734060947624, 0, 0,
140734060947456, 5, 140540732635856, 3254074056659234048, 0, 3254074056659234048, 140540734919328, 0, 140540732620568}}, sa_flags = 2017368797,
sa_restorer = 0x55ab783e9af4}
sigs = {__val = {94194945138048, 140540732616498, 94194945137373, 3254074056659234048, 140540734936736, 94194945137373, 94194945137396, 158, 140540732620568,
140540731423359, 206158430232, 140734060947696, 140734060947504, 3254074056659234048, 94194945137373, 158}}
(gdb) up
#1 0x00007fd2305b64ea in __assert_fail_base (fmt=0x7fd23071bf18 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x55ab783e9af4 "roster != NULL",
file=file@entry=0x55ab783e9add "src/xmpp/roster_list.c", line=line@entry=158, function=function@entry=0x55ab783e9d80 <__PRETTY_FUNCTION__.12922> "roster_get_contact")
at assert.c:92
92 assert.c: No such file or directory.
(gdb) i
87 in assert.c
#1 0x00007fd2305b64ea in __assert_fail_base (fmt=0x7fd23071bf18 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x55ab783e9af4 "roster != NULL",
file=file@entry=0x55ab783e9add "src/xmpp/roster_list.c", line=line@entry=158, function=function@entry=0x55ab783e9d80 <__PRETTY_FUNCTION__.12922> "roster_get_contact")
at assert.c:92
92 in assert.c
fmt = 0x7fd23071bf18 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n"
assertion = 0x55ab783e9af4 "roster != NULL"
file = 0x55ab783e9add "src/xmpp/roster_list.c"
line = 158
function = 0x55ab783e9d80 <__PRETTY_FUNCTION__.12922> "roster_get_contact"
str = 0x55ab79debeb0 "\200\310\336y\253U"
total = 4096
(gdb) up
#2 0x00007fd2305b656a in __GI___assert_fail (assertion=assertion@entry=0x55ab783e9af4 "roster != NULL", file=file@entry=0x55ab783e9add "src/xmpp/roster_list.c",
line=line@entry=158, function=function@entry=0x55ab783e9d80 <__PRETTY_FUNCTION__.12922> "roster_get_contact") at assert.c:101
101 in assert.c
(gdb) i
96 in assert.c
#2 0x00007fd2305b656a in __GI___assert_fail (assertion=assertion@entry=0x55ab783e9af4 "roster != NULL", file=file@entry=0x55ab783e9add "src/xmpp/roster_list.c",
line=line@entry=158, function=function@entry=0x55ab783e9d80 <__PRETTY_FUNCTION__.12922> "roster_get_contact") at assert.c:101
101 in assert.c
assertion = 0x55ab783e9af4 "roster != NULL"
file = 0x55ab783e9add "src/xmpp/roster_list.c"
line = 158
function = 0x55ab783e9d80 <__PRETTY_FUNCTION__.12922> "roster_get_contact"
No locals.
(gdb) up
#3 0x000055ab7834698d in roster_get_contact (barejid=<optimized out>) at src/xmpp/roster_list.c:158
158 assert(roster != NULL);
(gdb) i
153 }
154
155 PContact
156 roster_get_contact(const char *const barejid)
157 {
158 assert(roster != NULL);
159
160 gchar *barejidlower = g_utf8_strdown(barejid, -1);
161 PContact contact = g_hash_table_lookup(roster->contacts, barejidlower);
162 g_free(barejidlower);
#3 0x000055ab7834698d in roster_get_contact (barejid=<optimized out>) at src/xmpp/roster_list.c:158
158 assert(roster != NULL);
barejid = <optimized out>
__PRETTY_FUNCTION__ = "roster_get_contact"
barejidlower = <optimized out>
contact = <optimized out>
(gdb) up
#4 0x000055ab78361f2a in _display_name (tab=0x55ab7d91d8a0) at src/ui/statusbar.c:523
523 PContact contact = roster_get_contact(tab->identifier);
(gdb) i
518 } else if (tab->window_type == WIN_XML) {
519 fullname = strdup("xmlconsole");
520 } else if (tab->window_type == WIN_PLUGIN) {
521 fullname = strdup(tab->identifier);
522 } else if (tab->window_type == WIN_CHAT) {
523 PContact contact = roster_get_contact(tab->identifier);
524 if (contact && p_contact_name(contact)) {
525 fullname = strdup(p_contact_name(contact));
526 } else {
527 char *pref = prefs_get_string(PREF_STATUSBAR_CHAT);
#4 0x000055ab78361f2a in _display_name (tab=0x55ab7d91d8a0) at src/ui/statusbar.c:523
523 PContact contact = roster_get_contact(tab->identifier);
tab = 0x55ab7d91d8a0
contact = <optimized out>
fullname = 0x0
tablen = <optimized out>
namelen = <optimized out>
trimmed = <optimized out>
trimmedname = <optimized out>
(gdb) up
#5 0x000055ab7836224d in _tabs_width () at src/ui/statusbar.c:481
481 char *display_name = _display_name(tab);
(gdb) i
476 int width = g_hash_table_size(statusbar->tabs) > max_tabs ? 4 : 1;
477 int i = 0;
478 for (i = 1; i <= max_tabs; i++) {
479 StatusBarTab *tab = g_hash_table_lookup(statusbar->tabs, GINT_TO_POINTER(i));
480 if (tab) {
481 char *display_name = _display_name(tab);
482 width += utf8_display_len(display_name);
483 width += 4;
484 free(display_name);
485 }
#5 0x000055ab7836224d in _tabs_width () at src/ui/statusbar.c:481
481 char *display_name = _display_name(tab);
No arguments.
display_name = <optimized out>
tab = <optimized out>
width = 74
i = 8
show_number = <optimized out>
show_name = <optimized out>
max_tabs = 15
(gdb) up
#6 0x000055ab7836256e in status_bar_draw () at src/ui/statusbar.c:265
265 pos = getmaxx(stdscr) - _tabs_width();
(gdb) i
260
261 pos = _status_bar_draw_time(pos);
262
263 _status_bar_draw_maintext(pos);
264
265 pos = getmaxx(stdscr) - _tabs_width();
266 if (pos < 0) {
267 pos = 0;
268 }
269 gint max_tabs = prefs_get_statusbartabs();
#6 0x000055ab7836256e in status_bar_draw () at src/ui/statusbar.c:265
265 pos = getmaxx(stdscr) - _tabs_width();
No arguments.
pos = <optimized out>
max_tabs = <optimized out>
i = <optimized out>
(gdb) up
#7 0x000055ab7835e754 in ui_update () at src/ui/core.c:140
140 status_bar_draw();
(gdb) i
135
136 if (prefs_get_boolean(PREF_WINTITLE_SHOW)) {
137 _ui_draw_term_title();
138 }
139 title_bar_update_virtual();
140 status_bar_draw();
141 inp_put_back();
142 doupdate();
143
144 if (perform_resize) {
#7 0x000055ab7835e754 in ui_update () at src/ui/core.c:140
140 status_bar_draw();
No arguments.
current = 0x55ab79dc3220
(gdb) up
#8 0x000055ab7834438f in prof_run (log_level=<optimized out>, account_name=<optimized out>) at src/profanity.c:129
129 ui_update();
(gdb) i
124 #endif
125 plugins_run_timed();
126 notify_remind();
127 session_process_events();
128 iq_autoping_check();
129 ui_update();
130 #ifdef HAVE_GTK
131 tray_update();
132 #endif
133 }
#8 0x000055ab7834438f in prof_run (log_level=<optimized out>, account_name=<optimized out>) at src/profanity.c:129
129 ui_update();
log_level = <optimized out>
account_name = <optimized out>
line = <optimized out>
(gdb) up
#9 0x000055ab783a9ccb in main (argc=<optimized out>, argv=<optimized out>) at src/main.c:170
170 prof_run(log, account_name);
(gdb) i
165 #endif
166
167 return 0;
168 }
169
170 prof_run(log, account_name);
171
172 return 0;
173 }
#9 0x000055ab783a9ccb in main (argc=<optimized out>, argv=<optimized out>) at src/main.c:170
170 prof_run(log, account_name);
argc = <optimized out>
argv = <optimized out>
entries = {{long_name = 0x55ab783e9e19 "version", short_name = 118 'v', flags = 0, arg = G_OPTION_ARG_NONE, arg_data = 0x55ab78694978 <version>,
description = 0x55ab7840b294 "Show version information", arg_description = 0x0}, {long_name = 0x55ab783f647f "account", short_name = 97 'a', flags = 0,
arg = G_OPTION_ARG_STRING, arg_data = 0x55ab78694970 <account_name>, description = 0x55ab7840b480 "Auto connect to an account on startup", arg_description = 0x0}, {
long_name = 0x55ab7840a90c "log", short_name = 108 'l', flags = 0, arg = G_OPTION_ARG_STRING, arg_data = 0x55ab7868b8c0 <log>,
description = 0x55ab7840b4a8 "Set logging levels, DEBUG, INFO (default), WARN, ERROR", arg_description = 0x55ab7840b2ad "LEVEL"}, {long_name = 0x0,
short_name = 0 '\000', flags = 0, arg = G_OPTION_ARG_NONE, arg_data = 0x0, description = 0x0, arg_description = 0x0}}
error = 0x0
context = 0x55ab79d51710
(gdb) bt
#0 __GI_abort () at abort.c:49
#1 0x00007fd2305b64ea in __assert_fail_base (fmt=0x7fd23071bf18 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x55ab783e9af4 "roster != NULL",
file=file@entry=0x55ab783e9add "src/xmpp/roster_list.c", line=line@entry=158, function=function@entry=0x55ab783e9d80 <__PRETTY_FUNCTION__.12922> "roster_get_contact")
at assert.c:92
#2 0x00007fd2305b656a in __GI___assert_fail (assertion=assertion@entry=0x55ab783e9af4 "roster != NULL", file=file@entry=0x55ab783e9add "src/xmpp/roster_list.c",
line=line@entry=158, function=function@entry=0x55ab783e9d80 <__PRETTY_FUNCTION__.12922> "roster_get_contact") at assert.c:101
#3 0x000055ab7834698d in roster_get_contact (barejid=<optimized out>) at src/xmpp/roster_list.c:158
#4 0x000055ab78361f2a in _display_name (tab=0x55ab7d91d8a0) at src/ui/statusbar.c:523
#5 0x000055ab7836224d in _tabs_width () at src/ui/statusbar.c:481
#6 0x000055ab7836256e in status_bar_draw () at src/ui/statusbar.c:265
#7 0x000055ab7835e754 in ui_update () at src/ui/core.c:140
#8 0x000055ab7834438f in prof_run (log_level=<optimized out>, account_name=<optimized out>) at src/profanity.c:129
#9 0x000055ab783a9ccb in main (argc=<optimized out>, argv=<optimized out>) at src/main.c:170
(gdb)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment