Closed dimbleby closed 3 years ago
I don't understand the code to know whether this is what's wanted, but the following fix certainly sidesteps the issue, and doesn't immediately fall over...
- int16_t prt_ind = *ind_ptr;
+ int16_t prt_ind = ind_len_stk.size() > 1 ? *ind_ptr : 0;
I thought I'd see how this parser handled being fuzzed. I didn't get very far: it looks as though every file provokes invalid memory access! The pointer being dereferenced here is not valid.
Certainly the empty file is sufficient to provoke this error.