Project

General

Profile

Actions

Bug #1333

open

Crash on invalid argument sequence

Added by Simon Marchi about 3 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
-
Start date:
11/29/2021
Due date:
% Done:

0%

Estimated time:

Description

I tried this (non-sensical) argument sequence, and I get a crash:

$ /tmp/babeltrace/bin/babeltrace2 tourlou --plugin-path=$PWD list-plugins
[1] 561573 abort (core dumped) /tmp/babeltrace/bin/babeltrace2 tourlou --plugin-path=$PWD list-plugins

(gdb) bt
#0  0x00007ffff70f5d22 in raise () from /usr/lib/libc.so.6
#1  0x00007ffff70df862 in abort () from /usr/lib/libc.so.6
#2  0x00005555555b56e4 in bt_common_abort () at /home/simark/src/babeltrace/src/common/common.c:2111
#3  0x0000555555597500 in bt_config_convert_from_args (argc=3, argv=0x7fffffffdec0, cfg_out=0x7fffffffdd60, plugin_paths=0x606000000140, default_log_level=0x7fffffffdc20, interrupter=0x6060000000e0, consumed_args=1) at /home/simark/src/babeltrace/src/cli/babeltrace2-cfg-cli-args.c:3737
#4  0x000055555559d2ba in bt_config_cli_args_create (argc=4, argv=0x7fffffffdeb8, cfg=0x7fffffffdd60, omit_system_plugin_path=false, omit_home_plugin_path=false, initial_plugin_paths=0x0, interrupter=0x6060000000e0) at /home/simark/src/babeltrace/src/cli/babeltrace2-cfg-cli-args.c:4951
#5  0x00005555555a0d61 in bt_config_cli_args_create_with_default (argc=4, argv=0x7fffffffdeb8, cfg=0x7fffffffdd60, interrupter=0x6060000000e0) at /home/simark/src/babeltrace/src/cli/babeltrace2-cfg-cli-args-default.c:70
#6  0x0000555555583dc1 in main (argc=4, argv=0x7fffffffdeb8) at /home/simark/src/babeltrace/src/cli/babeltrace2.c:2642

It's this abort: https://github.com/efficios/babeltrace/blob/7cf80be345190813bcd972b7688bcb928e58224d/src/cli/babeltrace2-cfg-cli-args.c#L3737

No data to display

Actions

Also available in: Atom PDF