Date: Sat, 03 Feb 2024 19:58:32 +0000 From: bugzilla-noreply@freebsd.org To: jail@FreeBSD.org Subject: [Bug 276809] SEGFAULTs using libjail Message-ID: <bug-276809-29815-I9kEXowTF4@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-276809-29815@https.bugs.freebsd.org/bugzilla/> References: <bug-276809-29815@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D276809 --- Comment #2 from Fabiano Sidler <freebsd-bugs@aliases.systohc.net> --- Ah, of course I'm an idiot! How can I expect any param to have a value in s= uch a "list all possible param NAMES" call? The C program works now as expected, but I still get the SEGFAULT in Python after the first parameter (zfs.mount_snapshot). What is there still a probl= em? --- listjailparams.c.old 2024-02-03 20:07:04.525535000 +0100 +++ listjailparams.c 2024-02-03 19:55:56.447438000 +0100 @@ -8,7 +8,7 @@ printf("number of params: %d\n", nparams); for (int i=3D0; i<nparams; i++) { - printf("jailparam: %s\n", jailparam_export(¶ms[i])); + printf("jailparam: %s\n", params[i].jp_name); } jailparam_free(params, nparams); return 0; --- listjailparams.py.old 2024-02-03 20:07:38.644856000 +0100 +++ listjailparams.py 2024-02-03 20:08:03.131423000 +0100 @@ -25,8 +25,7 @@ for i in range(nparams): param =3D params[i] name =3D param.name.decode('utf-8') - value =3D param.value if param.value is None else param.value.decode('utf-8') - print(f'Name: {name}, Value: {value}') + print('jailparam: %s'%name) jailparam_free(params, nparams) # vim:ts=3D2:noet: --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-276809-29815-I9kEXowTF4>