diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-02-13 14:43:12 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2009-02-13 14:43:12 +0000 |
commit | 9842858add66b084d4fc6f662d40daa0e984f131 (patch) | |
tree | b18c7c5d19e8ecb1ccb1e882c90fc15d3d8b4aaa /ext/socket/basicsocket.c | |
parent | 1fb7ce63031d2a2180b2706dd2185c741b0ff365 (diff) | |
download | ruby-9842858add66b084d4fc6f662d40daa0e984f131.tar.gz |
rdoc update.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22292 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/socket/basicsocket.c')
-rw-r--r-- | ext/socket/basicsocket.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/ext/socket/basicsocket.c b/ext/socket/basicsocket.c index 5510c659f8..550c9500ba 100644 --- a/ext/socket/basicsocket.c +++ b/ext/socket/basicsocket.c @@ -370,7 +370,13 @@ bsock_getpeername(VALUE sock) * * Socket.unix_server_loop("/tmp/sock") {|s| * begin - * p s.getpeereid #=> [1000, 1000] + * euid, egid = s.getpeereid + * + * # Check the connected client is myself or not. + * next if euid != Process.uid + * + * # do something about my resource. + * * ensure * s.close * end |