edelib  2.1.0
Run.h
1 /*
2  * $Id: Run.h 3499 2013-01-05 03:18:47Z karijes $
3  *
4  * Run external program
5  * Copyright (c) 2005-2013 edelib authors
6  *
7  * This library is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU Lesser General Public
9  * License as published by the Free Software Foundation; either
10  * version 2 of the License, or (at your option) any later version.
11  *
12  * This library is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15  * Lesser General Public License for more details.
16  *
17  * You should have received a copy of the GNU Lesser General Public License
18  * along with this library. If not, see <http://www.gnu.org/licenses/>.
19  */
20 
21 #ifndef __EDELIB_RUN_H__
22 #define __EDELIB_RUN_H__
23 
24 #include "edelib-global.h"
25 
26 EDELIB_NS_BEGIN
27 
28 enum {
29  RUN_NOT_FOUND = 65535,
30  RUN_EMPTY = 65534,
31  RUN_NOT_EXEC = 65533,
32  RUN_FORK_FAILED = 65532,
35  RUN_PIPE_FAILED = 65529,
36  RUN_NO_ACCESS = 65528
37 };
38 
49 EDELIB_API int run_sync(const char *fmt, ...);
50 
54 EDELIB_API int run_async(const char *fmt, ...);
55 
63 EDELIB_API int run_async_with_pid(int *child_pid, const char *fmt, ...);
64 
65 EDELIB_NS_END
66 #endif
given parameter is NULL
Definition: Run.h:30
internal fork failed
Definition: Run.h:32
not enough permissions to execute it
Definition: Run.h:36
internal waitpid failed
Definition: Run.h:33
given parameter is not executable on system
Definition: Run.h:31
executable not found
Definition: Run.h:29
internal pipe failed
Definition: Run.h:35
internal execve failed
Definition: Run.h:34