modlib:Allow loading elf from block devices

Signed-off-by: anjiahao <anjiahao@xiaomi.com>
This commit is contained in:
anjiahao 2024-07-18 17:04:53 +08:00 committed by Xiang Xiao
parent 434442d707
commit 4f92d7aafd
1 changed files with 0 additions and 8 deletions

View File

@ -70,14 +70,6 @@ static inline int modlib_fileinfo(FAR struct mod_loadinfo_s *loadinfo)
return -errval;
}
/* Verify that it is a regular file */
if (!S_ISREG(buf.st_mode))
{
berr("ERROR: Not a regular file. mode: %d\n", buf.st_mode);
return -ENOENT;
}
/* Return some stats info of the file in the loadinfo structure */
loadinfo->filelen = buf.st_size;