the problem occours only with solaris 9 gcc version 2.95.3 20010315 not with solaris 10 - higher gcc versions the following patch resolves the problem *** system.c_orig Thu Nov 15 04:15:03 2007 --- system.c Fri Dec 14 11:45:46 2007 *************** *** 2161,2169 **** #elif defined(HAVE_ATTROPEN) int ret = -1; int myflags = O_RDWR; if (flags & XATTR_CREATE) myflags |= O_EXCL; if (!(flags & XATTR_REPLACE)) myflags |= O_CREAT; ! int attrfd = solaris_attropen(path, name, myflags, (mode_t) SOLARIS_ATTRMODE); if (attrfd >= 0) { ret = solaris_write_xattr(attrfd, value, size); close(attrfd); --- 2161,2170 ---- #elif defined(HAVE_ATTROPEN) int ret = -1; int myflags = O_RDWR; + int attrfd ; if (flags & XATTR_CREATE) myflags |= O_EXCL; if (!(flags & XATTR_REPLACE)) myflags |= O_CREAT; ! attrfd = solaris_attropen(path, name, myflags, (mode_t) SOLARIS_ATTRMODE); if (attrfd >= 0) { ret = solaris_write_xattr(attrfd, value, size); close(attrfd); *************** *** 2224,2232 **** #elif defined(HAVE_ATTROPEN) int ret = -1; int myflags = O_RDWR | AT_SYMLINK_NOFOLLOW; if (flags & XATTR_CREATE) myflags |= O_EXCL; if (!(flags & XATTR_REPLACE)) myflags |= O_CREAT; ! int attrfd = solaris_attropen(path, name, myflags, (mode_t) SOLARIS_ATTRMODE); if (attrfd >= 0) { ret = solaris_write_xattr(attrfd, value, size); close(attrfd); --- 2225,2234 ---- #elif defined(HAVE_ATTROPEN) int ret = -1; int myflags = O_RDWR | AT_SYMLINK_NOFOLLOW; + int attrfd ; if (flags & XATTR_CREATE) myflags |= O_EXCL; if (!(flags & XATTR_REPLACE)) myflags |= O_CREAT; ! attrfd = solaris_attropen(path, name, myflags, (mode_t) SOLARIS_ATTRMODE); if (attrfd >= 0) { ret = solaris_write_xattr(attrfd, value, size); close(attrfd); *************** *** 2288,2296 **** #elif defined(HAVE_ATTROPEN) int ret = -1; int myflags = O_RDWR | O_XATTR; if (flags & XATTR_CREATE) myflags |= O_EXCL; if (!(flags & XATTR_REPLACE)) myflags |= O_CREAT; ! int attrfd = solaris_openat(filedes, name, myflags, (mode_t) SOLARIS_ATTRMODE); if (attrfd >= 0) { ret = solaris_write_xattr(attrfd, value, size); close(attrfd); --- 2290,2299 ---- #elif defined(HAVE_ATTROPEN) int ret = -1; int myflags = O_RDWR | O_XATTR; + int attrfd ; if (flags & XATTR_CREATE) myflags |= O_EXCL; if (!(flags & XATTR_REPLACE)) myflags |= O_CREAT; ! attrfd = solaris_openat(filedes, name, myflags, (mode_t) SOLARIS_ATTRMODE); if (attrfd >= 0) { ret = solaris_write_xattr(attrfd, value, size); close(attrfd);
Applied for 3.0.28a. Thanks. Jeremy.