Commit 8ef4257dc8d6b59b55d0169b66c8de135d5f199b

Garret Rieger 2021-03-31T15:00:46

[sanitize] change max ops to track number of bytes processed. Counting bytes as the operations is likely to be a better proxy for how much work processing the table will cost vs. the current approach of counting the number of sub-objects. This should allow checks for max features, max scripts, etc. to be removed. I tested this change against the full collection of fonts at https://github.com/google/fonts and a max ops factor of 3 was sufficient to successfully sanitize all of them.