Skip to content

Proposal: Add a closefd boolean argument to the chunk_generator function. #17

@Friz-zy

Description

@Friz-zy

Currently, the fastcdc_(py|cy) functions leave the file descriptor open after returning the generator since the generator requires it. This can result in a memory leak for non-CPython interpreters that do not utilize memory reference counting. To address this issue, I propose adding a boolean parameter called closefd to the chunk_generator function, along with some corresponding if code. I am confident that I can make these changes myself once my current pull request #16 is merged.

Alternative: Convert fastcdc_(py|cy) functions into generators themselves plus using with open(...) expression inside.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions