Fix a bug in select() with considering of node.count