lts-cleanup-sandbox-refs: Handle empty output from "git ls-remote"

Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
Change-Id: I59eac8832c9a4860727630449862be34baa36ae0
diff --git a/lts/lts-cleanup-sandbox-refs.py b/lts/lts-cleanup-sandbox-refs.py
index 76b1dde..326e791 100755
--- a/lts/lts-cleanup-sandbox-refs.py
+++ b/lts/lts-cleanup-sandbox-refs.py
@@ -46,6 +46,8 @@
         out = check_output(["git", "ls-remote", REMOTE, ref_pat], text=True)
 
         for line in out.rstrip().split("\n"):
+            if not line:
+                break
             rev, tag = line.split(None, 1)
             m = re.match(r".+-(\d{8}T\d{4})", tag)
             delete = False