I am working on directories using dirent.h in c and I want to use a couple of loop with
((entry = readdir(folder)) != NULL)
as a condition.
my question is, do I need to somehow reset it to the starting point of he directory again after the loop, and if so, how?
for example :
while ((entry = readdir(folder)) != NULL)
{
//...
}
//and then, use another loop with the same condition
while ((entry = readdir(folder)) != NULL)
{
//...
}