1 /* gspawn.c - Process launching
3 * Copyright 2000 Red Hat, Inc.
4 * g_execvpe implementation based on GNU libc execvp:
5 * Copyright 1991, 92, 95, 96, 97, 98, 99 Free Software Foundation, Inc.
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.1 of the License, or (at your option) any later version.
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.
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/>.
28 _g_spawn_exec_err_to_g_error (gint en
)
34 return G_SPAWN_ERROR_ACCES
;
39 return G_SPAWN_ERROR_PERM
;
44 return G_SPAWN_ERROR_TOO_BIG
;
49 return G_SPAWN_ERROR_NOEXEC
;
54 return G_SPAWN_ERROR_NAMETOOLONG
;
59 return G_SPAWN_ERROR_NOENT
;
64 return G_SPAWN_ERROR_NOMEM
;
69 return G_SPAWN_ERROR_NOTDIR
;
74 return G_SPAWN_ERROR_LOOP
;
79 return G_SPAWN_ERROR_TXTBUSY
;
84 return G_SPAWN_ERROR_IO
;
89 return G_SPAWN_ERROR_NFILE
;
94 return G_SPAWN_ERROR_MFILE
;
99 return G_SPAWN_ERROR_INVAL
;
104 return G_SPAWN_ERROR_ISDIR
;
109 return G_SPAWN_ERROR_LIBBAD
;
113 return G_SPAWN_ERROR_FAILED
;