Fix file type error for block devices