Rizin
unix-like reverse engineering framework and cli tools
asm_null.c
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: 2019 pancake <pancake@nopcode.org>
2 // SPDX-License-Identifier: LGPL-3.0-only
3 
4 #include <stdio.h>
5 #include <string.h>
6 #include <rz_types.h>
7 #include <rz_lib.h>
8 #include <rz_asm.h>
9 
10 static int disassemble(RzAsm *a, RzAsmOp *op, const ut8 *buf, int len) {
11  int opsz = 0;
12  rz_strbuf_set(&op->buf_asm, "");
13  op->size = opsz;
14  return opsz;
15 }
16 
17 static int assemble(RzAsm *a, RzAsmOp *op, const char *buf) {
18  return 0;
19 }
20 
22  .name = "null",
23  .author = "pancake",
24  .version = "1.0.0",
25  .arch = "null",
26  .license = "MIT",
27  .bits = 16 | 32 | 64,
28  .endian = RZ_SYS_ENDIAN_NONE,
29  .desc = "no disassemble",
30  .disassemble = &disassemble,
31  .assemble = &assemble
32 };
33 
34 #ifndef RZ_PLUGIN_INCORE
37  .data = &rz_asm_plugin_null,
39 };
40 #endif
size_t len
Definition: 6502dis.c:15
RzAsmPlugin rz_asm_plugin_null
Definition: asm_null.c:21
RZ_API RzLibStruct rizin_plugin
Definition: asm_null.c:35
static int disassemble(RzAsm *a, RzAsmOp *op, const ut8 *buf, int len)
Definition: asm_null.c:10
static int assemble(RzAsm *a, RzAsmOp *op, const char *buf)
Definition: asm_null.c:17
#define RZ_API
voidpf void * buf
Definition: ioapi.h:138
uint8_t ut8
Definition: lh5801.h:11
@ RZ_LIB_TYPE_ASM
Definition: rz_lib.h:72
RZ_API const char * rz_strbuf_set(RzStrBuf *sb, const char *s)
Definition: strbuf.c:153
#define RZ_SYS_ENDIAN_NONE
Definition: rz_types.h:525
#define RZ_VERSION
Definition: rz_version.h:8
#define a(i)
Definition: sha256.c:41
const char * name
Definition: rz_asm.h:130
const char * version
Definition: rz_asm.h:133
Definition: dis.c:32