if( system("tail -500 log.txt") == -1)
{
//Error calling tail.exe on log
//errno is a system macro that expands int returning
//the last error. strerror() converts the error to it's
//corresponding error message.
printf("Error calling tail.exe with system(): %s",strerror( errno ));
}
System() is calling Tail.exe with log.txt
All are in the same directory as the executable calling it.
Getting the error ENOENT- No such file or directory
Also, specified paths to everything, same error.
Any advice is appreciated, thank you.