<p>Cool! I&#39;ll try this out and let you know.</p>
<div class="gmail_quote">On Sep 27, 2012 1:33 PM, &quot;Miller Puckette&quot; &lt;<a href="mailto:msp@ucsd.edu">msp@ucsd.edu</a>&gt; wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I&#39;ve never done this but perhaps it would work to edit the line in<br>
pd-gui.tcl:<br>
<br>
exec -- $pd_exec -guiport $::port &amp;<br>
<br>
to:<br>
<br>
exec -- $pd_exec -guiport $::port -d 1 &gt;&amp; /tmp/foo &amp;<br>
<br>
(not sure if &#39;&gt;&amp;&quot; or &#39;2&gt;&#39; depending on shell).<br>
<br>
cheers<br>
Miller<br>
<br>
On Thu, Sep 27, 2012 at 01:23:23PM -0400, Ivica Ico Bukvic wrote:<br>
&gt; This is actually on Linux.<br>
&gt;<br>
&gt; The problem is likely not in C, since program does start up and creates the<br>
&gt; main Pd window and then hangs during loading of the patch (the patch window<br>
&gt; is created but canvas remains empty and after that nothing responds any<br>
&gt; more). It seems to me this is probably because at some point messages sent<br>
&gt; to tcl/tk over network (from C) get mangled after which gui stops<br>
&gt; responding. I had issues like these before with network externals and solved<br>
&gt; them, but this is the one that I had a hard time weeding out since it is so<br>
&gt; sporadic. For this reason, I would like to somehow output all  tcl/tk<br>
&gt; commands that were sent to gui. Any way to do this and send it to a separate<br>
&gt; log file without opening a terminal?<br>
&gt;<br>
&gt; &gt; -----Original Message-----<br>
&gt; &gt; From: Miller Puckette [mailto:<a href="mailto:msp@ucsd.edu">msp@ucsd.edu</a>]<br>
&gt; &gt; Sent: Thursday, September 27, 2012 12:27 PM<br>
&gt; &gt; To: Ivica Ico Bukvic<br>
&gt; &gt; Cc: <a href="mailto:pd-list@iem.at">pd-list@iem.at</a><br>
&gt; &gt; Subject: Re: [PD] debugging sporadic hangs at startup<br>
&gt; &gt;<br>
&gt; &gt; On Macintosh I presume...<br>
&gt; &gt;<br>
&gt; &gt; Maybe you can use gdb to &#39;attach&#39; to the running Pd process, assuming it<br>
&gt; at<br>
&gt; &gt; least gets started up (which I assume it must have in order to start<br>
&gt; loading<br>
&gt; &gt; the patch).<br>
&gt; &gt;<br>
&gt; &gt; cheers<br>
&gt; &gt; Miller<br>
&gt; &gt;<br>
&gt; &gt; On Thu, Sep 27, 2012 at 12:22:57PM -0400, Ivica Ico Bukvic wrote:<br>
&gt; &gt; &gt; All,<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; I am noticing sporadic GUI freezes when loading complex patches on<br>
&gt; &gt; startup.<br>
&gt; &gt; &gt; How would one go about debugging this when most of such startups<br>
&gt; &gt; &gt; happen by clicking on the app icon (so no access to gdb or console).<br>
&gt; &gt; &gt; Short of changing the app icon to make everyone&#39;s apps always start<br>
&gt; &gt; &gt; with gdb, is there a way to redirect debugging output to a file?<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt;<br>
&gt; &gt; &gt; On a related matter, any other users noticed these ocassional hangs<br>
&gt; &gt; &gt; when loading a complex patch (the window opens but remains blank and<br>
&gt; &gt; &gt; clicking on any options in the menu does nothing)?<br>
&gt; &gt; &gt;<br>
&gt; &gt;<br>
&gt; &gt; &gt; _______________________________________________<br>
&gt; &gt; &gt; <a href="mailto:Pd-list@iem.at">Pd-list@iem.at</a> mailing list<br>
&gt; &gt; &gt; UNSUBSCRIBE and account-management -&gt;<br>
&gt; &gt; &gt; <a href="http://lists.puredata.info/listinfo/pd-list" target="_blank">http://lists.puredata.info/listinfo/pd-list</a><br>
&gt;<br>
</blockquote></div>