fix function pointer types in dynamic procedure handler