Compilation fixes for master branch 

These 2 patches fix a compilation error and clean up some of the simple compilation warnings