Update to 0.7.3

Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
This commit is contained in:
Igor Gnatenko 2019-01-30 18:24:32 +01:00
parent 554118dd97
commit 0617b0ce5f
No known key found for this signature in database
GPG Key ID: 695714BD1BBC5F4C
7 changed files with 7 additions and 148 deletions

1
.gitignore vendored
View File

@ -45,3 +45,4 @@
/libsolv-0.7.0.tar.gz /libsolv-0.7.0.tar.gz
/libsolv-0.7.1.tar.gz /libsolv-0.7.1.tar.gz
/libsolv-0.7.2.tar.gz /libsolv-0.7.2.tar.gz
/libsolv-0.7.3.tar.gz

View File

@ -1,46 +0,0 @@
From 5323eb7e5c0c8dcdf339113f091317afaed810cc Mon Sep 17 00:00:00 2001
From: Michael Schroeder <mls@suse.de>
Date: Tue, 15 Jan 2019 14:06:08 +0100
Subject: [PATCH] Do not disable infarch rules when they don't conflict with the job
---
src/rules.c | 16 +++++++++++++---
1 file changed, 13 insertions(+), 3 deletions(-)
diff --git a/src/rules.c b/src/rules.c
index 2087b35..175cb8d 100644
--- a/src/rules.c
+++ b/src/rules.c
@@ -2126,7 +2126,13 @@ jobtodisablelist(Solver *solv, Id how, Id what, Queue *q)
if ((set & SOLVER_SETARCH) != 0 && solv->infarchrules != solv->infarchrules_end)
{
if (select == SOLVER_SOLVABLE)
- queue_push2(q, DISABLE_INFARCH, pool->solvables[what].name);
+ {
+ for (i = solv->infarchrules; i < solv->infarchrules_end; i++)
+ if (solv->rules[i].p == -what)
+ break;
+ if (i < solv->infarchrules_end)
+ queue_push2(q, DISABLE_INFARCH, pool->solvables[what].name);
+ }
else
{
int qcnt = q->count;
@@ -2140,8 +2146,12 @@ jobtodisablelist(Solver *solv, Id how, Id what, Queue *q)
if (q->elements[i + 1] == s->name)
break;
if (i < q->count)
- continue;
- queue_push2(q, DISABLE_INFARCH, s->name);
+ continue; /* already have that DISABLE_INFARCH element */
+ for (i = solv->infarchrules; i < solv->infarchrules_end; i++)
+ if (solv->rules[i].p == -p)
+ break;
+ if (i < solv->infarchrules_end)
+ queue_push2(q, DISABLE_INFARCH, s->name);
}
}
}
--
libgit2 0.27.7

View File

@ -1,25 +0,0 @@
From c5883b20b7b021ee94111cb72777ab3ba3f50950 Mon Sep 17 00:00:00 2001
From: Jaroslav Rohel <jrohel@redhat.com>
Date: Fri, 7 Dec 2018 07:05:10 +0100
Subject: [PATCH] Fix: Dereference of null pointer
---
ext/repo_repomdxml.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ext/repo_repomdxml.c b/ext/repo_repomdxml.c
index fd46272b..46d83615 100644
--- a/ext/repo_repomdxml.c
+++ b/ext/repo_repomdxml.c
@@ -181,7 +181,7 @@ startElement(struct solv_xmlparser *xmlp, int state, const char *name, const cha
while (value)
{
char *p = strchr(value, ',');
- if (*p)
+ if (p)
*p++ = 0;
if (*value)
repodata_add_poolstr_array(pd->data, SOLVID_META, REPOSITORY_UPDATES, value);
--
2.20.1

View File

@ -1,32 +0,0 @@
From 95c3d1b3aad7a003d129b957cf449d11edaca67b Mon Sep 17 00:00:00 2001
From: Jaroslav Rohel <jrohel@redhat.com>
Date: Tue, 11 Dec 2018 10:22:09 +0100
Subject: [PATCH] Fix: testsolv segfault
ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7fab0e11bf2b bp 0x7ffdfc044b70 sp 0x7ffdfc044a90 T0)
0 0x7fab0e11bf2a in testcase_str2dep_complex /home/company/real_sanitize/libsolv-master/ext/testcase.c:577
1 0x7fab0e11c80f in testcase_str2dep /home/company/real_sanitize/libsolv-master/ext/testcase.c:656
2 0x7fab0e12e64a in testcase_read /home/company/real_sanitize/libsolv-master/ext/testcase.c:2952
3 0x402aa5 in main /home/company/real_sanitize/libsolv-master/tools/testsolv.c:148
4 0x7fab0d9d2a3f in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x20a3f)
5 0x401bb8 in _start (/home/company/real_sanitize/libsolv-master/build/install/bin/testsolv+0x401bb8)
---
ext/testcase.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/ext/testcase.c b/ext/testcase.c
index 33998d47..fe2636cb 100644
--- a/ext/testcase.c
+++ b/ext/testcase.c
@@ -576,6 +576,8 @@ testcase_str2dep_complex(Pool *pool, const char **sp, int relop)
Id flags, id, id2, namespaceid = 0;
struct oplist *op;
+ if (!s)
+ return 0;
while (*s == ' ' || *s == '\t')
s++;
if (!strncmp(s, "namespace:", 10))
--
2.20.1

View File

@ -1,38 +0,0 @@
From 6de825c4d27022e48570824f0be77132c5b6d45a Mon Sep 17 00:00:00 2001
From: Jaroslav Rohel <jrohel@redhat.com>
Date: Tue, 11 Dec 2018 10:27:15 +0100
Subject: [PATCH] Fix: testsolv segfaults
ERROR: AddressSanitizer: SEGV on unknown address 0x0000000002f0 (pc 0x7f31501d3bd2 bp 0x7ffcfe4d4a50 sp 0x7ffcfe4d4a30 T0)
0 0x7f31501d3bd1 in pool_whatprovides /home/company/real_sanitize/libsolv-master/src/pool.h:331
1 0x7f31501d895e in testcase_str2solvid /home/company/real_sanitize/libsolv-master/ext/testcase.c:793
2 0x7f31501e8388 in testcase_read /home/company/real_sanitize/libsolv-master/ext/testcase.c:2807
3 0x402aa5 in main /home/company/real_sanitize/libsolv-master/tools/testsolv.c:148
4 0x7f314fa8da3f in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x20a3f)
5 0x401bb8 in _start (/home/company/real_sanitize/libsolv-master/build/install/bin/testsolv+0x401bb8)
ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7f5af9e7815f bp 0x7ffc4c843a40 sp 0x7ffc4c8436c0 T0)
0 0x7f5af9e7815e in testcase_read /home/company/real_sanitize/libsolv-master/ext/testcase.c:2799
1 0x402aa5 in main /home/company/real_sanitize/libsolv-master/tools/testsolv.c:148
2 0x7f5af971da3f in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x20a3f)
3 0x401bb8 in _start (/home/company/real_sanitize/libsolv-master/build/install/bin/testsolv+0x401bb8)
---
ext/testcase.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ext/testcase.c b/ext/testcase.c
index fe2636cb..c8dd14ee 100644
--- a/ext/testcase.c
+++ b/ext/testcase.c
@@ -2795,7 +2795,7 @@ testcase_read(Pool *pool, FILE *fp, const char *testcase, Queue *job, char **res
{
int i = strlen(pieces[1]);
s = strchr(pieces[1], '(');
- if (!s && pieces[1][i - 1] != ')')
+ if (!s || pieces[1][i - 1] != ')')
{
pool_error(pool, 0, "testcase_read: bad namespace '%s'", pieces[1]);
}
--
2.20.1

View File

@ -39,17 +39,13 @@
%endif %endif
Name: lib%{libname} Name: lib%{libname}
Version: 0.7.2 Version: 0.7.3
Release: 3%{?dist} Release: 1%{?dist}
Summary: Package dependency solver Summary: Package dependency solver
License: BSD License: BSD
URL: https://github.com/openSUSE/libsolv URL: https://github.com/openSUSE/libsolv
Source: %{url}/archive/%{version}/%{name}-%{version}.tar.gz Source: %{url}/archive/%{version}/%{name}-%{version}.tar.gz
Patch0001: 0001-Fix-Dereference-of-null-pointer.patch
Patch0002: 0001-Fix-testsolv-segfault.patch
Patch0003: 0001-Fix-testsolv-segfaults.patch
Patch0004: 0001-Do-not-disable-infarch-rules-when-they-dont-conflict-with-the-job.patch
BuildRequires: cmake BuildRequires: cmake
BuildRequires: gcc-c++ BuildRequires: gcc-c++
@ -292,6 +288,9 @@ Python 3 version.
%endif %endif
%changelog %changelog
* Wed Jan 30 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.7.3-1
- Update to 0.7.3
* Tue Jan 15 2019 Jaroslav Mracek <jmracek@redhat.com> - 0.7.2-2 * Tue Jan 15 2019 Jaroslav Mracek <jmracek@redhat.com> - 0.7.2-2
- Backport Do-not-disable-infarch-rules-when-they-dont-conflict-with-the-job - Backport Do-not-disable-infarch-rules-when-they-dont-conflict-with-the-job

View File

@ -1 +1 @@
SHA512 (libsolv-0.7.2.tar.gz) = 4b61e63ffa71305cbbcbdb50f178fbfbf0ac6bf23f4def60221665129b75e7c4b63c48164398635a05ae17e99974b908c6db739c21625aa6946924dd81734e63 SHA512 (libsolv-0.7.3.tar.gz) = 7e2864265636c00340d1d4c4d3a53a22638d43681c8239e61f8848c9bf217fb14b46de449e720707965f8da39fb1cbe0f629898ca9b970d5b18b792bf6158343