[erlang-bugs] erlang,hd,[[]]
Robert Virding
robert.virding@REDACTED
Mon Feb 11 01:35:37 CET 2013
You are crashing because you are trying to call hd([]) which is illegal as hd/1 returns the head of the argument list and [] has no head. Hence the badarg error. Why it is calling hd([]) in cpu_sup:get_uint32/2 is another story. Can't help you there.
Robert
----- Original Message -----
> From: "Vitaliy Kulchevych" <coolchevy@REDACTED>
> To: erlang-bugs@REDACTED
> Sent: Friday, 8 February, 2013 2:17:18 PM
> Subject: [erlang-bugs] erlang,hd,[[]]
>
> Hi, all!
> I'm using cpu_sup for monitoring os of erlang node. Sometimes I catch
> crash:
>
> {badarg,[{erlang,hd,[[]],[]},{cpu_sup,get_uint32_measurement,2,[{file,"cpu_sup.erl"},{line,282}]},{cpu_sup,measurement_server_loop,1,[{file,"cpu_sup.erl"},{line,585}]}]}
>
>
> Darwin coolchevy.local 11.4.2 Darwin Kernel Version 11.4.2: Thu Aug
> 23
> 16:25:48 PDT 2012; root:xnu-1699.32.7~1/RELEASE_X86_64 x86_64
>
> Mac OS X 10.7.5
>
> Erlang from mac ports: Erlang R15B (erts-5.9)
>
> --
> live free or die;
> _______________________________________________
> erlang-bugs mailing list
> erlang-bugs@REDACTED
> http://erlang.org/mailman/listinfo/erlang-bugs
>
More information about the erlang-bugs
mailing list