Stop trusting header totalSfntSize and glyf origLength

This commit is contained in:
Rod Sheeter
2016-03-08 12:30:08 -08:00
parent 643c7b4589
commit b220918cab
12 changed files with 726 additions and 526 deletions
+2 -1
View File
@@ -23,8 +23,8 @@
#include <string>
#include <vector>
#include "./buffer.h"
#include "./encode.h"
#include "./buffer.h"
#include "./font.h"
#include "./normalize.h"
#include "./round.h"
@@ -47,6 +47,7 @@ using std::vector;
const size_t kWoff2HeaderSize = 48;
const size_t kWoff2EntrySize = 20;
bool Compress(const uint8_t* data, const size_t len,
uint8_t* result, uint32_t* result_len,
brotli::BrotliParams::Mode mode, int quality) {