Skip to content

Commit

Permalink
Remove redundant check
Browse files Browse the repository at this point in the history
`is_ld("ld")` returns true
  • Loading branch information
rui314 committed Nov 23, 2023
1 parent 1ae4b95 commit d386776
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion elf/mold-wrapper.c
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ int posix_spawnp(pid_t *pid, const char *file,
const posix_spawnattr_t *attrp,
char *const *argv, char *const *envp) {
debug_print("posix_spawnp %s\n", file);
if (!strcmp(file, "ld") || is_ld(file))
if (is_ld(file))
file = get_mold_path();
typeof(posix_spawnp) *real = dlsym(RTLD_NEXT, "posix_spawnp");
return real(pid, file, file_actions, attrp, argv, envp);
Expand Down

0 comments on commit d386776

Please sign in to comment.