Skip to content

TypeError: Cannot read property 'allocUnsafe' of undefined #18

Open
@josharian

Description

@josharian

I'm executing this polyfill in v8, and getting:

TypeError: Cannot read property 'allocUnsafe' of undefined

It's coming from this line:

var NativeBuffer_allocUnsafe = NativeBuffer["allocUnsafe"];

Commenting out that line appears to fix the problem. Perhaps setting up NativeBuffer_allocUnsafe should be guarded by some other conditions? (My javascript is not strong.)

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