summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2010-07-14 16:59:57 +0200
committerBram Moolenaar <Bram@vim.org>2010-07-14 16:59:57 +0200
commitb28ebbca8400dccfc5eb9957ed96fcba9fe05e46 (patch)
tree8fa968011df56fec3f042429f66b41262ada7895 /src
parentc8bbaa3b187bf934c400b9f60438283883aba9ac (diff)
Fix using freed memory in :find completion.
Diffstat (limited to 'src')
-rw-r--r--src/misc1.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/misc1.c b/src/misc1.c
index 675c2e77a5..493b532bd3 100644
--- a/src/misc1.c
+++ b/src/misc1.c
@@ -9550,15 +9550,14 @@ gen_expand_wildcards(num_pat, pat, num_file, file, flags)
vim_free(t);
}
+#if defined(FEAT_SEARCHPATH)
+ if (flags & EW_PATH)
+ uniquefy_paths(&ga, p);
+#endif
if (p != pat[i])
vim_free(p);
}
-#if defined(FEAT_SEARCHPATH)
- if (flags & EW_PATH)
- uniquefy_paths(&ga, p);
-#endif
-
*num_file = ga.ga_len;
*file = (ga.ga_data != NULL) ? (char_u **)ga.ga_data : (char_u **)"";
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
{lib, stdenv, fetchurl, cmake, libpng, libtiff, libjpeg, panotools, libxml2 }:

stdenv.mkDerivation {
  name = "autopano-sift-C-2.5.1";

  src = fetchurl {
    url = "mirror://sourceforge/hugin/autopano-sift-C-2.5.1.tar.gz";
    sha256 = "0dqk8ff82gmy4v5ns5nr9gpzkc1p7c2y8c8fkid102r47wsjk44s";
  };

  nativeBuildInputs = [ cmake ];
  buildInputs = [ libpng libtiff libjpeg panotools libxml2 ];

  patches = [
    (fetchurl {
      url = "https://gitweb.gentoo.org/repo/gentoo.git/plain/media-gfx/autopano-sift-C/files/autopano-sift-C-2.5.1-lm.patch";
      sha256 = "1bfcr5sps0ip9gl4jprji5jgf9wkczz6d2clsjjlbsy8r3ixi3lv";
    })
  ];

  meta = {
    homepage = "http://hugin.sourceforge.net/";
    description = "Implementation in C of the autopano-sift algorithm for automatically stitching panoramas";
    license = lib.licenses.gpl2;
    platforms = lib.platforms.linux;
  };
}