[erlang-bugs] ERTS_DIST_MSG_DBG flag bug

pan@REDACTED pan@REDACTED
Tue Sep 18 16:52:22 CEST 2012


Hi!

While this define is not something you can set in configure, i.e. it's 
only for hard debugging during development, it's still nice to 
have it fixed. Thanx!

/Patrik, OTP

On Mon, 17 Sep 2012, Ádám Gólya wrote:

> Hi,
>
> I can't complie branch maint with CFLAGS="-D ERTS_DIST_MSG_DBG".
>
> $ sudo CFLAGS="-D ERTS_DIST_MSG_DBG" ./configure
>
> $ sudo make
> ...
> beam/dist.c: In function ?dist_msg_dbg?:
> beam/dist.c:70:5: error: too many arguments to function
> ?erts_decode_dist_ext_size?
> beam/external.h:178:6: note: declared here
> make[3]: *** [obj/x86_64-unknown-linux-gnu/opt/smp/dist.o] Error 1
> make[3]: Leaving directory
> `/home/golya/ewc/erlangbuild/git/otp/erts/emulator'
> make[2]: *** [opt] Error 2
> make[2]: Leaving directory
> `/home/golya/ewc/erlangbuild/git/otp/erts/emulator'
> make[1]: *** [smp] Error 2
> make[1]: Leaving directory `/home/golya/ewc/erlangbuild/git/otp/erts'
> make: *** [emulator] Error 2
>
> $ git branch
> * maint
>
> I made little change, and its works:
>
> $ git diff
> diff --git a/erts/emulator/beam/dist.c b/erts/emulator/beam/dist.c
> index 025258e..b08db7b 100644
> --- a/erts/emulator/beam/dist.c
> +++ b/erts/emulator/beam/dist.c
> @@ -67,7 +67,7 @@ dist_msg_dbg(ErtsDistExternal *edep, char *what, byte
> *buf, int sz)
> {
>     byte *extp = edep->extp;
>     Eterm msg;
> -    Sint size = erts_decode_dist_ext_size(edep, 0);
> +    Sint size = erts_decode_dist_ext_size(edep);
>     if (size < 0) {
>        erts_fprintf(stderr,
>                     "DIST MSG DEBUG: erts_decode_dist_ext_size(%s)
> failed:\n",
>
> Regards,
> Ádám
>


More information about the erlang-bugs mailing list