In jsonb code, clean up temp memory contexts after processing.

same as recent fix in json code on master/9.3.