diff options
| author | Steve McIntyre <93sam@debian.org> | 2021-02-21 13:46:16 +0000 |
|---|---|---|
| committer | Steve McIntyre <93sam@debian.org> | 2021-02-21 13:46:16 +0000 |
| commit | 2a55644555e3c9bb1d948ab817b047123c1dcfd9 (patch) | |
| tree | f3c68875b270405a4cf93cec1b9aa5fb567e0c48 /Cryptlib/OpenSSL/crypto/comp/comp_lib.c | |
| parent | 379f0954e0632f29f5154a0157a046ef20053121 (diff) | |
| parent | 888f5b544b7cce3cdae8074aa617b1d4add271a1 (diff) | |
| download | efi-boot-shim-2a55644555e3c9bb1d948ab817b047123c1dcfd9.tar.gz efi-boot-shim-2a55644555e3c9bb1d948ab817b047123c1dcfd9.zip | |
Update upstream source from tag 'upstream/15+1613861442.888f5b5'
Update to upstream version '15+1613861442.888f5b5'
with Debian dir 15b0853a73144b1f8571ce2bebc2eea68af4a8e3
Diffstat (limited to 'Cryptlib/OpenSSL/crypto/comp/comp_lib.c')
| -rw-r--r-- | Cryptlib/OpenSSL/crypto/comp/comp_lib.c | 37 |
1 files changed, 6 insertions, 31 deletions
diff --git a/Cryptlib/OpenSSL/crypto/comp/comp_lib.c b/Cryptlib/OpenSSL/crypto/comp/comp_lib.c index 32afd0db..bd4eb7a1 100644 --- a/Cryptlib/OpenSSL/crypto/comp/comp_lib.c +++ b/Cryptlib/OpenSSL/crypto/comp/comp_lib.c @@ -1,25 +1,18 @@ -/* - * Copyright 1998-2016 The OpenSSL Project Authors. All Rights Reserved. - * - * Licensed under the OpenSSL license (the "License"). You may not use - * this file except in compliance with the License. You can obtain a copy - * in the file LICENSE in the source distribution or at - * https://www.openssl.org/source/license.html - */ - #include <stdio.h> #include <stdlib.h> #include <string.h> #include <openssl/objects.h> #include <openssl/comp.h> -#include "comp_lcl.h" COMP_CTX *COMP_CTX_new(COMP_METHOD *meth) { COMP_CTX *ret; - if ((ret = OPENSSL_zalloc(sizeof(*ret))) == NULL) + if ((ret = (COMP_CTX *)OPENSSL_malloc(sizeof(COMP_CTX))) == NULL) { + /* ZZZZZZZZZZZZZZZZ */ return (NULL); + } + memset(ret, 0, sizeof(COMP_CTX)); ret->meth = meth; if ((ret->meth->init != NULL) && !ret->meth->init(ret)) { OPENSSL_free(ret); @@ -28,21 +21,6 @@ COMP_CTX *COMP_CTX_new(COMP_METHOD *meth) return (ret); } -const COMP_METHOD *COMP_CTX_get_method(const COMP_CTX *ctx) -{ - return ctx->meth; -} - -int COMP_get_type(const COMP_METHOD *meth) -{ - return meth->type; -} - -const char *COMP_get_name(const COMP_METHOD *meth) -{ - return meth->name; -} - void COMP_CTX_free(COMP_CTX *ctx) { if (ctx == NULL) @@ -59,6 +37,7 @@ int COMP_compress_block(COMP_CTX *ctx, unsigned char *out, int olen, { int ret; if (ctx->meth->compress == NULL) { + /* ZZZZZZZZZZZZZZZZZ */ return (-1); } ret = ctx->meth->compress(ctx, out, olen, in, ilen); @@ -75,6 +54,7 @@ int COMP_expand_block(COMP_CTX *ctx, unsigned char *out, int olen, int ret; if (ctx->meth->expand == NULL) { + /* ZZZZZZZZZZZZZZZZZ */ return (-1); } ret = ctx->meth->expand(ctx, out, olen, in, ilen); @@ -84,8 +64,3 @@ int COMP_expand_block(COMP_CTX *ctx, unsigned char *out, int olen, } return (ret); } - -int COMP_CTX_get_type(const COMP_CTX* comp) -{ - return comp->meth ? comp->meth->type : NID_undef; -} |
