uname.c (1c8af8787354e20c2b38cab5801698133ff8b403) | uname.c (7db98de9574fbcd5e07e0ec45f49d73aa7f7e2d6) |
---|---|
1/*- 2 * Copyright (c) 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 53 unchanged lines hidden (view full) --- 62#define SFLAG 0x08 63#define VFLAG 0x10 64 u_int flags; 65 int ch, mib[2]; 66 size_t len, tlen; 67 char *p, *prefix, buf[1024]; 68 69 flags = 0; | 1/*- 2 * Copyright (c) 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 53 unchanged lines hidden (view full) --- 62#define SFLAG 0x08 63#define VFLAG 0x10 64 u_int flags; 65 int ch, mib[2]; 66 size_t len, tlen; 67 char *p, *prefix, buf[1024]; 68 69 flags = 0; |
70 while ((ch = getopt(argc, argv, "amnrsv")) != -1) | 70 while ((ch = getopt(argc, argv, "amnprsv")) != -1) |
71 switch(ch) { 72 case 'a': 73 flags |= (MFLAG | NFLAG | RFLAG | SFLAG | VFLAG); 74 break; | 71 switch(ch) { 72 case 'a': 73 flags |= (MFLAG | NFLAG | RFLAG | SFLAG | VFLAG); 74 break; |
75 case 'p': |
|
75 case 'm': 76 flags |= MFLAG; 77 break; 78 case 'n': 79 flags |= NFLAG; 80 break; 81 case 'r': 82 flags |= RFLAG; --- 81 unchanged lines hidden --- | 76 case 'm': 77 flags |= MFLAG; 78 break; 79 case 'n': 80 flags |= NFLAG; 81 break; 82 case 'r': 83 flags |= RFLAG; --- 81 unchanged lines hidden --- |