#include <precomp.h>
#include <process.h>
#include <tchar.h>
#include <internal/wine/msvcrt.h>
Go to the source code of this file.
|
int | access_dirT (const _TCHAR *_path) |
|
const _TCHAR * | find_execT (const _TCHAR *path, _TCHAR *rpath) |
|
static _TCHAR * | argvtosT (const _TCHAR *const *argv, _TCHAR delim) |
|
static _TCHAR * | valisttosT (const _TCHAR *arg0, va_list alist, _TCHAR delim) |
|
static intptr_t | do_spawnT (int mode, const _TCHAR *cmdname, const _TCHAR *args, const _TCHAR *envp) |
|
intptr_t | _tspawnl (int mode, const _TCHAR *cmdname, const _TCHAR *arg0,...) |
|
intptr_t | _tspawnv (int mode, const _TCHAR *cmdname, const _TCHAR *const *argv) |
|
intptr_t | _tspawnle (int mode, const _TCHAR *cmdname, const _TCHAR *arg0,...) |
|
intptr_t | _tspawnve (int mode, const _TCHAR *cmdname, const _TCHAR *const *argv, const _TCHAR *const *envp) |
|
intptr_t | _tspawnvp (int mode, const _TCHAR *cmdname, const _TCHAR *const *argv) |
|
intptr_t | _tspawnlp (int mode, const _TCHAR *cmdname, const _TCHAR *arg0,...) |
|
intptr_t | _tspawnlpe (int mode, const _TCHAR *cmdname, const _TCHAR *arg0,...) |
|
intptr_t | _tspawnvpe (int mode, const _TCHAR *cmdname, const _TCHAR *const *argv, const _TCHAR *const *envp) |
|
intptr_t | _texecl (const _TCHAR *cmdname, const _TCHAR *arg0,...) |
|
intptr_t | _texecv (const _TCHAR *cmdname, const _TCHAR *const *argv) |
|
intptr_t | _texecle (const _TCHAR *cmdname, const _TCHAR *arg0,...) |
|
intptr_t | _texecve (const _TCHAR *cmdname, const _TCHAR *const *argv, const _TCHAR *const *envp) |
|
intptr_t | _texeclp (const _TCHAR *cmdname, const _TCHAR *arg0,...) |
|
intptr_t | _texecvp (const _TCHAR *cmdname, const _TCHAR *const *argv) |
|
intptr_t | _texeclpe (const _TCHAR *cmdname, const _TCHAR *arg0,...) |
|
intptr_t | _texecvpe (const _TCHAR *cmdname, const _TCHAR *const *argv, const _TCHAR *const *envp) |
|
◆ access_dirT
#define access_dirT access_dirA |
◆ argvtosT
◆ do_spawnT
◆ extT
◆ find_execT
◆ MK_STR
◆ sT
◆ valisttosT
◆ _texecl()
Definition at line 534 of file process.c.
535{
539
541
544
546 {
549 }
552}
◆ _texecle()
Definition at line 566 of file process.c.
567{
573
575
578 do
579 {
581 }
586 {
589 }
590 if (envs)
591 {
593 }
596}
◆ _texeclp()
Definition at line 610 of file process.c.
611{
616
618
621
623 {
626 }
629}
◆ _texeclpe()
Definition at line 643 of file process.c.
644{
651
653
656 do
657 {
659 }
664 {
667 }
668 if (envs)
669 {
671 }
674}
◆ _texecv()
◆ _texecve()
◆ _texecvp()
◆ _texecvpe()
◆ _tspawnl()
Definition at line 345 of file process.c.
346{
350
352
355
357 {
360 }
363}
◆ _tspawnle()
Definition at line 388 of file process.c.
389{
395
397
400 do
401 {
403 }
408 {
411 }
412 if (envs)
413 {
415 }
418
419}
◆ _tspawnlp()
Definition at line 462 of file process.c.
463{
468
470
474 {
477 }
480}
◆ _tspawnlpe()
Definition at line 486 of file process.c.
487{
494
496
499 do
500 {
502 }
507 {
510 }
511 if (envs)
512 {
514 }
517}
◆ _tspawnv()
Definition at line 368 of file process.c.
369{
372
374
376
378 {
381 }
383}
◆ _tspawnve()
Definition at line 424 of file process.c.
425{
429
431
434
436 {
439 }
440 if (envs)
441 {
443 }
445}
◆ _tspawnvp()
◆ _tspawnvpe()
◆ access_dirT()
Definition at line 19 of file access.c.
20{
23
26 return -1;
27 }
28
30 {
32 return -1;
33 }
34
35 return 0;
36}
#define FILE_ATTRIBUTE_DIRECTORY
void _dosmaperr(unsigned long oserrcode)
errno_t __cdecl _set_errno(_In_ int _Value)
_Must_inspect_result_ _In_ WDFDMAENABLER _In_ _In_opt_ PWDF_OBJECT_ATTRIBUTES Attributes
DWORD WINAPI GetLastError(void)
#define GetFileAttributes
◆ argvtosT()
Definition at line 122 of file process.c.
123{
127
130
132 {
134 }
135
139
141 {
146 }
148
150}
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define memcpy(s1, s2, n)
◆ do_spawnT()
Definition at line 196 of file process.c.
197{
200
201
202
207
209
210
212 {
214 return( -1);
215 }
216
218 {
220 return(-1);
221 }
223 {
225 return(-1);
226 }
227
228 memset (&StartupInfo, 0,
sizeof(StartupInfo));
229 StartupInfo.
cb =
sizeof(StartupInfo);
230
231#if 0
232
233 for (
last =
i = 0;
i < FDINFO_FD_MAX;
i++)
234 {
236 {
238 }
239 }
240
242 {
246 {
248 return -1;
249 }
250
255 {
256 int _mode = __fileno_getmode(
i);
258
259
260
262 {
264 *fmode = 0;
265 }
266 else
267 {
272 {
275 }
276 else
277 {
279 *fmode = 0;
280 }
281 }
282 fmode++;
284 }
285 }
286#endif
287
289
291 {
293 }
294#ifdef _UNICODE
296#endif
297
306 &StartupInfo,
307 &ProcessInformation);
308
310 {
312 }
313
314 if (!bResult)
315 {
317 ERR(
"%x\n", dwError);
319 return(-1);
320 }
323 {
334 return( (int)dwExitCode);
337 return( 0);
338 }
340}
#define INVALID_HANDLE_VALUE
BOOL WINAPI GetHandleInformation(IN HANDLE hObject, OUT LPDWORD lpdwFlags)
BOOL WINAPI GetExitCodeProcess(IN HANDLE hProcess, IN LPDWORD lpExitCode)
GLfloat GLfloat GLfloat GLfloat h
static void create_io_inherit_block(STARTUPINFOA *startup, unsigned int count, const HANDLE *handles)
_CRTIMP intptr_t __cdecl _get_osfhandle(_In_ int _FileHandle)
DWORD WINAPI WaitForSingleObject(IN HANDLE hHandle, IN DWORD dwMilliseconds)
#define CREATE_UNICODE_ENVIRONMENT
#define HANDLE_FLAG_INHERIT
_In_ PCCERT_CONTEXT _In_ DWORD dwFlags
◆ find_execT()
Definition at line 45 of file process.c.
46{
49 unsigned int i, found = 0;
50
52
54 {
56 }
58 {
60 }
61
62 for (
rd =
path, rp = rpath; *
rd; *rp++ = *
rd++)
63 ;
64 *rp = 0;
65
67 {
69
70 TRACE(
"trying '%"sT"'\n", rpath);
71
73 {
74 found = 1;
75 break;
76 }
77 }
78 if (!found)
79 {
82 {
84 while (*ep && !found)
85 {
86 if (*ep == ';')
87 ep++;
88 rp=rpath;
89 for (; *ep && (*ep != ';'); *rp++ = *ep++)
90 ;
91 if (rp > rpath)
92 {
93 rp--;
94 if (*rp != '/' && *rp != '\\')
95 {
96 *++rp = '\\';
97 }
98 rp++;
99 }
101 ;
103 {
105
106 TRACE(
"trying '%"sT"'\n", rpath);
107
109 {
110 found = 1;
111 break;
112 }
113 }
114 }
115 }
116 }
117
118 return found ? rpath :
path;
119}
static LPCWSTR LPCWSTR LPCWSTR env
◆ valisttosT()
Definition at line 153 of file process.c.
154{
158
161
165 do
166 {
169 }
171
174 {
177 }
178
180 do
181 {
187 }
190
193}
◆ extT
Initial value:
Definition at line 36 of file process.c.