diff --git a/CMakeLists.txt b/CMakeLists.txt
index 69efeeddce7868cc555b0d24d1f3ae057017828f..1591c36f7a31f74f1e8fee51839471283a02fbcc 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -121,7 +121,6 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR CMAKE_CXX_COMPILER_ID MATCHES "GNU")
         -Werror \
         -pipe \
         -pedantic \
-        -ferror-limit=3 \
         -Wunreachable-code")
 
     if(CMAKE_CXX_COMPILER_ID MATCHES "GNU")
diff --git a/src/MatrixClient.cc b/src/MatrixClient.cc
index 3a987d2773edb439c159d1d6df4940a838b2b502..28aeb47dbdf7aec51f9231282dd1e95f9cf7654c 100644
--- a/src/MatrixClient.cc
+++ b/src/MatrixClient.cc
@@ -927,7 +927,7 @@ MatrixClient::readEvent(const QString &room_id, const QString &event_id)
 
         auto reply = post(request, "{}");
 
-        connect(reply, &QNetworkReply::finished, this, [this, reply]() {
+        connect(reply, &QNetworkReply::finished, this, [reply]() {
                 reply->deleteLater();
 
                 int status = reply->attribute(QNetworkRequest::HttpStatusCodeAttribute).toInt();