Ticket #64021: libclamav-others_common.c-O_SYMLINK@Tiger.patch

File libclamav-others_common.c-O_SYMLINK@Tiger.patch, 711 bytes (added by ballapete (Peter "Pete" Dyballa), 3 years ago)

Patch for Tiger, fits into "platform darwin 8" clause

  • libclamav/others_common.

    old new  
    14991499       Plus, we probably don't wan tot follow the link in this case anyways,
    15001500       so this will check the realpath of the link, and not of the thing the
    15011501       link points to. */
     1502#if (__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1050)
     1503    if(S_ISLNK(*file_name) | S_ISREG(*file_name)) {
     1504      fd = open(file_name, O_RDONLY);
     1505    }
     1506#else
    15021507    fd = open(file_name, O_RDONLY | O_SYMLINK);
     1508#endif  /* Tiger workaround for missing O_SYMLINK macro */
    15031509    if (fd == -1) {
    15041510        char err[128];
    15051511        cli_strerror(errno, err, sizeof(err));