blob: d9573e2f54db0634412b0bbaed3df2198b1aba53 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
/* $OpenBSD: alloca.c,v 1.6 2003/09/02 23:52:16 david Exp $ */
/* Written by Michael Shalayeff, 2003, Public Domain. */
#include <stdio.h>
#include <stdlib.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));
}
|