fix a crash if a non-pointer is given to Decode

/cc @sethvargo