summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSarven Capadisli <csarven@status.net>2010-03-03 22:58:28 -0500
committerSarven Capadisli <csarven@status.net>2010-03-03 22:58:28 -0500
commit239750aa0001b0b1ea5076f6f71ed6ffbb433c31 (patch)
treeefc9a842df9238dd1b6fc81a88a6d5cdac9e8c73
parentde687d00c0ebe8bf5d185b7037df7f1edfd368a3 (diff)
parent24835c1164251e48037f6ddee14e4b696fe57320 (diff)
Merge branch 'testing' of git@gitorious.org:statusnet/mainline into testing
-rw-r--r--plugins/OStatus/lib/xrd.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/plugins/OStatus/lib/xrd.php b/plugins/OStatus/lib/xrd.php
index f00e1f809..aa13ef024 100644
--- a/plugins/OStatus/lib/xrd.php
+++ b/plugins/OStatus/lib/xrd.php
@@ -57,6 +57,9 @@ class XRD
throw new Exception("Invalid XML");
}
$xrd_element = $dom->getElementsByTagName('XRD')->item(0);
+ if (!$xrd_element) {
+ throw new Exception("Invalid XML, missing XRD root");
+ }
// Check for host-meta host
$host = $xrd_element->getElementsByTagName('Host')->item(0);