Linux build fix.
Fix an assign. Some other misc changes.
Merge pull request #120 from xsacha/master

Linux build fix