ftrace: Fix the conditional that updates $ref_func