Skip to content

PlayerKernel.open() throws exception when opening ISpecialFile file with O_TRUNC #61

@testpoiu

Description

@testpoiu

O_TRUNC will make fileentry.bytes.length = 0, but this throws a null pointer exception when fileentry.bytes is not set (which can be the case for ISpecialFile entries). Easily fixed:

if ( fileentry.bytes ) fileentry.bytes.length = 0

A real fix might call on ISpecialFile, which would require a new method such as truncate().

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions