[PATCH] ft-hb-ft.c: fix ft_hb_ft_reference_table() to use ft_sfree()

Harry Sintonen <[email protected]> Tue, 13 Jan 2026 14:24:29 +0200 (EET)
Newsgroups gmane.comp.fonts.freetype.devel
Message-ID <[email protected]>
  This message is in MIME format.  The first part should be readable text,
  while the remaining parts are likely unreadable without MIME-aware tools.

---664816595-2008815355-1768307069=:394088
Content-Type: text/plain; format=flowed; charset=US-ASCII

Fixes obvious mistake where free() is used instead of ft_sfree().

--- src-old/autofit/ft-hb-ft.c	2025-09-07 16:54:20.000000000 +0300
+++ src/autofit/ft-hb-ft.c	2026-01-13 14:09:10.435181069 +0200
@@ -60,7 +60,7 @@
    error = FT_Load_Sfnt_Table (ft_face, tag, 0, buffer, &length);
    if (error)
    {
-    free (buffer);
+    ft_sfree (buffer);
      return NULL;
    }

--

   Regards,
-- 
l=2001;main(i){float o,O,_,I,D;for(;O=I=l/571.-1.75,l;)for(putchar(--l%80?
i:10),o=D=l%80*.05-2,i=31;_=O*O,O=2*o*O+I,o=o*o-_+D,o+_+_<4+D&i++<87;);puts
("  Harry 'Piru' Sintonen <[email protected]> https://www.iki.fi/sintonen");}
---664816595-2008815355-1768307069=:394088
Content-Type: text/x-diff; name=fix-ft_hb_ft_reference_table-free.patch
Content-Transfer-Encoding: BASE64
Content-ID: <[email protected]>
Content-Description: 
Content-Disposition: attachment; filename=fix-ft_hb_ft_reference_table-free.patch

LS0tIHNyYy1vbGQvYXV0b2ZpdC9mdC1oYi1mdC5jCTIwMjUtMDktMDcgMTY6
NTQ6MjAuMDAwMDAwMDAwICswMzAwDQorKysgc3JjL2F1dG9maXQvZnQtaGIt
ZnQuYwkyMDI2LTAxLTEzIDE0OjA5OjEwLjQzNTE4MTA2OSArMDIwMA0KQEAg
LTYwLDcgKzYwLDcgQEANCiAgIGVycm9yID0gRlRfTG9hZF9TZm50X1RhYmxl
IChmdF9mYWNlLCB0YWcsIDAsIGJ1ZmZlciwgJmxlbmd0aCk7DQogICBpZiAo
ZXJyb3IpDQogICB7DQotICAgIGZyZWUgKGJ1ZmZlcik7DQorICAgIGZ0X3Nm
cmVlIChidWZmZXIpOw0KICAgICByZXR1cm4gTlVMTDsNCiAgIH0NCiANCg==

---664816595-2008815355-1768307069=:394088--