• Jeff Layton's avatar
    [CIFS] fix oops on second mount to same server when null auth is used · 9b8f5f57
    Jeff Layton authored
    When a share is mounted using no username, cifs_mount sets
    volume_info.username as a NULL pointer, and the sesInfo userName as an
    empty string. The volume_info.username is passed to a couple of other
    functions to see if there is an existing unc or tcp connection that can
    be used. These functions assume that the username will be a valid
    string that can be passed to strncmp. If the pointer is NULL, then the
    kernel will oops if there's an existing session to which the string
    can be compared.
    
    This patch changes cifs_mount to set volume_info.username to an empty
    string in this situation, which prevents the oops and should make it
    so that the comparison to other null auth sessions match.
    Signed-off-by: default avatarJeff Layton <jlayton@redhat.com>
    Signed-off-by: default avatarSteve French <sfrench@us.ibm.com>
    9b8f5f57
To find the state of this project's repository at the time of any of these versions, check out the tags.
CHANGES 38.6 KB