// common.cpp kCvar test("test", "test cvar", 1337.0f); kCmd testCmd("testCmd", "test command", testCallback); // cmd.cpp kCmdSystem *cmdSys = new kCmdSystem; // cvar.cpp kCvarSystem *cvarSys = new kCvarSystem; i get a segfault in the constructor for testCmd. cmdSys is NULL at this point. however, cvarSys is not. i'm betting on undefined behavior. the constructors for kCvar and kCmd call functions inside cvarSys and cmdSys, respectively.