Closed danfe closed 4 years ago
This affects FreeBSD, NetBSD and OpenBSD. Glibc based systems should be fine.
Yeah, it mainly affects *BSD systems, however, the underlying assumption, and thus the while()
-only code, is still wrong. Thanks for fixing.
The following loop can go wrong on some systems because it assumes that
save
may not become zero again, which is not guaranteed, and may in turn lead to an infinite loop:Correct way is to separate the calls and
directory
check. Compare to the similar loop in thesrc/yicon.cc
for example:Here is the actual patch.