Like I said.....By a newbie :)
I didn't use IO::Select because I couldn't find any useful examples for it. Since I really don't know what I'm doing I had to go by what I could find examples for.
Thanks for the $socket->close(). Again with little docs and based on examples I found I didn't even know I could do it that way.
I indent my code as I program, It makes for easy readibility (I use a 4 space tab)...Sorry that it screwed up so much on the page.
My "paranoid" client is a scaled down uncleaned version. I had 3 conditions but removed one and I also feel that including an extra (even if impossible) else statement is good for debugging.
I've got lots to learn about IPC. I don't think I understand it too well. I was using some server code found on the site and when it forked it seemed to lose the connection or something. Someone suggested putting a sleep(5) line in and that seemed to fix it, but I wasn't satified with that kind of a fix. I wanted to see if I could get the processes to talk to each other so they could confirm having started before closing any connections. I think I accomplished that, but then again I don't really know much about IPC.
(That comment about IO:Handle and the thousands of lines is from a search: perlipc example....I just didn't take it out.)
:) Thanks for the comments
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.