diff --git a/main/pbx.c b/main/pbx.c
index 700c4f51701f62ea8cb6322ea3825ff994319800..fd914ef4e83cb686753b53554aa0d4f96e94ee8b 100644
--- a/main/pbx.c
+++ b/main/pbx.c
@@ -1586,11 +1586,14 @@ struct ast_exten *pbx_find_extension(struct ast_channel *chan,
 		return NULL;
 	}
 
-	if (!eroot && action == E_CANMATCH && score.canmatch_exten) {
+	if (!eroot && (action == E_CANMATCH || action == E_MATCHMORE) && score.canmatch_exten) {
 		q->status = STATUS_SUCCESS;
 		return score.canmatch_exten;
 	}
 
+	if (action == E_MATCHMORE && eroot)
+		return NULL;  /* according to the code, complete matches are null matches in MATCHMORE mode */
+
 	if (eroot) {
 		/* found entry, now look for the right priority */
 		if (q->status < STATUS_NO_PRIORITY)