in reply to Re: Multi-threading ping of a list of hosts.....Again!
in thread Multi-threading ping of a list of hosts.....Again!

A couple of questions about your code:

  1. Why accumulate your thread handles into @kids when you never use them again?
  2. Why not detach the threads at creation when you don't use the returns?

Please note. There is no implied critism here, just comparing notes.

FWIW, I like your technique of enqueuing undefs to terminate your loops. It's much cleaner than several things I've used.


Examine what is said, not who speaks.
"Efficiency is intelligent laziness." -David Dunham
"Think for yourself!" - Abigail
"Memory, processor, disk in that order on the hardware side. Algorithm, algorithm, algorithm on the code side." - tachyon

Replies are listed 'Best First'.
Re^3: Multi-threading ping of a list of hosts.....Again!
by NetWallah (Canon) on Sep 21, 2004 at 19:11 UTC
    I sort of "converted" someone elses program model, and never cleaned it up after proving that it worked , so it has leftover junk. Since this was just a "test program", I did not bother to do the cleanup, so, points taken. Thanks.

        Earth first! (We'll rob the other planets later)