diff options
Diffstat (limited to 'Library/Formula')
| -rw-r--r-- | Library/Formula/ctags.rb | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/Library/Formula/ctags.rb b/Library/Formula/ctags.rb index b502e4299..c07e7595e 100644 --- a/Library/Formula/ctags.rb +++ b/Library/Formula/ctags.rb @@ -2,6 +2,7 @@ class Ctags < Formula homepage "http://ctags.sourceforge.net/" url "https://downloads.sourceforge.net/ctags/ctags-5.8.tar.gz" sha1 "482da1ecd182ab39bbdc09f2f02c9fba8cd20030" + revision 1 bottle do cellar :any @@ -102,3 +103,26 @@ diff -ur a/ctags-5.8/read.h b/ctags-5.8/read.h /* * FUNCTION PROTOTYPES + + +Bugfix: Don't use strcpy on overlapping buffers +Upstream commit (not in release yet): http://sourceforge.net/p/ctags/code/782/ +diff -ur a/ctags-5.8/routines.c b/ctags-5.8/routines.c +--- a/ctags-5.8/routines.c 2007-06-07 00:35:21.000000000 -0400 ++++ b/ctags-5.8/routines.c 2015-03-07 20:38:58.000000000 -0500 +@@ -757,13 +757,13 @@ + else if (cp [0] != PATH_SEPARATOR) + cp = slashp; + #endif +- strcpy (cp, slashp + 3); ++ memmove (cp, slashp + 3, strlen (slashp + 3) + 1); + slashp = cp; + continue; + } + else if (slashp [2] == PATH_SEPARATOR || slashp [2] == '\0') + { +- strcpy (slashp, slashp + 2); ++ memmove (slashp, slashp + 2, strlen (slashp + 2) + 1); + continue; + } + } |
