simon-git: putty (master): Simon Tatham

Commits to Tartarus hosted VCS tartarus-commits at lists.tartarus.org
Fri Apr 3 18:02:12 BST 2020


TL;DR:
  e4b6a7ef Fix null-dereference in ssh2_channel_response.
  0fd30113 gtk: fill in missing case in scroll_event().

Repository:     https://git.tartarus.org/simon/putty.git
On the web:     https://git.tartarus.org/?p=simon/putty.git
Branch updated: master
Committer:      Simon Tatham <anakin at pobox.com>
Date:           2020-04-03 18:02:12

commit e4b6a7efd2cab27a681c9a832f6c650abf57c7be
web diff https://git.tartarus.org/?p=simon/putty.git;a=commitdiff;h=e4b6a7efd2cab27a681c9a832f6c650abf57c7be;hp=26930236ae4aa4b192bb39e481675dd85d885b5e
Author: Simon Tatham <anakin at pobox.com>
Date:   Fri Apr 3 17:53:36 2020 +0100

    Fix null-dereference in ssh2_channel_response.
    
    In the SSH-2 connection layer, an outstanding_channel_request
    structure comes with a handler to be called back with the reply
    packet, when the other end sends one. But sometimes it doesn't - if
    the channel begins to close before the request has been replied to -
    in which case the handler function is called with a NULL packet
    pointer.
    
    The common ssh2_channel_response function that handles most of the
    client-side channel requests was not prepared to cope with that
    pointer being null. Fixed by making it handle a null return the same
    as CHANNEL_FAILURE.

 ssh2connection-client.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

commit 0fd30113f14657448ce455b7f72104d884f39e6d
web diff https://git.tartarus.org/?p=simon/putty.git;a=commitdiff;h=0fd30113f14657448ce455b7f72104d884f39e6d;hp=e4b6a7efd2cab27a681c9a832f6c650abf57c7be
Author: Simon Tatham <anakin at pobox.com>
Date:   Fri Apr 3 17:56:30 2020 +0100

    gtk: fill in missing case in scroll_event().
    
    If gdk_event_get_scroll_deltas() return failure for a given
    GdkEventScroll, it doesn't follow that that event has no usable
    scrolling action in it at all. The fallback is to call
    gdk_event_get_scroll_direction() instead, which is less precise but
    still gives _something_ you can use. So in that situation, instead of
    just returning false, we can fall through to the handling we use for
    pre-GTK3 scroll events (which are always imprecise).
    
    In particular, I've noticed recently that if you run GTK 3 PuTTY in
    the virtual X display created by vnc4server, and connect to it using
    xtightvncviewer, then scroll-wheel actions passed through from the VNC
    client will cause scroll_event() to receive low-res GdkEventScroll
    structures of exactly this kind. So scroll-wheel activity on the
    terminal window wasn't causing a scroll in that environment, and with
    this patch, it does.

 unix/gtkwin.c | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)



More information about the tartarus-commits mailing list