VFS: workaround to allow TIOCSCTTY on PTYs
Fix /dev/tty-related issues in tmux(1) by hardcoding the PTY major in VFS in addition to the TTY major. Even though this is exactly what we did NOT want to have to do, the actual fix for this issue is going to take a little longer. Change-Id: I24c75eaf688b9ebd28e931f2e445b8442cfdac78
This commit is contained in:
		
							parent
							
								
									29e004d23b
								
							
						
					
					
						commit
						4b12166f26
					
				| @ -288,8 +288,9 @@ int cdev_io( | ||||
|   /* Handle TIOCSCTTY ioctl: set controlling tty.
 | ||||
|    * TODO: cleaner implementation work in progress. | ||||
|    */ | ||||
|   if (op == CDEV_IOCTL && bytes == TIOCSCTTY && major(dev) == TTY_MAJOR) { | ||||
|        fp->fp_tty = dev; | ||||
|   if (op == CDEV_IOCTL && bytes == TIOCSCTTY && | ||||
|      (major(dev) == TTY_MAJOR || major(dev) == PTY_MAJOR)) { | ||||
| 	fp->fp_tty = dev; | ||||
|   } | ||||
| 
 | ||||
|   /* Create a grant for the buffer provided by the user process. */ | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 David van Moolenbroek
						David van Moolenbroek