Commit 6208a9a9 authored by Bernhard Link's avatar Bernhard Link

record new upstream branch created by importing reprepro_5.3.0.orig.tar.gz and merge it

parents 5e720852 d6b9eef4
2019-02-02 Bernhard R. Link <brlink@debian.org>
* handle a missing Binary field in a .changes file like an empty one.
(So not having one in a source only upload will be ignored,
while a missing one in a binary upload will complain about the
packages not listed in Binary: instead of complaining about not
having a Binary field).
2018-09-23 Bernhard R. Link <brlink@debian.org>
* check command no longer checks if the files
of existing packages are names as they are
expected to be named. (There was no way to
get them wrong apart editing the database and
checking it makes the code more complex).
2018-08-26 Bernhard R. Link <brlink@debian.org> 2018-08-26 Bernhard R. Link <brlink@debian.org>
* mark .lz support as deprecated * mark .lz support as deprecated
......
Updates between 5.2.0 and 5.3.0:
- no Binary field in a .changes file is no longer an error
but handled like an empty Binary field. (Needed to still
accept source only .changes files by dpkg > 1.19.3).
Updates between 5.1.1 and 5.2.0: Updates between 5.1.1 and 5.2.0:
- mark .lz support as deprecated - mark .lz support as deprecated
- add _listcodenames command - add _listcodenames command
......
...@@ -443,8 +443,7 @@ static retvalue floodlist_trypackage(struct floodlist *list, struct package *pac ...@@ -443,8 +443,7 @@ static retvalue floodlist_trypackage(struct floodlist *list, struct package *pac
return RET_ERROR_OOM; return RET_ERROR_OOM;
} }
r = list->target->getinstalldata(list->target, r = list->target->getinstalldata(list->target,
new->name, new->new_version, package,
architecture_all, package->control,
&new->new_control, &new->new_filekeys, &new->new_control, &new->new_filekeys,
&new->new_origfiles); &new->new_origfiles);
if (RET_WAS_ERROR(r)) { if (RET_WAS_ERROR(r)) {
...@@ -525,8 +524,7 @@ static retvalue floodlist_trypackage(struct floodlist *list, struct package *pac ...@@ -525,8 +524,7 @@ static retvalue floodlist_trypackage(struct floodlist *list, struct package *pac
return RET_ERROR_OOM; return RET_ERROR_OOM;
r = list->target->getinstalldata(list->target, r = list->target->getinstalldata(list->target,
package->name, package->version, package,
architecture_all, package->control,
&control, &files, &origfiles); &control, &files, &origfiles);
if (RET_WAS_ERROR(r)) { if (RET_WAS_ERROR(r)) {
free(new_version); free(new_version);
...@@ -634,7 +632,7 @@ static retvalue floodlist_install(struct floodlist *list, struct logger *logger, ...@@ -634,7 +632,7 @@ static retvalue floodlist_install(struct floodlist *list, struct logger *logger,
logger, pkg->name, pkg->new_version, logger, pkg->name, pkg->new_version,
pkg->new_control, &pkg->new_filekeys, pkg->new_control, &pkg->new_filekeys,
false, td, architecture_all, false, td, architecture_all,
NULL, NULL, NULL); NULL, NULL);
RET_UPDATE(result, r); RET_UPDATE(result, r);
if (RET_WAS_ERROR(r)) if (RET_WAS_ERROR(r))
break; break;
......
...@@ -36,6 +36,7 @@ ...@@ -36,6 +36,7 @@
#include "override.h" #include "override.h"
#include "tracking.h" #include "tracking.h"
#include "debfile.h" #include "debfile.h"
#include "package.h"
static const char * const deb_checksum_headers[cs_COUNT] = { static const char * const deb_checksum_headers[cs_COUNT] = {
"MD5sum", "SHA1", "SHA256", "Size"}; "MD5sum", "SHA1", "SHA256", "Size"};
...@@ -120,39 +121,28 @@ retvalue binaries_getarchitecture(const char *chunk, architecture_t *architectur ...@@ -120,39 +121,28 @@ retvalue binaries_getarchitecture(const char *chunk, architecture_t *architectur
/* get somefields out of a "Packages.gz"-chunk. /* get somefields out of a "Packages.gz"-chunk.
* returns RET_OK on success, RET_NOTHING if incomplete, error otherwise */ * returns RET_OK on success, RET_NOTHING if incomplete, error otherwise */
static retvalue binaries_parse_chunk(const char *chunk, const char *packagename, packagetype_t packagetype, architecture_t package_architecture, const char *version, /*@out@*/char **sourcename_p, /*@out@*/char **basename_p) { static retvalue binaries_calc_basename(struct package *package, /*@out@*/char **basename_p) {
retvalue r; retvalue r;
char *mysourcename, *mybasename; char *mybasename;
assert(packagename!=NULL); assert (package->name != NULL);
assert (package->version != NULL);
/* get the sourcename */
r = chunk_getname(chunk, "Source", &mysourcename, true);
if (r == RET_NOTHING) {
mysourcename = strdup(packagename);
if (FAILEDTOALLOC(mysourcename))
r = RET_ERROR_OOM;
}
if (RET_WAS_ERROR(r)) {
return r;
}
r = properpackagename(packagename); r = properpackagename(package->name);
if (!RET_WAS_ERROR(r)) if (!RET_WAS_ERROR(r))
r = properversion(version); r = properversion(package->version);
if (RET_WAS_ERROR(r)) { if (RET_WAS_ERROR(r)) {
free(mysourcename);
return r; return r;
} }
mybasename = calc_binary_basename(packagename, version, mybasename = calc_binary_basename(package->name,
package_architecture, packagetype); package->version,
package->architecture,
package->target->packagetype);
if (FAILEDTOALLOC(mybasename)) { if (FAILEDTOALLOC(mybasename)) {
free(mysourcename);
return RET_ERROR_OOM; return RET_ERROR_OOM;
} }
*basename_p = mybasename; *basename_p = mybasename;
*sourcename_p = mysourcename;
return RET_OK; return RET_OK;
} }
...@@ -231,28 +221,29 @@ retvalue binaries_getversion(const char *control, char **version) { ...@@ -231,28 +221,29 @@ retvalue binaries_getversion(const char *control, char **version) {
return r; return r;
} }
retvalue binaries_getinstalldata(const struct target *t, const char *packagename, const char *version, architecture_t package_architecture, const char *chunk, char **control, struct strlist *filekeys, struct checksumsarray *origfiles) { retvalue binaries_getinstalldata(const struct target *t, struct package *package, char **control, struct strlist *filekeys, struct checksumsarray *origfiles) {
char *sourcename, *basefilename; char *basefilename;
struct checksumsarray origfilekeys; struct checksumsarray origfilekeys;
retvalue r; retvalue r;
const char *chunk = package->control;
r = binaries_parse_chunk(chunk, packagename, assert (t->packagetype == package->target->packagetype);
t->packagetype, package_architecture,
version, &sourcename, &basefilename); r = package_getsource(package);
if (RET_WAS_ERROR(r)) { if (RET_WAS_ERROR(r))
return r; return r;
} else if (r == RET_NOTHING) {
fprintf(stderr, "Does not look like a binary package: '%s'!\n", r = binaries_calc_basename(package, &basefilename);
chunk); if (RET_WAS_ERROR(r))
return RET_ERROR; return RET_ERROR;
}
r = binaries_getchecksums(chunk, &origfilekeys); r = binaries_getchecksums(chunk, &origfilekeys);
if (RET_WAS_ERROR(r)) { if (RET_WAS_ERROR(r)) {
free(sourcename); free(basefilename); free(basefilename);
return r; return r;
} }
r = calcnewcontrol(chunk, packagename, sourcename, basefilename, r = calcnewcontrol(chunk, package->name, package->source,
basefilename,
t->component, filekeys, control); t->component, filekeys, control);
if (RET_WAS_ERROR(r)) { if (RET_WAS_ERROR(r)) {
checksumsarray_done(&origfilekeys); checksumsarray_done(&origfilekeys);
...@@ -260,7 +251,7 @@ retvalue binaries_getinstalldata(const struct target *t, const char *packagename ...@@ -260,7 +251,7 @@ retvalue binaries_getinstalldata(const struct target *t, const char *packagename
assert (r != RET_NOTHING); assert (r != RET_NOTHING);
checksumsarray_move(origfiles, &origfilekeys); checksumsarray_move(origfiles, &origfilekeys);
} }
free(sourcename); free(basefilename); free(basefilename);
return r; return r;
} }
...@@ -500,7 +491,7 @@ void binaries_debdone(struct deb_headers *pkg) { ...@@ -500,7 +491,7 @@ void binaries_debdone(struct deb_headers *pkg) {
free(pkg->priority); free(pkg->priority);
} }
retvalue binaries_readdeb(struct deb_headers *deb, const char *filename, bool needssourceversion) { retvalue binaries_readdeb(struct deb_headers *deb, const char *filename) {
retvalue r; retvalue r;
char *architecture; char *architecture;
...@@ -538,11 +529,8 @@ retvalue binaries_readdeb(struct deb_headers *deb, const char *filename, bool ne ...@@ -538,11 +529,8 @@ retvalue binaries_readdeb(struct deb_headers *deb, const char *filename, bool ne
if (RET_WAS_ERROR(r)) if (RET_WAS_ERROR(r))
return r; return r;
/* can be there, otherwise we also know what it is */ /* can be there, otherwise we also know what it is */
if (needssourceversion) r = chunk_getnameandversion(deb->control, "Source",
r = chunk_getnameandversion(deb->control, "Source", &deb->source, &deb->sourceversion);
&deb->source, &deb->sourceversion);
else
r = chunk_getname(deb->control, "Source", &deb->source, true);
if (r == RET_NOTHING) { if (r == RET_NOTHING) {
deb->source = strdup(deb->name); deb->source = strdup(deb->name);
if (FAILEDTOALLOC(deb->source)) if (FAILEDTOALLOC(deb->source))
...@@ -550,7 +538,7 @@ retvalue binaries_readdeb(struct deb_headers *deb, const char *filename, bool ne ...@@ -550,7 +538,7 @@ retvalue binaries_readdeb(struct deb_headers *deb, const char *filename, bool ne
} }
if (RET_WAS_ERROR(r)) if (RET_WAS_ERROR(r))
return r; return r;
if (needssourceversion && deb->sourceversion == NULL) { if (deb->sourceversion == NULL) {
deb->sourceversion = strdup(deb->version); deb->sourceversion = strdup(deb->version);
if (FAILEDTOALLOC(deb->sourceversion)) if (FAILEDTOALLOC(deb->sourceversion))
return RET_ERROR_OOM; return RET_ERROR_OOM;
...@@ -676,7 +664,7 @@ retvalue binaries_adddeb(const struct deb_headers *deb, const struct atomlist *f ...@@ -676,7 +664,7 @@ retvalue binaries_adddeb(const struct deb_headers *deb, const struct atomlist *f
false, false,
trackingdata, trackingdata,
deb->architecture, deb->architecture,
NULL, NULL, NULL); NULL, NULL);
r2 = target_closepackagesdb(t); r2 = target_closepackagesdb(t);
RET_ENDUPDATE(r, r2); RET_ENDUPDATE(r, r2);
} }
...@@ -718,7 +706,7 @@ retvalue binaries_adddeb(const struct deb_headers *deb, const struct atomlist *f ...@@ -718,7 +706,7 @@ retvalue binaries_adddeb(const struct deb_headers *deb, const struct atomlist *f
false, false,
trackingdata, trackingdata,
deb->architecture, deb->architecture,
NULL, NULL, NULL); NULL, NULL);
r2 = target_closepackagesdb(t); r2 = target_closepackagesdb(t);
RET_ENDUPDATE(r, r2); RET_ENDUPDATE(r, r2);
} }
...@@ -794,4 +782,3 @@ retvalue binaries_calcfilekeys(component_t component, const struct deb_headers * ...@@ -794,4 +782,3 @@ retvalue binaries_calcfilekeys(component_t component, const struct deb_headers *
free(basefilename); free(basefilename);
return r; return r;
} }
...@@ -44,7 +44,7 @@ struct deb_headers { ...@@ -44,7 +44,7 @@ struct deb_headers {
* error returned * error returned
* - no checks for sanity of values, left to the caller */ * - no checks for sanity of values, left to the caller */
retvalue binaries_readdeb(struct deb_headers *, const char *filename, bool /*needssourceversion*/); retvalue binaries_readdeb(struct deb_headers *, const char *filename);
void binaries_debdone(struct deb_headers *); void binaries_debdone(struct deb_headers *);
retvalue binaries_calcfilekeys(component_t, const struct deb_headers *, packagetype_t, /*@out@*/struct strlist *); retvalue binaries_calcfilekeys(component_t, const struct deb_headers *, packagetype_t, /*@out@*/struct strlist *);
......
...@@ -452,10 +452,16 @@ static retvalue changes_read(const char *filename, /*@out@*/struct changes **cha ...@@ -452,10 +452,16 @@ static retvalue changes_read(const char *filename, /*@out@*/struct changes **cha
r = properversion(c->sourceversion); r = properversion(c->sourceversion);
R; R;
} }
r = chunk_getwordlist(c->control, "Binary", &c->binaries);
E("Missing 'Binary' field");
r = chunk_getwordlist(c->control, "Architecture", &c->architectures); r = chunk_getwordlist(c->control, "Architecture", &c->architectures);
E("Missing 'Architecture' field"); E("Missing 'Architecture' field");
r = chunk_getwordlist(c->control, "Binary", &c->binaries);
if (r == RET_NOTHING) {
/* this could print a waring if architectures
* contains anything but 'source', but the .deb
* files are checked anyway... */
strlist_init(&c->binaries);
}
R;
r = chunk_getvalue(c->control, "Version", &c->changesversion); r = chunk_getvalue(c->control, "Version", &c->changesversion);
E("Missing 'Version' field"); E("Missing 'Version' field");
r = properversion(c->changesversion); r = properversion(c->changesversion);
...@@ -1577,7 +1583,6 @@ retvalue changes_add(trackingdb const tracks, const struct atomlist *packagetype ...@@ -1577,7 +1583,6 @@ retvalue changes_add(trackingdb const tracks, const struct atomlist *packagetype
assert (logger_isprepared(distribution->logger)); assert (logger_isprepared(distribution->logger));
logger_logchanges(distribution->logger, distribution->codename, logger_logchanges(distribution->logger, distribution->codename,
changes->source, changes->changesversion, changes->source, changes->changesversion,
changes->control,
changesfilename, changes->changesfilekey); changesfilename, changes->changesfilekey);
} }
/* wait for notify scripts (including those for the packages) /* wait for notify scripts (including those for the packages)
......
...@@ -73,7 +73,7 @@ void deb_free(/*@only@*/struct debpackage *pkg) { ...@@ -73,7 +73,7 @@ void deb_free(/*@only@*/struct debpackage *pkg) {
} }
/* read the data from a .deb, make some checks and extract some data */ /* read the data from a .deb, make some checks and extract some data */
static retvalue deb_read(/*@out@*/struct debpackage **pkg, const char *filename, bool needssourceversion) { static retvalue deb_read(/*@out@*/struct debpackage **pkg, const char *filename) {
retvalue r; retvalue r;
struct debpackage *deb; struct debpackage *deb;
...@@ -81,12 +81,12 @@ static retvalue deb_read(/*@out@*/struct debpackage **pkg, const char *filename, ...@@ -81,12 +81,12 @@ static retvalue deb_read(/*@out@*/struct debpackage **pkg, const char *filename,
if (FAILEDTOALLOC(deb)) if (FAILEDTOALLOC(deb))
return RET_ERROR_OOM; return RET_ERROR_OOM;
r = binaries_readdeb(&deb->deb, filename, needssourceversion); r = binaries_readdeb(&deb->deb, filename);
if (RET_IS_OK(r)) if (RET_IS_OK(r))
r = properpackagename(deb->deb.name); r = properpackagename(deb->deb.name);
if (RET_IS_OK(r)) if (RET_IS_OK(r))
r = propersourcename(deb->deb.source); r = propersourcename(deb->deb.source);
if (RET_IS_OK(r) && needssourceversion) if (RET_IS_OK(r))
r = properversion(deb->deb.sourceversion); r = properversion(deb->deb.sourceversion);
if (RET_IS_OK(r)) if (RET_IS_OK(r))
r = properversion(deb->deb.version); r = properversion(deb->deb.version);
...@@ -240,7 +240,7 @@ retvalue deb_prepare(/*@out@*/struct debpackage **deb, component_t forcecomponen ...@@ -240,7 +240,7 @@ retvalue deb_prepare(/*@out@*/struct debpackage **deb, component_t forcecomponen
/* First taking a closer look in the file: */ /* First taking a closer look in the file: */
r = deb_read(&pkg, debfilename, true); r = deb_read(&pkg, debfilename);
if (RET_WAS_ERROR(r)) { if (RET_WAS_ERROR(r)) {
return r; return r;
} }
...@@ -341,7 +341,7 @@ retvalue deb_add(component_t forcecomponent, const struct atomlist *forcearchite ...@@ -341,7 +341,7 @@ retvalue deb_add(component_t forcecomponent, const struct atomlist *forcearchite
causingfile = debfilename; causingfile = debfilename;
r = deb_read(&pkg, debfilename, tracks != NULL); r = deb_read(&pkg, debfilename);
if (RET_WAS_ERROR(r)) { if (RET_WAS_ERROR(r)) {
return r; return r;
} }
......
...@@ -147,7 +147,7 @@ retvalue dsc_addprepared(const struct dsc_headers *dsc, component_t component, c ...@@ -147,7 +147,7 @@ retvalue dsc_addprepared(const struct dsc_headers *dsc, component_t component, c
dsc->control, filekeys, dsc->control, filekeys,
false, trackingdata, false, trackingdata,
architecture_source, architecture_source,
NULL, NULL, NULL); NULL, NULL);
r2 = target_closepackagesdb(t); r2 = target_closepackagesdb(t);
RET_ENDUPDATE(r, r2); RET_ENDUPDATE(r, r2);
} }
......
#! /bin/sh #! /bin/sh
# Guess values for system-dependent variables and create Makefiles. # Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69 for reprepro 5.2.0. # Generated by GNU Autoconf 2.69 for reprepro 5.3.0.
# #
# Report bugs to <brlink@debian.org>. # Report bugs to <brlink@debian.org>.
# #
...@@ -580,8 +580,8 @@ MAKEFLAGS= ...@@ -580,8 +580,8 @@ MAKEFLAGS=
# Identity of this package. # Identity of this package.
PACKAGE_NAME='reprepro' PACKAGE_NAME='reprepro'
PACKAGE_TARNAME='reprepro' PACKAGE_TARNAME='reprepro'
PACKAGE_VERSION='5.2.0' PACKAGE_VERSION='5.3.0'
PACKAGE_STRING='reprepro 5.2.0' PACKAGE_STRING='reprepro 5.3.0'
PACKAGE_BUGREPORT='brlink@debian.org' PACKAGE_BUGREPORT='brlink@debian.org'
PACKAGE_URL='' PACKAGE_URL=''
...@@ -1292,7 +1292,7 @@ if test "$ac_init_help" = "long"; then ...@@ -1292,7 +1292,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing. # Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh. # This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF cat <<_ACEOF
\`configure' configures reprepro 5.2.0 to adapt to many kinds of systems. \`configure' configures reprepro 5.3.0 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]... Usage: $0 [OPTION]... [VAR=VALUE]...
...@@ -1359,7 +1359,7 @@ fi ...@@ -1359,7 +1359,7 @@ fi
if test -n "$ac_init_help"; then if test -n "$ac_init_help"; then
case $ac_init_help in case $ac_init_help in
short | recursive ) echo "Configuration of reprepro 5.2.0:";; short | recursive ) echo "Configuration of reprepro 5.3.0:";;
esac esac
cat <<\_ACEOF cat <<\_ACEOF
...@@ -1463,7 +1463,7 @@ fi ...@@ -1463,7 +1463,7 @@ fi
test -n "$ac_init_help" && exit $ac_status test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then if $ac_init_version; then
cat <<\_ACEOF cat <<\_ACEOF
reprepro configure 5.2.0 reprepro configure 5.3.0
generated by GNU Autoconf 2.69 generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc. Copyright (C) 2012 Free Software Foundation, Inc.
...@@ -1886,7 +1886,7 @@ cat >config.log <<_ACEOF ...@@ -1886,7 +1886,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake. running configure, to aid debugging if configure makes a mistake.
It was created by reprepro $as_me 5.2.0, which was It was created by reprepro $as_me 5.3.0, which was
generated by GNU Autoconf 2.69. Invocation command line was generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@ $ $0 $@
...@@ -2750,7 +2750,7 @@ fi ...@@ -2750,7 +2750,7 @@ fi
# Define the identity of the package. # Define the identity of the package.
PACKAGE='reprepro' PACKAGE='reprepro'
VERSION='5.2.0' VERSION='5.3.0'
cat >>confdefs.h <<_ACEOF cat >>confdefs.h <<_ACEOF
...@@ -6661,7 +6661,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ...@@ -6661,7 +6661,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their # report actual input values of CONFIG_FILES etc. instead of their
# values after options handling. # values after options handling.
ac_log=" ac_log="
This file was extended by reprepro $as_me 5.2.0, which was This file was extended by reprepro $as_me 5.3.0, which was
generated by GNU Autoconf 2.69. Invocation command line was generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES CONFIG_FILES = $CONFIG_FILES
...@@ -6727,7 +6727,7 @@ _ACEOF ...@@ -6727,7 +6727,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\ ac_cs_version="\\
reprepro config.status 5.2.0 reprepro config.status 5.3.0
configured by $0, generated by GNU Autoconf 2.69, configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\" with options \\"\$ac_cs_config\\"
......
...@@ -2,7 +2,7 @@ dnl ...@@ -2,7 +2,7 @@ dnl
dnl Process this file with autoconf to produce a configure script dnl Process this file with autoconf to produce a configure script
dnl dnl
AC_INIT(reprepro, 5.2.0, brlink@debian.org) AC_INIT(reprepro, 5.3.0, brlink@debian.org)
AC_CONFIG_SRCDIR(main.c) AC_CONFIG_SRCDIR(main.c)
AC_CONFIG_AUX_DIR(ac) AC_CONFIG_AUX_DIR(ac)
AM_INIT_AUTOMAKE([-Wall -Werror -Wno-portability]) AM_INIT_AUTOMAKE([-Wall -Werror -Wno-portability])
......
...@@ -182,8 +182,7 @@ static retvalue list_prepareadd(struct package_list *list, struct target *target ...@@ -182,8 +182,7 @@ static retvalue list_prepareadd(struct package_list *list, struct target *target
assert (new != NULL); assert (new != NULL);
new->architecture = package->architecture; new->architecture = package->architecture;
r = target->getinstalldata(target, new->name, new->version, r = target->getinstalldata(target, package,
new->architecture, package->control,
&new->control, &new->filekeys, &new->origfiles); &new->control, &new->filekeys, &new->origfiles);
assert (r != RET_NOTHING); assert (r != RET_NOTHING);
if (RET_WAS_ERROR(r)) { if (RET_WAS_ERROR(r)) {
...@@ -275,7 +274,7 @@ static retvalue package_add(struct distribution *into, /*@null@*/trackingdb trac ...@@ -275,7 +274,7 @@ static retvalue package_add(struct distribution *into, /*@null@*/trackingdb trac
(tracks != NULL)? (tracks != NULL)?
&trackingdata:NULL, &trackingdata:NULL,
package->architecture, package->architecture,
NULL, suitefrom, NULL); NULL, suitefrom);
RET_UPDATE(into->status, r); RET_UPDATE(into->status, r);
if (tracks != NULL) { if (tracks != NULL) {
retvalue r2; retvalue r2;
......
# see git-dpm(1) from git-dpm package # see git-dpm(1) from git-dpm package
759040053fb0741f14c80b783fee10235f0b27cf d6b9eef4c7606e9b0e0dff6bea28c7fcc67be818
759040053fb0741f14c80b783fee10235f0b27cf d6b9eef4c7606e9b0e0dff6bea28c7fcc67be818
759040053fb0741f14c80b783fee10235f0b27cf d6b9eef4c7606e9b0e0dff6bea28c7fcc67be818
759040053fb0741f14c80b783fee10235f0b27cf d6b9eef4c7606e9b0e0dff6bea28c7fcc67be818
reprepro_5.2.0.orig.tar.gz reprepro_5.3.0.orig.tar.gz
a1abe4d7993f5ed09933249b2f0a84ce21bf70e6 3b486c23893fedc28c0dbef013ed319624430129
708762 681871
signature:81e2dfc05b59900930cc9a6034958b0811bc0903:924223:reprepro_5.3.0.orig.tar.gz.asc
...@@ -99,7 +99,7 @@ static void description_genmd5(const char *description, /*@out@*/ char *d, size_ ...@@ -99,7 +99,7 @@ static void description_genmd5(const char *description, /*@out@*/ char *d, size_
* the cached description is not yet used, long descriptions are not stored elsewhere * the cached description is not yet used, long descriptions are not stored elsewhere
* and thus also no reference counting is done. */ * and thus also no reference counting is done. */
retvalue description_addpackage(struct target *target, const char *package, const char *control, const char *oldcontrol, struct description *cached, char **control_p) { retvalue description_addpackage(struct target *target, const char *package, const char *control, char **control_p) {
char *description, *description_md5, *deb_description, *newcontrol; char *description, *description_md5, *deb_description, *newcontrol;
struct fieldtoadd *todo; struct fieldtoadd *todo;
size_t dlen; size_t dlen;
...@@ -200,8 +200,3 @@ retvalue description_addpackage(struct target *target, const char *package, cons ...@@ -200,8 +200,3 @@ retvalue description_addpackage(struct target *target, const char *package, cons
*control_p = newcontrol; *control_p = newcontrol;
return RET_OK; return RET_OK;
} }
retvalue description_preparepackage(UNUSED(struct target *target), UNUSED(const char *package), UNUSED(const char *control), UNUSED(struct description **description_p)) {
/* everything yet done in description_addpackage */
return RET_NOTHING;
}
#ifndef REPREPRO_DESCRIPTIONS_H #ifndef REPREPRO_DESCRIPTIONS_H
#define REPREPRO_DESCRIPTIONS_H #define REPREPRO_DESCRIPTIONS_H
struct description;
retvalue description_preparepackage(struct target*, const char */*package*/, const char */*control*/, /*@out@*/struct description**);
/* Do what is needed description/translation wise for a new package added. /* Do what is needed description/translation wise for a new package added.
* control is the control chunk of the new package to be normalized * control is the control chunk of the new package to be normalized
* (depending on the target, towards containing full Description or checksumed), * (depending on the target, towards containing full Description or checksumed),
* oldcontrol is a old version of a package replaced or NULL
* (for repairdescriptions oldcontrol==control).
* newcontrol_p gets the new normalized control chunk. * newcontrol_p gets the new normalized control chunk.
* description is the data returned by a description_prepareaddpackage or NULL
* if that was not yet called
*/ */
retvalue description_addpackage(struct target*, const char */*package*/, const char */*control*/,/*@null@*/const char */*oldcontrol*/, /*@null@*/struct description*, /*@out@*/char **/*newcontrol_p*/); retvalue description_addpackage(struct target*, const char */*package*/, const char */*control*/, /*@out@*/char **/*newcontrol_p*/);
#endif #endif
...@@ -775,10 +775,13 @@ static retvalue candidate_parse(struct incoming *i, struct candidate *c) { ...@@ -775,10 +775,13 @@ static retvalue candidate_parse(struct incoming *i, struct candidate *c) {
r = properversion(c->sourceversion); r = properversion(c->sourceversion);
E("Malforce Source Version number!"); E("Malforce Source Version number!");
} }
r = chunk_getwordlist(c->control, "Binary", &c->binaries);
E("Missing 'Binary' field!");
r = chunk_getwordlist(c->control, "Architecture", &c->architectures); r = chunk_getwordlist(c->control, "Architecture", &c->architectures);
E("Missing 'Architecture' field!"); E("Missing 'Architecture' field!");
r = chunk_getwordlist(c->control, "Binary", &c->binaries);
if (r == RET_NOTHING)
strlist_init(&c->binaries);
else if (RET_WAS_ERROR(r))
return r;
r = chunk_getvalue(c->control, "Version", &c->changesversion); r = chunk_getvalue(c->control, "Version", &c->changesversion);
E("Missing 'Version' field!"); E("Missing 'Version' field!");
r = properversion(c->changesversion); r = properversion(c->changesversion);
...@@ -998,7 +1001,7 @@ static retvalue candidate_read_deb(struct incoming *i, struct candidate *c, stru ...@@ -998,7 +1001,7 @@ static retvalue candidate_read_deb(struct incoming *i, struct candidate *c, stru
char *base; char *base;
const char *packagenametocheck; const char *packagenametocheck;
r = binaries_readdeb(&file->deb, file->tempfilename, true); r = binaries_readdeb(&file->deb, file->tempfilename);
if (RET_WAS_ERROR(r)) if (RET_WAS_ERROR(r))
return r; return r;
if (strcmp(file->name, file->deb.name) != 0) { if (strcmp(file->name, file->deb.name) != 0) {
...@@ -1788,7 +1791,7 @@ static retvalue add_dsc(struct distribution *into, struct trackingdata *tracking ...@@ -1788,7 +1791,7 @@ static retvalue add_dsc(struct distribution *into, struct trackingdata *tracking
&p->filekeys, &p->filekeys,
false, trackingdata, false, trackingdata,
architecture_source, architecture_source,
NULL, NULL, NULL); NULL, NULL);
r2 = target_closepackagesdb(t); r2 = target_closepackagesdb(t);
RET_ENDUPDATE(r, r2); RET_ENDUPDATE(r, r2);
} }
...@@ -2268,7 +2271,7 @@ static retvalue candidate_really_add(struct incoming *i, struct candidate *c) { ...@@ -2268,7 +2271,7 @@ static retvalue candidate_really_add(struct incoming *i, struct candidate *c) {
} else if (d->byhandhookstocall == NULL) } else if (d->byhandhookstocall == NULL)
continue; continue;
logger_logchanges(into->logger, into->codename, logger_logchanges(into->logger, into->codename,
c->source, c->changesversion, c->control, c->source, c->changesversion,
changesfile(c)->tempfilename, changesfilekey); changesfile(c)->tempfilename, changesfilekey);
} }
return RET_OK; return RET_OK;
......
...@@ -672,7 +672,7 @@ static retvalue startchild(void) { ...@@ -672,7 +672,7 @@ static retvalue startchild(void) {
return RET_OK; return RET_OK;
} }
static retvalue notificator_enqueuechanges(struct notificator *n, const char *codename, const char *name, const char *version, const char *changeschunk, const char *safefilename, /*@null@*/const char *filekey) { static retvalue notificator_enqueuechanges(struct notificator *n, const char *codename, const char *name, const char *version, const char *safefilename, /*@null@*/const char *filekey) {
size_t count, i, j; size_t count, i, j;
char **arguments; char **arguments;
struct notification_process *p; struct notification_process *p;
...@@ -744,16 +744,13 @@ static retvalue notificator_enqueuechanges(struct notificator *n, const char *co ...@@ -744,16 +744,13 @@ static retvalue notificator_enqueuechanges(struct notificator *n, const char *co
p->datalen = 0; p->datalen = 0;
p->datasent = 0; p->datasent = 0;
p->