distribution and funs

Luke Gorrie <>
Fri Nov 17 15:53:45 CET 2000


Hi there,

We're getting some emulator crashes triggered in the erlang
distribution code, and the problem seems to be that we're trying to
send a fun to a C program that uses erl_interface.

In the function encode_size_struct2 of external.c, the emulator aborts
if you try to encode a fun for a connection that doesn't have the
DFLAG_FUN_TAGS flag, which erl_interface connections don't. I guess
better behaviour would be to crash the erlang process instead. I don't
know my way around the emulator code so I hereby chicken out and
report it as a bug :-)

You're probably wondering why we would want to send a fun to a C
program :-) it's actually happening accidentally; we're sending the
result of a 'catch', and are catching an {'EXIT', {badmatch, X}} where
X contains a fun.

Cheers,
Luke




More information about the erlang-questions mailing list