diff options
author | pixel <pixel> | 2007-06-14 17:33:50 +0000 |
---|---|---|
committer | pixel <pixel> | 2007-06-14 17:33:50 +0000 |
commit | 5b78ba1fe46faf96bf40814e81b3d4164b5e460c (patch) | |
tree | bac6a3c90582a76b214ec4fd9a3c8fb93217bc38 | |
parent | 452e0e4e41e98df8fcf11e07fa8a0725c43142b4 (diff) |
Fixing segfault in LuaTask.
-rw-r--r-- | lib/LuaTask.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/LuaTask.cc b/lib/LuaTask.cc index 3dcabdc..e38c136 100644 --- a/lib/LuaTask.cc +++ b/lib/LuaTask.cc @@ -17,7 +17,7 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ -/* $Id: LuaTask.cc,v 1.12 2007-06-14 14:12:03 pixel Exp $ */ +/* $Id: LuaTask.cc,v 1.13 2007-06-14 17:33:50 pixel Exp $ */ #include <LuaTask.h> #include <LuaHandle.h> @@ -144,7 +144,7 @@ int LuaTask::Do() throw (GeneralException) { cmd = L->tostring(2).strdup(); - args = (char **) malloc(sizeof(char *) * (L->gettop() - 1)); + args = (char **) malloc(sizeof(char *) * (L->gettop())); args[0] = cmd; for (i = 3; i <= L->gettop(); i++) { args[i - 2] = L->tostring(i).strdup(); |