aboutsummaryrefslogtreecommitdiff
blob: dcf3cceb76a2cf6cc7f4cc3a81c6abb2ff3ca207 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/*
 * Copyright 2014 Gentoo Foundation
 * Distributed under the terms of the GNU General Public License v2
 */

static const char *_basename(const char *filename)
{
	const char *p = strrchr(filename, '/');
	return p ? p + 1 : filename;
}

/* Avoid issues with clobbering C library def */
#undef basename
#define basename(x) _basename(x)