Ignore:
Timestamp:
Sep 3, 2008, 12:05:43 AM (17 years ago)
Author:
bird
Message:

kmk_chmod: made it build on solaris (no lchmod or ALLPERMS).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kmk/kmkbuiltin/solfakes.c

    r1246 r1711  
    7474}
    7575
     76
     77
     78int sol_lchmod(const char *pszPath, mode_t mode)
     79{
     80    /*
     81     * Weed out symbolic links.
     82     */
     83    struct stat s;
     84    if (    !lstat(pszPath, &s)
     85        &&  S_ISLNK(s.st_mode))
     86    {
     87        errno = -ENOSYS;
     88        return -1;
     89    }
     90
     91    return chmod(pszPath, mode);
     92}
     93
Note: See TracChangeset for help on using the changeset viewer.