diff --git a/src/main/java/org/mariadb/jdbc/internal/failover/impl/AuroraListener.java b/src/main/java/org/mariadb/jdbc/internal/failover/impl/AuroraListener.java
index <HASH>..<HASH> 100644
--- a/src/main/java/org/mariadb/jdbc/internal/failover/impl/AuroraListener.java
+++ b/src/main/java/org/mariadb/jdbc/internal/failover/impl/AuroraListener.java
@@ -191,7 +191,7 @@ public class AuroraListener extends MastersSlavesListener {
                 //eat exception because cannot happen in this getString()
             } catch (QueryException qe) {
                 if (proxy.hasToHandleFailover(qe) && setSecondaryHostFail()) {
-                    addToBlacklist(currentProtocol.getHostAddress());
+                    addToBlacklist(secondaryProtocol.getHostAddress());
                 }
             }
         }
[CONJ-<I>] possible NPE on aurora when failover occur during connection initialisation