[#1880] Use commons-io API to avoid re-inventing the wheel -  fixed compilation error
Merge branch 'close-streams' into 1.3.x-codeborne