fix a few things in common.h, not compiling yet