Mercurial > urweb
comparison src/c/urweb.c @ 278:137744c5b1ae
First query example working
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Tue, 02 Sep 2008 16:10:07 -0400 |
parents | ed4af33681d8 |
children | fdd7a698be01 |
comparison
equal
deleted
inserted
replaced
277:286f734db702 | 278:137744c5b1ae |
---|---|
573 strcat(s, s2); | 573 strcat(s, s2); |
574 ctx->heap_front += len; | 574 ctx->heap_front += len; |
575 | 575 |
576 return s; | 576 return s; |
577 } | 577 } |
578 | |
579 lw_Basis_string lw_Basis_strdup(lw_context ctx, lw_Basis_string s1) { | |
580 int len = strlen(s1) + 1; | |
581 char *s; | |
582 | |
583 lw_check_heap(ctx, len); | |
584 | |
585 s = ctx->heap_front; | |
586 | |
587 strcpy(s, s1); | |
588 ctx->heap_front += len; | |
589 | |
590 return s; | |
591 } |