detect wrong cwd