Skip to content

Attempt to use undefined value #41

@bookmoons

Description

@bookmoons

Attempting to decode bytes 474946383961494638fd627a4421 raises an error:

TypeError: Cannot read property 'toString' of undefined

It seems to happen on line 459 of omggif.js:

                "Unknown graphic control label: 0x" + buf[p-1].toString(16));

This code reproduces:

const omggif = require('omggif')
const bytes = Buffer.from('474946383961494638fd627a4421', 'hex')
omggif.GifReader(bytes)

This was found by running jsfuzz on the module.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions