virtiofsd: Silence gcc warning
Gcc worries fd might be used unset, in reality it's always set if fi is set, and only used if fi is set so it's safe. Initialise it to -1 just to keep gcc happy for now. Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Message-Id: <20200827153657.111098-2-dgilbert@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com> Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
This commit is contained in:
		
							parent
							
								
									2387df497b
								
							
						
					
					
						commit
						2acf4f8fdd
					
				@ -620,7 +620,7 @@ static void lo_setattr(fuse_req_t req, fuse_ino_t ino, struct stat *attr,
 | 
				
			|||||||
    struct lo_inode *inode;
 | 
					    struct lo_inode *inode;
 | 
				
			||||||
    int ifd;
 | 
					    int ifd;
 | 
				
			||||||
    int res;
 | 
					    int res;
 | 
				
			||||||
    int fd;
 | 
					    int fd = -1;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    inode = lo_inode(req, ino);
 | 
					    inode = lo_inode(req, ino);
 | 
				
			||||||
    if (!inode) {
 | 
					    if (!inode) {
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user