some small changes of codes.