Added exact match feature to dtree lookup and fixed a lookup bug that caused one
extra lookup and possible segmentation fault.