I am trying to set a variable name and variable value in the environment of Windows by using this function
void env_add(char varname[], char varvalue[]) {
}
The problem is that i do not know how to put both of these variables to int putenv(char *string);
Should I combine them into one char array or not?
Thank you
Yes, you should combine them into a single string. The string has the form “name=value”.