• Al Viro's avatar
    cifs: fix the race in cifs_writev() · 19dfc1f5
    Al Viro authored
    O_APPEND handling there hadn't been completely fixed by Pavel's
    patch; it checks the right value, but it's racy - we can't really
    do that until i_mutex has been taken.
    
    Fix by switching to __generic_file_aio_write() (open-coding
    generic_file_aio_write(), actually) and pulling mutex_lock() above
    inode_size_read().
    
    Cc: stable@vger.kernel.org
    Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
    19dfc1f5
file.c 95.8 KB