fix some bugs for evn issue