Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Made stream_stat() ignore StreamUtil::getSize() result if it is 0 to … #22

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

DylanDonkersgoed
Copy link

…fix issue #21

@AbhayPai
Copy link

AbhayPai commented Nov 12, 2021

I faced similar issue, what i did was just to put default stat

        // Use the size of our handle, since it could have been written to or
        // truncated.
        $stream_util_size = StreamUtil::getSize($this->handle);
        if (!empty($stream_util_size)) {
            // Only set size if stream_util_size is available or
            // just send original file metadata.
            $stat['size'] = $stat[7] = $stream_util_size;
        }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants