mirror of
https://github.com/rizinorg/rizin
synced 2026-08-22 20:26:16 -04:00
Make rz_analysis_op_is_call() treat op->type 's as enum values rather than bit flags (#6631)
This commit is contained in:
parent
cc06c1dedb
commit
e49ce34306
1 changed files with 10 additions and 3 deletions
|
|
@ -979,11 +979,18 @@ RZ_API bool rz_analysis_op_is_eob(const RzAnalysisOp *op) {
|
|||
*/
|
||||
RZ_API bool rz_analysis_op_is_call(RZ_NONNULL const RzAnalysisOp *op) {
|
||||
rz_return_val_if_fail(op, false);
|
||||
if ((op->type & RZ_ANALYSIS_OP_TYPE_CALL) == RZ_ANALYSIS_OP_TYPE_CALL ||
|
||||
(op->type & RZ_ANALYSIS_OP_TYPE_UCALL) == RZ_ANALYSIS_OP_TYPE_UCALL) {
|
||||
switch (op->type & RZ_ANALYSIS_OP_TYPE_MASK) {
|
||||
case RZ_ANALYSIS_OP_TYPE_CALL:
|
||||
case RZ_ANALYSIS_OP_TYPE_UCALL:
|
||||
case RZ_ANALYSIS_OP_TYPE_RCALL:
|
||||
case RZ_ANALYSIS_OP_TYPE_ICALL:
|
||||
case RZ_ANALYSIS_OP_TYPE_IRCALL:
|
||||
case RZ_ANALYSIS_OP_TYPE_CCALL:
|
||||
case RZ_ANALYSIS_OP_TYPE_UCCALL:
|
||||
return true;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
RZ_API void rz_analysis_purge(RzAnalysis *analysis) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue