                        open(unit=u_live,file=livename,status='old')
                        i=0
                        do
                                i=i+1
                                read(u_live,*,IOSTAT=iostatus) p(1:ndims,i),l(i)
                                if(iostatus<0) then
                                        i=i-1
                                        if(i<nlive) then
                                                write(*,*)"ERROR: live points file has less than ",nlive," points."
                                                write(*,*)"Aborting"
#ifdef MPI
                                                call MPI_ABORT(MPI_COMM_WORLD,errcode)
#endif
                                                stop
                                        endif
                                        exit
                                endif
                                if(i>nlive) then
                                        write(*,*)"ERROR: live points file has greater than ",nlive," points."
                                        write(*,*)"Aborting"
#ifdef MPI
                                        call MPI_ABORT(MPI_COMM_WORLD,errcode)
#endif
                                        stop
                                endif
                        enddo
                        close(u_live)

! ERROR: live points file has less than        20000  points. ndims=           8 
!  i=       10000
! Aborting
!
! "live points file" is LargeLogMasseslive.points and i give the output of wc for it below
!
!  [akulasuj@qb1 HiggsNS]$ wc LargeLogMasseslive.points 
!    20000  160000 4500000 LargeLogMasseslive.points
!
