How to? TPIPE ... see output right away?

May 20, 2008
11,400
99
Syracuse, NY, USA
WINDUMP.EXE is a network monitor (packet sniffer). I use it to produce console output like this.
Code:
windump: listening on \Device\NPF_{ED1ECC20-450A-4ABC-9C82-188211DAE7F6}
11:19:21.442540 IP 61.36.172.93.53680 > 72.230.84.149.1433: tcp 0
11:21:10.141435 IP 77.72.82.80.59801 > 72.230.84.149.4147: tcp 0
11:22:17.461848 IP 74.194.6.5.55649 > 72.230.84.149.2222: tcp 0
11:22:26.598176 IP 5.188.62.25.49605 > 72.230.84.149.8545: tcp 0
I see the output right away, that is, as soon as the packet arrives.

I want to pipe to "TPIPE /replace" to pick certain data from each line. But when I do that, I don't see any output until I terminate WINDUMP with Ctrl-C. This is unlike, for example, piping to GREP.EXE which shows me the output immediately.

Can I get TPIPE to show me the output right away?
 
May 20, 2008
11,400
99
Syracuse, NY, USA
Judging by the command description, no.
Why do you say that? The help says:
Code:
If you don't specify an input filename, TPIPE will read from standard input if it has been redirected. If you don't specify an output filename, TPIPE will write to standard output.
Calling that true is a stretch. What actually seems to happen when you "command | tpipe" is one of these (1 would be my guess).

1. The output of the command is sent to a file and then TPIPE acts on the file.
2. TPIPE writes to a TMP file, and after the command has finished, writes the TMP file to standard output.

Rex, can't it be made to really read from standard in and write to standard out?
 

rps

Jul 6, 2008
436
6
Why do you say that? The help says:
Code:
If you don't specify an input filename, TPIPE will read from standard input if it has been redirected. If you don't specify an output filename, TPIPE will write to standard output.
Calling that true is a stretch. What actually seems to happen when you "command | tpipe" is one of these (1 would be my guess).

1. The output of the command is sent to a file and then TPIPE acts on the file.
2. TPIPE writes to a TMP file, and after the command has finished, writes the TMP file to standard output.

Rex, can't it be made to really read from standard in and write to standard out?
Based on a log file entry #2 is true, tpipe is creating a temporary file and then "typing" it to the screen, then the temp file is gone.
I see this when just entering tpipe directly without any pipe or re-direction.

When I execute:
Code:
tpipe /input=%JPsoft\varlist-master.lst /grep=3,0,0,0,0,0,0,0,"^^([\w]*+)(\=)|^^\.(\w*+)\="

Which produces the expected display and this in the log:
Code:
..............................................

     .........   C:\JPSoft\TCMD21x64\TCC.EXE /c TYPE C:\Users\rps\AppData\Local\Temp\TPI3C40.tmp [456]
[ 9/24/17 15:58:01][456] quit
[ 9/24/17 15:58:01][456] TYPE C:\Users\rps\AppData\Local\Temp\TPI3C40.tmp
....................
This shows the delayed output from tpipe being a temp file as you suspected.

TPIPE starts a transient TCC instance during this file processing.

Using:
Code:
 [I]type %jpsoft\varlist-master.lst |! tpipe /grep=3,0,0,0,0,0,0,0,"^^([\w]*+)(\=)|^^\.(\w*+)\=" |! view
The results and log entries are similar. Meaning the temp file name is different, but the sequence of execution is the same.
It seems the transient TCC is a result of TPIPE in both the piped input or cmd line with input=file.

So, it is obvious that, at present, there isn't a direct to STD output using TPIPE as your OP observed.

If you really need this, add it to the suggestions. I don't see the need myself.
 
Similar threads
Thread starter Title Forum Replies Date
H TPIPE: /FILTER and /OUTPUT unexpected incompatibility Support 6
samintz How to? TPIPE /simple=61 Support 6
R Bug TPIPE's pdf to text conversions don't work Support 2
Kachupp How to? tpipe Support 4
H TPIPE /simple=4 Support 12
D TPIPE produces unwanted logs. Support 1
Kachupp How to? tpipe Support 8
vefatica Documentation TPIPE, /perl, DotMatchesNewLines Support 1
vefatica Stop TPIPE /EOL removing bad EOLs (and TPIPE changine EOLs)? Support 2
vefatica TPIPE in an alias? Support 2
C How to? TPIPE ?'s Support 2
H History and TPipe Oddness Support 3
Jay Sage Baffling Behavior With TPIPE Support 5
vefatica TPIPE: unbalanced escaped quotes in a regex? Support 5
Joe Caverly Multiple Text Searches at once using FFIND or TPIPE Support 4
Kachupp FFIND TPIPE Support 9
vefatica TPIPE and avarice? Support 5
Peter Murschall TPIPE generate unicode on Piping or redirecting Support 3
x13 TPIPE /REPLACE - Remove line (including EOL) Support 3
Charles Dye Documentation TPIPE /REPLACELIST Support 0
Joe Caverly TPIPE and /inputstring Support 3
vefatica How to? Add real <ESC> characters with TPIPE Support 2
vefatica TPIPE.EXE crashes on Ctrl-C Support 9
O TPIPE: Error -Can´t access textpipeengine.dll Support 24
vefatica Extract fields with TPIPE? Support 10
vefatica TPIPE, crash and question Support 1
MickeyF Another TPIPE question Support 6
MickeyF Can't get my TPIPE /replace to work Support 4
Joe Caverly Printing TPIPE documentation Support 3
C WAD tpipe /simple=28 Support 8
vefatica Remove double-quotes with TPIPE Support 4
vefatica TPIPE crashes on Ctrl-C Support 1
C How to? Add date/time to custom tpipe based BTM Support 1
C tpipe /simple=28 error Support 5
C TPipe /dup Support 5
T TPipe: Replacing String with Double Quotes Support 3
C tpipe and extract email addresses Support 1
vefatica How do I do this with TPIPE? Support 1
vefatica TPIPE's /perl option? Support 1
D TPIPE help typo Support 0
vefatica TPIPE access violations are back Support 2
Joe Caverly Word Count using TPIPE Support 10
Dan Glynhampton TPIPE in Build 41 Support 4
Phileosophos TPIPE doesn't work at all with v16 Support 3
vefatica TPIPE access violation again Support 1
David McClelland TPIPE matching problem Support 3
vefatica TPIPE: Access violation Support 5
jbanaszczyk TCMD 16 - TPIPE Support 4
P TPipe relaunches TCC window and 4start, etc Support 7
Phileosophos Documentation TPIPE /string type code confusion Support 4

Similar threads