fix #104 add (currently unused, optional) extra error return from C functions