Fixed some small bug and compile problems.
3 files changed