[erlang-questions] erl_interface issue

Davide Marquês <>
Mon May 11 13:41:06 CEST 2009

Hi all,

Just wanted to let you know that I found out what was preventing
erl_interface from working on windows! :)
The solution had already been shared on the mailing lists:
It's just a matter of setting stdin/out to binary mode and voilá: working code!

We have Serge Aleynikov to thank for figuring out the solution to this
problem and
for a great tutorial on using ei:
Thanks wherever you are! :)

The erl_interface examples complex/echo
are now working. :)


2009/5/4 Davide Marquês <>:
> Hi all,
> erl_interface help wanted! :)
> I'm getting a consistent failure under certain inputs:
> 1> echo:start("../../MSVC/Release/echo.exe").
> <0.33.0>
> 2> echo:echo("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa").
> sending to port: {echo,{"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"}}
> {ok,"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"}
> 3> echo:echo("aaaaa").
> sending to port: {echo,{"aaaaa"}}
> {ok,"aaaaaaaaa"}
> 4> echo:echo("aaa aaaaaa").
> sending to port: {echo,{"aaa aaaaaa"}}
> =ERROR REPORT==== 4-May-2009::16:11:15 ===
> catch: error:badarg
> As far as I can tell it's not an issue with the size of the message but with
> the actual data being passed. I first spotted this problem with the
> "New Folder" string. But the problem is not "string" specific... exchanging
> a 'New Folder' atom or <<"New Folder">> binary will also fail.
> At first I thought this problem could have been the result of using broken
> erl_interface libraries (built with MinGW), but I've since started using MSVC
> to link my program with the libraries that are bundled in the windows
> erlang distribution and the problem remains.
> I've made all the code necessary to replicate this issue available here:
> http://github.com/davide/erl_interface-examples/tree/master
> At this point I have absolutely no idea how to proceed into debugging this.
> Any tips are welcome! ;)
> Cheers,
> :Davide

More information about the erlang-questions mailing list