summaryrefslogtreecommitdiff
path: root/src/regress/lib/libc/alloca/alloca.c
blob: 14ef87b29ad97f53a47f3399d56e6646b927e548 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/*	$OpenBSD: alloca.c,v 1.5 2003/08/02 01:24:36 david Exp $	*/

/*	Written by Michael Shalayeff, 2003, Public Domain.	*/

#include <stdio.h>
#include <string.h>

int
main(int argc, char *argv[])
{
	char *q, *p;

	p = alloca(41);
	strcpy(p, "hellow world");

	q = alloca(53);
	strcpy(q, "hellow world");

	exit(strcmp(p, q));
}