VirtualBox

Ignore:
Timestamp:
Jul 26, 2007 4:26:39 PM (18 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
23258
Message:

Solaris.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/r3/posix/process-posix.cpp

    r3672 r3888  
    237237     * files and code for this.
    238238     */
    239 #if defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD)
     239#if defined(RT_OS_LINUX) || defined(RT_OS_FREEBSD) || defined(RT_OS_SOLARIS)
    240240# ifdef RT_OS_LINUX
    241241    int cchLink = readlink("/proc/self/exe", pszExecName, cchExecName - 1);
    242 # else   
     242# elif defined(RT_OS_SOLARIS)
     243    char szFileBuf[80];
     244    RTStrPrintf(szFileBuf, sizeof(szFileBuf), "/proc/%ld/path/a.out", (long)getpid());
     245    int cchLink = readlink(szFileBuf, pszExecName, cchExecName - 1);
     246# else
    243247    int cchLink = readlink("/proc/curproc/file", pszExecName, cchExecName - 1);
    244 # endif   
     248# endif
    245249    if (cchLink > 0 && (size_t)cchLink <= cchExecName - 1)
    246250    {
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette