-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Sat, 18 Sep 2010, David McClellan wrote:

It's a single equals sign and I believe you're testing a condition?

        What's being tested is the value assigned to 'entry', which is, in
turn, the return value of readdir(). readdir() returns the next directory
entry in a stream, or NULL if it's run out of entries. Putting the
assignment inside the test for the while loop means that it will continue to
loop until readdir() runs out of directory entries, and then readdir() will
return NULL, which will be assigned to 'entry', and the loop, testing that
assigned value, will find it false and terminate. This is likely the desired
behavior.

- -- John Campbell
[email protected]

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)

iEYEARECAAYFAkyVejAACgkQPu/PJk2ePZ3I6wCggd3OyNE/aOhjAY9M1QVR/DH8
Kg4AoMg7PDRW6pRorRjlG6bfh5gAPoEd
=B/xZ
-----END PGP SIGNATURE-----

Reply via email to