uname.c (e7b883c427297e23d68c18fb70a00d277f3d7997) | uname.c (8293a8fe11891f6e298d08392792fa488dc2753a) |
---|---|
1/*- 2 * Copyright (c) 2002 Juli Mallett. 3 * Copyright (c) 1993 4 * The Regents of the University of California. All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 74 unchanged lines hidden (view full) --- 83main(int argc, char *argv[]) 84{ 85 u_int flags; 86 int ch; 87 88 setup_get(); 89 flags = 0; 90 | 1/*- 2 * Copyright (c) 2002 Juli Mallett. 3 * Copyright (c) 1993 4 * The Regents of the University of California. All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 74 unchanged lines hidden (view full) --- 83main(int argc, char *argv[]) 84{ 85 u_int flags; 86 int ch; 87 88 setup_get(); 89 flags = 0; 90 |
91 while ((ch = getopt(argc, argv, "aimnprsv")) != -1) | 91 while ((ch = getopt(argc, argv, "aimnoprsv")) != -1) |
92 switch(ch) { 93 case 'a': 94 flags |= (MFLAG | NFLAG | RFLAG | SFLAG | VFLAG); 95 break; 96 case 'i': 97 flags |= IFLAG; 98 break; 99 case 'm': --- 4 unchanged lines hidden (view full) --- 104 break; 105 case 'p': 106 flags |= PFLAG; 107 break; 108 case 'r': 109 flags |= RFLAG; 110 break; 111 case 's': | 92 switch(ch) { 93 case 'a': 94 flags |= (MFLAG | NFLAG | RFLAG | SFLAG | VFLAG); 95 break; 96 case 'i': 97 flags |= IFLAG; 98 break; 99 case 'm': --- 4 unchanged lines hidden (view full) --- 104 break; 105 case 'p': 106 flags |= PFLAG; 107 break; 108 case 'r': 109 flags |= RFLAG; 110 break; 111 case 's': |
112 case 'o': |
|
112 flags |= SFLAG; 113 break; 114 case 'v': 115 flags |= VFLAG; 116 break; 117 case '?': 118 default: 119 usage(); --- 130 unchanged lines hidden --- | 113 flags |= SFLAG; 114 break; 115 case 'v': 116 flags |= VFLAG; 117 break; 118 case '?': 119 default: 120 usage(); --- 130 unchanged lines hidden --- |