fix add point issue #136, error when running from console