Improve detection of target file in relative symlinks.
If xbps-create(8) did not guess the target file of relative symlinks for some reason, just compare the current symlink and what's stored as is, without converting it to absolute. This might happen with dangling relative symlinks or existing binary packages that were not created with a newer xbps-create(8).
This commit is contained in:
1 parent
05f879ec09
commit
67eba7d912
4 files changed
+20
-9
No files matched your search
@@ -77,7 +77,7 @@ check_pkg_symlinks(struct xbps_handle *xhp, const char *pkgname, void *arg)
|
||||
continue;
|
||||
}
|
||||
snprintf(path, sizeof(path), "%s/%s", xhp->rootdir, file);
|
||||
if ((lnk = xbps_symlink_target(xhp, path)) == NULL) {
|
||||
if ((lnk = xbps_symlink_target(xhp, path, tgt)) == NULL) {
|
||||
xbps_error_printf("%s: broken symlink %s (target: %s)\n", pkgname, file, tgt);
|
||||
broken = true;
|
||||
continue;
|
||||
|
||||
Reference in new issue
Block a user