tree-wide: remove unnecessary __UNCONST usage.
This commit is contained in:
parent
1e39f21f51
commit
47df729bcc
@ -30,10 +30,6 @@
|
||||
|
||||
#include "../xbps-install/defs.h"
|
||||
|
||||
#ifndef __UNCONST
|
||||
#define __UNCONST(a) ((void *)(unsigned long)(const void *)(a))
|
||||
#endif
|
||||
|
||||
/* from show-deps.c */
|
||||
int show_pkg_deps(struct xbps_handle *, const char *, bool, bool);
|
||||
int show_pkg_revdeps(struct xbps_handle *, const char *, bool);
|
||||
|
@ -60,10 +60,6 @@
|
||||
|
||||
#endif
|
||||
|
||||
#ifndef __UNCONST
|
||||
#define __UNCONST(a) ((void *)(unsigned long)(const void *)(a))
|
||||
#endif
|
||||
|
||||
#define _XBPS_RINDEX "xbps-rindex"
|
||||
|
||||
/* From index-add.c */
|
||||
|
@ -51,7 +51,7 @@ set_extract_flags(uid_t euid)
|
||||
static bool
|
||||
match_preserved_file(struct xbps_handle *xhp, const char *entry)
|
||||
{
|
||||
char *file;
|
||||
const char *file;
|
||||
|
||||
if (xhp->preserved_files == NULL)
|
||||
return false;
|
||||
@ -60,7 +60,7 @@ match_preserved_file(struct xbps_handle *xhp, const char *entry)
|
||||
file = strchr(entry, '.') + 1;
|
||||
assert(file);
|
||||
} else {
|
||||
file = __UNCONST(entry);
|
||||
file = entry;
|
||||
}
|
||||
|
||||
return xbps_match_string_in_array(xhp->preserved_files, file);
|
||||
|
@ -83,7 +83,7 @@ xbps_pubkey2fp(struct xbps_handle *xhp, xbps_data_t pubkey)
|
||||
mdctx = EVP_MD_CTX_new();
|
||||
assert(mdctx);
|
||||
pubkeydata = xbps_data_data_nocopy(pubkey);
|
||||
bio = BIO_new_mem_buf(__UNCONST(pubkeydata), xbps_data_size(pubkey));
|
||||
bio = BIO_new_mem_buf(pubkeydata, xbps_data_size(pubkey));
|
||||
assert(bio);
|
||||
|
||||
pPubKey = PEM_read_bio_PUBKEY(bio, NULL, NULL, NULL);
|
||||
|
@ -52,7 +52,7 @@ rsa_verify_hash(struct xbps_repo *repo, xbps_data_t pubkey,
|
||||
ERR_load_crypto_strings();
|
||||
SSL_load_error_strings();
|
||||
|
||||
bio = BIO_new_mem_buf(__UNCONST(xbps_data_data_nocopy(pubkey)),
|
||||
bio = BIO_new_mem_buf(xbps_data_data_nocopy(pubkey),
|
||||
xbps_data_size(pubkey));
|
||||
assert(bio);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user