[erlang-questions] Question on Diagraph module

Vlad Dumitrescu vladdu55@REDACTED
Tue Jan 29 11:28:44 CET 2008


Hi,

On Jan 29, 2008 11:33 AM, Søren Hilmer <sh@REDACTED> wrote:
> Well I do not think that is the problem Balu is facing. Just tried his
> example (same result btw).
> And doing a G. after the badarith, still shows G, and the shell is fine.

G only is a record and the numbers in it (14, 15, 16) are handles to
ets tables containing the graph data. These are owned by the shell
process and disappear when that process crashes and dies. When calling
digraph:info/1 again, it queries the inexistent tables for their size
and they return "undefined" instead of a size and there's a badarith
exception when trying to add those 'undefined' atoms...

A better error message would be very useful in this case, I think.

best regards,
Vlad



More information about the erlang-questions mailing list