fix from Matthieu Herrb <matthieu@laas.fr> to do multiple arguments.

This commit is contained in:
cgd 1994-02-06 05:27:40 +00:00
parent e0cbda5321
commit e66d2ec65d
1 changed files with 13 additions and 13 deletions

View File

@ -30,7 +30,7 @@
*/ */
#ifndef lint #ifndef lint
static char rcsid[] = "$Id: uname.c,v 1.5 1994/01/29 01:43:43 jtc Exp $"; static char rcsid[] = "$Id: uname.c,v 1.6 1994/02/06 05:27:40 cgd Exp $";
#endif /* not lint */ #endif /* not lint */
#include <stdio.h> #include <stdio.h>
@ -62,22 +62,22 @@ main(argc, argv)
while ((c = getopt(argc,argv,"amnrsv")) != -1 ) { while ((c = getopt(argc,argv,"amnrsv")) != -1 ) {
switch ( c ) { switch ( c ) {
case 'a': case 'a':
print_mask = PRINT_ALL; print_mask |= PRINT_ALL;
break; break;
case 'm': case 'm':
print_mask = PRINT_MACHINE; print_mask |= PRINT_MACHINE;
break; break;
case 'n': case 'n':
print_mask = PRINT_NODENAME; print_mask |= PRINT_NODENAME;
break; break;
case 'r': case 'r':
print_mask = PRINT_RELEASE; print_mask |= PRINT_RELEASE;
break; break;
case 's': case 's':
print_mask = PRINT_SYSNAME; print_mask |= PRINT_SYSNAME;
break; break;
case 'v': case 'v':
print_mask = PRINT_VERSION; print_mask |= PRINT_VERSION;
break; break;
default: default:
usage(); usage();