tee.c (87303) | tee.c (92922) |
---|---|
1/* 2 * Copyright (c) 1988, 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 --- 28 unchanged lines hidden (view full) --- 37 The Regents of the University of California. All rights reserved.\n"; 38#endif /* not lint */ 39 40#ifndef lint 41#if 0 42static char sccsid[] = "@(#)tee.c 8.1 (Berkeley) 6/6/93"; 43#endif 44static const char rcsid[] = | 1/* 2 * Copyright (c) 1988, 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 --- 28 unchanged lines hidden (view full) --- 37 The Regents of the University of California. All rights reserved.\n"; 38#endif /* not lint */ 39 40#ifndef lint 41#if 0 42static char sccsid[] = "@(#)tee.c 8.1 (Berkeley) 6/6/93"; 43#endif 44static const char rcsid[] = |
45 "$FreeBSD: head/usr.bin/tee/tee.c 87303 2001-12-03 21:37:35Z dwmalone $"; | 45 "$FreeBSD: head/usr.bin/tee/tee.c 92922 2002-03-22 01:42:45Z imp $"; |
46#endif /* not lint */ 47 48#include <sys/types.h> 49#include <sys/stat.h> 50#include <err.h> 51#include <fcntl.h> 52#include <signal.h> 53#include <stdio.h> 54#include <stdlib.h> 55#include <string.h> 56#include <unistd.h> 57 58typedef struct _list { 59 struct _list *next; 60 int fd; 61 const char *name; 62} LIST; 63LIST *head; 64 | 46#endif /* not lint */ 47 48#include <sys/types.h> 49#include <sys/stat.h> 50#include <err.h> 51#include <fcntl.h> 52#include <signal.h> 53#include <stdio.h> 54#include <stdlib.h> 55#include <string.h> 56#include <unistd.h> 57 58typedef struct _list { 59 struct _list *next; 60 int fd; 61 const char *name; 62} LIST; 63LIST *head; 64 |
65void add __P((int, const char *)); 66static void usage __P((void)); | 65void add(int, const char *); 66static void usage(void); |
67 68int 69main(argc, argv) 70 int argc; 71 char *argv[]; 72{ 73 register LIST *p; 74 register int n, fd, rval, wval; --- 73 unchanged lines hidden --- | 67 68int 69main(argc, argv) 70 int argc; 71 char *argv[]; 72{ 73 register LIST *p; 74 register int n, fd, rval, wval; --- 73 unchanged lines hidden --- |