• Eric Biggers's avatar
    KEYS: remove unnecessary get/put of explicit dest_keyring · a2d8737d
    Eric Biggers authored
    In request_key_and_link(), in the case where the dest_keyring was
    explicitly specified, there is no need to get another reference to
    dest_keyring before calling key_link(), then drop it afterwards.  This
    is because by definition, we already have a reference to dest_keyring.
    
    This change is useful because we'll be making
    construct_get_dest_keyring() able to return an error code, and we don't
    want to have to handle that error here for no reason.
    Signed-off-by: default avatarEric Biggers <ebiggers@google.com>
    Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
    a2d8737d
request_key.c 19.6 KB