matched flag fixed