test: fix GetCurExecutableDir() on Mac
test: fix GetCurExecutableDir() on Mac

_NSGetExecutablePath(ptr, &size) doesn't change |size|
if the passed buffer is larger than needed. This causes
the returned string to contain stray characters, which then
cause hilarious failures on Mac (the test ends up screwing
up building the cmdline and ends up re-executing itself).

TBR: fmayer
Change-Id: Ie26c19536b794407ab4491466d36e32d79eac145

google/perfetto,google/perfetto,google/perfetto,google/perfetto,google/perfetto,google/perfetto,google/perfetto,google/perfetto