bin/xbps-rindex/remove-obsoletes.c: always opendir() pwd
If repodir is given as a relative path, it will not work because it will try to open the dir relative to itself because it already chdir()ed into repodir. This fixes xbps-rindex -r when relative paths are specified. fixes #519
This commit is contained in:
parent
0990b2ec81
commit
0d0a2b9657
@ -134,7 +134,7 @@ remove_obsoletes(struct xbps_handle *xhp, const char *repodir)
|
||||
rv = errno;
|
||||
goto out;
|
||||
}
|
||||
if ((dirp = opendir(repodir)) == NULL) {
|
||||
if ((dirp = opendir(".")) == NULL) {
|
||||
fprintf(stderr, "xbps-rindex: failed to open %s: %s\n",
|
||||
repodir, strerror(errno));
|
||||
rv = errno;
|
||||
|
Loading…
Reference in New Issue
Block a user