Skip to content

An encoding bug introduced in the MarcStreamWriter constructor #7

@zliebsco

Description

@zliebsco

Is this project still active? I hope it is, since it's a very useful library. I think the bug was introduced in the encoding change in the constructor of the MarcStreamWriter class.
This is the changed code
public MarcStreamWriter(Stream output, String encoding, bool allowOversizeRecord) : this(output,
Encoding.GetEncoding(encoding), allowOversizeRecord)

It throws exception when calling the constructor
public MarcStreamWriter(Stream output)

because the Encoding.GetEncoding(encoding) calls the GetEncoding without checking for null.

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