perl -e'connect _,pack sa14,2,"\nDBo\$\36",socket _,2,1,$/=select _;$|=print"d ! @ARGV\nq\n";print$/ <_>=~/".+?^(.*?)^\./sm' perl
Enjoy!
•Update: one char shorter, which also made it slightly more reliable (I initially matched on the result code, but it could on occasion accidently show up in the host identification. Now I match on a doublequote, which seems to be safe)
Note: pack is used to make it endian-independent
Note 2: the commandline arg ('perl') is the word to be looked up
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: DICT (v2)
by xmath (Hermit) on Jul 21, 2003 at 12:11 UTC |