diff --git a/cgroup.c b/cgroup.c
index 4ed8872250adde02a34879afa7d23c0247d1ffb9..aa63253e3d701497a2c62ae447b63a91c713059f 100644
--- a/cgroup.c
+++ b/cgroup.c
@@ -9,7 +9,7 @@
#include "cgroup.h"
#include "common.h"
-#if SWAP_LIMIT
+#ifdef SWAP_LIMIT
#define MEMSW ".memsw"
#else
#define MEMSW
@@ -174,7 +174,7 @@ cgroup_set_mem_limit_twice(const char *chier, const char *cgroup, size_t nlimit,
int
cgroup_set_mem_limit(const char *chier, const char *cgroup, size_t nlimit)
{
-#if SWAP_LIMIT
+#ifdef SWAP_LIMIT
/* We need to set both the "normal" and memsw limits, but in such
* order that normal <= memsw always holds. */
size_t curlimit = cgroup_get_mem_limit(chier, cgroup);
diff --git a/debian/changelog b/debian/changelog
index 30ef9f1d7cce5bf475188cc7333d6278a4162fe5..57b0af76ddbfa41205cab7ec0175772107a124c3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+compctl (1.2-3) UNRELEASED; urgency=medium
+
+ * Turned off SWAP_LIMIT by default.
+
+ -- Martin Mares <mj@ucw.cz> Fri, 16 Feb 2018 13:16:34 +0100
+
compctl (1.2-2) stable; urgency=medium
* Updated packaging for Debian Stretch.