Rizin
unix-like reverse engineering framework and cli tools
cmd_windows_heap.c
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: 2021 Pulak Malhotra <pulakmalhotra2000@gmail.com>
2 // SPDX-License-Identifier: LGPL-3.0-only
3 
4 #include <rz_core.h>
5 #include "../core_private.h"
6 
7 #define NOT_SUPPORTED_ERROR_MESSAGE \
8  eprintf("Windows heap parsing is not supported on this platform\n"); \
9  return RZ_CMD_STATUS_ERROR;
10 
11 #if __WINDOWS__
13  rz_heap_list_w32(core, mode);
14  return RZ_CMD_STATUS_OK;
15 }
16 
18  if (argc == 2) {
19  rz_heap_debug_block_win(core, argv[1], mode, false);
20  } else {
21  rz_heap_debug_block_win(core, NULL, mode, false);
22  }
23  return RZ_CMD_STATUS_OK;
24 }
25 
26 RZ_IPI RzCmdStatus rz_cmd_debug_heap_block_flag_handler(RzCore *core, int argc, const char **argv) {
28  return RZ_CMD_STATUS_OK;
29 }
30 
31 #else
34 }
35 
38 }
39 
42 }
43 #endif
#define RZ_IPI
Definition: analysis_wasm.c:11
RZ_IPI RzCmdStatus rz_cmd_debug_heap_block_flag_handler(RzCore *core, int argc, const char **argv)
RZ_IPI RzCmdStatus rz_cmd_debug_process_heaps_handler(RzCore *core, int argc, const char **argv, RzOutputMode mode)
#define NOT_SUPPORTED_ERROR_MESSAGE
RZ_IPI RzCmdStatus rz_cmd_debug_process_heap_block_handler(RzCore *core, int argc, const char **argv, RzOutputMode mode)
#define NULL
Definition: cris-opc.c:27
const char int mode
Definition: ioapi.h:137
static static fork const void static count static fd const char const char static newpath char char argv
Definition: sflib.h:40
enum rz_cmd_status_t RzCmdStatus
@ RZ_CMD_STATUS_OK
command handler exited in the right way
Definition: rz_cmd.h:24
RzOutputMode
Enum to describe the way data are printed.
Definition: rz_types.h:38
@ RZ_OUTPUT_MODE_STANDARD
Definition: rz_types.h:39
RZ_IPI void rz_heap_list_w32(RzCore *core, RzOutputMode mode)
RZ_IPI void rz_heap_debug_block_win(RzCore *core, const char *addr, RzOutputMode mode, bool flag)