Skip to content

Saving binary string in sessionStorage in IE produces and Error #11

@AugustePop

Description

@AugustePop

The BinaryString encoding may produce string containing 0-coded character, namely "\0". IE will throw an error when we try to save the string directly in to sessionStorage.

var str = String.fromCharCode(0);
/* Error thrown in following line */
sessionStorage.setItem('test', str);

I ran a simple test against IE sessionStorage, and find out only char with code 0 will result in an exception.

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