set output parameters to NULL initially