xbps_remove_pkg: ignore ELOOP in realpath() when checking symlinks.

Probably it is a broken symlink, so we don't have to care about it.
This commit is contained in:
Juan RP 2013-02-04 16:35:15 +01:00
parent 90cde72283
commit a8e8e8fd5d

View File

@ -170,7 +170,7 @@ xbps_remove_pkg_files(struct xbps_handle *xhp,
* point, so we will only remove dangling symlinks. * point, so we will only remove dangling symlinks.
*/ */
if (realpath(path, buf) == NULL) { if (realpath(path, buf) == NULL) {
if (errno != ENOENT) { if (errno != ENOENT && errno != ELOOP) {
free(path); free(path);
rv = errno; rv = errno;
break; break;