From 91ef66b5fe0d1c2023f7e43140d8c69260588ac4 Mon Sep 17 00:00:00 2001 From: beware Date: Thu, 18 Sep 2025 23:42:12 +0000 Subject: [PATCH 1/1] getting v4 local IPs was not working on 64 bits unix --- lcorelocalips.pas | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lcorelocalips.pas b/lcorelocalips.pas index 453ce81..07752ca 100644 --- a/lcorelocalips.pas +++ b/lcorelocalips.pas @@ -82,13 +82,18 @@ const {amd64: mac OS X: $C00C6924; freeBSD: $c0106924} type tifconf=packed record - ifc_len:longint; + ifc_len:taddrint; ifcu_rec:pointer; end; tifrec=packed record ifr_ifrn:array [0..IF_NAMESIZE-1] of char; - ifru_addr:TSockAddr; + case integer of + 0: (ifru_addr: Tsockaddr); + {$ifdef cpu64} + //tifrec is 40 bytes on 64 bits due to a union with one of the other data types + 1: (sizefor64: array[0..23] of byte); + {$endif} end; var -- 2.30.2