Skip to content
  • Luiz Capitulino's avatar
    migration: qmp_migrate(): keep working after syntax error · c9501142
    Luiz Capitulino authored
    If a user or QMP client enter a bad syntax for the migrate
    command in QMP/HMP, then the migrate command will never succeed
    from that point on.
    
    For example, if you enter:
    
    (qemu) migrate tcp;0:4444
    migrate: Parameter 'uri' expects a valid migration protocol
    
    Then the migrate command will always fail from now on:
    
    (qemu) migrate tcp:0:4444
    migrate: There's a migration process in progress
    
    The problem is that qmp_migrate() sets the migration status to
    MIG_STATE_SETUP and doesn't reset it on syntax error. This bug
    was introduced by commit 29ae8a41
    
    .
    
    Reviewed-by: default avatarMichael R. Hines <mrhines@us.ibm.com>
    Signed-off-by: default avatarLuiz Capitulino <lcapitulino@redhat.com>
    c9501142