Commit c376e160 authored by Bernhard Link's avatar Bernhard Link

make import use the same directory for overrides as the rest

parent 62c4f3fa
......@@ -908,7 +908,7 @@ static retvalue candidate_checkpermissions(const char *confdir, struct incoming
return RET_NOTHING;
}
static retvalue candidate_add(const char *confdir, filesdb filesdb, const char *dbdir, references refs, struct strlist *dereferenced, struct incoming *i, struct candidate *c, struct distribution *into) {
static retvalue candidate_add(const char *confdir,const char *overridedir,filesdb filesdb, const char *dbdir, references refs, struct strlist *dereferenced, struct incoming *i, struct candidate *c, struct distribution *into) {
struct candidate_file *file;
struct trackingdata *trackingdata = NULL;
retvalue r;
......@@ -946,7 +946,7 @@ static retvalue candidate_add(const char *confdir, filesdb filesdb, const char *
return RET_ERROR;
}
r = distribution_loadalloverrides(into,confdir);
r = distribution_loadalloverrides(into, overridedir);
if( RET_WAS_ERROR(r) )
return r;
......@@ -1057,7 +1057,7 @@ static retvalue candidate_add(const char *confdir, filesdb filesdb, const char *
return RET_OK;
}
static retvalue process_changes(const char *confdir, filesdb filesdb, const char *dbdir, references refs, struct strlist *dereferenced, struct incoming *i, int ofs) {
static retvalue process_changes(const char *confdir,const char *overridedir,filesdb filesdb,const char *dbdir,references refs,struct strlist *dereferenced,struct incoming *i,int ofs) {
struct candidate *c;
struct distribution *into = NULL;
struct candidate_file *file;
......@@ -1126,7 +1126,7 @@ static retvalue process_changes(const char *confdir, filesdb filesdb, const char
i->files.values[ofs]);
r = RET_ERROR;
} else
r = candidate_add(confdir, filesdb, dbdir,
r = candidate_add(confdir, overridedir, filesdb, dbdir,
refs, dereferenced,
i, c, into);
if( RET_WAS_ERROR(r) && i->cleanup.on_error ) {
......@@ -1143,7 +1143,7 @@ static retvalue process_changes(const char *confdir, filesdb filesdb, const char
}
/* tempdir should ideally be on the same partition like the pooldir */
retvalue process_incoming(const char *basedir,const char *confdir, filesdb files, const char *dbdir, references refs, struct strlist *dereferenced, struct distribution *distributions, const char *name) {
retvalue process_incoming(const char *basedir,const char *confdir,const char *overridedir,filesdb files,const char *dbdir,references refs,struct strlist *dereferenced,struct distribution *distributions,const char *name) {
struct incoming *i;
retvalue result,r;
int j;
......@@ -1162,7 +1162,7 @@ retvalue process_incoming(const char *basedir,const char *confdir, filesdb files
if( l <= C_LEN || strcmp(basename+(l-C_LEN),C_SUFFIX) != 0 )
continue;
/* a .changes file, check it */
r = process_changes(confdir, files, dbdir, refs, dereferenced, i, j);
r = process_changes(confdir, overridedir, files, dbdir, refs, dereferenced, i, j);
RET_UPDATE(result, r);
}
......
......@@ -6,5 +6,5 @@
#warning "What's hapening here?"
#endif
retvalue process_incoming(const char *basedir,const char *confdir, filesdb files, const char *dbdir, references refs, struct strlist *dereferenced, struct distribution *distributions, const char *name);
retvalue process_incoming(const char *basedir,const char *confdir,const char *overridedir,filesdb files,const char *dbdir,references refs,struct strlist *dereferenced,struct distribution *distributions,const char *name);
#endif
......@@ -73,6 +73,7 @@ static char /*@only@*/ /*@notnull@*/ // *g*
*dbdir = NULL,
*listdir = NULL,
*confdir = NULL,
/* This should have never been a seperate directory, well to late... */
*overridedir = NULL,
*methoddir = NULL;
static char /*@only@*/ /*@null@*/
......@@ -1980,7 +1981,7 @@ ACTION_D(import) {
return r;
}
result = process_incoming(mirrordir, confdir, filesdb, dbdir, references, dereferenced, distributions, argv[1]);
result = process_incoming(mirrordir, confdir, overridedir, filesdb, dbdir, references, dereferenced, distributions, argv[1]);
r = distribution_exportandfreelist(export,distributions,
confdir,dbdir,distdir, filesdb);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment