Fixed sensors file continuation
Fixed the open files leak