bugfix: fix handling of invalid primitive data types.

Signed-off-by: Kim Kulling <kim.kulling@googlemail.com>