From 97dc5e7f396129222419811c173edc7fa767b0f8 Mon Sep 17 00:00:00 2001 From: Sverker Eriksson Date: Wed, 30 Aug 2017 19:53:37 +0200 Subject: erts: Fix crash in binary_to_atom/term for invalid utf8 such as a sub-binary, of a correct utf8 string, that ends in the middle of a character. --- erts/emulator/test/binary_SUITE.erl | 3 +++ 1 file changed, 3 insertions(+) (limited to 'erts/emulator/test/binary_SUITE.erl') diff --git a/erts/emulator/test/binary_SUITE.erl b/erts/emulator/test/binary_SUITE.erl index fe0a745db8..fc3be38519 100644 --- a/erts/emulator/test/binary_SUITE.erl +++ b/erts/emulator/test/binary_SUITE.erl @@ -599,6 +599,9 @@ bad_binary_to_term(Config) when is_list(Config) -> %% Bad float. ?line bad_bin_to_term(<<131,70,-1:64>>), + + %% Truncated UTF8 character (ERL-474) + bad_bin_to_term(<<131,119,1,194,163>>), ok. bad_bin_to_term(BadBin) -> -- cgit v1.2.3