The problem here is that if an exception is thrown during the read process the method will exit without closing the stream and hence without releasing the file system resources, it may run out of resources before it does run.I will make a commit in github right now.
I've made a pull request in https://github.com/apache/log4j/pull/2/files to resolve the bug.
Note that v1 is not actively maintained. I strongly encourage you to migrate to v2, which includes a v1.2 compatibility layer.