in reply to Why is "If" condition not working
Your current directory is not the directory that you opened for scanning with readdir. That's why it (usually) returns false. If it returns true, it's because, by incident, a different with the same name exists in your current directory.
|
|---|