diff --git a/CHANGES b/CHANGES
index 856e5dc6ff41d59a8e2a100ca5293261f69a0edc..e336d03ade214001efe478474aa8349ef8bdee1c 100644
--- a/CHANGES
+++ b/CHANGES
@@ -11,6 +11,7 @@ OpenLDAP 2.4.16 Engineering
 	Fixed slapd ctxcsn race condition (ITS#6001)
 	Fixed slapd syncrepl newCookie sync messages (ITS#5972)
 	Fixed slapd syncrepl multiple CSN propagation (ITS#5973)
+	Fixed slapd syncrepl hang during shutdown (ITS#6011)
 	Fixed slapd-bdb/hdb cachesize handling (ITS#5860)
 	Fixed slapd-bdb/hdb with slapcat with empty dn (ITS#6006)
 	Fixed slapd-ldap incorrect referral handling (ITS#6003,ITS#5916)
diff --git a/servers/slapd/syncrepl.c b/servers/slapd/syncrepl.c
index 7ad5c813ab76ea8a10c92108faf63184673ac47d..ad38463a6261cc7cf2d6d5d52a334c01d664d92a 100644
--- a/servers/slapd/syncrepl.c
+++ b/servers/slapd/syncrepl.c
@@ -1260,6 +1260,8 @@ do_syncrepl(
 
 	/* Don't get stuck here while a pause is initiated */
 	while ( ldap_pvt_thread_mutex_trylock( &si->si_mutex )) {
+		if ( slapd_shutdown )
+			return NULL;
 		if ( !ldap_pvt_thread_pool_pausecheck( &connection_pool ))
 			ldap_pvt_thread_yield();
 	}