[Fontconfig] Did You Know That FT_Done_Face Can Return An Error?

Lawrence D'Oliveiro ldo at geek-central.gen.nz
Mon May 7 03:29:35 UTC 2018


On Mon, 7 May 2018 12:09:11 +0900, Akira TAGOH wrote:

> That said this is the case-by-case. it wouldn't be a reason to ignore
> for others.

I think there should never be a reason in general for a dispose call to
return an error code. The example to follow is free(3)
<https://linux.die.net/man/3/free>: if you pass this a valid pointer,
it frees it; pass it NULL, and it returns successfully without doing
anything. Passing an invalid pointer is a program bug, so there is no
point reporting this with a status code; the best thing is to print an
error message and abort.


More information about the Fontconfig mailing list