Skip to content

mmap_array segfaults #11351

@quinnj

Description

@quinnj

While battle-testing #11280, I discovered the following for Windows:

s = open(file, "r") # open file as read-only with contents "Hello World\n"
m = Mmap.Array(s) # same as previous mmap_array()
m[5] = UInt8('x')
# segfault

On OSX, I get an OutOfMemoryError(), but I don't think that's very informative.

I'm not entirely sure what to do here. Restrict Mmap.Array to file's where we have read & write permissions? Is that overly restrictive? Put a warning in the docs to be careful with read-only files? Rethink the Mmap.Array interface entirely?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions