From 098ffde13c840b58dfe8349d0ba5d3e9f68715de Mon Sep 17 00:00:00 2001 From: Esa Korhonen Date: Fri, 5 Jun 2020 19:03:27 +0300 Subject: [PATCH] Remove obsolete debug assert from PamAuth Would be always hit in debug mode. --- server/modules/authenticator/PAM/PAMAuth/pam_auth.cc | 2 -- server/modules/authenticator/PAM/PAMAuth/pam_auth.hh | 1 - server/modules/authenticator/PAM/PAMAuth/pam_instance.cc | 1 - 3 files changed, 4 deletions(-) diff --git a/server/modules/authenticator/PAM/PAMAuth/pam_auth.cc b/server/modules/authenticator/PAM/PAMAuth/pam_auth.cc index fb883cc99..abcb3ed90 100644 --- a/server/modules/authenticator/PAM/PAMAuth/pam_auth.cc +++ b/server/modules/authenticator/PAM/PAMAuth/pam_auth.cc @@ -40,8 +40,6 @@ const string FIELD_HAS_PROXY = "proxy_grant"; const string FIELD_DB = "db"; const string FIELD_ROLE = "role"; -const int NUM_FIELDS = 6; - const char* SQLITE_OPEN_FAIL = "Failed to open SQLite3 handle for file '%s': '%s'"; const char* SQLITE_OPEN_OOM = "Failed to allocate memory for SQLite3 handle for file '%s'."; diff --git a/server/modules/authenticator/PAM/PAMAuth/pam_auth.hh b/server/modules/authenticator/PAM/PAMAuth/pam_auth.hh index abf0a3822..ab499566b 100644 --- a/server/modules/authenticator/PAM/PAMAuth/pam_auth.hh +++ b/server/modules/authenticator/PAM/PAMAuth/pam_auth.hh @@ -36,7 +36,6 @@ extern const string FIELD_DEF_ROLE; extern const string FIELD_HAS_PROXY; extern const string FIELD_IS_ROLE; extern const string FIELD_ROLE; -extern const int NUM_FIELDS; extern const char* SQLITE_OPEN_FAIL; extern const char* SQLITE_OPEN_OOM; diff --git a/server/modules/authenticator/PAM/PAMAuth/pam_instance.cc b/server/modules/authenticator/PAM/PAMAuth/pam_instance.cc index 94dd5e526..5aec340e5 100644 --- a/server/modules/authenticator/PAM/PAMAuth/pam_instance.cc +++ b/server/modules/authenticator/PAM/PAMAuth/pam_instance.cc @@ -491,7 +491,6 @@ void PamInstance::diagnostic(DCB* dcb) static int diag_cb_json(json_t* data, int columns, char** row, char** field_names) { - mxb_assert(columns == NUM_FIELDS); json_t* obj = json_object(); for (int i = 0; i < columns; i++) {