mirror of
https://github.com/msgpack/msgpack-python.git
synced 2026-02-07 02:09:59 +00:00
Handle unsupported typecode
This commit is contained in:
parent
003fb3392f
commit
ee16e2eb30
1 changed files with 3 additions and 0 deletions
|
|
@ -4,6 +4,7 @@ import (
|
|||
"io"
|
||||
"os"
|
||||
"unsafe"
|
||||
"strconv"
|
||||
"reflect"
|
||||
)
|
||||
|
||||
|
|
@ -264,6 +265,8 @@ func unpack(reader io.Reader, reflected bool) (v reflect.Value, n int, err os.Er
|
|||
}
|
||||
nbytesread += n
|
||||
if e != nil { return nil, nbytesread, e }
|
||||
default:
|
||||
panic("unsupported code: " + strconv.Itoa(int(c)))
|
||||
}
|
||||
}
|
||||
return retval, nbytesread, nil
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue