diff options
author | David Timber <mieabby@gmail.com> | 2020-01-03 20:16:38 +1100 |
---|---|---|
committer | David Timber <mieabby@gmail.com> | 2020-01-03 20:16:38 +1100 |
commit | 1120c866527fe439fb51e24fc2e512a24e79c37a (patch) | |
tree | 53d7b122ffcc7d34a19b50dadfb822c4ab994118 /src/proone-unpack.c | |
parent | 9a2a07861e3919ea2d8f3b4f36e2d51d7748ba9d (diff) |
removed openssl dep.
Diffstat (limited to 'src/proone-unpack.c')
-rw-r--r-- | src/proone-unpack.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/proone-unpack.c b/src/proone-unpack.c index 32b80da..d865bd4 100644 --- a/src/proone-unpack.c +++ b/src/proone-unpack.c @@ -6,8 +6,8 @@ #include <unistd.h> #include <fcntl.h> -#include <openssl/err.h> #include <zlib.h> +#include <mbedtls/error.h> #include "pack.h" #include "util_rt.h" @@ -15,14 +15,16 @@ static void report_unpack_bin_archive_err (const prne_unpack_bin_archive_result_t *r) { const char *err_str, *err_msg = NULL; + char err_buf[1024]; switch (r->result) { case PRNE_UNPACK_BIN_ARCHIVE_OK: err_str = "ok"; break; - case PRNE_UNPACK_BIN_ARCHIVE_OPENSSL_ERR: - err_str = "openssl error"; - err_msg = ERR_error_string(r->err, NULL); + case PRNE_UNPACK_BIN_ARCHIVE_CRYPTO_ERR: + err_str = "crypto error"; + mbedtls_strerror(r->err, err_buf, 1024); + err_msg = err_buf; break; case PRNE_UNPACK_BIN_ARCHIVE_Z_ERR: err_str = "zlib error"; |