minor changes in common.h, working on windows support