Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Windows] execve regression #1188

Closed
G4Vi opened this issue May 25, 2024 · 0 comments · Fixed by #1190
Closed

[Windows] execve regression #1188

G4Vi opened this issue May 25, 2024 · 0 comments · Fixed by #1190

Comments

@G4Vi
Copy link
Collaborator

G4Vi commented May 25, 2024

Before cf70a44 the following program paginates a file: on Windows.

#include <unistd.h>

int main(int argc, char *argv[]) {
    pid_t pid = fork();
    if (pid == 0) {
        char *newargv[] = {"/C/Windows/system32/more.com", "C:\\Users\\username\\AppData\\Local\\Temp\\8z8K3x9WA2", NULL};
        char *noenv[] = {NULL};
        execve("/C/Windows/system32/more.com", newargv, noenv);
    } else {
        wait(NULL);
    }
}

CreateProcess succeeds in both places, but immediately terminates since cf70a44.

The --strace before and after looks the same. No changes appear to be made to lpApplicationName and lpCommandLine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant