Fix parsing of array overrides

If a depends (makedepends, checkdepends, optdepends, conflicts,
provides, replaces, license, groups, source) line appears in a package
section, it replaces the corresponding array from the pkgbase section.
If there is a single "depends = " line in the package section, the
depends array of that package is considered empty.

This partly reverts the behavior introduced in commit 137a9ae (Fix
parsing of array overrides, 2014-05-03).

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
This commit is contained in:
Lukas Fleischer 2014-05-03 18:01:49 +02:00
parent e161c4f94b
commit 782e9eb188
2 changed files with 12 additions and 5 deletions

View file

@ -135,7 +135,7 @@ if ($uid):
$pkginfo = array();
$section_info = array();
foreach (explode("\n", $srcinfo_raw) as $line) {
$line = trim($line);
$line = ltrim($line);
if (empty($line) || $line[0] == '#') {
continue;
}