Spotlight: Limiting searches to subfolders, bug #581

Netatalk didn't use the kMDScopeArray Spotlight query
attribute. Instead the volume path was passed to the SPARQL query
mapper.

Simple fix: pass the kMDScopeArray value instead of the volume path.

Signed-off-by: Ralph Boehme <slow@samba.org>
libatalk: ABI: add abi-clean target

Signed-off-by: Ralph Boehme <slow@samba.org>
afpd: fix unbecome_root()

Reloading logging config may result in privilege escalation in afpd
processes.

Signed-off-by: Ralph Boehme <slow@samba.org>
afpd: several ACL error messages now logged with loglevel debug

Signed-off-by: Ralph Boehme <slow@samba.org>
cnid_metad: fix tsockfd_create() return value on error

We ran into a case where the netatalk log grew at an extremely rapid
pace.  There was one message that kept repeating:

cnid_metad[2528] {usockfd.c:169} (E:CNID): error in accept: Socket
operation on non-socket

An strace showed pselect() getting called on stdin, rather than an
actual socket.  Looking at the code, I see that tsockfd_create() will
return 0 instead of -1 if the call to getaddrinfo() fails, which is
obviously wrong.

Reviewed-by: Ralph Boehme <slow@samba.org>
CNID/mysql: fix volume table name generation from UUID, bug #566

Signed-off-by: Ralph Boehme <rb@sernet.de>
Release: 3.1.7

Signed-off-by: Ralph Boehme <rb@sernet.de>
Version: 3.1.8dev

Signed-off-by: Ralph Boehme <rb@sernet.de>
CNID/MySQL: Quote UUID table names

MySQL forbids unquoted table names that begin with a digit. We use UUIDs
as table names, which sometimes begin with a character and sometimes
begin with a digit.  Quote the table names everywhere we use them to
make the MySQL syntax valid.

https://sourceforge.net/p/netatalk/bugs/585/

Signed-off-by: Brian Campbell <brian.campbell@editshare.com>
Reviewed-by: Ralph Boehme <slow@samba.org>