From c8b93d6573550ec3735b070245769970db62a312 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Tue, 18 Nov 2014 20:56:27 +0100 Subject: Client: assume uid==0 is local socket A negative uid value means it's not a "local socket" (PF_LOCAL). uid==0 means user "root" connected. --- src/Client.hxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Client.hxx') diff --git a/src/Client.hxx b/src/Client.hxx index f0bc6b0f7..fd81b59e0 100644 --- a/src/Client.hxx +++ b/src/Client.hxx @@ -109,7 +109,7 @@ public: * a local (UNIX domain) socket? */ bool IsLocal() const { - return uid > 0; + return uid >= 0; } unsigned GetPermission() const { -- cgit v1.2.3