X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=fs%2Fecryptfs%2Fkeystore.c;h=3cf1546dca8257677572db866f86e3f2190a918e;hb=09cbfeaf1a5a67bfb3201e0c83c810cecb2efa5a;hp=c5c84dfb5b3e3e0cf488a38846d4897b19fd53d0;hpb=ef504fa591aae6f6ebdf26edbe6ec0bfd32ea7d3;p=mirror_ubuntu-zesty-kernel.git diff --git a/fs/ecryptfs/keystore.c b/fs/ecryptfs/keystore.c index c5c84dfb5b3e..3cf1546dca82 100644 --- a/fs/ecryptfs/keystore.c +++ b/fs/ecryptfs/keystore.c @@ -635,8 +635,7 @@ ecryptfs_write_tag_70_packet(char *dest, size_t *remaining_bytes, if (!s) { printk(KERN_ERR "%s: Out of memory whilst trying to kmalloc " "[%zd] bytes of kernel memory\n", __func__, sizeof(*s)); - rc = -ENOMEM; - goto out; + return -ENOMEM; } (*packet_size) = 0; rc = ecryptfs_find_auth_tok_for_sig( @@ -922,8 +921,7 @@ ecryptfs_parse_tag_70_packet(char **filename, size_t *filename_size, if (!s) { printk(KERN_ERR "%s: Out of memory whilst trying to kmalloc " "[%zd] bytes of kernel memory\n", __func__, sizeof(*s)); - rc = -ENOMEM; - goto out; + return -ENOMEM; } if (max_packet_size < ECRYPTFS_TAG_70_MIN_METADATA_SIZE) { printk(KERN_WARNING "%s: max_packet_size is [%zd]; it must be " @@ -1800,7 +1798,7 @@ int ecryptfs_parse_packet_set(struct ecryptfs_crypt_stat *crypt_stat, * added the our &auth_tok_list */ next_packet_is_auth_tok_packet = 1; while (next_packet_is_auth_tok_packet) { - size_t max_packet_size = ((PAGE_CACHE_SIZE - 8) - i); + size_t max_packet_size = ((PAGE_SIZE - 8) - i); switch (src[i]) { case ECRYPTFS_TAG_3_PACKET_TYPE: