In a origin lookup mode (-O) don't bail out when encountering empty package
directory, because this prevent this option from being used from the package-depends target of bsd.port.mk since it creates such empty dir during its normal operation. MFC after: 6 days
This commit is contained in:
parent
18074efb5e
commit
f351f851db
@ -440,8 +440,14 @@ find_pkgs_by_origin(const char *db_dir, const char *origin)
|
||||
char *cp, tmp[PATH_MAX];
|
||||
int cmd;
|
||||
|
||||
snprintf(tmp, PATH_MAX, "%s/%s/%s", db_dir, installed[i],
|
||||
CONTENTS_FNAME);
|
||||
snprintf(tmp, PATH_MAX, "%s/%s", db_dir, installed[i]);
|
||||
/*
|
||||
* SPECIAL CASE: ignore empty dirs, since we can can see them
|
||||
* during port installation.
|
||||
*/
|
||||
if (isemptydir(tmp))
|
||||
continue;
|
||||
snprintf(tmp, PATH_MAX, "%s/%s", tmp, CONTENTS_FNAME);
|
||||
fp = fopen(tmp, "r");
|
||||
if (fp == NULL) {
|
||||
warn("%s", tmp);
|
||||
|
Loading…
x
Reference in New Issue
Block a user