$OpenBSD: patch-gateway_Gateway_cpp,v 1.4 2018/03/16 15:35:02 robert Exp $

Index: gateway/Gateway.cpp
--- gateway/Gateway.cpp.orig
+++ gateway/Gateway.cpp
@@ -59,6 +59,10 @@
 #include <openssl/ssl.h>
 #include <kopano/hl.hpp>
 
+#ifdef __OpenBSD__
+#include <sys/resource.h>
+#endif
+
 /**
  * @defgroup gateway Gateway for IMAP and POP3 
  * @{
@@ -319,10 +323,10 @@ int main(int argc, char *argv[]) {
 	bool exp_config = false;
 	static const configsetting_t lpDefaults[] = {
 		{ "server_bind", "" },
-		{ "run_as_user", "kopano" },
-		{ "run_as_group", "kopano" },
+		{ "run_as_user", "_kopano" },
+		{ "run_as_group", "_kopano" },
 		{ "pid_file", "/var/run/kopano/gateway.pid" },
-		{ "running_path", "/var/lib/kopano" },
+		{ "running_path", "/var/empty" },
 		{ "process_model", "thread" },
 		{"coredump_enabled", "systemdefault"},
 		{"pop3_enable", "yes", CONFIGSETTING_NONEMPTY},
