]> git.cameronkatri.com Git - pw-darwin.git/commitdiff
Remove useless calls to basename().
authorEd Schouten <ed@FreeBSD.org>
Sun, 1 May 2016 08:22:11 +0000 (08:22 +0000)
committerEd Schouten <ed@FreeBSD.org>
Sun, 1 May 2016 08:22:11 +0000 (08:22 +0000)
There are a couple of places in the source three where we call
basename() on constant strings. This is bad, because the prototype
standardized by POSIX allows the implementation to use its argument as a
storage buffer.

This change eliminates some of these unportable calls to basename() in
cases where it was only added for cosmetical reasons, namely to trim
argv[0]. There's nothing wrong with setting argv[0] to the full path.

Reviewed by: jilles
Differential Revision: https://reviews.freebsd.org/D6093


No differences found