Skip to content

Commit

Permalink
Fix bug in resolving absolute symlinks in find_library_paths()
Browse files Browse the repository at this point in the history
Previously, only relative symlinks would work since we weren't fully
resolving the symlinks, but rather just joining them in the host
filesystem.

Signed-off-by: Kevin Klues <kklues@nvidia.com>
  • Loading branch information
klueska committed Dec 7, 2020
1 parent 31674b9 commit 5ae7360
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/nvc_container.c
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ find_library_paths(struct error *err, struct nvc_container *cnt)
if (!(cnt->flags & OPT_COMPUTE_LIBS))
return (0);

if (path_join(err, path, cnt->cfg.rootfs, cnt->cfg.cudart_dir) < 0)
if (path_resolve_full(err, path, cnt->cfg.rootfs, cnt->cfg.cudart_dir) < 0)
return (-1);
if (path_append(err, path, "compat/lib*.so.*") < 0)
return (-1);
Expand Down

0 comments on commit 5ae7360

Please sign in to comment.