modified: makefile
[GalaxyCodeBases.git] / c_cpp / etc / md5_sha / mega.c
blob1649e7fa0e2dd7096e5a71c0e185b505a9373ea4
1 /*
2 * mega - output 1,000,000 repetitions of "a"
4 * @(#) $Revision: 13.1 $
5 * @(#) $Id: mega.c,v 13.1 2006/08/14 03:16:33 chongo Exp $
6 * @(#) $Source: /usr/local/src/cmd/hash/RCS/mega.c,v $
8 * This file was written by Landon Curt Noll.
10 * This output is the message specified by FIPS PUB 180-1 APPENDIX C.
12 * This code has been placed in the public domain. Please do not
13 * copyright this code.
15 * LANDON CURT NOLL DISCLAIMS ALL WARRANTIES WITH REGARD TO
16 * THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MER-
17 * CHANTABILITY AND FITNESS. IN NO EVENT SHALL LANDON CURT
18 * NOLL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
19 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
20 * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
21 * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
22 * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
24 * chongo (was here) /\oo/\
25 * http://www.isthe.com/chongo/index.html
27 * Share and enjoy! :-)
30 #include <stdio.h>
31 #include <sys/types.h>
32 #include <stdlib.h>
33 #include <unistd.h>
36 /*ARGSUSED*/
37 int
38 main(int argc, char *argv[])
40 int i;
42 /* usage */
43 if (argc != 1) {
44 fprintf(stderr, "usage: %s\n", argv[0]);
45 exit(1);
48 for (i=0; i < 1000000/50; ++i) {
49 write(1, "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", 50);
51 exit(0);