Fixed code to build on linux