提交 0a40c543 编写于 作者: Z zhOu 提交者: Gitee

修复dev 文件夹mmap bug

上级 e901790b
......@@ -661,7 +661,7 @@ STATUS_T OsNamedMMap(struct file *filep, LosVmMapRegion *region)
return LOS_ERRNO_VM_MAP_FAILED;
}
} else if (INODE_IS_DRIVER(inodePtr)) {
if (inodePtr->u.i_ops->mmap) {
if (inodePtr->u.i_ops && inodePtr->u.i_ops->mmap) {
LOS_SetRegionTypeDev(region);
return inodePtr->u.i_ops->mmap(filep, region);
} else {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册