Bug 690889 - Potential NULL-dereference...
Summary: Potential NULL-dereference...
Status: RESOLVED FIXED
Alias: None
Product: jbig2dec
Classification: Unclassified
Component: Parsing (show other bugs)
Version: master
Hardware: All All
: P4 normal
Assignee: Henry Stiles
URL: http://code.google.com/p/sumatrapdf/i...
Keywords:
: 690895 (view as bug list)
Depends on:
Blocks:
 
Reported: 2009-11-05 11:10 UTC by Tor Andersson
Modified: 2011-05-11 22:30 UTC (History)
3 users (show)

See Also:
Customer:
Word Size: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tor Andersson 2009-11-05 11:10:24 UTC
A bug report (http://code.google.com/p/sumatrapdf/issues/detail?id=716) 
from sumatrapdf mentions a NULL-dereference. I checked this briefly and it 
seems to be a genuine issue, here is a probable call path:

jbig2_decode_symbol_dict(...)
    jbig2_decode_text_region(..., (Jbig2WordStream *)NULL);
        if (params->SBHUFF) {
          jbig2_huffman_new(..., ws); // ws is NULL here
             result->this_word = ws->get_next_word (ws, 0); // ws is NULL and is dereferenced here...

 / Sebastian
Comment 1 Ralph Giles 2009-11-05 17:27:11 UTC
Looks like you're right. Thanks for the report. Do you have a file which
exercises this?
Comment 3 Henry Stiles 2011-05-11 22:30:37 UTC
*** Bug 690895 has been marked as a duplicate of this bug. ***