added timeout to getlocation