Hi,
thanks for the review!
Il 11/03/21 21:55, Nikolay Sivov ha scritto:
I don't see it crashing now anywhere on test vms. If that becomes an issue later on after implementation changes, this test diff should be included there.
It used to crash on my machine, because of a different set of installed fonts. I don't think the tests should be written just for the test VMs: any machine should reasonably be able to run them correctly and without crashes. The reason for this patch is that in C you should never dereference a NULL pointer, so the moment you get a pointer that might be NULL, you should test it before using it. If you want practical reasons, consider the case of a developer who wants to run the tests and has to waste their time chasing a segmentation fault caused by them having a different (but entirely legitimate) font set installed on their machine.
In other words, this patch makes the program more correct and gives less headaches to anybody using it, so why is it a problem?
Giovanni.