diff src/c/lacweb.c @ 138:d6d78055f001

Change driver to use Pthreads
author Adam Chlipala <adamc@hcoop.net>
date Sat, 19 Jul 2008 18:56:57 -0400
parents 4ffdbf429e8d
children f0d3402184d1
line wrap: on
line diff
--- a/src/c/lacweb.c	Thu Jul 17 14:32:49 2008 -0400
+++ b/src/c/lacweb.c	Sat Jul 19 18:56:57 2008 -0400
@@ -31,6 +31,11 @@
   free(ctx);
 }
 
+void lw_reset(lw_context ctx) {
+  ctx->page_front = ctx->page;
+  ctx->heap_front = ctx->heap;
+}
+
 static void lw_check_heap(lw_context ctx, size_t extra) {
   if (ctx->heap_back - ctx->heap_front < extra) {
     size_t desired = ctx->heap_back - ctx->heap_front + extra, next;