From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Tremer To: location@lists.ipfire.org Subject: Re: Segfault on d5ff39d "tree: Actually delete any deleted nodes" Date: Mon, 17 Jul 2023 20:09:21 +0100 Message-ID: <35C9DB4A-BAC6-4A2F-BEC5-B41A8ABE7CB3@ipfire.org> In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1842099325158015567==" List-Id: --===============1842099325158015567== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Hello Valters, Thanks for reviewing my changes. This was indeed a thing that I did observe a= s well and fixed it right here: https://git.ipfire.org/?p=3Dlocation/libloc.git;a=3Dcommitdiff;h=3D0e894966= 750e89d1b83c6ad90f37945d4d349118 The root node got deleted and lots of the code just relied on it being there.= Especially when the tree was empty. -Michael > On 17 Jul 2023, at 19:35, Valters Jansons wrot= e: >=20 > Hi, >=20 > I am seeing a segfault during tests (src/test-as, src/test-country and > src/test-signature) for all Ubuntu LTS versions. This only occurs with > the latest commit (d5ff39d) applied. Looking at the change, the node > still seems to be used after dereference, but I am not fully sure of > the way you have planned out the deletion, therefore I am not offering > a patch/resolution. >=20 > From gdb I am seeing: >=20 > Program received signal SIGSEGV, Segmentation fault. > loc_network_tree_delete_nodes (tree=3D0x55555555a370) at src/network.c:1045 > 1045 tree->root->deleted =3D 0; >=20 > Best regards, > Valters Jansons --===============1842099325158015567==--