where condition, some bugs fixed.
fix most selection bugs. Fix address bug in 64 bit OS.
Merge.