Skip to main content
0 votes
1 answer
79 views

I have a large application which forks and execv another binary. I have compiled both parent application and forked child application using --coverage flags. Noticed that .gcno files are created for ...
M09Y's user avatar
  • 15
0 votes
2 answers
154 views

I was trying to understand when the memory owned by shared (smart) pointers are cleared on calling execv() from the code. Assume the following code: #include <memory> class Test { public: ~...
Naveen Kedilaya's user avatar
1 vote
1 answer
60 views

I have a script that is basically just a small GUI to create a config-file for a long-running-program without any graphics. I have and control the source-code for both of these. The usual workflow of ...
julaine's user avatar
  • 2,313
0 votes
1 answer
71 views

I am trying to write only to a file when a user specifies which file to write in with ">". The first iteration works fine, but when a user types any command after the one where they ...
Wragnam's user avatar
  • 31
2 votes
1 answer
113 views

I have a program (parent.rs) that will: Fork Create a userfaultfd on the child, then transfer it to the parent (with pidfd_getfd). Execs the child (child.rs) Child allocates memory with mmap and &...
Filipe Rodrigues's user avatar
1 vote
0 answers
58 views

I am working on custom wrappers for Unix-specific system calls now. And the last problem I met is about how to create a complete function for creating new processes with another image. And I want this ...
Viktoriia Pashchenko's user avatar
1 vote
1 answer
173 views

I'm afraid I have to take out a bit of length so that my question can be understood exactly. I know that forking can cause some problems, especially if you mix it with threads. One nasty problem I ...
SoulfreezerXP's user avatar
-1 votes
2 answers
110 views

I'm writing pseudo-shell and now write parallel-command functionality. In this question ( Differences between fork and exec ) I'm found how I can call execv with returning to my code execution. But I ...
bazylevnik0's user avatar
0 votes
0 answers
206 views

I'm trying to build a version of a linux shell wherein, I take in the commands from the user and execute the commands using execv() system call. I'm using strtok_r to tokenize the commands and pass ...
TheCoder's user avatar
0 votes
2 answers
117 views

I have a simple C program that creates an array of arguments as required by the second argument of execv() that executes a program that computes and outputs the Caeser Cipher decoding of the argument. ...
Panda's user avatar
  • 39
0 votes
1 answer
3k views

I have a C program that I am running on my MacOS terminal. All command line tools and GCC compiler have been installed. However for using functions like getpid() or execv() it gives the following ...
Panda's user avatar
  • 39
2 votes
1 answer
263 views

I am making a program that can take another program as an argument and run it. I am using execv() to run the second program, but how can I use argv[] (that comes from the main program, is a char*) as ...
user avatar
0 votes
1 answer
136 views

I'm currently trying to run an ls command in my C code and then pipe the outputted strings to the parent process via a fd. The problem I'm currently facing is, that I execv the ls command but I don't ...
SourceCodeEngineer's user avatar
0 votes
1 answer
451 views

I'm trying to run a series of commands through execv() and forking a new process in C to run each one, and yet for some reason they aren't running in parallel. The following code is run for each ...
Fathom820's user avatar
0 votes
0 answers
40 views

I'm writing a code in C and I'm trying to use 3 commands (echo, grep and wc) with excev() but its not working. It is possible to do it and if not any other solution or I will need to use fscanf(). How ...
ocram ali's user avatar

15 30 50 per page
1
2 3 4 5
13