data tree BUGFIX support unlinking opaque nodes

Fixes #1074
diff --git a/tests/src/test_parser_xml.c b/tests/src/test_parser_xml.c
index 3f17953..e0357d7 100644
--- a/tests/src/test_parser_xml.c
+++ b/tests/src/test_parser_xml.c
@@ -373,6 +373,11 @@
     free(str);
     lyd_free_all(tree);
 
+    /* opaq flag and fail */
+    assert_int_equal(LY_EVALID, lyd_parse_xml_data(ctx, "<a xmlns=\"ns\"><b>x</b><c xml:id=\"D\">1</c></a>",
+            LYD_OPT_OPAQ | LYD_VALOPT_DATA_ONLY, &tree));
+    assert_null(tree);
+
     *state = NULL;
 }