mirror of
https://github.com/git/git.git
synced 2026-04-02 04:50:12 +02:00
Avoid declaration after instruction
Microsoft Visual C++ does not understand this C99 style. Signed-off-by: Frank Li <lznuaa@gmail.com> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This commit is contained in:
committed by
Johannes Schindelin
parent
7ea14c8f59
commit
3c150abb10
@@ -123,6 +123,7 @@ int start_command(struct child_process *cmd)
|
||||
exit(127);
|
||||
}
|
||||
#else
|
||||
{
|
||||
int s0 = -1, s1 = -1, s2 = -1; /* backups of stdin, stdout, stderr */
|
||||
const char **sargv = cmd->argv;
|
||||
char **env = environ;
|
||||
@@ -186,6 +187,7 @@ int start_command(struct child_process *cmd)
|
||||
dup2(s1, 1), close(s1);
|
||||
if (s2 >= 0)
|
||||
dup2(s2, 2), close(s2);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (cmd->pid < 0) {
|
||||
|
||||
Reference in New Issue
Block a user