Original Post
Hi,
i''ve a problem with a char function i wrote, after calling the function the argument ''input'' changes. For example input = "abc 123", the function should now set temp to "abc" and not change ''input''.
The Call:
temp = GetConCommand(input);
The Function:
char* GetConCommand(char* minput)
{
int round = 0;
while (minput[round] != '' '') {
round++;
}
minput[round] = ''\0'';
return minput;
}
Need help. I made a workaround and copyed input to another var but i want to know why it works not the way i want it.
greets
flery