Skip to content

return download(xxx) 文件太大会导致 Allowed memory size of xxxxx bytes exhausted #1160

@mgzhenhong

Description

@mgzhenhong

vendor/topthink/framework/src/think/response/File.php line 76

return $this->isContent ? $data : file_get_contents($data);

如果文件太大会导致内存不足.
这里能否改为返回一个具体执行输出的 callable $outputCallback;

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