Skip to content

Commit 6e3587d

Browse files
committed
fix DIET build by #ifdef-ing code that uses struct fields not available in DIET configuration
1 parent 7117a43 commit 6e3587d

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

arch/RISCV/RISCVMapping.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,12 +107,16 @@ void RISCV_add_groups(MCInst *MI) {
107107
return;
108108

109109
MI->flat_insn->detail->groups_count = 0;
110+
111+
#ifndef CAPSTONE_DIET
110112
int i = 0;
111113
while (insns[MI->Opcode].groups[i] != 0) {
112114

113115
add_group(MI, insns[MI->Opcode].groups[i]);
114116
i++;
115117
}
118+
#endif
119+
116120
RISCV_add_adhoc_groups(MI);
117121
}
118122

0 commit comments

Comments
 (0)