[SPARK-3546] InputStream of ManagedBuffer is not closed and causes running out of file descriptor

Ah, do you mean line 122 - 124 should be out of try block? I agree with that.