From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gisle Vanem To: location@lists.ipfire.org Subject: Re: Warning in '__loc_network_tree_count()' Date: Sat, 04 Mar 2023 12:00:57 +0100 Message-ID: <7845ed2c-76c8-df33-7f8a-2bccd8d10c6e@online.no> In-Reply-To: <34085602-5207-4A22-9C9D-34292A3A3344@ipfire.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2660124168574856476==" List-Id: --===============2660124168574856476== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Michael Tremer wrote: >> So shouldn't the function be: >> >> static int __loc_network_tree_count(struct loc_network* network, void* dat= a) { >> size_t* counter =3D (size_t*)data; >> >> // Increase the counter for each network >> (*counter)++; >> return 0; >=20 > Yes, you are incorrect. I am incrementing the pointer when I wanted to incr= ement the value.=20 You mean "you are correct"? > Thank you for helping to improve libloc. How does it run on Windows? I doesn't run at all w/o much patching by myself. I've added support for it and 'location.db' files in my project Wsock-trace: https://github.com/gvanem/wsock-trace The patched up 'libloc' version: https://github.com/gvanem/wsock-trace/tree/master/src/Geo-IP/IPFire/src --=20 --gv --===============2660124168574856476==--