mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 04:32:44 +00:00 
			
		
		
		
	Kernel: Make SharedInodeVMObject allocation OOM-safe
This commit is contained in:
		
							parent
							
								
									59049ae4b7
								
							
						
					
					
						commit
						af8c74a328
					
				
					 4 changed files with 17 additions and 6 deletions
				
			
		|  | @ -97,7 +97,7 @@ KResultOr<Region*> InodeFile::mmap(Process& process, FileDescription& descriptio | |||
|     // FIXME: If PROT_EXEC, check that the underlying file system isn't mounted noexec.
 | ||||
|     RefPtr<InodeVMObject> vmobject; | ||||
|     if (shared) | ||||
|         vmobject = SharedInodeVMObject::create_with_inode(inode()); | ||||
|         vmobject = SharedInodeVMObject::try_create_with_inode(inode()); | ||||
|     else | ||||
|         vmobject = PrivateInodeVMObject::create_with_inode(inode()); | ||||
|     if (!vmobject) | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Andreas Kling
						Andreas Kling