Skip to content

ReadLineAsync returns Null #97

@thopdev

Description

@thopdev

Describe the bug
All lines read from files are null when build with --configuration Release

Code:
using var stream = await _fileReference.OpenReadAsync();
using var reader = new StreamReader(stream, Encoding.UTF8, true, 10000);
string line;
while ((line = await reader.ReadLineAsync()) != null)
{
yield return line;
}

line is always null when build with Release.

When building with Debug no problems occur.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions