fix a bug causes editing extra hosts when their names match in regexp. related: #72. thanks @wangtai for the report.