[#2212] CID25612 and CID25852:

genQueryOutToCollRes no longer incorrectly frees collSqlResult,
which is subsequently no longer dereferenced after free.