msvcrt: Constify the arguments of execv functions.

This commit is contained in:
Alexandre Julliard 2013-04-09 13:45:48 +02:00
parent e2d3553642
commit d95857d669
2 changed files with 22 additions and 22 deletions

View File

@ -600,9 +600,9 @@ MSVCRT_intptr_t CDECL _execlpe(const char* name, const char* arg0, ...)
*
* Unicode version of _execv
*/
MSVCRT_intptr_t CDECL _wexecv(const MSVCRT_wchar_t* name, MSVCRT_wchar_t* const* argv)
MSVCRT_intptr_t CDECL _wexecv(const MSVCRT_wchar_t* name, const MSVCRT_wchar_t* const* argv)
{
return MSVCRT__wspawnve(MSVCRT__P_OVERLAY, name, (const MSVCRT_wchar_t* const*) argv, NULL);
return MSVCRT__wspawnve(MSVCRT__P_OVERLAY, name, argv, NULL);
}
/*********************************************************************
@ -611,9 +611,9 @@ MSVCRT_intptr_t CDECL _wexecv(const MSVCRT_wchar_t* name, MSVCRT_wchar_t* const*
* Like on Windows, this function does not handle arguments with spaces
* or double-quotes.
*/
MSVCRT_intptr_t CDECL _execv(const char* name, char* const* argv)
MSVCRT_intptr_t CDECL _execv(const char* name, const char* const* argv)
{
return MSVCRT__spawnve(MSVCRT__P_OVERLAY, name, (const char* const*) argv, NULL);
return MSVCRT__spawnve(MSVCRT__P_OVERLAY, name, argv, NULL);
}
/*********************************************************************
@ -621,9 +621,9 @@ MSVCRT_intptr_t CDECL _execv(const char* name, char* const* argv)
*
* Unicode version of _execve
*/
MSVCRT_intptr_t CDECL _wexecve(const MSVCRT_wchar_t* name, MSVCRT_wchar_t* const* argv, const MSVCRT_wchar_t* const* envv)
MSVCRT_intptr_t CDECL _wexecve(const MSVCRT_wchar_t* name, const MSVCRT_wchar_t* const* argv, const MSVCRT_wchar_t* const* envv)
{
return MSVCRT__wspawnve(MSVCRT__P_OVERLAY, name, (const MSVCRT_wchar_t* const*) argv, envv);
return MSVCRT__wspawnve(MSVCRT__P_OVERLAY, name, argv, envv);
}
/*********************************************************************
@ -632,9 +632,9 @@ MSVCRT_intptr_t CDECL _wexecve(const MSVCRT_wchar_t* name, MSVCRT_wchar_t* const
* Like on Windows, this function does not handle arguments with spaces
* or double-quotes.
*/
MSVCRT_intptr_t CDECL MSVCRT__execve(const char* name, char* const* argv, const char* const* envv)
MSVCRT_intptr_t CDECL MSVCRT__execve(const char* name, const char* const* argv, const char* const* envv)
{
return MSVCRT__spawnve(MSVCRT__P_OVERLAY, name, (const char* const*) argv, envv);
return MSVCRT__spawnve(MSVCRT__P_OVERLAY, name, argv, envv);
}
/*********************************************************************
@ -642,9 +642,9 @@ MSVCRT_intptr_t CDECL MSVCRT__execve(const char* name, char* const* argv, const
*
* Unicode version of _execvpe
*/
MSVCRT_intptr_t CDECL _wexecvpe(const MSVCRT_wchar_t* name, MSVCRT_wchar_t* const* argv, const MSVCRT_wchar_t* const* envv)
MSVCRT_intptr_t CDECL _wexecvpe(const MSVCRT_wchar_t* name, const MSVCRT_wchar_t* const* argv, const MSVCRT_wchar_t* const* envv)
{
return MSVCRT__wspawnvpe(MSVCRT__P_OVERLAY, name, (const MSVCRT_wchar_t* const*) argv, envv);
return MSVCRT__wspawnvpe(MSVCRT__P_OVERLAY, name, argv, envv);
}
/*********************************************************************
@ -653,9 +653,9 @@ MSVCRT_intptr_t CDECL _wexecvpe(const MSVCRT_wchar_t* name, MSVCRT_wchar_t* cons
* Like on Windows, this function does not handle arguments with spaces
* or double-quotes.
*/
MSVCRT_intptr_t CDECL _execvpe(const char* name, char* const* argv, const char* const* envv)
MSVCRT_intptr_t CDECL _execvpe(const char* name, const char* const* argv, const char* const* envv)
{
return MSVCRT__spawnvpe(MSVCRT__P_OVERLAY, name, (const char* const*) argv, envv);
return MSVCRT__spawnvpe(MSVCRT__P_OVERLAY, name, argv, envv);
}
/*********************************************************************
@ -663,7 +663,7 @@ MSVCRT_intptr_t CDECL _execvpe(const char* name, char* const* argv, const char*
*
* Unicode version of _execvp
*/
MSVCRT_intptr_t CDECL _wexecvp(const MSVCRT_wchar_t* name, MSVCRT_wchar_t* const* argv)
MSVCRT_intptr_t CDECL _wexecvp(const MSVCRT_wchar_t* name, const MSVCRT_wchar_t* const* argv)
{
return _wexecvpe(name, argv, NULL);
}
@ -674,7 +674,7 @@ MSVCRT_intptr_t CDECL _wexecvp(const MSVCRT_wchar_t* name, MSVCRT_wchar_t* const
* Like on Windows, this function does not handle arguments with spaces
* or double-quotes.
*/
MSVCRT_intptr_t CDECL _execvp(const char* name, char* const* argv)
MSVCRT_intptr_t CDECL _execvp(const char* name, const char* const* argv)
{
return _execvpe(name, argv, NULL);
}

View File

@ -36,10 +36,10 @@ intptr_t __cdecl _execl(const char*,const char*,...);
intptr_t __cdecl _execle(const char*,const char*,...);
intptr_t __cdecl _execlp(const char*,const char*,...);
intptr_t __cdecl _execlpe(const char*,const char*,...);
intptr_t __cdecl _execv(const char*,char* const *);
intptr_t __cdecl _execve(const char*,char* const *,const char* const *);
intptr_t __cdecl _execvp(const char*,char* const *);
intptr_t __cdecl _execvpe(const char*,char* const *,const char* const *);
intptr_t __cdecl _execv(const char*,const char* const *);
intptr_t __cdecl _execve(const char*,const char* const *,const char* const *);
intptr_t __cdecl _execvp(const char*,const char* const *);
intptr_t __cdecl _execvpe(const char*,const char* const *,const char* const *);
int __cdecl _getpid(void);
intptr_t __cdecl _spawnl(int,const char*,const char*,...);
intptr_t __cdecl _spawnle(int,const char*,const char*,...);
@ -94,10 +94,10 @@ int __cdecl _wsystem(const wchar_t*);
static inline intptr_t cwait(int *status, intptr_t pid, int action) { return _cwait(status, pid, action); }
static inline int getpid(void) { return _getpid(); }
static inline intptr_t execv(const char* name, char* const* argv) { return _execv(name, argv); }
static inline intptr_t execve(const char* name, char* const* argv, const char* const* envv) { return _execve(name, argv, envv); }
static inline intptr_t execvp(const char* name, char* const* argv) { return _execvp(name, argv); }
static inline intptr_t execvpe(const char* name, char* const* argv, const char* const* envv) { return _execvpe(name, argv, envv); }
static inline intptr_t execv(const char* name, const char* const* argv) { return _execv(name, argv); }
static inline intptr_t execve(const char* name, const char* const* argv, const char* const* envv) { return _execve(name, argv, envv); }
static inline intptr_t execvp(const char* name, const char* const* argv) { return _execvp(name, argv); }
static inline intptr_t execvpe(const char* name, const char* const* argv, const char* const* envv) { return _execvpe(name, argv, envv); }
static inline intptr_t spawnv(int flags, const char* name, const char* const* argv) { return _spawnv(flags, name, argv); }
static inline intptr_t spawnve(int flags, const char* name, const char* const* argv, const char* const* envv) { return _spawnve(flags, name, argv, envv); }
static inline intptr_t spawnvp(int flags, const char* name, const char* const* argv) { return _spawnvp(flags, name, argv); }