Fix obdir detection