test-cmdline-reader segfaults on mips
Version: 1.14.2
Trying to run the test-suite on mips fails with
ERROR: src/initrd/tests/test-cmdline-reader
===========================================
./tools/run-nm-test.sh: line 235: 3643 Segmentation fault "${NMTST_DBUS_RUN_SESSION[@]}" "$TEST" "$@"
# random seed: R02Sa947c19e152ca3707ac9350dccc66ba1
1..16
# Start of initrd tests
# Start of cmdline tests
ok 1 /initrd/cmdline/auto
PASS: src/initrd/tests/test-cmdline-reader 1 /initrd/cmdline/auto
ERROR: src/initrd/tests/test-cmdline-reader - too few tests run (expected 16, got 1)
ERROR: src/initrd/tests/test-cmdline-reader - exited with status 139 (terminated by signal 11?)
Full build log available at https://buildd.debian.org/status/fetch.php?pkg=network-manager&arch=mips&ver=1.14.2-2&stamp=1540141161&raw=0
Here's a gdb backtrace from a porter machine:
Starting program: /home/biebl/nm/network-manager-1.14.2/src/initrd/tests/test-cmdline-reader
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/mips-linux-gnu/libthread_db.so.1".
Program received signal SIGSEGV, Segmentation fault.
__GI_strchr (s=<optimized out>, c_in=58) at strchr.c:48
48 strchr.c: No such file or directory.
#0 0x7778c9e8 in __GI_strchr (s=<optimized out>, c_in=58) at strchr.c:48
char_ptr = 0x682 <error: Cannot access memory at address 0x682>
longword_ptr = <optimized out>
longword = <optimized out>
charmask = <optimized out>
c = 58 ':'
#1 0x77a3d940 in g_param_spec_pool_lookup (pool=0x5565e9f8, param_name=0x682 <error: Cannot access memory at address 0x682>, owner_type=0x55668790 [NMSettingWired/NMSetting], walk_ancestors=1) at ../../../../gobject/gparam.c:1071
pspec = <optimized out>
delim = <optimized out>
__func__ = "g_param_spec_pool_lookup"
#2 0x77a378dc in g_object_set_valist (object=0x5566a8e0 [NMSettingWired], first_property_name=<optimized out>, var_args=0x7fff60d8) at ../../../../gobject/gobject.c:2289
value =
{g_type = 0x0, data = {{v_int = 0, v_uint = 0, v_long = 0, v_ulong = 0, v_int64 = 0, v_uint64 = 0, v_float = 0, v_double = 0, v_pointer = 0x0}, {v_int = 0, v_uint = 0, v_long = 0, v_ulong = 0, v_int64 = 0, v_uint64 = 0, v_float = 0, v_double = 0, v_pointer = 0x0}}}
pspec = <optimized out>
error = 0x0
nqueue = <optimized out>
__func__ = "g_object_set_valist"
#3 0x77a38658 in g_object_set (_object=0x5566a8e0, first_property_name=0x5561b0a8 "mtu")
at ../../../../gobject/gobject.c:2473
object = 0x5566a8e0 [NMSettingWired]
var_args = 0x7fff60d0
__func__ = "g_object_set"
#4 0x556028fc in _base_setting_set (connection=<optimized out>, property=0x5561b0a8 "mtu", value=0x5567199d "1666") at src/initrd/nmi-cmdline-reader.c:142
setting = 0x5566a8e0 [NMSettingWired]
type_name = 0x55671468 "802-3-ethernet"
object_class = 0x5565c7e0
spec = 0x5566e4e8 [GParamUInt]
#5 0x55603df0 in parse_ip (argument=<optimized out>, sysfs_dir=0x5561802c "/home/biebl/nm/network-manager-1.14.2/src/initrd/tests/sysfs", connections=0x556588b8) at src/initrd/nmi-cmdline-reader.c:432
s_ip6 = 0x5566d968 [NMSettingIP6Config]
client_ip = <optimized out>
client_hostname = <optimized out>
mtu = 0x5567199d "1666"
client_ip_prefix = -1
dns = {0x0, 0x0}
connection = 0x556645d0
netmask = <optimized out>
kind = <optimized out>
peer = 0x0
s_ip4 = 0x5566b540 [NMSettingIP4Config]
ibft = 0x0
tmp = <optimized out>
gateway_ip = <optimized out>
ifname = <optimized out>
macaddr = 0x556719a1 ""
error = 0x0
client_ip_family = <optimized out>
dns_addr_family = {0, 0}
connections = 0x556588b8
tag = <optimized out>
argument = 0x55671993 "eth0"
ignore_bootif = 0
bootif = 0x0
i = <optimized out>
#6 0x55603df0 in nmi_cmdline_reader_parse (sysfs_dir=0x5561802c "/home/biebl/nm/network-manager-1.14.2/src/initrd/tests/sysfs", argv=<optimized out>) at src/initrd/nmi-cmdline-reader.c:674
connections = 0x556588b8
tag = <optimized out>
argument = 0x55671993 "eth0"
ignore_bootif = 0
bootif = 0x0
i = <optimized out>
#7 0x5557538c in test_if_auto_with_mtu () at src/initrd/tests/test-cmdline-reader.c:99
connections = 0x0
argv = 0x55669d70
connection = <optimized out>
s_wired = <optimized out>
s_ip4 = <optimized out>
s_ip6 = <optimized out>
__func__ = "test_if_auto_with_mtu"
#8 0x77964240 in test_case_run (tc=0x55662130) at ../../../../glib/gtestutils.c:2318
test_run_timer = 0x5566ce00
largs = {0, 0, 0.0091380000000000003}
fixture = 0x0
old_base = 0x0
old_free_list = <optimized out>
filename_free_list = 0x0
success = 0
tc = 0x55662130
n_bad = 0
old_name = 0x5565f4c0 "/initrd/cmdline"
iter =
0x5565d0d0 = {0x55662130, 0x55662148, 0x55662160, 0x55662178, 0x55662190, 0x556621a8, 0x556621c0, 0x55662308, 0x55662320, 0x55662350, 0x55662368, 0x55662398, 0x556623b0}
__func__ = "g_test_run_suite_internal"
#9 0x77964240 in g_test_run_suite_internal (suite=0x55664130, path=0x0) at ../../../../glib/gtestutils.c:2403
tc = 0x55662130
n_bad = 0
old_name = 0x5565f4c0 "/initrd/cmdline"
iter =
0x5565d0d0 = {0x55662130, 0x55662148, 0x55662160, 0x55662178, 0x55662190, 0x556621a8, 0x556621c0, 0x55662308, 0x55662320, 0x55662350, 0x55662368, 0x55662398, 0x556623b0}
__func__ = "g_test_run_suite_internal"
#10 0x77964084 in g_test_run_suite_internal (suite=0x55664120, path=0x0) at ../../../../glib/gtestutils.c:2415
ts = 0x55664130
n_bad = 0
old_name = 0x55647ee0 "/initrd"
iter = 0x5565d0a0 = {0x55664130}
__func__ = "g_test_run_suite_internal"
#11 0x77964084 in g_test_run_suite_internal (suite=0x55664110, path=0x0) at ../../../../glib/gtestutils.c:2415
ts = 0x55664120
n_bad = 0
old_name = 0x55647e50 "/"
iter = 0x5565d098 = {0x55664120}
__func__ = "g_test_run_suite_internal"
#12 0x779645b0 in g_test_run_suite (suite=0x55664110) at ../../../../glib/gtestutils.c:2490
n_bad = 0
__func__ = "g_test_run_suite"
#13 0x77964600 in g_test_run () at ../../../../glib/gtestutils.c:1755
#14 0x5556c23c in main (argc=1, argv=<optimized out>) at src/initrd/tests/test-cmdline-reader.c:786