I have this code:
if (argv[i] == "-n")
{
wait = atoi(argv[i + 1]);
}
else
{
printf("bad argument '%s'\n",argv[i]);
exit(0);
}
When this code gets executed I get the following error:
bad argument '-n'
I seriously don't know why it does that. Can someone explain?