X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/526954c5968baa29218c994ec48e476ae2bd4b9f..ad653fa23069c5d9378247084f03c9a718c3ad62:/src/unix/stdpaths.cpp diff --git a/src/unix/stdpaths.cpp b/src/unix/stdpaths.cpp index c26f6d706c..58f8c2c670 100644 --- a/src/unix/stdpaths.cpp +++ b/src/unix/stdpaths.cpp @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////////// -// Name: unix/stdpaths.cpp +// Name: src/unix/stdpaths.cpp // Purpose: wxStandardPaths implementation for Unix & OpenVMS systems // Author: Vadim Zeitlin // Modified by: @@ -122,7 +122,7 @@ wxString wxStandardPaths::GetExecutablePath() const wxString exeStr; char buf[4096]; - int result = readlink("/proc/self/exe", buf, WXSIZEOF(buf) - sizeof(char)); + int result = readlink("/proc/self/exe", buf, WXSIZEOF(buf) - 1); if ( result != -1 ) { buf[result] = '\0'; // readlink() doesn't NUL-terminate the buffer