Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??
I'm trying to provide fd for Linux::INotify, but I'm having problems fetching that..., I tried something like that:

my ($fd); open($fd,"/tmp"); use Data::Dumper; print "PID: $$"; print Dumper(\$fd);
but all I get is:
 PID: 22117
 $VAR1 = \\*{'::$fd'};
Additionally I tried looking at that pid:
wraith eyck 11:17 ~> ls /proc/22117/fd -l
total 0
lrwx------  1 eyck root 64 Sep 13 11:17 0 -> /dev/pts/44
lrwx------  1 eyck root 64 Sep 13 11:17 1 -> /dev/pts/44
lrwx------  1 eyck root 64 Sep 13 11:17 2 -> /dev/pts/44
lr-x------  1 eyck root 64 Sep 13 11:17 3 -> /tmp
Is there a way to see that from inside?

In reply to How to get file descriptor (number) by Eyck

Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":

  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?

What's my password?
Create A New User
Domain Nodelet?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (8)
As of 2023-03-27 13:49 GMT
Find Nodes?
    Voting Booth?
    Which type of climate do you prefer to live in?

    Results (65 votes). Check out past polls.