Deleted Added
full compact
kgzcmp.c (76224) kgzcmp.c (79452)
1/*
2 * Copyright (c) 1999 Global Technology Associates, Inc.
3 * 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

--- 9 unchanged lines hidden (view full) ---

18 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
19 * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
20 * OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
21 * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
22 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
23 * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
24 * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 *
1/*
2 * Copyright (c) 1999 Global Technology Associates, Inc.
3 * 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

--- 9 unchanged lines hidden (view full) ---

18 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
19 * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
20 * OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
21 * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
22 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
23 * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
24 * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 *
26 * $FreeBSD: head/usr.sbin/kgzip/kgzcmp.c 76224 2001-05-02 23:56:21Z obrien $
26 * $FreeBSD: head/usr.sbin/kgzip/kgzcmp.c 79452 2001-07-09 09:24:06Z brian $
27 */
28
29#include <sys/types.h>
30#include <sys/stat.h>
31#include <sys/wait.h>
32#include <machine/elf.h>
33
34#include <err.h>

--- 96 unchanged lines hidden (view full) ---

131 err(1, NULL);
132 case 0:
133 close(fd[1]);
134 dup2(fd[0], STDIN_FILENO);
135 close(fd[0]);
136 close(idi->fd);
137 dup2(ido->fd, STDOUT_FILENO);
138 close(ido->fd);
27 */
28
29#include <sys/types.h>
30#include <sys/stat.h>
31#include <sys/wait.h>
32#include <machine/elf.h>
33
34#include <err.h>

--- 96 unchanged lines hidden (view full) ---

131 err(1, NULL);
132 case 0:
133 close(fd[1]);
134 dup2(fd[0], STDIN_FILENO);
135 close(fd[0]);
136 close(idi->fd);
137 dup2(ido->fd, STDOUT_FILENO);
138 close(ido->fd);
139 execlp("gzip", "gzip", "-9", NULL);
139 execlp("gzip", "gzip", "-9", (char *)NULL);
140 warn(NULL);
141 _exit(1);
142 default:
143 close(fd[0]);
144 idp.fname = "(pipe)";
145 idp.fd = fd[1];
146 e = fmt == F_ELF ? ld_elf(idi, &idp, kh, &hdr.ee) :
147 fmt == F_AOUT ? ld_aout(idi, &idp, kh, &hdr.ex) : -1;

--- 80 unchanged lines hidden ---
140 warn(NULL);
141 _exit(1);
142 default:
143 close(fd[0]);
144 idp.fname = "(pipe)";
145 idp.fd = fd[1];
146 e = fmt == F_ELF ? ld_elf(idi, &idp, kh, &hdr.ee) :
147 fmt == F_AOUT ? ld_aout(idi, &idp, kh, &hdr.ex) : -1;

--- 80 unchanged lines hidden ---