Skip to content

Commit

Permalink
modify CMD2_DL
Browse files Browse the repository at this point in the history
  • Loading branch information
Young-Flash committed Aug 24, 2022
1 parent 2ad4395 commit f565fe0
Show file tree
Hide file tree
Showing 4 changed files with 93 additions and 89 deletions.
8 changes: 6 additions & 2 deletions include/command_helpers.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,12 @@ cleanup_commands();
#define CMD2_ANY_LIST(key, slot) \
CMD2_A_FUNCTION(key, command_base_call_list<rpc::target_type>, slot, "i:", "")

#define CMD2_DL(key, slot) \
CMD2_A_FUNCTION(key, command_base_call<core::Download*>, slot, "i:", "")
#define CMD2_DL(key, slot, is_readonly) \
do { \
if (is_readonly) rpc::readonly_command.insert(key); \
CMD2_A_FUNCTION(key, command_base_call<core::Download*>, slot, "i:", "") \
} while (0) \

#define CMD2_DL_V(key, slot) \
CMD2_A_FUNCTION(key, \
command_base_call<core::Download*>, \
Expand Down
Loading

0 comments on commit f565fe0

Please sign in to comment.