lib/repo.c: add user-facing error message when repodata doesn't exist
Instead of just cryptically exiting 0 when opening a non-existant repodata or stagedata, with the only message existing in the debug output, show an error to the user on stderr. mentioned in #519
This commit is contained in:
parent
a1a0167d80
commit
6de3c0f1fd
@ -246,6 +246,7 @@ repo_open_with_type(struct xbps_handle *xhp, const char *url, const char *name)
|
|||||||
int rv = errno;
|
int rv = errno;
|
||||||
xbps_dbg_printf("[repo] `%s' open %s %s\n",
|
xbps_dbg_printf("[repo] `%s' open %s %s\n",
|
||||||
repofile, name, strerror(rv));
|
repofile, name, strerror(rv));
|
||||||
|
xbps_error_printf("%s: %s\n", strerror(rv), repofile);
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
if (repo_open_local(repo, repofile)) {
|
if (repo_open_local(repo, repofile)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user