[doc] fix hb_blob_create call example

otherwise free(0) will be called that silently makes a leak
This commit is contained in:
Ebrahim Byagowi 2019-12-12 15:42:37 +03:30 committed by GitHub
parent 4ef597e170
commit e75d785b51
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -244,7 +244,7 @@
<function>malloc()</function>, you would create the blob using
</para>
<programlisting language="C">
hb_blob_create (data, length, HB_MEMORY_MODE_WRITABLE, NULL, free)
hb_blob_create (data, length, HB_MEMORY_MODE_WRITABLE, data, free)
</programlisting>
<para>
That way, HarfBuzz will call <function>free()</function> on the