<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.eggheads.org/app.php/feed/topic/6669" />

	<title>egghelp/eggheads community</title>
	<subtitle>Discussion of eggdrop bots, shell accounts and tcl scripts.</subtitle>
	<link href="https://forum.eggheads.org/index.php" />
	<updated>2004-01-22T13:32:39-04:00</updated>

	<author><name><![CDATA[egghelp/eggheads community]]></name></author>
	<id>https://forum.eggheads.org/app.php/feed/topic/6669</id>

		<entry>
		<author><name><![CDATA[stdragon]]></name></author>
		<updated>2004-01-22T13:32:39-04:00</updated>

		<published>2004-01-22T13:32:39-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32779#p32779</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32779#p32779"/>
		<title type="html"><![CDATA[Checking if pipe is still open]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32779#p32779"><![CDATA[
So the java program exits, it doesn't hang? Then what is using 100% cpu, eggdrop? That means you're doing something wrong, such as...<br><br>1. you have a loop with gets, but are using nonblocking mode<br>2. you have a loop with gets, in blocking mode, but aren't checking for eof<br>3. you have fconfigured events with nonblocking mode, but never close the pipe<br><br>That's to start with anyway. It's really impossible to say without you posting at least some of your code. Also, try adding debugging info (to eggdrop, and your java program).<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8">stdragon</a> — Thu Jan 22, 2004 1:32 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2004-01-22T13:10:04-04:00</updated>

		<published>2004-01-22T13:10:04-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32776#p32776</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32776#p32776"/>
		<title type="html"><![CDATA[Checking if pipe is still open]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32776#p32776"><![CDATA[
Then you have an *infinite* loop that is not been closed. <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mrgreen.gif" width="15" height="15" alt=":mrgreen:" title="Mr. Green"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Thu Jan 22, 2004 1:10 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Massacre]]></name></author>
		<updated>2004-01-22T08:17:49-04:00</updated>

		<published>2004-01-22T08:17:49-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32771#p32771</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32771#p32771"/>
		<title type="html"><![CDATA[Checking if pipe is still open]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32771#p32771"><![CDATA[
Even on non-blocking mode it still hangs and uses 100% cpu when the java prog is dead <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_sad.gif" width="15" height="15" alt=":(" title="Sad"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2880">Massacre</a> — Thu Jan 22, 2004 8:17 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Massacre]]></name></author>
		<updated>2004-01-22T07:48:59-04:00</updated>

		<published>2004-01-22T07:48:59-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32770#p32770</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32770#p32770"/>
		<title type="html"><![CDATA[Checking if pipe is still open]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32770#p32770"><![CDATA[
I'm trying to test for the java prog exiting unexpetidly cause what happens is, the java prog dies then @ the next call to gets it's probably reading -1 or something and it hangs, cpu hits 100% and has to be killed. Is the only way round this to build my own gets proc and reload the java prog when im gettin -1 or whatever (EOF didn't work cause pipe was alive @ last call to gets).<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2880">Massacre</a> — Thu Jan 22, 2004 7:48 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[user]]></name></author>
		<updated>2004-01-21T15:39:40-04:00</updated>

		<published>2004-01-21T15:39:40-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32751#p32751</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32751#p32751"/>
		<title type="html"><![CDATA[Re: Checking if pipe is still open]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32751#p32751"><![CDATA[
<blockquote class="uncited"><div>Is there a way I can check whether the pipe to my java prog is still open?</div></blockquote>It will be "open" untill you '<a href="http://tcl.tk/man/tcl8.4/TclCmd/close.htm" class="postlink">close</a>' it. I think what you want is '<a href="http://tcl.tk/man/tcl8.4/TclCmd/eof.htm" class="postlink">eof</a>' <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2878">user</a> — Wed Jan 21, 2004 3:39 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Ofloo]]></name></author>
		<updated>2004-01-21T15:27:59-04:00</updated>

		<published>2004-01-21T15:27:59-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32748#p32748</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32748#p32748"/>
		<title type="html"><![CDATA[Checking if pipe is still open]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32748#p32748"><![CDATA[
what do u mean if a dcc is open or what ever maybe use <br><br>if {[info exists varname]}<br><br>stuff like that valididx ..? what is the open pipe ??<br><br>if its a file then use eof or something ..<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3151">Ofloo</a> — Wed Jan 21, 2004 3:27 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Massacre]]></name></author>
		<updated>2004-01-21T09:43:46-04:00</updated>

		<published>2004-01-21T09:43:46-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32736#p32736</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32736#p32736"/>
		<title type="html"><![CDATA[Checking if pipe is still open]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32736#p32736"><![CDATA[
Ha, ok, so it should be "pid $pipe" not [pid $pipe] and it works now but it still returns the PID even if the stream is closed, so does anyone know a working method please?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2880">Massacre</a> — Wed Jan 21, 2004 9:43 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Massacre]]></name></author>
		<updated>2004-01-21T06:53:57-04:00</updated>

		<published>2004-01-21T06:53:57-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32731#p32731</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32731#p32731"/>
		<title type="html"><![CDATA[Checking if pipe is still open]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32731#p32731"><![CDATA[
hmmz, ok no i didn't, the problem still stands, cause catch is always returning 1.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2880">Massacre</a> — Wed Jan 21, 2004 6:53 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Massacre]]></name></author>
		<updated>2004-01-21T06:48:04-04:00</updated>

		<published>2004-01-21T06:48:04-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32730#p32730</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32730#p32730"/>
		<title type="html"><![CDATA[Checking if pipe is still open]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32730#p32730"><![CDATA[
Ok, i've fixed this now by doing the following check:<div class="codebox"><p>Code: </p><pre><code> [catch [pid $pipe]] != "0"</code></pre></div>If it's != "0" then there was an err (eg, $pipe doesn't exist anymore) and I can restart the java prog.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2880">Massacre</a> — Wed Jan 21, 2004 6:48 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Massacre]]></name></author>
		<updated>2004-01-21T05:43:31-04:00</updated>

		<published>2004-01-21T05:43:31-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32727#p32727</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32727#p32727"/>
		<title type="html"><![CDATA[Checking if pipe is still open]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32727#p32727"><![CDATA[
Is there a way I can check whether the pipe to my java prog is still open?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2880">Massacre</a> — Wed Jan 21, 2004 5:43 am</p><hr />
]]></content>
	</entry>
	</feed>
