31057a08c0
see http://www.opencm.org/news.html for hilights of this update, major noteworthy changes include: - sxd has gone away, gzfs is 'interim' while 'sxd2' is almost ready - if you have an old sxd repository, read the mailing list archives for how to update (use an interum version) - an incompatible update to the server/client protocol requires that you update both at the same time (as a reminder, this is 'alpha' and as such is subject to incompatible changes like the above. expect more to come when sxd2 emerges) Also, add a 'nogc' flavor that removes the dependency on boehm-gc, at the cost of not free()'ing all memory allocated (read: at the moment, most).
58 lines
2.0 KiB
Plaintext
58 lines
2.0 KiB
Plaintext
$OpenBSD: patch-base_libgdiff_util_c,v 1.1 2003/05/23 13:22:14 todd Exp $
|
|
--- base/libgdiff/util.c.orig Sat Mar 29 16:15:27 2003
|
|
+++ base/libgdiff/util.c Thu May 22 17:46:40 2003
|
|
@@ -130,7 +130,7 @@ message5 (format, arg1, arg2, arg3, arg4
|
|
{
|
|
if (paginate_flag)
|
|
{
|
|
- struct msg *new = (struct msg *) GC_MALLOC (sizeof (struct msg));
|
|
+ struct msg *new = (struct msg *) malloc (sizeof (struct msg));
|
|
new->format = format;
|
|
new->arg1 = concat (arg1, "", "");
|
|
new->arg2 = concat (arg2, "", "");
|
|
@@ -196,7 +196,7 @@ begin_output ()
|
|
output_in_progress = 1;
|
|
|
|
/* Construct the header of this piece of diff. */
|
|
- name = GC_MALLOC (strlen (current_name0) + strlen (current_name1)
|
|
+ name = malloc (strlen (current_name0) + strlen (current_name1)
|
|
+ strlen (switch_string) + 7);
|
|
/* Posix.2 section 4.17.6.1.1 specifies this format. But there is a
|
|
bug in the first printing (IEEE Std 1003.2-1992 p 251 l 3304):
|
|
@@ -246,7 +246,7 @@ begin_output ()
|
|
pfatal_with_name ("fdopen");
|
|
}
|
|
# else /* ! HAVE_FORK */
|
|
- char *command = GC_MALLOC (4 * strlen (name) + strlen (PR_PROGRAM) + 10);
|
|
+ char *command = malloc (4 * strlen (name) + strlen (PR_PROGRAM) + 10);
|
|
char *p;
|
|
char const *a = name;
|
|
sprintf (command, "%s -f -h ", PR_PROGRAM);
|
|
@@ -256,7 +256,7 @@ begin_output ()
|
|
outfile = popen (command, "w");
|
|
if (!outfile)
|
|
pfatal_with_name (command);
|
|
- GC_FREE (command);
|
|
+ free (command);
|
|
# endif /* ! HAVE_FORK */
|
|
#else
|
|
fatal ("This port does not support the --paginate option to diff.");
|
|
@@ -273,7 +273,7 @@ begin_output ()
|
|
printf_output ("%s\n", name);
|
|
}
|
|
|
|
- GC_FREE (name);
|
|
+ free (name);
|
|
|
|
/* A special header is needed at the beginning of context output. */
|
|
switch (output_style)
|
|
@@ -819,7 +819,7 @@ concat (s1, s2, s3)
|
|
char const *s1, *s2, *s3;
|
|
{
|
|
size_t len = strlen (s1) + strlen (s2) + strlen (s3);
|
|
- char *new = GC_MALLOC (len + 1);
|
|
+ char *new = malloc (len + 1);
|
|
sprintf (new, "%s%s%s", s1, s2, s3);
|
|
return new;
|
|
}
|