From 731dac72d71ce916ef199f16d228a2bb8642bc7f Mon Sep 17 00:00:00 2001 From: Ilia Choly Date: Mon, 11 Nov 2019 17:37:31 -0500 Subject: [PATCH] Return ErrUnsuppConversion for all unsuported types --- unmarshal.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/unmarshal.go b/unmarshal.go index 1382009..5c292e7 100644 --- a/unmarshal.go +++ b/unmarshal.go @@ -561,7 +561,7 @@ func unmarshalVal(data []byte, bo binary.ByteOrder, ft FieldType, v reflect.Valu return ErrUnsuppConversion{ft, typ} } v.SetInt(i64) - case reflect.Uint8, reflect.Int8, reflect.Float32, reflect.Float64: + default: // If this was not handled at the top, we do not support // converting other types to these types. return ErrUnsuppConversion{ft, typ}