<p>In modules/exec/exec.c:</p>
<pre style='color:#555'>> +        } else if (outvar) {
> +                pid = __popen(command->s, "r", &pout);
> +        } else {
> +                pid = fork();
> +                if (pid == 0) {
> +                        execl("/bin/sh", "/bin/sh", "-c", command->s, NULL);
> +                        exit(-1);
> +                }
> +        }
> +
> +        if (input->len) {
> +                if (fwrite(input->s, 1, input->len, pin) != input->len) {
> +                        LM_ERR("failed to write to pipe\n");
> +                        ser_error=E_EXEC;
> +                        goto error;
> +                }
</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;">—<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>