Revision 8ac470c1

b/monitor.c
112 112
        int  (*cmd_async)(Monitor *mon, const QDict *params,
113 113
                          MonitorCompletion *cb, void *opaque);
114 114
    } mhandler;
115
    int async;
115
    int flags;
116 116
} mon_cmd_t;
117 117

  
118 118
/* file descriptors passed via SCM_RIGHTS */
......
327 327

  
328 328
static inline bool monitor_handler_is_async(const mon_cmd_t *cmd)
329 329
{
330
    return cmd->async != 0;
330
    return cmd->flags & MONITOR_CMD_ASYNC;
331 331
}
332 332

  
333 333
static inline int monitor_has_error(const Monitor *mon)
......
2536 2536
        .help       = "show balloon information",
2537 2537
        .user_print = monitor_print_balloon,
2538 2538
        .mhandler.info_async = do_info_balloon,
2539
        .async      = 1,
2539
        .flags      = MONITOR_CMD_ASYNC,
2540 2540
    },
2541 2541
    {
2542 2542
        .name       = "qtree",
b/monitor.h
15 15
#define MONITOR_USE_READLINE  0x02
16 16
#define MONITOR_USE_CONTROL   0x04
17 17

  
18
/* flags for monitor commands */
19
#define MONITOR_CMD_ASYNC       0x0001
20

  
18 21
/* QMP events */
19 22
typedef enum MonitorEvent {
20 23
    QEVENT_SHUTDOWN,
b/qemu-monitor.hx
1287 1287
        .help       = "request VM to change its memory allocation (in MB)",
1288 1288
        .user_print = monitor_user_noop,
1289 1289
        .mhandler.cmd_async = do_balloon,
1290
        .async      = 1,
1290
        .flags      = MONITOR_CMD_ASYNC,
1291 1291
    },
1292 1292

  
1293 1293
STEXI

Also available in: Unified diff