wg: propagate set errno
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
This commit is contained in:
		
							parent
							
								
									a773a23c75
								
							
						
					
					
						commit
						a8baff2ab3
					
				
					 1 changed files with 1 additions and 0 deletions
				
			
		| 
						 | 
					@ -201,6 +201,7 @@ static int userspace_set_device(struct wgdevice *dev)
 | 
				
			||||||
	ret = ret_code;
 | 
						ret = ret_code;
 | 
				
			||||||
out:
 | 
					out:
 | 
				
			||||||
	close_and_unlink(fd);
 | 
						close_and_unlink(fd);
 | 
				
			||||||
 | 
						errno = -ret;
 | 
				
			||||||
	return (int)ret;
 | 
						return (int)ret;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue