LibComCom  0.1.0
Run an OS command with given input and receive output
libcomcom.h
Go to the documentation of this file.
1 /* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */
2 /*
3  * libcomcom.h
4  * Copyright (C) 2018 Victor Porton <porton@narod.ru>
5  *
6  * libcomcom is free software: you can redistribute it and/or modify it
7  * under the terms of the GNU Lesser General Public License as published
8  * by the Free Software Foundation, either version 3 of the License, or
9  * (at your option) any later version.
10  *
11  * libcomcom is distributed in the hope that it will be useful, but
12  * WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
14  * See the GNU Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public License
17  * along with this program. If not, see <http://www.gnu.org/licenses/>.";
18  */
19 
20 #ifndef LIBCOMCOM_H
21 #define LIBCOMCOM_H
22 
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26 
27 #include <stddef.h>
28 #include <signal.h>
29 
37 int libcomcom_init(void);
38 
49 int libcomcom_init2(struct sigaction *old);
50 
63 int libcomcom_init_stratum(void);
64 
77 int libcomcom_run_command(const char *input, size_t input_len,
78  const char **output, size_t *output_len,
79  const char *file, char *const argv[],
80  char *const envp[],
81  int timeout);
82 
88 int libcomcom_destroy(void);
89 
94 int libcomcom_terminate(void);
95 
104 
113 
125 
132 
133 #ifdef __cplusplus
134 }
135 #endif
136 
137 #endif /* LIBCOMCOM_H */
int libcomcom_init(void)
int libcomcom_init2(struct sigaction *old)
int libcomcom_run_command(const char *input, size_t input_len, const char **output, size_t *output_len, const char *file, char *const argv[], char *const envp[], int timeout)
int libcomcom_init_stratum(void)
int libcomcom_destroy(void)
int libcomcom_set_default_terminate(void)
int libcomcom_reset_default_terminate2(void)
int libcomcom_reset_default_terminate(void)
int libcomcom_terminate(void)
int libcomcom_set_default_terminate2(void)