aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lang/erlang/Makefile2
-rw-r--r--lang/erlang/files/patch-erts_emulator_beam_erl__process__dump.c27
-rw-r--r--lang/erlang14/Makefile2
-rw-r--r--lang/erlang14/files/patch-erts_emulator_beam_erl__process__dump.c27
4 files changed, 56 insertions, 2 deletions
diff --git a/lang/erlang/Makefile b/lang/erlang/Makefile
index 5c9f53bbd8f..5065c6f9790 100644
--- a/lang/erlang/Makefile
+++ b/lang/erlang/Makefile
@@ -7,7 +7,7 @@
PORTNAME= erlang
PORTVERSION= r11b3
-PORTREVISION= 1
+PORTREVISION= 2
PORTEPOCH= 1
CATEGORIES= lang parallel
MASTER_SITES= http://www.erlang.org/download/ \
diff --git a/lang/erlang/files/patch-erts_emulator_beam_erl__process__dump.c b/lang/erlang/files/patch-erts_emulator_beam_erl__process__dump.c
new file mode 100644
index 00000000000..cdccf8671ff
--- /dev/null
+++ b/lang/erlang/files/patch-erts_emulator_beam_erl__process__dump.c
@@ -0,0 +1,27 @@
+
+$FreeBSD$
+
+--- erts/emulator/beam/erl_process_dump.c.orig
++++ erts/emulator/beam/erl_process_dump.c
+@@ -399,9 +399,11 @@
+ static void
+ dump_externally(int to, void *to_arg, Eterm term)
+ {
+- byte sbuf[1024]; /* encode and hope for the best ... */
+- byte* s;
+- byte* p;
++ byte *sbuf, *s, *p;
++ unsigned size;
++
++ size = encode_size_struct(term, TERM_TO_BINARY_DFLAGS);
++ sbuf = (byte *) erts_alloc(ERTS_ALC_T_TMP, size);
+
+ s = p = sbuf;
+ erts_to_external_format(NULL, term, &p, NULL, NULL);
+@@ -409,4 +411,6 @@
+ while (s < p) {
+ erts_print(to, to_arg, "%02X", *s++);
+ }
++
++ erts_free(ERTS_ALC_T_TMP, (void *) sbuf);
+ }
diff --git a/lang/erlang14/Makefile b/lang/erlang14/Makefile
index 5c9f53bbd8f..5065c6f9790 100644
--- a/lang/erlang14/Makefile
+++ b/lang/erlang14/Makefile
@@ -7,7 +7,7 @@
PORTNAME= erlang
PORTVERSION= r11b3
-PORTREVISION= 1
+PORTREVISION= 2
PORTEPOCH= 1
CATEGORIES= lang parallel
MASTER_SITES= http://www.erlang.org/download/ \
diff --git a/lang/erlang14/files/patch-erts_emulator_beam_erl__process__dump.c b/lang/erlang14/files/patch-erts_emulator_beam_erl__process__dump.c
new file mode 100644
index 00000000000..cdccf8671ff
--- /dev/null
+++ b/lang/erlang14/files/patch-erts_emulator_beam_erl__process__dump.c
@@ -0,0 +1,27 @@
+
+$FreeBSD$
+
+--- erts/emulator/beam/erl_process_dump.c.orig
++++ erts/emulator/beam/erl_process_dump.c
+@@ -399,9 +399,11 @@
+ static void
+ dump_externally(int to, void *to_arg, Eterm term)
+ {
+- byte sbuf[1024]; /* encode and hope for the best ... */
+- byte* s;
+- byte* p;
++ byte *sbuf, *s, *p;
++ unsigned size;
++
++ size = encode_size_struct(term, TERM_TO_BINARY_DFLAGS);
++ sbuf = (byte *) erts_alloc(ERTS_ALC_T_TMP, size);
+
+ s = p = sbuf;
+ erts_to_external_format(NULL, term, &p, NULL, NULL);
+@@ -409,4 +411,6 @@
+ while (s < p) {
+ erts_print(to, to_arg, "%02X", *s++);
+ }
++
++ erts_free(ERTS_ALC_T_TMP, (void *) sbuf);
+ }