fix some shell bug