<p>In modules/exec/exec.c:</p>
<pre style='color:#555'>&gt; +        } else if (outvar) {
&gt; +                pid = __popen(command-&gt;s, &quot;r&quot;, &amp;pout);
&gt; +        } else {
&gt; +                pid = fork();
&gt; +                if (pid == 0) {
&gt; +                        execl(&quot;/bin/sh&quot;, &quot;/bin/sh&quot;, &quot;-c&quot;, command-&gt;s, NULL);
&gt; +                        exit(-1);
&gt; +                }
&gt; +        }
&gt; +
&gt; +        if (input-&gt;len) {
&gt; +                if (fwrite(input-&gt;s, 1, input-&gt;len, pin) != input-&gt;len) {
&gt; +                        LM_ERR(&quot;failed to write to pipe\n&quot;);
&gt; +                        ser_error=E_EXEC;
&gt; +                        goto error;
&gt; +                }
</pre>
<p>This will stall if there is lots of output before the input is needed.</p>

<p>Pipes won't buffer an unlimited amount of data, and I doube that FILE streams will either.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">&mdash;<br>Reply to this email directly or <a href="https://github.com/OpenSIPS/opensips/pull/360/files#r18956935">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/5479561__eyJzY29wZSI6Ik5ld3NpZXM6QmVhY29uIiwiZXhwaXJlcyI6MTcyOTA4NzcxOSwiZGF0YSI6eyJpZCI6NDU5OTk0NjB9fQ==--a55612e02bbba9706061d8e84a96f869c0473edf.gif" width="1" /></p>
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","description":"View this Pull Request on GitHub","action":{"@type":"ViewAction","url":"https://github.com/OpenSIPS/opensips/pull/360/files#r18956935","name":"View Pull Request"}}</script>