xbps_init() now sets rootdir, cachedir and flags.
That means that the following functions were removed: - xbps_set_{cachedir,flags,rootdir}. - xbps_get_{cachedir,flags,rootdir}. With this change fixed an obvious typo that made -c argument to not work, and now the cache directory is an absolute path not relative to rootdir.
This commit is contained in:
@@ -163,11 +163,13 @@ unregister_repository(const char *uri)
|
||||
int
|
||||
register_repository(const char *uri)
|
||||
{
|
||||
const struct xbps_handle *xhp;
|
||||
struct repoinfo *rpi = NULL;
|
||||
const char *idxstr = NULL;
|
||||
char *metadir, *plist;
|
||||
int rv = 0;
|
||||
|
||||
xhp = xbps_handle_get();
|
||||
if ((idxstr = sanitize_url(uri)) == NULL)
|
||||
return errno;
|
||||
|
||||
@@ -189,7 +191,7 @@ register_repository(const char *uri)
|
||||
/*
|
||||
* Create metadir if necessary.
|
||||
*/
|
||||
metadir = xbps_xasprintf("%s/%s", xbps_get_rootdir(),
|
||||
metadir = xbps_xasprintf("%s/%s", xhp->rootdir,
|
||||
XBPS_META_PATH);
|
||||
if (metadir == NULL)
|
||||
return errno;
|
||||
|
Reference in New Issue
Block a user