summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--include/perk/perk.h5
-rw-r--r--src/driver/pe_unit_ctx.c2
2 files changed, 2 insertions, 5 deletions
diff --git a/include/perk/perk.h b/include/perk/perk.h
index 670fefc..2ed6eed 100644
--- a/include/perk/perk.h
+++ b/include/perk/perk.h
@@ -35,6 +35,7 @@ extern "C" {
#define PERK_DRIVER_VERSION 0x0010
#define PERK_DRIVER_DRY_RUN 0x0020
+#define PERK_DRIVER_MAP_WRITE_ACCESS 0x0040
#define PERK_DRIVER_ANNOTATE_ALWAYS 0x1000
#define PERK_DRIVER_ANNOTATE_NEVER 0x2000
@@ -44,9 +45,6 @@ extern "C" {
#define PERK_DRIVER_AR_STRICT_PE_ARCH 0x20000
#define PERK_DRIVER_AR_OBJECT_VECTOR 0x40000
-/* unit action flags */
-#define PERK_ACTION_MAP_READWRITE 0x0001
-
/* error flags */
#define PERK_ERROR_TOP_LEVEL 0x0001
#define PERK_ERROR_NESTED 0x0002
@@ -214,7 +212,6 @@ struct pe_error_info {
struct pe_common_ctx {
uint64_t drvflags;
- uint64_t actflags;
uint64_t fmtflags;
uint64_t hdrdump;
enum pe_cmd cmd;
diff --git a/src/driver/pe_unit_ctx.c b/src/driver/pe_unit_ctx.c
index 0e0373a..a5509f4 100644
--- a/src/driver/pe_unit_ctx.c
+++ b/src/driver/pe_unit_ctx.c
@@ -143,7 +143,7 @@ int pe_lib_get_unit_ctx(
pe_driver_set_ectx(
dctx,0,path);
- prot = (dctx->cctx->actflags & PERK_ACTION_MAP_READWRITE)
+ prot = (dctx->cctx->drvflags & PERK_DRIVER_MAP_WRITE_ACCESS)
? PROT_READ | PROT_WRITE
: PROT_READ;