set '\0' termination to readlink result.

refs #643
This commit is contained in:
Tomoki Shirasawa
2015-11-26 16:58:15 +09:00
parent 65dda3f24e
commit 7f2220b8e9

View File

@ -489,6 +489,7 @@ retry:
fprintf(stderr, "lookup_exec_path(): error readlink\n");
return EINVAL;
}
link_path[error] = '\0';
__dprintf("lookup_exec_path(): %s is link -> %s\n", path, link_path);