More fixes

- Fixes build issue on case-sensitive HFS (see https://github.com/angband/angband/pull/253)
- Fixes polymorph crash by allowing monsters to be placed on objects. This seemed to be the main reason that it was crashing. However, this does not prevent project_m() from crashing if m_ptr is null; it would seem to be a bigger project to do that.
- Fixes/highlights some things as pointed out by the analyzer.