summaryrefslogtreecommitdiffstats
path: root/bcd/bcd.c
diff options
context:
space:
mode:
authorcgd <cgd@NetBSD.org>1995-03-21 15:03:38 +0000
committercgd <cgd@NetBSD.org>1995-03-21 15:03:38 +0000
commit5ff78ede5ea1a80c654d3f0684cd5f36d5253ae1 (patch)
tree81a19a5b24b0353e8cbac8b1f0ad82be1cf16323 /bcd/bcd.c
parent45171656c266fc63f08d074d856b5ae99ac29211 (diff)
downloadbsdgames-darwin-5ff78ede5ea1a80c654d3f0684cd5f36d5253ae1.tar.gz
bsdgames-darwin-5ff78ede5ea1a80c654d3f0684cd5f36d5253ae1.tar.zst
bsdgames-darwin-5ff78ede5ea1a80c654d3f0684cd5f36d5253ae1.zip
clean up import
Diffstat (limited to 'bcd/bcd.c')
-rw-r--r--bcd/bcd.c31
1 files changed, 23 insertions, 8 deletions
diff --git a/bcd/bcd.c b/bcd/bcd.c
index ef50737a..ea554a34 100644
--- a/bcd/bcd.c
+++ b/bcd/bcd.c
@@ -1,9 +1,11 @@
+/* $NetBSD: bcd.c,v 1.5 1995/03/21 15:08:15 cgd Exp $ */
+
/*
- * Copyright (c) 1989 The Regents of the University of California.
- * All rights reserved.
+ * Copyright (c) 1989, 1993
+ * The Regents of the University of California. All rights reserved.
*
* This code is derived from software contributed to Berkeley by
- * Steve Hayman of the Indiana University Computer Science Dept..
+ * Steve Hayman of the Indiana University Computer Science Dept.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -35,14 +37,13 @@
*/
#ifndef lint
-char copyright[] =
-"@(#) Copyright (c) 1989 The Regents of the University of California.\n\
- All rights reserved.\n";
+static char copyright[] =
+"@(#) Copyright (c) 1989, 1993\n\
+ The Regents of the University of California. All rights reserved.\n";
#endif /* not lint */
#ifndef lint
-/*static char sccsid[] = "from: @(#)bcd.c 4.4 (Berkeley) 6/1/90";*/
-static char rcsid[] = "$Id: bcd.c,v 1.4 1993/11/05 20:22:35 jtc Exp $";
+static char sccsid[] = "@(#)bcd.c 8.2 (Berkeley) 3/20/94";
#endif /* not lint */
/*
@@ -61,9 +62,22 @@ static char rcsid[] = "$Id: bcd.c,v 1.4 1993/11/05 20:22:35 jtc Exp $";
* Steve Hayman
* sahayman@iuvax.cs.indiana.edu
* 1989 11 30
+ *
+ *
+ * I found an error in the table. The same error is found in the SunOS 4.1.1
+ * version of bcd. It has apparently been around a long time. The error caused
+ * 'Q' and 'R' to have the same punch code. I only noticed the error due to
+ * someone pointing it out to me when the program was used to print a cover
+ * for an APA! The table was wrong in 4 places. The other error was masked
+ * by the fact that the input is converted to upper case before lookup.
+ *
+ * Dyane Bruce
+ * db@diana.ocunix.on.ca
+ * Nov 5, 1993
*/
#include <sys/types.h>
+
#include <stdio.h>
#include <ctype.h>
@@ -107,6 +121,7 @@ u_short holes[256] = {
*/
#define bit(w,i) ((w)&(1<<(i)))
+int
main(argc, argv)
int argc;
char **argv;