#3073 (feature/session): Fix a GC issue with the files driver