updated cncom.h:IsWeaklyConn() so that it does not crash for empty graphs