HPCC-9010 Check query tree branch before using it

When a query is deleted, it's tree branch is removed from the
'queryset' tree. The existing code tries to set the 'suspended'
attribute for the tree branch, which causes the core. This fix
checks the query branch before setting the 'suspended' attribute.

Signed-off-by: Kevin Wang <kevin.wang@lexisnexis.com>
Merge pull request #4341 from richardkchapman/cherry-pick

HPCC-9010 Check query tree branch before using it

Reviewed-By: Richard Chapman <rchapman@hpccsystems.com>
Community Edition 3.10.8-1 Gold

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>
Merge remote-tracking branch 'origin/candidate-3.10.8' into candidate-3.10.x

Conflicts:
	version.cmake

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>