Gentoo Archives: gentoo-commits

From: Fabian Groffen <grobian@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/portage-utils:master commit in: libq/
Date: Sun, 19 Jan 2020 19:09:18
Message-Id: 1579458649.00e2a72d50acf329a128b81f116e037c82f27c72.grobian@gentoo
1 commit: 00e2a72d50acf329a128b81f116e037c82f27c72
2 Author: Fabian Groffen <grobian <AT> gentoo <DOT> org>
3 AuthorDate: Sun Jan 19 18:30:49 2020 +0000
4 Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org>
5 CommitDate: Sun Jan 19 18:30:49 2020 +0000
6 URL: https://gitweb.gentoo.org/proj/portage-utils.git/commit/?id=00e2a72d
7
8 libq/set: fix Coverity 206548 Sizeof not portable
9
10 Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org>
11
12 libq/set.c | 2 +-
13 1 file changed, 1 insertion(+), 1 deletion(-)
14
15 diff --git a/libq/set.c b/libq/set.c
16 index ceb6f47..88b5876 100644
17 --- a/libq/set.c
18 +++ b/libq/set.c
19 @@ -252,7 +252,7 @@ list_set(set *q, char ***l)
20 set_elem *w;
21 char **ret;
22
23 - ret = *l = xmalloc(sizeof(char **) * (q->len + 1));
24 + ret = *l = xmalloc(sizeof(char *) * (q->len + 1));
25 for (i = 0; i < _SET_HASH_SIZE; i++) {
26 for (w = q->buckets[i]; w != NULL; w = w->next) {
27 *ret = w->name;