Author: iratqq
Date: Sat Apr 12 13:14:54 2008
New Revision: 5415
Modified:
trunk/emacs/callback.c
trunk/emacs/commit.c
trunk/emacs/commit.h
Log:
* emacs/callback.c (commit_cb):
- Revert to r5414.
* emacs/commit.c (add_commit_string):
- Ditto.
* emacs/commit.h (add_commit_string):
- Ditto.
Modified: trunk/emacs/callback.c
==============================================================================
--- trunk/emacs/callback.c (original)
+++ trunk/emacs/callback.c Sat Apr 12 13:14:54 2008
@@ -44,7 +44,7 @@
debug_printf(DEBUG_NOTE, "commit_cb\n");
- ua->comstr = add_commit_string(ua->comstr, str, strlen(ua->comstr));
+ ua->comstr = add_commit_string(ua->comstr, str);
}
Modified: trunk/emacs/commit.c
==============================================================================
--- trunk/emacs/commit.c (original)
+++ trunk/emacs/commit.c Sat Apr 12 13:14:54 2008
@@ -37,7 +37,7 @@
#include "commit.h"
char *
-add_commit_string(char *comstr, const char *str, size_t len)
+add_commit_string(char *comstr, const char *str)
{
int buflen;
@@ -58,7 +58,7 @@
debug_printf(DEBUG_NOTE,
"add_commit_string comstr: %s (%p)\n", comstr,
comstr);
- strlcat(comstr, str, len);
+ strlcat(comstr, str, buflen + strlen(str) + 1);
}
debug_printf(DEBUG_NOTE,
Modified: trunk/emacs/commit.h
==============================================================================
--- trunk/emacs/commit.h (original)
+++ trunk/emacs/commit.h Sat Apr 12 13:14:54 2008
@@ -41,7 +41,7 @@
#include "output.h"
-char *add_commit_string(char *comstr, const char *str, size_t len);
+char *add_commit_string(char *comstr, const char *str);
int show_commit_string(char *comstr);
void reset_commit_string(char *comstr);