On Wed, 11.02.15 18:27, Zbigniew Jędrzejewski-Szmek (zbys...@in.waw.pl) wrote:
> > > extern char *__xpg_basename (char *__path) __THROW; > > > #define basename __xpg_basename > > > > > > And __xpg_basename is the borked implementation. #undef basename means > > > that > > > we use the GNU version instead. > > > > So, hmm, so if I got this right: > > > > a) The good basame() is in strings.h > > b) The bad basename() is in libgen.h > > c) The only other call in libgen.h is dirname() > > > > Which means, that we only ever need to include libgen.h when we need > > dirname(), and that avery single including of libgen.sh should be > > matched with an "#undef basename"? > > Yes and yes. OK, added one #undef basename now, and documented all this in adjacent comments and in CODING_STYLE, since it's really not obvious... Lennart -- Lennart Poettering, Red Hat _______________________________________________ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel