conf.c (7c478bd95313f5f23a4c958a745db2134aa03244) conf.c (0ea5e3a571e3da934507bdd32924d11659c70704)
1/*
2 * CDDL HEADER START
3 *
4 * The contents of this file are subject to the terms of the
1/*
2 * CDDL HEADER START
3 *
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License, Version 1.0 only
6 * (the "License"). You may not use this file except in compliance
7 * with the License.
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 *
9 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10 * or http://www.opensolaris.org/os/licensing.
11 * See the License for the specific language governing permissions
12 * and limitations under the License.
13 *
14 * When distributing Covered Code, include this CDDL HEADER in each
15 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16 * If applicable, add the following below this CDDL HEADER, with the
17 * fields enclosed by brackets "[]" replaced with your own identifying
18 * information: Portions Copyright [yyyy] [name of copyright owner]
19 *
20 * CDDL HEADER END
21 */
22/*
7 *
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
12 *
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 */
21/*
23 * Copyright (c) 1997-2000 by Sun Microsystems, Inc.
24 * All rights reserved.
22 * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
23 * Use is subject to license terms.
25 */
26
27#pragma ident "%Z%%M% %I% %E% SMI"
28
29#include <sys/types.h>
30#include <sys/wait.h>
31
32#include <unistd.h>
33#include <signal.h>
34#include <string.h>
35#include <stdlib.h>
36#include <stdio.h>
37#include <errno.h>
38
39#include "conf.h"
40
41#define CF_DEFSIZE 32 /* Starting table size */
42#define CF_GROW 2 /* Table size multiplier on grow */
43
24 */
25
26#pragma ident "%Z%%M% %I% %E% SMI"
27
28#include <sys/types.h>
29#include <sys/wait.h>
30
31#include <unistd.h>
32#include <signal.h>
33#include <string.h>
34#include <stdlib.h>
35#include <stdio.h>
36#include <errno.h>
37
38#include "conf.h"
39
40#define CF_DEFSIZE 32 /* Starting table size */
41#define CF_GROW 2 /* Table size multiplier on grow */
42
44extern void logerror(char *);
45
46static FILE *
47open_conf_pipe(const char *cmd, char *argv[], pid_t *pidp)
48{
49 int pfds[2];
50 pid_t pid;
51 struct sigaction act;
52
53 /* Create a pipe and fork a child process to run the command */

--- 166 unchanged lines hidden ---
43static FILE *
44open_conf_pipe(const char *cmd, char *argv[], pid_t *pidp)
45{
46 int pfds[2];
47 pid_t pid;
48 struct sigaction act;
49
50 /* Create a pipe and fork a child process to run the command */

--- 166 unchanged lines hidden ---