Merge commit '03fa848afd16ee678e2d04ec824794893f199804' * commit '03fa848afd16ee678e2d04ec824794893f199804': Fix RS bugs. We were holding a pointer to the script text from the java vm. Move freeing of objects to before context teardown to allow allocations to clean up their data.