aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabian Groffen <grobian@gentoo.org>2019-03-09 19:55:47 +0100
committerFabian Groffen <grobian@gentoo.org>2019-03-09 19:58:23 +0100
commitaffdba842a41c49b71911109272186acf36cfd8a (patch)
treed204e4b684260ae6759e06aeb99a96fa3d64a0dd /libq/basename.c
parentrmspace: add copyright (diff)
downloadportage-utils-affdba842a41c49b71911109272186acf36cfd8a.tar.gz
portage-utils-affdba842a41c49b71911109272186acf36cfd8a.tar.bz2
portage-utils-affdba842a41c49b71911109272186acf36cfd8a.zip
libq: introduce set to replace virtuals (queue)
The virtuals file contained some queue functions which actually were list functions. Replaced this with a proper set, which hash backend to speed up many search operations. Changed throughout the code to use more efficient path. While at it, merge xstrdup wrappers in xmalloc, and use wrappers more consistently. Signed-off-by: Fabian Groffen <grobian@gentoo.org>
Diffstat (limited to 'libq/basename.c')
-rw-r--r--libq/basename.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libq/basename.c b/libq/basename.c
index dcf3cceb..2a3b2e6b 100644
--- a/libq/basename.c
+++ b/libq/basename.c
@@ -1,8 +1,9 @@
/*
- * Copyright 2014 Gentoo Foundation
+ * Copyright 2014-2019 Gentoo Foundation
* Distributed under the terms of the GNU General Public License v2
*/
+/* our own basename which does not modify its input */
static const char *_basename(const char *filename)
{
const char *p = strrchr(filename, '/');