Loading include/qapi/qmp/dispatch.h +1 −0 Original line number Diff line number Diff line Loading @@ -36,6 +36,7 @@ typedef struct QmpCommand void qmp_register_command(const char *name, QmpCommandFunc *fn, QmpCommandOptions options); void qmp_unregister_command(const char *name); QmpCommand *qmp_find_command(const char *name); QObject *qmp_dispatch(QObject *request); void qmp_disable_command(const char *name); Loading qapi/qmp-registry.c +8 −0 Original line number Diff line number Diff line Loading @@ -30,6 +30,14 @@ void qmp_register_command(const char *name, QmpCommandFunc *fn, QTAILQ_INSERT_TAIL(&qmp_commands, cmd, node); } void qmp_unregister_command(const char *name) { QmpCommand *cmd = qmp_find_command(name); QTAILQ_REMOVE(&qmp_commands, cmd, node); g_free(cmd); } QmpCommand *qmp_find_command(const char *name) { QmpCommand *cmd; Loading Loading
include/qapi/qmp/dispatch.h +1 −0 Original line number Diff line number Diff line Loading @@ -36,6 +36,7 @@ typedef struct QmpCommand void qmp_register_command(const char *name, QmpCommandFunc *fn, QmpCommandOptions options); void qmp_unregister_command(const char *name); QmpCommand *qmp_find_command(const char *name); QObject *qmp_dispatch(QObject *request); void qmp_disable_command(const char *name); Loading
qapi/qmp-registry.c +8 −0 Original line number Diff line number Diff line Loading @@ -30,6 +30,14 @@ void qmp_register_command(const char *name, QmpCommandFunc *fn, QTAILQ_INSERT_TAIL(&qmp_commands, cmd, node); } void qmp_unregister_command(const char *name) { QmpCommand *cmd = qmp_find_command(name); QTAILQ_REMOVE(&qmp_commands, cmd, node); g_free(cmd); } QmpCommand *qmp_find_command(const char *name) { QmpCommand *cmd; Loading