diff options
author | Patrick J Volkerding <volkerdi@slackware.com> | 2009-08-26 10:00:38 -0500 |
---|---|---|
committer | Eric Hameleers <alien@slackware.com> | 2018-05-31 22:41:17 +0200 |
commit | 5a12e7c134274dba706667107d10d231517d3e05 (patch) | |
tree | 55718d5acb710fde798d9f38d0bbaf594ed4b296 /source/ap/vim/patches/7.2.125 | |
download | current-5a12e7c134274dba706667107d10d231517d3e05.tar.gz |
Slackware 13.0slackware-13.0
Wed Aug 26 10:00:38 CDT 2009
Slackware 13.0 x86_64 is released as stable! Thanks to everyone who
helped make this release possible -- see the RELEASE_NOTES for the
credits. The ISOs are off to the replicator. This time it will be a
6 CD-ROM 32-bit set and a dual-sided 32-bit/64-bit x86/x86_64 DVD.
We're taking pre-orders now at store.slackware.com. Please consider
picking up a copy to help support the project. Once again, thanks to
the entire Slackware community for all the help testing and fixing
things and offering suggestions during this development cycle.
As always, have fun and enjoy! -P.
Diffstat (limited to 'source/ap/vim/patches/7.2.125')
-rw-r--r-- | source/ap/vim/patches/7.2.125 | 161 |
1 files changed, 161 insertions, 0 deletions
diff --git a/source/ap/vim/patches/7.2.125 b/source/ap/vim/patches/7.2.125 new file mode 100644 index 00000000..460bdea5 --- /dev/null +++ b/source/ap/vim/patches/7.2.125 @@ -0,0 +1,161 @@ +To: vim-dev@vim.org +Subject: Patch 7.2.125 +Fcc: outbox +From: Bram Moolenaar <Bram@moolenaar.net> +Mime-Version: 1.0 +Content-Type: text/plain; charset=ISO-8859-1 +Content-Transfer-Encoding: 8bit +------------ + +Patch 7.2.125 +Problem: Leaking memory when reading XPM bitmap for a sign. +Solution: Don't allocate the memory twice. (Dominique Pelle) +Files: src/gui_x11.c + + +*** ../vim-7.2.124/src/gui_x11.c Wed Nov 12 13:07:48 2008 +--- src/gui_x11.c Sun Feb 22 21:58:19 2009 +*************** +*** 1587,1592 **** +--- 1587,1594 ---- + XtCloseDisplay(gui.dpy); + gui.dpy = NULL; + vimShell = (Widget)0; ++ vim_free(gui_argv); ++ gui_argv = NULL; + } + + /* +*************** +*** 1761,1766 **** +--- 1763,1770 ---- + * says that this isn't needed when exiting, so just skip it. */ + XtCloseDisplay(gui.dpy); + #endif ++ vim_free(gui_argv); ++ gui_argv = NULL; + } + + /* +*************** +*** 3439,3485 **** + char_u *signfile; + { + XpmAttributes attrs; +! XImage *sign; + int status; + + /* + * Setup the color substitution table. + */ +- sign = NULL; + if (signfile[0] != NUL && signfile[0] != '-') + { +! sign = (XImage *)alloc(sizeof(XImage)); +! if (sign != NULL) + { +! XpmColorSymbol color[5] = +! { +! {"none", NULL, 0}, +! {"iconColor1", NULL, 0}, +! {"bottomShadowColor", NULL, 0}, +! {"topShadowColor", NULL, 0}, +! {"selectColor", NULL, 0} +! }; +! attrs.valuemask = XpmColorSymbols; +! attrs.numsymbols = 2; +! attrs.colorsymbols = color; +! attrs.colorsymbols[0].pixel = gui.back_pixel; +! attrs.colorsymbols[1].pixel = gui.norm_pixel; +! status = XpmReadFileToImage(gui.dpy, (char *)signfile, + &sign, NULL, &attrs); +! +! if (status == 0) +! { +! /* Sign width is fixed at two columns now. +! if (sign->width > gui.sign_width) +! gui.sign_width = sign->width + 8; */ +! } +! else +! { +! vim_free(sign); +! sign = NULL; +! EMSG(_(e_signdata)); +! } + } + } + + return (void *)sign; +--- 3443,3479 ---- + char_u *signfile; + { + XpmAttributes attrs; +! XImage *sign = NULL; + int status; + + /* + * Setup the color substitution table. + */ + if (signfile[0] != NUL && signfile[0] != '-') + { +! XpmColorSymbol color[5] = + { +! {"none", NULL, 0}, +! {"iconColor1", NULL, 0}, +! {"bottomShadowColor", NULL, 0}, +! {"topShadowColor", NULL, 0}, +! {"selectColor", NULL, 0} +! }; +! attrs.valuemask = XpmColorSymbols; +! attrs.numsymbols = 2; +! attrs.colorsymbols = color; +! attrs.colorsymbols[0].pixel = gui.back_pixel; +! attrs.colorsymbols[1].pixel = gui.norm_pixel; +! status = XpmReadFileToImage(gui.dpy, (char *)signfile, + &sign, NULL, &attrs); +! if (status == 0) +! { +! /* Sign width is fixed at two columns now. +! if (sign->width > gui.sign_width) +! gui.sign_width = sign->width + 8; */ + } ++ else ++ EMSG(_(e_signdata)); + } + + return (void *)sign; +*************** +*** 3489,3496 **** + gui_mch_destroy_sign(sign) + void *sign; + { +! XFree(((XImage *)sign)->data); +! vim_free(sign); + } + #endif + +--- 3483,3489 ---- + gui_mch_destroy_sign(sign) + void *sign; + { +! XDestroyImage((XImage*)sign); + } + #endif + +*** ../vim-7.2.124/src/version.c Mon Feb 23 00:53:35 2009 +--- src/version.c Tue Feb 24 04:09:33 2009 +*************** +*** 678,679 **** +--- 678,681 ---- + { /* Add new patch number below this line */ ++ /**/ ++ 125, + /**/ + +-- +I have a watch cat! Just break in and she'll watch. + + /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ +/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ +\\\ download, build and distribute -- http://www.A-A-P.org /// + \\\ help me help AIDS victims -- http://ICCF-Holland.org /// |