Commit b939eb89 authored by Daniel P. Berrangé's avatar Daniel P. Berrangé Committed by Gerd Hoffmann
Browse files

ui: remove redundant indentation in vnc_client_update



Now that previous dead / unreachable code has been removed, we can simplify
the indentation in the vnc_client_update method.

Signed-off-by: default avatarDaniel P. Berrange <berrange@redhat.com>
Reviewed-by: default avatarDarren Kenny <darren.kenny@oracle.com>
Reviewed-by: default avatarMarc-André Lureau <marcandre.lureau@redhat.com>
Message-id: 20171218191228.31018-4-berrange@redhat.com
Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
parent c53df961
Loading
Loading
Loading
Loading
+57 −55
Original line number Diff line number Diff line
@@ -963,25 +963,30 @@ static int find_and_clear_dirty_height(VncState *vs,

static int vnc_update_client(VncState *vs, int has_dirty)
{
    VncDisplay *vd = vs->vd;
    VncJob *job;
    int y;
    int height, width;
    int n = 0;

    if (vs->disconnecting) {
        vnc_disconnect_finish(vs);
        return 0;
    }

    vs->has_dirty += has_dirty;
    if (vs->need_update) {
        VncDisplay *vd = vs->vd;
        VncJob *job;
        int y;
        int height, width;
        int n = 0;
    if (!vs->need_update) {
        return 0;
    }

        if (vs->output.offset && !vs->audio_cap && !vs->force_update)
    if (vs->output.offset && !vs->audio_cap && !vs->force_update) {
        /* kernel send buffers are full -> drop frames to throttle */
        return 0;
    }

        if (!vs->has_dirty && !vs->audio_cap && !vs->force_update)
    if (!vs->has_dirty && !vs->audio_cap && !vs->force_update) {
        return 0;
    }

    /*
     * Send screen updates to the vnc client using the server
@@ -1030,9 +1035,6 @@ static int vnc_update_client(VncState *vs, int has_dirty)
    return n;
}

    return 0;
}

/* audio */
static void audio_capture_notify(void *opaque, audcnotification_e cmd)
{