Fixed coding style and some other things.