Re: Did You Know That FT_Done_Face Can Return An Error?
Behdad Esfahbod <[email protected]> Fri, 11 May 2018 10:59:43 -0700
| Newsgroups | gmane.comp.fonts.fontconfig |
|---|---|
| Message-ID | <CAF63+7XqX-gO548CXXPOWf3vhvbqE0OrYBptyv6PEtpUT4iTvw@mail.gmail.com> |
On Thu, May 10, 2018 at 9:32 PM, Werner LEMBERG <[email protected]> wrote: > > > I fully agree with you. Libraries should not crash **on bad data**. > > On programmer error and invalid memory state, crashing is safest for > > avoiding exploits and discovering and fixing bugs. > > Well, the stdc version of `free' *does* crash if you try to improperly > deallocate memory blocks. So? That's consistent with my statement. Invalid pointers are programmer error, hence crash. > And it returns an error code on programmer > error (i.e., an invalid `FT_Face' handle). > It should assert and crash insteda. > > Werner > -- behdad http://behdad.org/ _______________________________________________ Fontconfig mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/fontconfig