Skip to content

Commit aa36e6f

Browse files
committed
Fix bug in extracting empty tree.
1 parent f0c5735 commit aa36e6f

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

jsquery_extract.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -574,9 +574,12 @@ extractJsQuery(JsQuery *jq, MakeEntryHandler handler, Pointer extra)
574574
ExtractedNode *root;
575575

576576
root = recursiveExtract(VARDATA(jq), 0, false, NULL);
577-
flatternTree(root);
578-
simplifyRecursive(root);
579-
root = makeEntries(root, handler, extra);
577+
if (root)
578+
{
579+
flatternTree(root);
580+
simplifyRecursive(root);
581+
root = makeEntries(root, handler, extra);
582+
}
580583
return root;
581584
}
582585

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy