$OpenBSD: patch-base_libgdiff_diff_c,v 1.1 2003/05/23 13:22:14 todd Exp $
--- base/libgdiff/diff.c.orig	Sat Mar 29 16:15:23 2003
+++ base/libgdiff/diff.c	Thu May 22 17:46:39 2003
@@ -85,7 +85,7 @@ option_list (optionvec, count)
   for (i = 0; i < count; i++)
     length += strlen (optionvec[i]) + 1;
 
-  result = GC_MALLOC (length + 1);
+  result = malloc (length + 1);
   result[0] = 0;
 
   for (i = 0; i < count; i++)
@@ -136,8 +136,8 @@ add_exclude (pattern)
   if (exclude_alloc <= exclude_count)
     exclude = (char const **)
 	      (exclude_alloc == 0
-	       ? GC_MALLOC ((exclude_alloc = 64) * sizeof (*exclude))
-	       : GC_REALLOC (exclude, (exclude_alloc *= 2) * sizeof (*exclude)));
+	       ? malloc ((exclude_alloc = 64) * sizeof (*exclude))
+	       : realloc (exclude, (exclude_alloc *= 2) * sizeof (*exclude)));
 
   exclude[exclude_count++] = pattern;
 }
@@ -338,7 +338,7 @@ diff_run (argc, argv, out, callbacks_arg
 	    int i, err = 0;
 	    static char const C_ifdef_group_formats[] =
 	      "#ifndef %s\n%%<#endif /* not %s */\n%c#ifdef %s\n%%>#endif /* %s */\n%c%%=%c#ifndef %s\n%%<#else /* %s */\n%%>#endif /* %s */\n";
-	    char *b = GC_MALLOC (sizeof (C_ifdef_group_formats)
+	    char *b = malloc (sizeof (C_ifdef_group_formats)
 			       + 7 * strlen(optarg) - 14 /* 7*"%s" */
 			       - 8 /* 5*"%%" + 3*"%c" */);
 	    sprintf (b, C_ifdef_group_formats,
@@ -701,7 +701,7 @@ diff_run (argc, argv, out, callbacks_arg
   /* Print any messages that were saved up for last.  */
   print_message_queue ();
 
-  GC_FREE (switch_string);
+  free (switch_string);
 
   optind = optind_old;
 
@@ -725,9 +725,9 @@ add_regexp (reglist, pattern)
   struct regexp_list *r;
   char const *m;
 
-  r = (struct regexp_list *) GC_MALLOC (sizeof (*r));
+  r = (struct regexp_list *) malloc (sizeof (*r));
   bzero (r, sizeof (*r));
-  r->buf.fastmap = GC_MALLOC (256);
+  r->buf.fastmap = malloc (256);
   m = re_compile_pattern (pattern, strlen (pattern), &r->buf);
   if (m != 0)
     diff_error ("%s: %s", pattern, m);
@@ -1195,9 +1195,9 @@ compare_files (dir0, name0, dir1, name1,
     flush_output ();
 
   if (free0)
-    GC_FREE (free0);
+    free (free0);
   if (free1)
-    GC_FREE (free1);
+    free (free1);
 
   return val;
 }
