From: Ralph Boehme Date: Tue, 2 Apr 2013 16:13:43 +0000 (+0200) Subject: Merge remote-tracking branch 'origin/develop' into spotlight X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?p=netatalk.git;a=commitdiff_plain;h=82195e48bedce7bf1e214679c3cceb0cb33845eb;hp=b3aa86438c224bc7fea23a4b096de476f425ed90 Merge remote-tracking branch 'origin/develop' into spotlight Conflicts: VERSION --- diff --git a/NEWS b/NEWS index 5456a411..5d6ff9cf 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,9 @@ +Changes in 3.0.4 +================ +* FIX: Opening files without metadata EA may result in an invalid + metadata EA. Check for malformed metadata EAs and delete them. + Fixes bug #510. + Changes in 3.0.3 ================ * UPD: afpd: Increase default DSI server quantum to 1 MB @@ -21,6 +27,7 @@ Changes in 3.0.3 system security configuration files. New option 'afpstats' (default: no) which determines whether to enable the feature or not. +* NEW: configure option --with-init-dir * NEW: dtrace probes, cf include/atalk/afp_dtrace.d for available probes. * UPD: Reload groups when reloading volumes. FR #71. @@ -35,6 +42,16 @@ Changes in 3.0.3 * FIX: Permissions of ._ AppleDouble ressource fork after conversion from v2 to ea. Fixes bug #505. +* UPD: Use FreeBSD sendfile() capability to send protocol header. + From FR #75. +* UPD: Increase IO size when sendfile() is not used. + From FR #76. +* FIX: Can't set Finder label on symlinked folder with "follow symlinks = yes". + Fixes bug #508. +* FIX: Setting POSIX ACLs on Linux + Fixes bug #506. +* FIX: "ad ls" segfault if requested object is not in an AFP volume. + Fixes bug #496. Changes in 3.0.2 ================ diff --git a/bin/ad/ad_ls.c b/bin/ad/ad_ls.c index d8362595..b5947e17 100644 --- a/bin/ad/ad_ls.c +++ b/bin/ad/ad_ls.c @@ -227,7 +227,7 @@ static void print_flags(char *path, afpvol_t *vol, const struct stat *st) if (S_ISDIR(st->st_mode)) adflags = ADFLAGS_DIR; - if (vol->vol->v_path == NULL) + if (vol->vol == NULL || vol->vol->v_path == NULL) return; ad_init(&ad, vol->vol); diff --git a/bin/ad/ad_util.c b/bin/ad/ad_util.c index 135bf7ab..a168eed8 100644 --- a/bin/ad/ad_util.c +++ b/bin/ad/ad_util.c @@ -138,9 +138,11 @@ int openvol(AFPObj *obj, const char *path, afpvol_t *vol) void closevol(afpvol_t *vol) { - if (vol->vol->v_cdb) { - cnid_close(vol->vol->v_cdb); - vol->vol->v_cdb = NULL; + if (vol->vol) { + if (vol->vol->v_cdb) { + cnid_close(vol->vol->v_cdb); + vol->vol->v_cdb = NULL; + } } memset(vol, 0, sizeof(afpvol_t)); } diff --git a/distrib/initscripts/Makefile.am b/distrib/initscripts/Makefile.am index 2d1cb3ab..79dcfb3f 100644 --- a/distrib/initscripts/Makefile.am +++ b/distrib/initscripts/Makefile.am @@ -54,7 +54,7 @@ uninstall: uninstall-startup if USE_REDHAT_SYSV -sysvdir = /etc/rc.d/init.d +sysvdir = $(INIT_DIR) sysv_SCRIPTS = netatalk $(sysv_SCRIPTS): rc.redhat @@ -76,7 +76,7 @@ endif if USE_SYSTEMD -servicedir = /lib/systemd/system +servicedir = $(INIT_DIR) service_DATA = netatalk.service netatalk.service: service.systemd @@ -98,7 +98,7 @@ endif if USE_SUSE_SYSV -sysvdir = /etc/init.d +sysvdir = $(INIT_DIR) sysv_SCRIPTS = netatalk $(sysv_SCRIPTS): rc.suse @@ -120,7 +120,7 @@ endif if USE_NETBSD -sysvdir = /etc/rc.d +sysvdir = $(INIT_DIR) sysv_SCRIPTS = netatalk netatalk: rc.netbsd @@ -141,7 +141,7 @@ endif if USE_SOLARIS -servicedir = /lib/svc/manifest/network/ +servicedir = $(INIT_DIR) service_DATA = netatalk.xml install-data-hook: @@ -158,7 +158,7 @@ endif if USE_GENTOO -sysvdir = /etc/init.d +sysvdir = $(INIT_DIR) sysv_SCRIPTS = netatalk $(sysv_SCRIPTS): rc.gentoo @@ -180,7 +180,7 @@ endif if USE_DEBIAN -sysvdir = /etc/init.d +sysvdir = $(INIT_DIR) sysv_SCRIPTS = netatalk $(sysv_SCRIPTS): rc.debian diff --git a/etc/afpd/acls.c b/etc/afpd/acls.c index 56ffeea9..6f2abdf3 100644 --- a/etc/afpd/acls.c +++ b/etc/afpd/acls.c @@ -1157,17 +1157,21 @@ static int set_acl(const struct vol *vol, } LOG(log_debug7, logtype_afpd, "set_acl: copied %d trivial ACEs", trivial_ace_count); - /* Ressourcefork first. - Note: for dirs we set the same ACL on the .AppleDouble/.Parent _file_. This - might be strange for ACE_DELETE_CHILD and for inheritance flags. */ + /* Ressourcefork first */ if ((ret = (vol->vfs->vfs_acl(vol, name, ACE_SETACL, new_aces_count, new_aces))) != 0) { - LOG(log_error, logtype_afpd, "set_acl: error setting acl: %s", strerror(errno)); - if (errno == (EACCES | EPERM)) + LOG(log_debug, logtype_afpd, "set_acl: error setting acl: %s", strerror(errno)); + switch (errno) { + case EACCES: + case EPERM: EC_STATUS(AFPERR_ACCESS); - else if (errno == ENOENT) - EC_STATUS(AFPERR_NOITEM); - else + break; + case ENOENT: + EC_STATUS(AFP_OK); + break; + default: EC_STATUS(AFPERR_MISC); + break; + } goto EC_CLEANUP; } if ((ret = (acl(name, ACE_SETACL, new_aces_count, new_aces))) != 0) { diff --git a/etc/afpd/filedir.c b/etc/afpd/filedir.c index c349f532..8feac755 100644 --- a/etc/afpd/filedir.c +++ b/etc/afpd/filedir.c @@ -265,7 +265,7 @@ static int moveandrename(struct vol *vol, #ifdef HAVE_ATFUNCS opened = of_findnameat(sdir_fd, &path); #else - opened = of_findname(&path); + opened = of_findname(vol, &path); #endif /* HAVE_ATFUNCS */ if (opened) { diff --git a/etc/afpd/fork.c b/etc/afpd/fork.c index 7f5487ee..0d050b32 100644 --- a/etc/afpd/fork.c +++ b/etc/afpd/fork.c @@ -386,6 +386,16 @@ int afp_openfork(AFPObj *obj _U_, char *ibuf, size_t ibuflen _U_, char *rbuf, si if (ad_open(ofork->of_ad, upath, adflags, 0666) == 0) { ofork->of_flags |= AFPFORK_META; + if (ad_get_MD_flags(ofork->of_ad) & O_CREAT) { + LOG(log_debug, logtype_afpd, "afp_openfork(\"%s\"): setting CNID", upath); + cnid_t id; + if ((id = get_id(vol, ofork->of_ad, st, dir->d_did, upath, strlen(upath))) == CNID_INVALID) { + LOG(log_error, logtype_afpd, "afp_createfile(\"%s\"): CNID error", upath); + goto openfork_err; + } + (void)ad_setid(ofork->of_ad, st->st_dev, st->st_ino, id, dir->d_did, vol->v_stamp); + ad_flush(ofork->of_ad); + } } else { switch (errno) { case EACCES: @@ -798,7 +808,7 @@ static int read_fork(AFPObj *obj, char *ibuf, size_t ibuflen _U_, char *rbuf, si "afp_read(fork: %" PRIu16 " [%s], off: %" PRIu64 ", len: %" PRIu64 ", size: %" PRIu64 ")", ofork->of_refnum, (ofork->of_flags & AFPFORK_DATA) ? "data" : "reso", offset, reqcount, size); - if (offset > size) { + if (offset >= size) { err = AFPERR_EOF; goto afp_read_err; } @@ -837,11 +847,13 @@ static int read_fork(AFPObj *obj, char *ibuf, size_t ibuflen _U_, char *rbuf, si } #endif - *rbuflen = MIN(reqcount, *rbuflen); + *rbuflen = MIN(reqcount, dsi->server_quantum); - err = read_file(ofork, eid, offset, rbuf, rbuflen); - if (err < 0) + cc = read_file(ofork, eid, offset, ibuf, rbuflen); + if (cc < 0) { + err = cc; goto afp_read_done; + } LOG(log_debug, logtype_afpd, "afp_read(name: \"%s\", offset: %jd, reqcount: %jd): got %jd bytes from file", @@ -854,18 +866,22 @@ static int read_fork(AFPObj *obj, char *ibuf, size_t ibuflen _U_, char *rbuf, si * we know that we're sending some data. if we fail, something * horrible happened. */ - if ((cc = dsi_readinit(dsi, rbuf, *rbuflen, reqcount, err)) < 0) + if ((cc = dsi_readinit(dsi, ibuf, *rbuflen, reqcount, err)) < 0) goto afp_read_exit; *rbuflen = cc; while (*rbuflen > 0) { - cc = read_file(ofork, eid, offset, rbuf, rbuflen); + /* + * This loop isn't really entered anymore, we've already + * sent the whole requested block in dsi_readinit(). + */ + cc = read_file(ofork, eid, offset, ibuf, rbuflen); if (cc < 0) goto afp_read_exit; offset += *rbuflen; /* dsi_read() also returns buffer size of next allocation */ - cc = dsi_read(dsi, rbuf, *rbuflen); /* send it off */ + cc = dsi_read(dsi, ibuf, *rbuflen); /* send it off */ if (cc < 0) goto afp_read_exit; *rbuflen = cc; diff --git a/libatalk/Makefile.am b/libatalk/Makefile.am index 4ad799bf..8254e579 100644 --- a/libatalk/Makefile.am +++ b/libatalk/Makefile.am @@ -18,7 +18,7 @@ # current+1:0:0 # -VERSION_INFO = 3:0:0 +VERSION_INFO = 4:0:0 # History: VERSION_INFO # @@ -30,6 +30,7 @@ VERSION_INFO = 3:0:0 # 3.0 1:0:0 # 3.0.1 2:0:0 # 3.0.2 3:0:0 +# 3.0.3 4:0:0 SUBDIRS = acl adouble bstring compat cnid dsi iniparser talloc tdb util unicode vfs @@ -96,4 +97,5 @@ EXTRA_DIST = \ libatalk-3.0beta2.abi \ libatalk-3.0.abi \ libatalk-3.0.1.abi \ - libatalk-3.0.2.abi + libatalk-3.0.2.abi \ + libatalk-3.0.3.abi diff --git a/libatalk/acl/uuid.c b/libatalk/acl/uuid.c index c1bc065f..ff58c3dd 100644 --- a/libatalk/acl/uuid.c +++ b/libatalk/acl/uuid.c @@ -254,6 +254,7 @@ int getnamefromuuid(const uuidp_t uuidp, char **name, uuidtype_t *type) { uid = ntohl(tmp); if ((pwd = getpwuid(uid)) == NULL) { /* not found, add negative entry to cache */ + *name = NULL; add_cachebyuuid(uuidp, "UUID_ENOENT", UUID_ENOENT, 0); ret = -1; } else { @@ -263,7 +264,7 @@ int getnamefromuuid(const uuidp_t uuidp, char **name, uuidtype_t *type) { } LOG(log_debug, logtype_afpd, "getnamefromuuid{local}: UUID: %s -> name: %s, type:%s", - uuid_bin2string(uuidp), *name, uuidtype[(*type) & UUIDTYPESTR_MASK]); + uuid_bin2string(uuidp), *name ? *name : "-", uuidtype[(*type) & UUIDTYPESTR_MASK]); return ret; } else if (memcmp(uuidp, local_group_uuid, 12) == 0) { *type = UUID_GROUP; diff --git a/libatalk/adouble/ad_open.c b/libatalk/adouble/ad_open.c index 4e1253d1..12250055 100644 --- a/libatalk/adouble/ad_open.c +++ b/libatalk/adouble/ad_open.c @@ -616,6 +616,7 @@ EC_CLEANUP: static int ad_header_read_ea(const char *path, struct adouble *ad, const struct stat *hst _U_) { + EC_INIT; uint16_t nentries; int len; ssize_t header_len; @@ -624,16 +625,16 @@ static int ad_header_read_ea(const char *path, struct adouble *ad, const struct if (ad_meta_fileno(ad) != -1) header_len = sys_fgetxattr(ad_meta_fileno(ad), AD_EA_META, ad->ad_data, AD_DATASZ_EA); else - header_len = sys_lgetxattr(path, AD_EA_META, ad->ad_data, AD_DATASZ_EA); - if (header_len < 1) { + header_len = sys_getxattr(path, AD_EA_META, ad->ad_data, AD_DATASZ_EA); + if (header_len < 1) { LOG(log_debug, logtype_ad, "ad_header_read_ea: %s", strerror(errno)); - return -1; + EC_FAIL; } - if (header_len < AD_HEADER_LEN) { - LOG(log_error, logtype_ad, "ad_header_read_ea(\"%s\"): bogus AppleDouble header.", fullpathname(path)); - errno = EIO; - return -1; + if (header_len < AD_DATASZ_EA) { + LOG(log_error, logtype_ad, "ad_header_read_ea(\"%s\"): short metadata EA", fullpathname(path)); + errno = EINVAL; + EC_FAIL; } memcpy(&ad->ad_magic, buf, sizeof( ad->ad_magic )); @@ -644,28 +645,44 @@ static int ad_header_read_ea(const char *path, struct adouble *ad, const struct if ((ad->ad_magic != AD_MAGIC) || (ad->ad_version != AD_VERSION2)) { LOG(log_error, logtype_ad, "ad_header_read_ea(\"%s\"): wrong magic or version", fullpathname(path)); - errno = EIO; - return -1; + errno = EINVAL; + EC_FAIL; } memcpy(&nentries, buf + ADEDOFF_NENTRIES, sizeof( nentries )); nentries = ntohs( nentries ); - - /* Protect against bogus nentries */ - len = nentries * AD_ENTRY_LEN; - if (len + AD_HEADER_LEN > sizeof(ad->ad_data)) - len = sizeof(ad->ad_data) - AD_HEADER_LEN; - if (len > header_len - AD_HEADER_LEN) { - LOG(log_error, logtype_ad, "ad_header_read_ea(\"%s\"): can't read entry info.", fullpathname(path)); - errno = EIO; - return -1; + if (nentries != ADEID_NUM_EA) { + LOG(log_error, logtype_ad, "ad_header_read_ea(\"%s\"): invalid number of entries: %d", fullpathname(path), nentries); + errno = EINVAL; + EC_FAIL; } - nentries = len / AD_ENTRY_LEN; /* Now parse entries */ parse_entries(ad, buf + AD_HEADER_LEN, nentries); - return 0; + if (nentries != ADEID_NUM_EA + || !ad_entry(ad, ADEID_FINDERI) + || !ad_entry(ad, ADEID_COMMENT) + || !ad_entry(ad, ADEID_FILEDATESI) + || !ad_entry(ad, ADEID_AFPFILEI) + || !ad_entry(ad, ADEID_PRIVDEV) + || !ad_entry(ad, ADEID_PRIVINO) + || !ad_entry(ad, ADEID_PRIVSYN) + || !ad_entry(ad, ADEID_PRIVID)) { + LOG(log_error, logtype_ad, "ad_header_read_ea(\"%s\"): invalid metadata EA", fullpathname(path)); + errno = EINVAL; + EC_FAIL; + } + +EC_CLEANUP: + if (ret != 0 && errno == EINVAL) { + become_root(); + (void)sys_removexattr(path, AD_EA_META); + unbecome_root(); + LOG(log_error, logtype_ad, "ad_header_read_ea(\"%s\"): deleted invalid metadata EA", fullpathname(path), nentries); + errno = ENOENT; + } + EC_EXIT; } /*! @@ -1131,7 +1148,7 @@ static int ad_open_hf(const char *path, int adflags, int mode, struct adouble *a { int ret = 0; - memset(ad->ad_eid, 0, sizeof( ad->ad_eid )); + ad->ad_meta_refcount++; switch (ad->ad_vers) { case AD_VERSION2: @@ -1145,10 +1162,10 @@ static int ad_open_hf(const char *path, int adflags, int mode, struct adouble *a break; } - if (ret == 0) - ad->ad_meta_refcount++; - else + if (ret != 0) { + ad->ad_meta_refcount--; ret = ad_error(ad, adflags); + } return ret; } @@ -1242,6 +1259,7 @@ static int ad_open_rf_ea(const char *path, int adflags, int mode, struct adouble EC_FAIL; } ad->ad_rfp->adf_flags &= ~( O_TRUNC | O_CREAT ); + ad->ad_reso_refcount++; ad->ad_rfp->adf_refcount++; EC_NEG1_LOG( ad->ad_rlen = ad_reso_size(path, adflags, ad)); goto EC_CLEANUP; diff --git a/libatalk/dsi/dsi_stream.c b/libatalk/dsi/dsi_stream.c index da58f87c..05c36fc8 100644 --- a/libatalk/dsi/dsi_stream.c +++ b/libatalk/dsi/dsi_stream.c @@ -344,6 +344,16 @@ ssize_t dsi_stream_read_file(DSI *dsi, const int fromfd, off_t offset, const siz int sfvcnt; struct sendfilevec vec[2]; ssize_t nwritten; +#elif defined(FREEBSD) + ssize_t nwritten; + void *hdrp; + struct sf_hdtr hdr; + struct iovec iovec; + hdr.headers = &iovec; + hdr.hdr_cnt = 1; + hdr.trailers = NULL; + hdr.trl_cnt = 0; + hdrp = &hdr; #endif LOG(log_maxdebug, logtype_dsi, "dsi_stream_read_file(off: %jd, len: %zu)", (intmax_t)offset, length); @@ -372,6 +382,9 @@ ssize_t dsi_stream_read_file(DSI *dsi, const int fromfd, off_t offset, const siz vec[1].sfv_flag = 0; vec[1].sfv_off = offset; vec[1].sfv_len = length; +#elif defined(FREEBSD) + iovec.iov_base = block; + iovec.iov_len = DSI_BLOCKSIZ; #else dsi_stream_write(dsi, block, sizeof(block), DSI_MSG_MORE); #endif @@ -380,6 +393,10 @@ ssize_t dsi_stream_read_file(DSI *dsi, const int fromfd, off_t offset, const siz #ifdef HAVE_SENDFILEV nwritten = 0; len = sendfilev(dsi->socket, vec, sfvcnt, &nwritten); +#elif defined(FREEBSD) + len = sendfile(fromfd, dsi->socket, pos, total - written, hdrp, &nwritten, 0); + if (len == 0) + len = nwritten; #else len = sys_sendfile(dsi->socket, fromfd, &pos, total - written); #endif @@ -388,16 +405,14 @@ ssize_t dsi_stream_read_file(DSI *dsi, const int fromfd, off_t offset, const siz case EINTR: case EAGAIN: len = 0; -#ifdef HAVE_SENDFILEV +#if defined(HAVE_SENDFILEV) || defined(FREEBSD) len = (size_t)nwritten; -#else -#if defined(SOLARIS) || defined(FREEBSD) +#elif defined(SOLARIS) if (pos > offset) { /* we actually have sent sth., adjust counters and keep trying */ len = pos - offset; offset = pos; } -#endif /* defined(SOLARIS) || defined(FREEBSD) */ #endif /* HAVE_SENDFILEV */ if (dsi_peek(dsi) != 0) { @@ -426,6 +441,18 @@ ssize_t dsi_stream_read_file(DSI *dsi, const int fromfd, off_t offset, const siz vec[0].sfv_off += len; vec[0].sfv_len -= len; } +#elif defined(FREEBSD) + if (hdrp) { + if (len >= iovec.iov_len) { + hdrp = NULL; + len -= iovec.iov_len; /* len now contains how much sendfile() actually sent from the file */ + } else { + iovec.iov_len -= len; + iovec.iov_base += len; + len = 0; + } + } + pos += len; #endif /* HAVE_SENDFILEV */ LOG(log_maxdebug, logtype_dsi, "dsi_stream_read_file: wrote: %zd", len); written += len; @@ -496,6 +523,7 @@ int dsi_stream_send(DSI *dsi, void *buf, size_t length) { char block[DSI_BLOCKSIZ]; struct iovec iov[2]; + int iovecs = 2; size_t towrite; ssize_t len; @@ -522,7 +550,7 @@ int dsi_stream_send(DSI *dsi, void *buf, size_t length) towrite = sizeof(block) + length; dsi->write_count += towrite; while (towrite > 0) { - if (((len = writev(dsi->socket, iov, 2)) == -1 && errno == EINTR) || (len == 0)) + if (((len = writev(dsi->socket, iov, iovecs)) == -1 && errno == EINTR) || (len == 0)) continue; if ((size_t)len == towrite) /* wrote everything out */ @@ -543,12 +571,13 @@ int dsi_stream_send(DSI *dsi, void *buf, size_t length) iov[0].iov_base = (char *) iov[0].iov_base + len; iov[0].iov_len -= len; } else { /* skip to data */ - if (iov[0].iov_len) { + if (iovecs == 2) { + iovecs = 1; len -= iov[0].iov_len; - iov[0].iov_len = 0; + iov[0] = iov[1]; } - iov[1].iov_base = (char *) iov[1].iov_base + len; - iov[1].iov_len -= len; + iov[0].iov_base = (char *) iov[0].iov_base + len; + iov[0].iov_len -= len; } } diff --git a/libatalk/libatalk-3.0.3.abi b/libatalk/libatalk-3.0.3.abi new file mode 100644 index 00000000..17e9539a --- /dev/null +++ b/libatalk/libatalk-3.0.3.abi @@ -0,0 +1,566 @@ +acl_ldap_freeconfig: void (void) +acl_ldap_readconfig: int (dictionary *) +ad_close: int (struct adouble *, int) +ad_convert: int (const char *, const struct stat *, const struct vol *, const char **) +ad_copy_header: int (struct adouble *, struct adouble *) +add_cachebyname: int (const char *, const uuidp_t, const uuidtype_t, const long unsigned int) +add_cachebyuuid: int (uuidp_t, const char *, uuidtype_t, const long unsigned int) +add_charset: charset_t (const char *) +ad_dir: char *(const char *) +ad_dtruncate: int (struct adouble *, const off_t) +adflags2logstr: const char *(int) +ad_flush: int (struct adouble *) +ad_forcegetid: uint32_t (struct adouble *) +adf_pread: ssize_t (struct ad_fd *, void *, size_t, off_t) +adf_pwrite: ssize_t (struct ad_fd *, const void *, size_t, off_t) +ad_getattr: int (const struct adouble *, uint16_t *) +ad_getdate: int (const struct adouble *, unsigned int, uint32_t *) +ad_getentryoff: off_t (const struct adouble *, int) +ad_getfuid: uid_t (void) +ad_getid: uint32_t (struct adouble *, const dev_t, const ino_t, const cnid_t, const void *) +ad_hf_mode: mode_t (mode_t) +ad_init: void (struct adouble *, const struct vol *) +ad_init_old: void (struct adouble *, int, int) +ad_lock: int (struct adouble *, uint32_t, int, off_t, off_t, int) +ad_metadata: int (const char *, int, struct adouble *) +ad_metadataat: int (int, const char *, int, struct adouble *) +ad_mkdir: int (const char *, mode_t) +ad_mode: int (const char *, mode_t) +ad_open: int (struct adouble *, const char *, int, ...) +ad_openat: int (struct adouble *, int, const char *, int, ...) +ad_openforks: uint16_t (struct adouble *, uint16_t) +ad_path: const char *(const char *, int) +ad_path_ea: const char *(const char *, int) +ad_path_osx: const char *(const char *, int) +ad_read: ssize_t (struct adouble *, const uint32_t, off_t, char *, const size_t) +ad_readfile_init: int (const struct adouble *, const int, off_t *, const int) +ad_rebuild_adouble_header_ea: int (struct adouble *) +ad_rebuild_adouble_header_v2: int (struct adouble *) +ad_refresh: int (const char *, struct adouble *) +ad_reso_size: off_t (const char *, int, struct adouble *) +ad_rtruncate: int (struct adouble *, const off_t) +ad_setattr: int (const struct adouble *, const uint16_t) +ad_setdate: int (struct adouble *, unsigned int, uint32_t) +ad_setfuid: int (const uid_t) +ad_setid: int (struct adouble *, const dev_t, const ino_t, const uint32_t, const cnid_t, const void *) +ad_setname: int (struct adouble *, const char *) +ad_size: off_t (const struct adouble *, const uint32_t) +ad_stat: int (const char *, struct stat *) +ad_testlock: int (struct adouble *, int, const off_t) +ad_tmplock: int (struct adouble *, uint32_t, int, off_t, off_t, int) +ad_unlock: void (struct adouble *, const int, int) +ad_valid_header_osx: int (const char *) +ad_write: ssize_t (struct adouble *, uint32_t, off_t, int, const char *, size_t) +afp_config_free: void (AFPObj *) +afp_config_parse: int (AFPObj *, char *) +allow_severity: 5 +apply_ip_mask: void (struct sockaddr *, int) +atalk_iconv: size_t (atalk_iconv_t, const char **, size_t *, char **, size_t *) +atalk_iconv_close: int (atalk_iconv_t) +atalk_iconv_open: atalk_iconv_t (const char *, const char *) +atalk_register_charset: int (struct charset_functions *) +balloc: int (bstring, int) +ballocmin: int (bstring, int) +basename_safe: const char *(const char *) +bassign: int (bstring, const_bstring) +bassignblk: int (bstring, const void *, int) +bassigncstr: int (bstring, const char *) +bassignformat: int (bstring, const char *, ...) +bassigngets: int (bstring, bNgetc, void *, char) +bassignmidstr: int (bstring, const_bstring, int, int) +bcatblk: int (bstring, const void *, int) +bcatcstr: int (bstring, const char *) +bconcat: int (bstring, const_bstring) +bconchar: int (bstring, char) +bcstrfree: int (char *) +bdelete: int (bstring, int, int) +bdestroy: int (bstring) +become_root: void (void) +bfindreplace: int (bstring, const_bstring, const_bstring, int) +bfindreplacecaseless: int (bstring, const_bstring, const_bstring, int) +bformat: bstring (const char *, ...) +bformata: int (bstring, const char *, ...) +bfromcstr: bstring (const char *) +bfromcstralloc: bstring (int, const char *) +bgetsa: int (bstring, bNgetc, void *, char) +bgetstream: bstring (bNgetc, void *, char) +binchr: int (const_bstring, int, const_bstring) +binchrr: int (const_bstring, int, const_bstring) +binsert: int (bstring, int, const_bstring, unsigned char) +binsertch: int (bstring, int, int, unsigned char) +binstr: int (const_bstring, int, const_bstring) +binstrcaseless: int (const_bstring, int, const_bstring) +binstrr: int (const_bstring, int, const_bstring) +binstrrcaseless: int (const_bstring, int, const_bstring) +biseq: int (const_bstring, const_bstring) +biseqcaseless: int (const_bstring, const_bstring) +biseqcstr: int (const_bstring, const char *) +biseqcstrcaseless: int (const_bstring, const char *) +bisstemeqblk: int (const_bstring, const void *, int) +bisstemeqcaselessblk: int (const_bstring, const void *, int) +bjoin: bstring (const struct bstrList *, const_bstring) +bjoinInv: bstring (const struct bstrList *, const_bstring) +blk2bstr: bstring (const void *, int) +bltrimws: int (bstring) +bmidstr: bstring (const_bstring, int, int) +bninchr: int (const_bstring, int, const_bstring) +bninchrr: int (const_bstring, int, const_bstring) +bpattern: int (bstring, int) +bread: bstring (bNread, void *) +breada: int (bstring, bNread, void *) +brefcstr: bstring (char *) +breplace: int (bstring, int, int, const_bstring, unsigned char) +brtrimws: int (bstring) +bsbufflength: int (struct bStream *, int) +bsclose: void *(struct bStream *) +bseof: int (const struct bStream *) +bsetstr: int (bstring, int, const_bstring, unsigned char) +bsopen: struct bStream *(bNread, void *) +bspeek: int (bstring, const struct bStream *) +bsplit: struct bstrList *(const_bstring, unsigned char) +bsplitcb: int (const_bstring, unsigned char, int, int (*)(void *, int, int), void *) +bsplits: struct bstrList *(const_bstring, const_bstring) +bsplitscb: int (const_bstring, const_bstring, int, int (*)(void *, int, int), void *) +bsplitstr: struct bstrList *(const_bstring, const_bstring) +bsplitstrcb: int (const_bstring, const_bstring, int, int (*)(void *, int, int), void *) +bsread: int (bstring, struct bStream *, int) +bsreada: int (bstring, struct bStream *, int) +bsreadln: int (bstring, struct bStream *, char) +bsreadlna: int (bstring, struct bStream *, char) +bsreadlns: int (bstring, struct bStream *, const_bstring) +bsreadlnsa: int (bstring, struct bStream *, const_bstring) +bssplitscb: int (struct bStream *, const_bstring, int (*)(void *, int, const_bstring), void *) +bssplitstrcb: int (struct bStream *, const_bstring, int (*)(void *, int, const_bstring), void *) +bstr2cstr: char *(const_bstring, char) +bstrchrp: int (const_bstring, int, int) +bstrcmp: int (const_bstring, const_bstring) +bstrcpy: bstring (const_bstring) +bstricmp: int (const_bstring, const_bstring) +bstrListAlloc: int (struct bstrList *, int) +bstrListAllocMin: int (struct bstrList *, int) +bstrListCreate: struct bstrList *(void) +bstrListCreateMin: struct bstrList *(int) +bstrListDestroy: int (struct bstrList *) +bstrListPop: bstring (struct bstrList *) +bstrListPush: int (struct bstrList *, bstring) +bstrncmp: int (const_bstring, const_bstring, int) +bstrnicmp: int (const_bstring, const_bstring, int) +bstrrchrp: int (const_bstring, int, int) +bsunread: int (struct bStream *, const_bstring) +btolower: int (bstring) +btoupper: int (bstring) +btrimws: int (bstring) +btrunc: int (bstring, int) +bunrefcstr: int (bstring) +bvcformata: int (bstring, int, const char *, struct __va_list_tag *) +charset_decompose: size_t (charset_t, char *, size_t, char *, size_t) +charset_mac_centraleurope: {name = "MAC_CENTRALEUROPE", kTextEncoding = 29, pull = , push = , flags = 17, iname = 0x0, prev = 0x0, next = 0x0} +charset_mac_chinese_simp: {name = "MAC_CHINESE_SIMP", kTextEncoding = 25, pull = , push = , flags = 85, iname = "EUC-CN", prev = 0x0, next = 0x0} +charset_mac_chinese_trad: {name = "MAC_CHINESE_TRAD", kTextEncoding = 2, pull = , push = , flags = 85, iname = "BIG-5", prev = 0x0, next = 0x0} +charset_mac_cyrillic: {name = "MAC_CYRILLIC", kTextEncoding = 7, pull = , push = , flags = 17, iname = 0x0, prev = 0x0, next = 0x0} +charset_mac_greek: {name = "MAC_GREEK", kTextEncoding = 6, pull = , push = , flags = 17, iname = 0x0, prev = 0x0, next = 0x0} +charset_mac_hebrew: {name = "MAC_HEBREW", kTextEncoding = 5, pull = , push = , flags = 17, iname = 0x0, prev = 0x0, next = 0x0} +charset_mac_japanese: {name = "MAC_JAPANESE", kTextEncoding = 1, pull = , push = , flags = 85, iname = "SHIFT_JIS", prev = 0x0, next = 0x0} +charset_mac_korean: {name = "MAC_KOREAN", kTextEncoding = 3, pull = , push = , flags = 85, iname = "EUC-KR", prev = 0x0, next = 0x0} +charset_mac_roman: {name = "MAC_ROMAN", kTextEncoding = 0, pull = , push = , flags = 21, iname = 0x0, prev = 0x0, next = 0x0} +charset_mac_turkish: {name = "MAC_TURKISH", kTextEncoding = 35, pull = , push = , flags = 17, iname = 0x0, prev = 0x0, next = 0x0} +charset_precompose: size_t (charset_t, char *, size_t, char *, size_t) +charset_strlower: size_t (charset_t, const char *, size_t, char *, size_t) +charset_strupper: size_t (charset_t, const char *, size_t, char *, size_t) +charset_to_ucs2_allocate: size_t (charset_t, uint16_t **, const char *) +charset_to_utf8_allocate: size_t (charset_t, char **, const char *) +charset_utf8: {name = "UTF8", kTextEncoding = 134217987, pull = , push = , flags = 22, iname = 0x0, prev = 0x0, next = 0x0} +charset_utf8_mac: {name = "UTF8-MAC", kTextEncoding = 134217987, pull = , push = , flags = 27, iname = 0x0, prev = 0x0, next = 0x0} +check_lockfile: int (const char *, const char *) +cjk_char_pull: size_t (uint16_t, uint16_t *, const uint32_t *) +cjk_char_push: size_t (uint16_t, uint8_t *) +cjk_compose: uint16_t (uint16_t, uint16_t, const uint32_t *, size_t) +cjk_compose_seq: uint16_t (const uint16_t *, size_t *, const uint32_t *, size_t) +cjk_generic_pull: size_t (size_t (*)(uint16_t *, const uint8_t *, size_t *), void *, char **, size_t *, char **, size_t *) +cjk_generic_push: size_t (size_t (*)(uint8_t *, const uint16_t *, size_t *), void *, char **, size_t *, char **, size_t *) +cjk_lookup: uint16_t (uint16_t, const cjk_index_t *, const uint16_t *) +cnid_add: cnid_t (struct _cnid_db *, const struct stat *, const cnid_t, const char *, const size_t, cnid_t) +cnid_close: void (struct _cnid_db *) +cnid_dbd_add: cnid_t (struct _cnid_db *, const struct stat *, cnid_t, const char *, size_t, cnid_t) +cnid_dbd_close: void (struct _cnid_db *) +cnid_dbd_delete: int (struct _cnid_db *, const cnid_t) +cnid_dbd_find: int (struct _cnid_db *, const char *, size_t, void *, size_t) +cnid_dbd_get: cnid_t (struct _cnid_db *, cnid_t, const char *, size_t) +cnid_dbd_getstamp: int (struct _cnid_db *, void *, const size_t) +cnid_dbd_lookup: cnid_t (struct _cnid_db *, const struct stat *, cnid_t, const char *, size_t) +cnid_dbd_module: {name = "dbd", db_list = {next = 0x0, prev = 0x0}, cnid_open = 0, flags = 0} +cnid_dbd_open: struct _cnid_db *(struct cnid_open_args *) +cnid_dbd_rebuild_add: cnid_t (struct _cnid_db *, const struct stat *, cnid_t, const char *, size_t, cnid_t) +cnid_dbd_resolve: char *(struct _cnid_db *, cnid_t *, void *, size_t) +cnid_dbd_update: int (struct _cnid_db *, cnid_t, const struct stat *, cnid_t, const char *, size_t) +cnid_dbd_wipe: int (struct _cnid_db *) +cnid_delete: int (struct _cnid_db *, cnid_t) +cnid_find: int (struct _cnid_db *, const char *, size_t, void *, size_t) +cnid_get: cnid_t (struct _cnid_db *, const cnid_t, char *, const size_t) +cnid_getstamp: int (struct _cnid_db *, void *, const size_t) +cnid_init: void (void) +cnid_last_add: cnid_t (struct _cnid_db *, const struct stat *, cnid_t, const char *, size_t, cnid_t) +cnid_last_close: void (struct _cnid_db *) +cnid_last_delete: int (struct _cnid_db *, const cnid_t) +cnid_last_get: cnid_t (struct _cnid_db *, cnid_t, const char *, size_t) +cnid_last_lookup: cnid_t (struct _cnid_db *, const struct stat *, cnid_t, const char *, size_t) +cnid_last_module: {name = "last", db_list = {next = 0x0, prev = 0x0}, cnid_open = 0, flags = 0} +cnid_last_open: struct _cnid_db *(struct cnid_open_args *) +cnid_last_resolve: char *(struct _cnid_db *, cnid_t *, void *, size_t) +cnid_last_update: int (struct _cnid_db *, cnid_t, const struct stat *, cnid_t, const char *, size_t) +cnid_lookup: cnid_t (struct _cnid_db *, const struct stat *, const cnid_t, char *, const size_t) +cnid_open: struct _cnid_db *(const char *, mode_t, char *, int, const char *, const char *) +cnid_rebuild_add: cnid_t (struct _cnid_db *, const struct stat *, const cnid_t, char *, const size_t, cnid_t) +cnid_register: void (struct _cnid_module *) +cnid_resolve: char *(struct _cnid_db *, cnid_t *, void *, size_t) +cnid_tdb_add: cnid_t (struct _cnid_db *, const struct stat *, cnid_t, const char *, size_t, cnid_t) +cnid_tdb_close: void (struct _cnid_db *) +cnid_tdb_delete: int (struct _cnid_db *, const cnid_t) +cnid_tdb_get: cnid_t (struct _cnid_db *, cnid_t, const char *, size_t) +cnid_tdb_lookup: cnid_t (struct _cnid_db *, const struct stat *, cnid_t, const char *, size_t) +cnid_tdb_module: {name = "tdb", db_list = {next = 0x0, prev = 0x0}, cnid_open = 0, flags = 12} +cnid_tdb_open: struct _cnid_db *(struct cnid_open_args *) +cnid_tdb_resolve: char *(struct _cnid_db *, cnid_t *, void *, size_t) +cnid_tdb_update: int (struct _cnid_db *, cnid_t, const struct stat *, cnid_t, const char *, size_t) +cnid_update: int (struct _cnid_db *, const cnid_t, const struct stat *, const cnid_t, char *, const size_t) +cnid_wipe: int (struct _cnid_db *) +compare_ip: int (const struct sockaddr *, const struct sockaddr *) +convert_charset: size_t (charset_t, charset_t, charset_t, const char *, size_t, char *, size_t, uint16_t *) +convert_string: size_t (charset_t, charset_t, const void *, size_t, void *, size_t) +convert_string_allocate: size_t (charset_t, charset_t, const void *, size_t, char **) +copy_ea: int (const char *, int, const char *, const char *, mode_t) +copy_file: int (int, const char *, const char *, mode_t) +copy_file_fd: int (int, int) +copy_fork: int (int, struct adouble *, struct adouble *) +create_lockfile: int (const char *, const char *) +daemonize: int (int, int) +decompose_w: size_t (uint16_t *, size_t, uint16_t *, size_t *) +deny_severity: 3 +dequeue: void *(q_t *) +_diacasemap: {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 231, 203, 229, 128, 204, 129, 130, 131, 233, 230, 232, 234, 237, 235, 236, 132, 238, 241, 239, 133, 205, 242, 244, 243, 134, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 181, 198, 183, 184, 184, 186, 187, 188, 189, 174, 175, 192, 193, 194, 195, 196, 197, 198, 199...} +_dialowermap: {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 138, 140, 141, 142, 150, 154, 159, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 132, 151, 152, 153, 154, 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 190, 191, 176, 177, 178, 179, 180, 181, 198, 183, 185, 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, 199...} +dictionary_del: void (dictionary *) +dictionary_dump: void (dictionary *, FILE *) +dictionary_get: const char *(const dictionary *, const char *, const char *, const char *) +dictionary_hash: unsigned int (char *) +dictionary_new: dictionary *(int) +dictionary_set: int (dictionary *, char *, char *, char *) +dictionary_unset: void (dictionary *, char *, char *) +dir_rx_set: int (mode_t) +dsi_attention: int (DSI *, AFPUserBytes) +dsi_close: void (DSI *) +dsi_cmdreply: int (DSI *, const int) +dsi_disconnect: int (DSI *) +dsi_free: void (DSI *) +dsi_getsession: int (DSI *, server_child_t *, int, afp_child_t **) +dsi_getstatus: void (DSI *) +dsi_init: DSI *(AFPObj *, const char *, const char *, const char *) +dsi_opensession: void (DSI *) +dsi_read: ssize_t (DSI *, void *, const size_t) +dsi_readdone: void (DSI *) +dsi_readinit: ssize_t (DSI *, void *, const size_t, const size_t, const int) +dsi_stream_read: size_t (DSI *, void *, const size_t) +dsi_stream_read_file: ssize_t (DSI *, const int, off_t, const size_t, const int) +dsi_stream_receive: int (DSI *) +dsi_stream_send: int (DSI *, void *, size_t) +dsi_stream_write: ssize_t (DSI *, void *, const size_t, int) +dsi_tcp_init: int (DSI *, const char *, const char *, const char *) +dsi_tickle: int (DSI *) +dsi_write: size_t (DSI *, void *, const size_t) +dsi_writeflush: void (DSI *) +dsi_writeinit: size_t (DSI *, void *, const size_t) +ea_chmod_dir: int (const struct vol *, const char *, mode_t, struct stat *) +ea_chmod_file: int (const struct vol *, const char *, mode_t, struct stat *) +ea_chown: int (const struct vol *, const char *, uid_t, gid_t) +ea_close: int (struct ea *) +ea_copyfile: int (const struct vol *, int, const char *, const char *) +ea_deletefile: int (const struct vol *, int, const char *) +ea_open: int (const struct vol *, const char *, eaflags_t, struct ea *) +ea_openat: int (const struct vol *, int, const char *, eaflags_t, struct ea *) +ea_path: char *(const struct ea *, const char *, int) +ea_renamefile: int (const struct vol *, int, const char *, const char *) +enqueue: qnode_t *(q_t *, void *) +fault_setup: void (void (*)(void *)) +fdset_add_fd: void (int, struct pollfd **, struct polldata **, int *, int *, int, enum fdtype, void *) +fdset_del_fd: void (struct pollfd **, struct polldata **, int *, int *, int) +find_charset_functions: struct charset_functions *(const char *) +_fini: +free_charset_names: void (void) +freeifacelist: void (char **) +fullpathname: const char *(const char *) +getcwdpath: const char *(void) +getdefextmap: struct extmap *(void) +get_eacontent: int (const struct vol *, char *, size_t *, const char *, int, const char *, int) +get_easize: int (const struct vol *, char *, size_t *, const char *, int, const char *) +getextmap: struct extmap *(const char *) +getifacelist: char **(void) +getip_port: unsigned int (const struct sockaddr *) +getip_string: const char *(const struct sockaddr *) +getnamefromuuid: int (const uuidp_t, char **, uuidtype_t *) +getuuidfromname: int (const char *, uuidtype_t, unsigned char *) +getvolbyname: struct vol *(const char *) +getvolbypath: struct vol *(AFPObj *, const char *) +getvolbyvid: struct vol *(const uint16_t) +getvolumes: struct vol *(void) +gmem: int (gid_t, int, gid_t *) +iniparser_dump: void (const dictionary *, FILE *) +iniparser_dump_ini: void (const dictionary *, FILE *) +iniparser_find_entry: int (const dictionary *, const char *) +iniparser_freedict: void (dictionary *) +iniparser_getboolean: int (const dictionary *, const char *, const char *, int) +iniparser_getdouble: double (const dictionary *, const char *, const char *, double) +iniparser_getint: int (const dictionary *, const char *, const char *, int) +iniparser_getnsec: int (const dictionary *) +iniparser_getsecname: const char *(const dictionary *, int) +iniparser_getstrdup: char *(const dictionary *, const char *, const char *, const char *) +iniparser_getstring: const char *(const dictionary *, const char *, const char *, const char *) +iniparser_load: dictionary *(const char *) +iniparser_set: int (dictionary *, char *, char *, char *) +iniparser_unset: void (dictionary *, char *, char *) +_init: +init_iconv: void (void) +initline: void (int, char *) +initvol_vfs: void (struct vol *) +ipc_child_state: int (AFPObj *, uint16_t) +ipc_child_write: int (int, uint16_t, int, void *) +ipc_server_read: int (server_child_t *, int) +islower_sp: int (uint32_t) +islower_w: int (uint16_t) +isupper_sp: int (uint32_t) +isupper_w: int (uint16_t) +ldap_auth_dn: 0x0 +ldap_auth_method: 0 +ldap_auth_pw: 0x0 +ldap_config_valid: 0 +ldap_getnamefromuuid: int (const char *, char **, uuidtype_t *) +ldap_getuuidfromname: int (const char *, uuidtype_t, char **) +ldap_group_attr: 0x0 +ldap_groupbase: 0x0 +ldap_groupscope: 0 +ldap_name_attr: 0x0 +ldap_prefs: {{pref = 0x0, name = "ldap server", strorint = 0, intfromarray = 0, valid = -1, valid_save = -1}, {pref = 0x0, name = "ldap auth method", strorint = 1, intfromarray = 1, valid = -1, valid_save = -1}, {pref = 0x0, name = "ldap auth dn", strorint = 0, intfromarray = 0, valid = 0, valid_save = 0}, {pref = 0x0, name = "ldap auth pw", strorint = 0, intfromarray = 0, valid = 0, valid_save = 0}, {pref = 0x0, name = "ldap userbase", strorint = 0, intfromarray = 0, valid = -1, valid_save = -1}, {pref = 0x0, name = "ldap userscope", strorint = 1, intfromarray = 1, valid = -1, valid_save = -1}, {pref = 0x0, name = "ldap groupbase", strorint = 0, intfromarray = 0, valid = -1, valid_save = -1}, {pref = 0x0, name = "ldap groupscope", strorint = 1, intfromarray = 1, valid = -1, valid_save = -1}, {pref = 0x0, name = "ldap uuid attr", strorint = 0, intfromarray = 0, valid = -1, valid_save = -1}, {pref = 0x0, name = "ldap uuid string", strorint = 0, intfromarray = 0, valid = 0, valid_save = 0}, {pref = 0x0, name = "ldap name attr", strorint = 0, intfromarray = 0, valid = -1, valid_save = -1}, {pref = 0x0, name = "ldap group attr", strorint = 0, intfromarray = 0, valid = -1, valid_save = -1}, {pref = 0x0, name = "ldap uid attr", strorint = 0, intfromarray = 0, valid = 0, valid_save = 0}, {pref = 0x0, name = "ldap uuid encoding", strorint = 1, intfromarray = 1, valid = 0, valid_save = 0}, {pref = 0x0, name = 0x0, strorint = 0, intfromarray = 0, valid = 0, valid_save = 0}} +ldap_server: 0x0 +ldap_uid_attr: 0x0 +ldap_userbase: 0x0 +ldap_userscope: 0 +ldap_uuid_attr: 0x0 +ldap_uuid_encoding: 0 +ldap_uuid_string: 0x0 +list_eas: int (const struct vol *, char *, size_t *, const char *, int) +load_charset: int (struct vol *) +load_volumes: int (AFPObj *) +localuuid_from_id: void (unsigned char *, uuidtype_t, unsigned int) +lock_reg: int (int, int, int, off_t, int, off_t) +log_config: {inited = false, syslog_opened = false, console = false, processname = '\0' , syslog_facility = 0, syslog_display_options = 0} +make_log_entry: void (enum loglevels, enum logtypes, const char *, int, char *, ...) +make_tdb_data: unsigned char *(uint32_t, const struct stat *, const cnid_t, const char *, const size_t) +mb_generic_pull: size_t (int (*)(uint16_t *, const unsigned char *), void *, char **, size_t *, char **, size_t *) +mb_generic_push: size_t (int (*)(unsigned char *, uint16_t), void *, char **, size_t *, char **, size_t *) +netatalk_panic: void (const char *) +netatalk_rmdir: int (int, const char *) +netatalk_rmdir_all_errors: int (int, const char *) +netatalk_unlink: int (const char *) +netatalk_unlinkat: int (int, const char *) +nftw: int (const char *, nftw_func_t, dir_notification_func_t, int, int) +ochdir: int (const char *, int) +ochmod: int (char *, mode_t, const struct stat *, int) +ochown: int (const char *, uid_t, gid_t, int) +opendirat: DIR *(int, const char *) +openflags2logstr: const char *(int) +ostat: int (const char *, struct stat *, int) +ostatat: int (int, const char *, struct stat *, int) +parseline: int (int, char *) +posix_chmod: int (const char *, mode_t) +posix_fchmod: int (int, mode_t) +precompose_w: size_t (uint16_t *, size_t, uint16_t *, size_t *) +prefs_array: {{pref = "ldap auth method", valuestring = "none", value = 0}, {pref = "ldap auth method", valuestring = "simple", value = 128}, {pref = "ldap auth method", valuestring = "sasl", value = 163}, {pref = "ldap userscope", valuestring = "base", value = 0}, {pref = "ldap userscope", valuestring = "one", value = 1}, {pref = "ldap userscope", valuestring = "sub", value = 2}, {pref = "ldap groupscope", valuestring = "base", value = 0}, {pref = "ldap groupscope", valuestring = "one", value = 1}, {pref = "ldap groupscope", valuestring = "sub", value = 2}, {pref = "ldap uuid encoding", valuestring = "ms-guid", value = 1}, {pref = "ldap uuid encoding", valuestring = "string", value = 0}, {pref = 0x0, valuestring = 0x0, value = 0}} +prequeue: qnode_t *(q_t *, void *) +print_groups: const char *(int, gid_t *) +queue_destroy: void (q_t *, void (*)(void *)) +queue_init: q_t *(void) +randombytes: void (void *, int) +readt: ssize_t (int, void *, const size_t, int, int) +realpath_safe: char *(const char *) +recv_fd: int (int, int) +rel_path_in_vol: bstring (const char *, const char *) +remove_acl_vfs: int (const char *) +remove_ea: int (const struct vol *, const char *, const char *, int) +run_cmd: int (const char *, char **) +search_cachebyname: int (const char *, uuidtype_t *, unsigned char *) +search_cachebyuuid: int (uuidp_t, char **, uuidtype_t *) +send_fd: int (int, int) +server_child_add: afp_child_t *(server_child_t *, pid_t, int) +server_child_alloc: server_child_t *(int) +server_child_free: void (server_child_t *) +server_child_kill: void (server_child_t *, int) +server_child_kill_one_by_id: void (server_child_t *, pid_t, uid_t, uint32_t, char *, uint32_t) +server_child_remove: int (server_child_t *, pid_t) +server_child_resolve: afp_child_t *(server_child_t *, id_t) +server_child_transfer_session: int (server_child_t *, pid_t, uid_t, int, uint16_t) +server_lock: pid_t (char *, char *, int) +server_reset_signal: void (void) +set_charset_name: int (charset_t, const char *) +set_ea: int (const struct vol *, const char *, const char *, const char *, size_t, int) +setfilmode: int (const struct vol *, const char *, mode_t, struct stat *) +set_groups: int (AFPObj *, struct passwd *) +setnonblock: int (int, int) +set_processname: void (const char *) +setuplog: void (const char *, const char *) +statat: int (int, const char *, struct stat *) +strcasechr_sp: uint16_t *(const uint16_t *, uint32_t) +strcasechr_w: uint16_t *(const uint16_t *, uint16_t) +strcasecmp_w: int (const uint16_t *, const uint16_t *) +strcasestr_w: uint16_t *(const uint16_t *, const uint16_t *) +strcat_w: uint16_t *(uint16_t *, const uint16_t *) +strchr_w: uint16_t *(const uint16_t *, uint16_t) +strcmp_w: int (const uint16_t *, const uint16_t *) +strdiacasecmp: int (const char *, const char *) +strdup_w: uint16_t *(const uint16_t *) +stripped_slashes_basename: char *(char *) +strlcat: size_t (char *, const char *, size_t) +strlcpy: size_t (char *, const char *, size_t) +strlen_w: size_t (const uint16_t *) +strlower_w: int (uint16_t *) +strncasecmp_w: int (const uint16_t *, const uint16_t *, size_t) +strncat_w: uint16_t *(uint16_t *, const uint16_t *, const size_t) +strncmp_w: int (const uint16_t *, const uint16_t *, size_t) +strncpy_w: uint16_t *(uint16_t *, const uint16_t *, const size_t) +strndiacasecmp: int (const char *, const char *, size_t) +strndup_w: uint16_t *(const uint16_t *, size_t) +strnlen_w: size_t (const uint16_t *, size_t) +strstr_w: uint16_t *(const uint16_t *, const uint16_t *) +strtok_quote: char *(char *, const char *) +strupper_w: int (uint16_t *) +sys_ea_copyfile: int (const struct vol *, int, const char *, const char *) +sys_fgetxattr: ssize_t (int, const char *, void *, size_t) +sys_fsetxattr: int (int, const char *, const void *, size_t, int) +sys_ftruncate: int (int, off_t) +sys_get_eacontent: int (const struct vol *, char *, size_t *, const char *, int, const char *, int) +sys_get_easize: int (const struct vol *, char *, size_t *, const char *, int, const char *) +sys_getxattr: ssize_t (const char *, const char *, void *, size_t) +sys_getxattrfd: int (int, const char *, int, ...) +sys_lgetxattr: ssize_t (const char *, const char *, void *, size_t) +sys_list_eas: int (const struct vol *, char *, size_t *, const char *, int) +sys_listxattr: ssize_t (const char *, char *, size_t) +sys_llistxattr: ssize_t (const char *, char *, size_t) +sys_lremovexattr: int (const char *, const char *) +sys_lsetxattr: int (const char *, const char *, const void *, size_t, int) +sys_remove_ea: int (const struct vol *, const char *, const char *, int) +sys_removexattr: int (const char *, const char *) +sys_sendfile: ssize_t (int, int, off_t *, size_t) +sys_set_ea: int (const struct vol *, const char *, const char *, const char *, size_t, int) +sys_setxattr: int (const char *, const char *, const void *, size_t, int) +tdb_add_flags: void (struct tdb_context *, unsigned int) +tdb_allocate: tdb_off_t (struct tdb_context *, tdb_len_t, struct tdb_record *) +tdb_alloc_read: unsigned char *(struct tdb_context *, tdb_off_t, tdb_len_t) +tdb_append: int (struct tdb_context *, TDB_DATA, TDB_DATA) +tdb_brlock: int (struct tdb_context *, tdb_off_t, int, int, int, size_t) +tdb_brlock_upgrade: int (struct tdb_context *, tdb_off_t, size_t) +tdb_chainlock: int (struct tdb_context *, TDB_DATA) +tdb_chainlock_mark: int (struct tdb_context *, TDB_DATA) +tdb_chainlock_nonblock: int (struct tdb_context *, TDB_DATA) +tdb_chainlock_read: int (struct tdb_context *, TDB_DATA) +tdb_chainlock_unmark: int (struct tdb_context *, TDB_DATA) +tdb_chainunlock: int (struct tdb_context *, TDB_DATA) +tdb_chainunlock_read: int (struct tdb_context *, TDB_DATA) +tdb_check: int (struct tdb_context *, int (*)(TDB_DATA, TDB_DATA, void *), void *) +tdb_close: int (struct tdb_context *) +tdb_convert: void *(void *, uint32_t) +tdb_delete: int (struct tdb_context *, TDB_DATA) +tdb_do_delete: int (struct tdb_context *, tdb_off_t, struct tdb_record *) +tdb_dump_all: void (struct tdb_context *) +tdb_enable_seqnum: void (struct tdb_context *) +tdb_error: enum TDB_ERROR (struct tdb_context *) +tdb_errorstr: const char *(struct tdb_context *) +tdb_exists: int (struct tdb_context *, TDB_DATA) +tdb_expand: int (struct tdb_context *, tdb_off_t) +tdb_fd: int (struct tdb_context *) +tdb_fetch: TDB_DATA (struct tdb_context *, TDB_DATA) +tdb_find_lock_hash: tdb_off_t (struct tdb_context *, TDB_DATA, uint32_t, int, struct tdb_record *) +tdb_firstkey: TDB_DATA (struct tdb_context *) +tdb_free: int (struct tdb_context *, tdb_off_t, struct tdb_record *) +tdb_freelist_size: int (struct tdb_context *) +tdb_get_flags: int (struct tdb_context *) +tdb_get_logging_private: void *(struct tdb_context *) +tdb_get_seqnum: int (struct tdb_context *) +tdb_hash_size: int (struct tdb_context *) +tdb_increment_seqnum_nonblock: void (struct tdb_context *) +tdb_io_init: void (struct tdb_context *) +tdb_lock: int (struct tdb_context *, int, int) +tdb_lockall: int (struct tdb_context *) +tdb_lockall_mark: int (struct tdb_context *) +tdb_lockall_nonblock: int (struct tdb_context *) +tdb_lockall_read: int (struct tdb_context *) +tdb_lockall_read_nonblock: int (struct tdb_context *) +tdb_lockall_unmark: int (struct tdb_context *) +tdb_lock_nonblock: int (struct tdb_context *, int, int) +tdb_lock_record: int (struct tdb_context *, tdb_off_t) +tdb_log_fn: tdb_log_func (struct tdb_context *) +tdb_map_size: size_t (struct tdb_context *) +tdb_mmap: void (struct tdb_context *) +tdb_munmap: int (struct tdb_context *) +tdb_name: const char *(struct tdb_context *) +tdb_nextkey: TDB_DATA (struct tdb_context *, TDB_DATA) +tdb_null: {dptr = 0x0, dsize = 0} +tdb_ofs_read: int (struct tdb_context *, tdb_off_t, tdb_off_t *) +tdb_ofs_write: int (struct tdb_context *, tdb_off_t, tdb_off_t *) +tdb_open: struct tdb_context *(const char *, int, int, int, mode_t) +tdb_open_ex: struct tdb_context *(const char *, int, int, int, mode_t, const struct tdb_logging_context *, tdb_hash_func) +tdb_parse_data: int (struct tdb_context *, TDB_DATA, tdb_off_t, tdb_len_t, int (*)(TDB_DATA, TDB_DATA, void *), void *) +tdb_parse_record: int (struct tdb_context *, TDB_DATA, int (*)(TDB_DATA, TDB_DATA, void *), void *) +tdb_printfreelist: int (struct tdb_context *) +tdb_rec_free_read: int (struct tdb_context *, tdb_off_t, struct tdb_record *) +tdb_rec_read: int (struct tdb_context *, tdb_off_t, struct tdb_record *) +tdb_rec_write: int (struct tdb_context *, tdb_off_t, struct tdb_record *) +tdb_remove_flags: void (struct tdb_context *, unsigned int) +tdb_reopen: int (struct tdb_context *) +tdb_reopen_all: int (int) +tdb_repack: int (struct tdb_context *) +tdb_setalarm_sigptr: void (struct tdb_context *, volatile sig_atomic_t *) +tdb_set_logging_function: void (struct tdb_context *, const struct tdb_logging_context *) +tdb_set_max_dead: void (struct tdb_context *, int) +tdb_store: int (struct tdb_context *, TDB_DATA, TDB_DATA, int) +_tdb_transaction_cancel: int (struct tdb_context *) +tdb_transaction_cancel: int (struct tdb_context *) +tdb_transaction_commit: int (struct tdb_context *) +tdb_transaction_lock: int (struct tdb_context *, int) +tdb_transaction_prepare_commit: int (struct tdb_context *) +tdb_transaction_recover: int (struct tdb_context *) +tdb_transaction_start: int (struct tdb_context *) +tdb_transaction_unlock: int (struct tdb_context *) +tdb_traverse: int (struct tdb_context *, tdb_traverse_func, void *) +tdb_traverse_read: int (struct tdb_context *, tdb_traverse_func, void *) +tdb_unlock: int (struct tdb_context *, int, int) +tdb_unlockall: int (struct tdb_context *) +tdb_unlockall_read: int (struct tdb_context *) +tdb_unlock_record: int (struct tdb_context *, tdb_off_t) +tdb_validate_freelist: int (struct tdb_context *, int *) +tdb_wipe_all: int (struct tdb_context *) +tdb_write_lock_record: int (struct tdb_context *, tdb_off_t) +tdb_write_unlock_record: int (struct tdb_context *, tdb_off_t) +tolower_sp: uint32_t (uint32_t) +tolower_w: uint16_t (uint16_t) +toupper_sp: uint32_t (uint32_t) +toupper_w: uint16_t (uint16_t) +type_configs: {{set = false, syslog = false, fd = -1, level = log_none, display_options = 0}, {set = false, syslog = false, fd = -1, level = log_none, display_options = 0}, {set = false, syslog = false, fd = -1, level = log_none, display_options = 0}, {set = false, syslog = false, fd = -1, level = log_none, display_options = 0}, {set = false, syslog = false, fd = -1, level = log_none, display_options = 0}, {set = false, syslog = false, fd = -1, level = log_none, display_options = 0}, {set = false, syslog = false, fd = -1, level = log_none, display_options = 0}, {set = false, syslog = false, fd = -1, level = log_none, display_options = 0}} +ucs2_to_charset: size_t (charset_t, const uint16_t *, char *, size_t) +ucs2_to_charset_allocate: size_t (charset_t, char **, const uint16_t *) +unbecome_root: void (void) +unix_rename: int (int, const char *, int, const char *) +unix_strlower: size_t (const char *, size_t, char *, size_t) +unix_strupper: size_t (const char *, size_t, char *, size_t) +unload_volumes: void (AFPObj *) +utf8_charlen: size_t (char *) +utf8_decompose: size_t (char *, size_t, char *, size_t) +utf8_precompose: size_t (char *, size_t, char *, size_t) +utf8_strlen_validate: size_t (char *) +utf8_strlower: size_t (const char *, size_t, char *, size_t) +utf8_strupper: size_t (const char *, size_t, char *, size_t) +utf8_to_charset_allocate: size_t (charset_t, char **, const char *) +uuid_bin2string: const char *(const unsigned char *) +uuidcache_dump: void (void) +uuid_string2bin: void (const char *, unsigned char *) +uuidtype: {"", "USER", "GROUP", "LOCAL"} +volume_free: void (struct vol *) +volume_unlink: void (struct vol *) +writet: ssize_t (int, void *, const size_t, int, int) diff --git a/libatalk/util/socket.c b/libatalk/util/socket.c index 1df0b96b..6a78c8e2 100644 --- a/libatalk/util/socket.c +++ b/libatalk/util/socket.c @@ -117,7 +117,7 @@ ssize_t readt(int socket, void *data, const size_t length, int setnonblocking, i while ((ret = select(socket + 1, &rfds, NULL, NULL, &tv)) < 1) { switch (ret) { case 0: - LOG(log_debug, logtype_afpd, "select timeout %d s", timeout); + LOG(log_debug, logtype_dsi, "select timeout %d s", timeout); errno = EAGAIN; goto exit; diff --git a/libatalk/vfs/acl.c b/libatalk/vfs/acl.c index c936f178..d7c8eb62 100644 --- a/libatalk/vfs/acl.c +++ b/libatalk/vfs/acl.c @@ -108,7 +108,7 @@ int remove_acl_vfs(const char *name) /* Remove default ACL if it's a dir */ - EC_ZERO_LOG_ERR(stat(name, &st), AFPERR_MISC); + EC_ZERO_ERR(stat(name, &st), AFPERR_MISC); if (S_ISDIR(st.st_mode)) { EC_NULL_LOG_ERR(acl = acl_init(0), AFPERR_MISC); EC_ZERO_LOG_ERR(acl_set_file(name, ACL_TYPE_DEFAULT, acl), AFPERR_MISC); @@ -129,6 +129,7 @@ int remove_acl_vfs(const char *name) EC_ZERO_LOG_ERR(acl_set_file(name, ACL_TYPE_ACCESS, acl), AFPERR_MISC); EC_CLEANUP: + if (errno == ENOENT) EC_STATUS(0); if (acl) acl_free(acl); EC_EXIT; diff --git a/libatalk/vfs/vfs.c b/libatalk/vfs/vfs.c index a349cfe8..d79ac05e 100644 --- a/libatalk/vfs/vfs.c +++ b/libatalk/vfs/vfs.c @@ -355,24 +355,17 @@ static int RF_solaris_acl(VFS_FUNC_ARGS_ACL) struct stat st; int len; - if ((stat(path, &st)) != 0) - return -1; - if (S_ISDIR(st.st_mode)) { - len = snprintf(buf, MAXPATHLEN, "%s/.AppleDouble",path); - if (len < 0 || len >= MAXPATHLEN) - return -1; - /* set acl on .AppleDouble dir first */ - if ((acl(buf, cmd, count, aces)) != 0) - return -1; - /* now set ACL on ressource fork */ - if ((acl(vol->ad_path(path, ADFLAGS_DIR), cmd, count, aces)) != 0) - return -1; - } else - /* set ACL on ressource fork */ - if ((acl(vol->ad_path(path, ADFLAGS_HF), cmd, count, aces)) != 0) - return -1; - - return 0; + if ((stat(path, &st)) != 0) { + if (errno == ENOENT) + return AFP_OK; + return AFPERR_MISC; + } + if (!S_ISDIR(st.st_mode)) { + /* set ACL on ressource fork */ + if ((acl(vol->ad_path(path, ADFLAGS_HF), cmd, count, aces)) != 0) + return AFPERR_MISC; + } + return AFP_OK; } static int RF_solaris_remove_acl(VFS_FUNC_ARGS_REMOVE_ACL) @@ -381,20 +374,15 @@ static int RF_solaris_remove_acl(VFS_FUNC_ARGS_REMOVE_ACL) static char buf[ MAXPATHLEN + 1]; int len; - if (dir) { - len = snprintf(buf, MAXPATHLEN, "%s/.AppleDouble",path); - if (len < 0 || len >= MAXPATHLEN) - return AFPERR_MISC; - /* remove ACL from .AppleDouble/.Parent first */ - if ((ret = remove_acl_vfs(vol->ad_path(path, ADFLAGS_DIR))) != AFP_OK) - return ret; - /* now remove from .AppleDouble dir */ - if ((ret = remove_acl_vfs(buf)) != AFP_OK) - return ret; - } else - /* remove ACL from ressource fork */ - if ((ret = remove_acl_vfs(vol->ad_path(path, ADFLAGS_HF))) != AFP_OK) - return ret; + if (dir) + return AFP_OK; + + /* remove ACL from ressource fork */ + if ((ret = remove_acl_vfs(vol->ad_path(path, ADFLAGS_HF))) != AFP_OK) { + if (errno == ENOENT) + return AFP_OK; + return ret; + } return AFP_OK; } @@ -404,55 +392,35 @@ static int RF_solaris_remove_acl(VFS_FUNC_ARGS_REMOVE_ACL) static int RF_posix_acl(VFS_FUNC_ARGS_ACL) { EC_INIT; - static char buf[ MAXPATHLEN + 1]; struct stat st; - int len; if (stat(path, &st) == -1) EC_FAIL; - if (S_ISDIR(st.st_mode)) { - len = snprintf(buf, MAXPATHLEN, "%s/.AppleDouble",path); - if (len < 0 || len >= MAXPATHLEN) - EC_FAIL; - /* set acl on .AppleDouble dir first */ - EC_ZERO_LOG(acl_set_file(buf, type, acl)); - - if (type == ACL_TYPE_ACCESS) - /* set ACL on ressource fork (".Parent") too */ - EC_ZERO_LOG(acl_set_file(vol->ad_path(path, ADFLAGS_DIR), type, acl)); - } else { + if (!S_ISDIR(st.st_mode)) { /* set ACL on ressource fork */ - EC_ZERO_LOG(acl_set_file(vol->ad_path(path, ADFLAGS_HF), type, acl)); + EC_ZERO_ERR( acl_set_file(vol->ad_path(path, ADFLAGS_HF), type, acl), AFPERR_MISC ); } EC_CLEANUP: - if (ret != 0) - return AFPERR_MISC; - return AFP_OK; + if (errno == ENOENT) + EC_STATUS(AFP_OK); + EC_EXIT; } static int RF_posix_remove_acl(VFS_FUNC_ARGS_REMOVE_ACL) { EC_INIT; - static char buf[ MAXPATHLEN + 1]; - int len; - if (dir) { - len = snprintf(buf, MAXPATHLEN, "%s/.AppleDouble",path); - if (len < 0 || len >= MAXPATHLEN) - return AFPERR_MISC; - /* remove ACL from .AppleDouble/.Parent first */ - EC_ZERO_LOG_ERR(remove_acl_vfs(vol->ad_path(path, ADFLAGS_DIR)), AFPERR_MISC); + if (dir) + EC_EXIT_STATUS(AFP_OK); - /* now remove from .AppleDouble dir */ - EC_ZERO_LOG_ERR(remove_acl_vfs(buf), AFPERR_MISC); - } else { - /* remove ACL from ressource fork */ - EC_ZERO_LOG_ERR(remove_acl_vfs(vol->ad_path(path, ADFLAGS_HF)), AFPERR_MISC); - } + /* remove ACL from ressource fork */ + EC_ZERO_ERR( remove_acl_vfs(vol->ad_path(path, ADFLAGS_HF)), AFPERR_MISC ); EC_CLEANUP: + if (errno == ENOENT) + EC_STATUS(AFP_OK); EC_EXIT; } #endif diff --git a/macros/netatalk.m4 b/macros/netatalk.m4 index 5e04b518..f5e48b8b 100644 --- a/macros/netatalk.m4 +++ b/macros/netatalk.m4 @@ -163,7 +163,9 @@ AC_DEFUN([AC_NETATALK_LIBEVENT], [ AC_MSG_ERROR([--with-libevent requires a path]) fi AC_MSG_RESULT([$use_bundled_libevent]) - AC_CONFIG_SUBDIRS([libevent]) + if test x"$use_bundled_libevent" = x"yes" ; then + AC_CONFIG_SUBDIRS([libevent]) + fi AC_SUBST(LIBEVENT_CFLAGS) AC_SUBST(LIBEVENT_LDFLAGS) AM_CONDITIONAL(USE_BUILTIN_LIBEVENT, test x"$use_bundled_libevent" = x"yes") @@ -410,7 +412,7 @@ AC_ARG_ENABLE(shell-check, ) ]) -dnl Check for optional sysv initscript install +dnl Check for optional initscript install AC_DEFUN([AC_NETATALK_INIT_STYLE], [ AC_ARG_WITH(init-style, [ --with-init-style use OS specific init config [[redhat-sysv|redhat-systemd|suse-sysv|suse-systemd|gentoo|netbsd|debian|solaris|systemd]]], @@ -422,36 +424,46 @@ AC_DEFUN([AC_NETATALK_INIT_STYLE], [ ;; "redhat-sysv") AC_MSG_RESULT([enabling redhat-style sysv initscript support]) + ac_cv_init_dir="/etc/rc.d/init.d" ;; "redhat-systemd") AC_MSG_RESULT([enabling redhat-style systemd support]) + ac_cv_init_dir="/lib/systemd/system" ;; "suse") AC_MSG_ERROR([--with-init-style=suse is obsoleted. Use suse-sysv or suse-systemd.]) ;; "suse-sysv") AC_MSG_RESULT([enabling suse-style sysv initscript support]) + ac_cv_init_dir="/etc/init.d" ;; "suse-systemd") AC_MSG_RESULT([enabling suse-style systemd support (>=openSUSE12.1)]) + ac_cv_init_dir="/lib/systemd/system" ;; "gentoo") AC_MSG_RESULT([enabling gentoo-style initscript support]) + ac_cv_init_dir="/etc/init.d" ;; "netbsd") AC_MSG_RESULT([enabling netbsd-style initscript support]) + ac_cv_init_dir="/etc/rc.d" ;; "debian") AC_MSG_RESULT([enabling debian-style initscript support]) + ac_cv_init_dir="/etc/init.d" ;; "solaris") AC_MSG_RESULT([enabling solaris-style SMF support]) + ac_cv_init_dir="/lib/svc/manifest/network/" ;; "systemd") AC_MSG_RESULT([enabling general systemd support]) + ac_cv_init_dir="/lib/systemd/system" ;; "none") AC_MSG_RESULT([disabling init-style support]) + ac_cv_init_dir="none" ;; *) AC_MSG_ERROR([illegal init-style]) @@ -466,6 +478,12 @@ AC_DEFUN([AC_NETATALK_INIT_STYLE], [ AM_CONDITIONAL(USE_SYSTEMD, test x$init_style = xsystemd || test x$init_style = xredhat-systemd || test x$init_style = xsuse-systemd) AM_CONDITIONAL(USE_UNDEF, test x$init_style = xnone) + AC_ARG_WITH(init-dir, + [ --with-init-dir=PATH path to OS specific init directory], + ac_cv_init_dir="$withval", ac_cv_init_dir="$ac_cv_init_dir" + ) + INIT_DIR="$ac_cv_init_dir" + AC_SUBST(INIT_DIR, ["$ac_cv_init_dir"]) ]) dnl OS specific configuration diff --git a/macros/summary.m4 b/macros/summary.m4 index b5093a04..71049c73 100644 --- a/macros/summary.m4 +++ b/macros/summary.m4 @@ -58,6 +58,9 @@ dnl AC_MSG_RESULT([ Samba sharemode interop: $neta_cv_have_smbshmd]) AC_MSG_RESULT([ dtrace probes: $WDTRACE]) AC_MSG_RESULT([ Paths:]) AC_MSG_RESULT([ Netatalk lockfile: $ac_cv_netatalk_lock]) + if test "x$init_style" != x"none"; then + AC_MSG_RESULT([ init directory: $ac_cv_init_dir]) + fi if test x"$atalk_cv_with_dbus" = x"yes"; then AC_MSG_RESULT([ dbus system directory: $ac_cv_dbus_sysdir]) fi diff --git a/man/man1/.gitignore b/man/man1/.gitignore index c767a967..39ffeb2f 100644 --- a/man/man1/.gitignore +++ b/man/man1/.gitignore @@ -6,6 +6,6 @@ apple_mv.1 apple_rm.1 asip-status.pl.1 afpldaptest.1 +afpstats.1 uniconv.1 -.gitignore *.o diff --git a/man/man1/Makefile.am b/man/man1/Makefile.am index fe81a7d7..20dede4e 100644 --- a/man/man1/Makefile.am +++ b/man/man1/Makefile.am @@ -12,8 +12,8 @@ SUFFIXES= .tmpl . -e s@:DEFAULT_CNID_SCHEME:@${DEFAULT_CNID_SCHEME}@ \ <$< >$@ -GENERATED_MANS = uniconv.1 asip-status.pl.1 afpldaptest.1 -TEMPLATE_FILES = uniconv.1.tmpl asip-status.pl.1.tmpl afpldaptest.1.tmpl +GENERATED_MANS = uniconv.1 asip-status.pl.1 afpldaptest.1 afpstats.1 +TEMPLATE_FILES = uniconv.1.tmpl asip-status.pl.1.tmpl afpldaptest.1.tmpl afpstats.1.tmpl NONGENERATED_MANS = ad.1 \ afppasswd.1 \ diff --git a/man/man1/afpstats.1.tmpl b/man/man1/afpstats.1.tmpl new file mode 100644 index 00000000..b7980996 --- /dev/null +++ b/man/man1/afpstats.1.tmpl @@ -0,0 +1,50 @@ +'\" t +.\" Title: afpstats +.\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] +.\" Generator: DocBook XSL Stylesheets v1.78.0 +.\" Date: 24 Mar 2013 +.\" Manual: Netatalk 3.0 +.\" Source: Netatalk 3.0 +.\" Language: English +.\" +.TH "AFPSTATS" "1" "24 Mar 2013" "Netatalk 3.0" "Netatalk 3.0" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +afpstats \- List AFP statistics +.SH "SYNOPSIS" +.HP \w'\fBafpstats\fR\fB\fR\ 'u +\fBafpstats\fR\fB\fR +.SH "DESCRIPTION" +.PP +\fBafpstats\fR +list AFP statistics via D\-Bus IPC\&. +.SH "NOTE" +.PP +\fBafpd\fR +must support D\-Bus\&. Check it by "\fBafpd \-V\fR"\&. +.PP +"\fBafpstats = yes\fR" must be set in +:ETCDIR:/afp\&.conf\&. +.SH "SEE ALSO" +.PP +\fBafpd\fR(8), +\fBafp.conf\fR(5), +\fBdbus-daemon\fR(1) diff --git a/man/man5/afp.conf.5.tmpl b/man/man5/afp.conf.5.tmpl index 6840bf7d..60ec8d0e 100644 --- a/man/man5/afp.conf.5.tmpl +++ b/man/man5/afp.conf.5.tmpl @@ -1035,7 +1035,7 @@ The default setting is false thus symlinks are not followed on the server\&. Thi .PP invisible dots = \fIBOOLEAN\fR (default: \fIno\fR) \fB(V)\fR .RS 4 -make dot files invisible\&. +make dot files invisible\&. WARNING: enabling this option will lead to unwanted sideeffects were OS X applications when saving files to a temporary file starting with a dot first, then renaming the temp file to its final name, result in the saved file being invisible\&. The only thing this option is useful for is making files that start with a dot invisible on Mac OS 9\&. It\*(Aqs completely useless on Mac OS X, as both in Finder and in Terminal files starting with a dot are hidden anyway\&. .RE .PP network ids = \fIBOOLEAN\fR (default: \fIyes\fR) \fB(V)\fR