comparison src/window.c @ 7256:79270eaac6de v7.4.936

commit https://github.com/vim/vim/commit/294a7e55b01149154807a23323038784549b8946 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Nov 22 19:39:38 2015 +0100 patch 7.4.936 Problem: Crash when dragging with the mouse. Solution: Add safety check for NULL pointer. Check mouse position for valid value. (Hirohito Higashi)
author Christian Brabandt <cb@256bit.org>
date Sun, 22 Nov 2015 19:45:05 +0100
parents ae360f1df2aa
children 743c258ca3ab
comparison
equal deleted inserted replaced
7255:c4606e322fa4 7256:79270eaac6de
5783 5783
5784 if (room < offset) /* Not enough room */ 5784 if (room < offset) /* Not enough room */
5785 offset = room; /* Move as far as we can */ 5785 offset = room; /* Move as far as we can */
5786 if (offset <= 0) /* No room at all, quit. */ 5786 if (offset <= 0) /* No room at all, quit. */
5787 return; 5787 return;
5788 if (fr == NULL)
5789 return; /* Safety check, should not happen. */
5788 5790
5789 /* grow frame fr by offset lines */ 5791 /* grow frame fr by offset lines */
5790 frame_new_width(fr, fr->fr_width + offset, left, FALSE); 5792 frame_new_width(fr, fr->fr_width + offset, left, FALSE);
5791 5793
5792 /* shrink other frames: current and at the left or at the right */ 5794 /* shrink other frames: current and at the left or at the right */