Maybe adding bpf_program__set_autoattach(skel->progs.handle_getdents_patch, false); before the code err = pidhide_bpf__load(skel); is a good choice?
In my test, I found that function handle_getdents_patch will also be automatically mounted, not just called by bpf_tail_call