From dirkjan@REDACTED Thu May 1 08:56:04 2014 From: dirkjan@REDACTED (Dirkjan Ochtman) Date: Thu, 1 May 2014 08:56:04 +0200 Subject: [erlang-bugs] epmd_srv.c:(.text+0x830): undefined reference to `sd_listen_fds' In-Reply-To: <5360B0BD.9010308@erlang.org> References: <535F60F1.9030400@erlang.org> <535F6806.8020308@erlang.org> <5360B0BD.9010308@erlang.org> Message-ID: On Wed, Apr 30, 2014 at 10:13 AM, Lukas Larsson wrote: > The interesting pieces are in erts/config.log, not in the top config.log. Do > you think you could get hold of that log? Why, yes: https://bugs.gentoo.org/attachment.cgi?id=376100 Cheers, Dirkjan From jani.j.hakala@REDACTED Thu May 1 11:48:17 2014 From: jani.j.hakala@REDACTED (Jani Hakala) Date: Thu, 01 May 2014 12:48:17 +0300 Subject: [erlang-bugs] epmd_srv.c:(.text+0x830): undefined reference to `sd_listen_fds' In-Reply-To: (Dirkjan Ochtman's message of "Thu, 1 May 2014 08:56:04 +0200") References: <535F60F1.9030400@erlang.org> <535F6806.8020308@erlang.org> <5360B0BD.9010308@erlang.org> Message-ID: <877g65u8wu.fsf@pingviini.dy.fi> Dirkjan Ochtman writes: > On Wed, Apr 30, 2014 at 10:13 AM, Lukas Larsson wrote: >> The interesting pieces are in erts/config.log, not in the top config.log. Do >> you think you could get hold of that log? > > Why, yes: > > https://bugs.gentoo.org/attachment.cgi?id=376100 > You could change the file erts/configure.in so that line AC_SEARCH_LIBS(sd_listen_fds,[systemd-daemon], is changed to AC_SEARCH_LIBS(sd_listen_fds,[systemd systemd-daemon], and after that, run autoconf. Jani Hakala From ransomr@REDACTED Thu May 1 15:29:35 2014 From: ransomr@REDACTED (Ransom Richardson) Date: Thu, 1 May 2014 13:29:35 +0000 Subject: [erlang-bugs] ssl versions option is order dependent - can incorrectly disable cipher suites In-Reply-To: <1398862454676.88659@talko.com> References: <1398862454676.88659@talko.com> Message-ID: <1398950975122.40996@talko.com> The issue is line 644 in ssl.erl: ciphers = handle_cipher_option(proplists:get_value(ciphers, Opts, []), hd(Versions)), If 'tlsv1.2' is in the versions list but not not the head, then any tlsv1.2 ciphers will be disabled. -------------- next part -------------- An HTML attachment was scrubbed... URL: From mjtruog@REDACTED Thu May 1 19:42:31 2014 From: mjtruog@REDACTED (Michael Truog) Date: Thu, 01 May 2014 10:42:31 -0700 Subject: [erlang-bugs] reltool dependencies ignored Message-ID: <53628787.3070802@gmail.com> Hi, I believe I found a bug that causes reltool to ignore dependencies when generating a release. I am not sure where the problem is within reltool, but I at least have a way to demonstrate it. https://github.com/CloudI/CloudI/blob/develop/src/reltool.config.in#L78-L89 shows lines that are unnecessary within the reltool.config file. The dependencies mentioned there should be found automatically by reltool. If you remove those lines and do a make install (after the autogen.sh and configure steps) you will see the dependencies mentioned in these lines are not there. Thanks, Michael From roland.karlsson@REDACTED Thu May 1 21:47:36 2014 From: roland.karlsson@REDACTED (Roland Karlsson) Date: Thu, 01 May 2014 21:47:36 +0200 Subject: [erlang-bugs] I sent a bug report with patch to erlang-patches Message-ID: <20140501214734.FC68.69B9F832@proxel.se> Hi, I found a bug and made a patch and sent it here http://erlang.org/pipermail/erlang-patches/2014-April/004667.html "bg fix patch for revert map_field_assoc in syntax_tools" Maybe I sent to the wrong mailing list? -- Roland Karlsson From wallentin.dahlberg@REDACTED Thu May 1 23:16:20 2014 From: wallentin.dahlberg@REDACTED (=?UTF-8?Q?Bj=C3=B6rn=2DEgil_Dahlberg?=) Date: Thu, 1 May 2014 23:16:20 +0200 Subject: [erlang-bugs] I sent a bug report with patch to erlang-patches In-Reply-To: <20140501214734.FC68.69B9F832@proxel.se> References: <20140501214734.FC68.69B9F832@proxel.se> Message-ID: Just overlooked. Does this fix the same issue as https://github.com/erlang/otp/pull/329 .. in that one I'm waiting for a testcase. If you are comfortable with GitHub Pull Requests you should really use that instead of the mailing list. It is much easier to see reported patches and organize them. // Bj?rn-Egil 2014-05-01 21:47 GMT+02:00 Roland Karlsson : > Hi, > > I found a bug and made a patch and sent it here > > http://erlang.org/pipermail/erlang-patches/2014-April/004667.html > "bg fix patch for revert map_field_assoc in syntax_tools" > > Maybe I sent to the wrong mailing list? > > > -- > Roland Karlsson > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Ingela.Anderton.Andin@REDACTED Fri May 2 09:04:35 2014 From: Ingela.Anderton.Andin@REDACTED (Ingela Anderton Andin) Date: Fri, 2 May 2014 09:04:35 +0200 Subject: [erlang-bugs] ssl versions option is order dependent - can incorrectly disable cipher suites In-Reply-To: <1398950975122.40996@talko.com> References: <1398862454676.88659@talko.com> <1398950975122.40996@talko.com> Message-ID: <53634383.8090800@ericsson.com> Hi! You have a good point. Although it in most cases it will be true that the highest version is at the head of the list, it is not documented that it has to be or even desirable that we should have such a dependency. I will change the code to diff --git a/lib/ssl/src/ssl.erl b/lib/ssl/src/ssl.erl index 866312f..4dea977 100644 --- a/lib/ssl/src/ssl.erl +++ b/lib/ssl/src/ssl.erl @@ -637,7 +637,8 @@ handle_options(Opts0, _Role) -> user_lookup_fun = handle_option(user_lookup_fun, Opts, undefined), psk_identity = handle_option(psk_identity, Opts, undefined), srp_identity = handle_option(srp_identity, Opts, undefined), - ciphers = handle_cipher_option(proplists:get_value(ciphers, Opts, []), hd(Versions)), + ciphers = handle_cipher_option(proplists:get_value(ciphers, Opts, []), + RecordCb:highest_protocol_version(Versions)), %% Server side option reuse_session = handle_option(reuse_session, Opts, ReuseSessionFun), reuse_sessions = handle_option(reuse_sessions, Opts, true), Regards Ingela Erlang/OTP Team - Ericsson AB On 05/01/2014 03:29 PM, Ransom Richardson wrote: > > The issue is line 644 in ssl.erl: > > > ciphers = handle_cipher_option(proplists:get_value(ciphers, Opts, > []), hd(Versions)), > > If 'tlsv1.2' is in the versions list but not not the head, then any > tlsv1.2 ciphers will be disabled. > > > > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > From argos83@REDACTED Fri May 2 11:31:53 2014 From: argos83@REDACTED (Seba) Date: Fri, 2 May 2014 11:31:53 +0200 Subject: [erlang-bugs] Erlang OTP's httpc module denial of service Message-ID: Hi list! I've found a vulnerability in the httpc module. I'm sorry I can't provide a patch (I can't code much erlang yet), I'm attaching a proof of concept though. Let me know if you need further details. Regards, Sebasti?n Tello Summary ======= Using httpc to connect to an untrusted server can cause the system to run out of memory and crash. Description =========== When requesting a URL from an untrusted source using the httpc OTP module, if the server: - accepts the connection - does not read from the socket - and indefinitely writes bytes in the socket. Then the client will keep on allocating memory until the system crashes. Proof of concept ================ Server-side (attacker): Start the malicious server (use the attached module). 1> httpc_dos:server(5678). Client-side (httpc), connect to the server: $ erl Erlang/OTP 17 [erts-6.0] [source] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false] Eshell V6.0 (abort with ^G) 1> application:start(inets). ok 2> httpc:request("http://SERVER_IP:5678"). Crash dump was written to: erl_crash.dump eheap_alloc: Cannot allocate 1167696400 bytes of memory (of type "heap"). Tested on ========= OTP 17 Ubuntu 12.04 x86_64 Workaround ========== I haven't been able to reproduce the issue using lhttpc ( https://github.com/esl/lhttpc) as the call will crash when the response size is too large. -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: httpc_dos.erl Type: text/x-erlang Size: 392 bytes Desc: not available URL: From roland.karlsson@REDACTED Fri May 2 11:42:22 2014 From: roland.karlsson@REDACTED (Roland Karlsson) Date: Fri, 02 May 2014 11:42:22 +0200 Subject: [erlang-bugs] I sent a bug report with patch to erlang-patches In-Reply-To: References: <20140501214734.FC68.69B9F832@proxel.se> Message-ID: <20140502114220.1D68.69B9F832@proxel.se> I am not sure if it fixes that problem. Can check that on Monday. But ... it sure looks like the same problem. Or a very similar one. Regarding pull requests. Yeah, I can issue a pull request if you want - also on Monday. /Roland On Thu, 1 May 2014 23:16:20 +0200 Bj?rn-Egil Dahlberg wrote: > Just overlooked. > > Does this fix the same issue as https://github.com/erlang/otp/pull/329 .. > in that one I'm waiting for a testcase. > > If you are comfortable with GitHub Pull Requests you should really use that > instead of the mailing list. It is much easier to see reported patches and > organize them. > > // Bj?rn-Egil > > > > > 2014-05-01 21:47 GMT+02:00 Roland Karlsson : > > > Hi, > > > > I found a bug and made a patch and sent it here > > > > http://erlang.org/pipermail/erlang-patches/2014-April/004667.html > > "bg fix patch for revert map_field_assoc in syntax_tools" > > > > Maybe I sent to the wrong mailing list? > > > > > > -- > > Roland Karlsson > > > > _______________________________________________ > > erlang-bugs mailing list > > erlang-bugs@REDACTED > > http://erlang.org/mailman/listinfo/erlang-bugs > > -- Roland Karlsson From n.oxyde@REDACTED Sun May 4 11:13:32 2014 From: n.oxyde@REDACTED (Anthony Ramine) Date: Sun, 4 May 2014 11:13:32 +0200 Subject: [erlang-bugs] Match error when mapping a list of maps with anonymous functions in the shell In-Reply-To: <535FA680.7060005@erlang.org> References: <6207E54E-3569-495E-BB6F-12D21A9F35F0@gmail.com> <535E50E1.80505@erlang.org> <20140429130802.GF68518@ferdair.local> <535FA680.7060005@erlang.org> Message-ID: Fixed the initial bug reported by Jos?: https://github.com/erlang/otp/pull/352 Now the only remaining bug concerns some edge cases: [X=not_ok,(fun (Y) -> X = Y end)(ok)]. [X=not_ok,case ok of ok -> X = ok; _ -> ok end]. In my opinion, in both cases the second X shouldn?t be matched against the first. -- Anthony Ramine Le 29 avr. 2014 ? 15:17, Bj?rn-Egil Dahlberg a ?crit : > On 2014-04-29 15:08, Fred Hebert wrote: >> (X=#{})#{x => (fun (Y) -> X = Y end)(ok). > > I tested this, > > (X=#{})#{x => (fun (Y) -> X = Y end)(#{}) }. > > > I think I see a scoping error with respect to X =( > > > From kostis@REDACTED Sun May 4 13:00:19 2014 From: kostis@REDACTED (Kostis Sagonas) Date: Sun, 04 May 2014 13:00:19 +0200 Subject: [erlang-bugs] Match error when mapping a list of maps with anonymous functions in the shell In-Reply-To: References: <6207E54E-3569-495E-BB6F-12D21A9F35F0@gmail.com> <535E50E1.80505@erlang.org> <20140429130802.GF68518@ferdair.local> <535FA680.7060005@erlang.org> Message-ID: <53661DC3.1020902@cs.ntua.gr> On 05/04/2014 11:13 AM, Anthony Ramine wrote: > Now the only remaining bug concerns some edge cases: > > [X=not_ok,(fun (Y) -> X = Y end)(ok)]. > [X=not_ok,case ok of ok -> X = ok; _ -> ok end]. > > In my opinion, in both cases the second X shouldn?t be matched against the first. Why not? Care to elaborate what is your rationale and what should happen in these cases? Kostis From n.oxyde@REDACTED Sun May 4 14:04:47 2014 From: n.oxyde@REDACTED (Anthony Ramine) Date: Sun, 4 May 2014 14:04:47 +0200 Subject: [erlang-bugs] Match error when mapping a list of maps with anonymous functions in the shell In-Reply-To: <53661DC3.1020902@cs.ntua.gr> References: <6207E54E-3569-495E-BB6F-12D21A9F35F0@gmail.com> <535E50E1.80505@erlang.org> <20140429130802.GF68518@ferdair.local> <535FA680.7060005@erlang.org> <53661DC3.1020902@cs.ntua.gr> Message-ID: Because it makes the evaluation order relevant to scoping, while it shouldn?t be. Compare with: [(fun (Y) -> X = Y end)(ok),X=not_ok]. [case ok of ok -> X = ok; _ -> ok end,X=not_ok]. Also, Bj?rn-Egil confirmed that the expression with the fun is indeed a bug. Nobody confirmed anything for the case with the unsafe X though. The Erlang documentation agrees that there is no defined evaluation order. And erl_lint agrees with me that the X in the fun shouldn?t match against the previous X, claiming both are unused. In both cases, I think the X in the fun (or the case) shouldn?t match against anything and just be declared as unused by erl_lint. Ideally, such code would just be forbidden by erl_lint because it is confusing. -- Anthony Ramine Le 4 mai 2014 ? 13:00, Kostis Sagonas a ?crit : > On 05/04/2014 11:13 AM, Anthony Ramine wrote: >> Now the only remaining bug concerns some edge cases: >> >> [X=not_ok,(fun (Y) -> X = Y end)(ok)]. >> [X=not_ok,case ok of ok -> X = ok; _ -> ok end]. >> >> In my opinion, in both cases the second X shouldn?t be matched against the first. > > Why not? Care to elaborate what is your rationale and what should happen in these cases? > > Kostis > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs From mononcqc@REDACTED Sun May 4 14:43:25 2014 From: mononcqc@REDACTED (Fred Hebert) Date: Sun, 4 May 2014 08:43:25 -0400 Subject: [erlang-bugs] Match error when mapping a list of maps with anonymous functions in the shell In-Reply-To: References: <6207E54E-3569-495E-BB6F-12D21A9F35F0@gmail.com> <535E50E1.80505@erlang.org> <20140429130802.GF68518@ferdair.local> <535FA680.7060005@erlang.org> <53661DC3.1020902@cs.ntua.gr> Message-ID: <20140504124324.GA85111@ferdmbp.local> So I see the original ones: [X=not_ok,(fun (Y) -> X = Y end)(ok)]. [X=not_ok,case ok of ok -> X = ok; _ -> ok end]. Here's an interesting experiment with these to hilight the order of operation vs. scoping relationship, tried both in the shell and with the compiler (and HiPE): - [A=1,B=A,C=A] => error: variable 'A' is unbound - [A=B,B=1,C=B] => error: variable 'B' is unbound - [A=B,B=C,C=1] => error: variable 'B' is unbound If no scope is present at first, the expressions will all fail. However, if I bind A=1 before building the list: - [A=1,B=A,C=A] => [1,1,1] - [A=B,B=1,C=B] => error: variable 'B' is unbound - [A=B,B=A,C=B] => error: variable 'B' is unbound - [A=B,B=C,C=1] => error: variable 'B' is unbound According to this kind of behavior, it does look like no order of evaluation is assumed for each of the entires of a list, similarly for tuples and lists declared as cons cells: - {A=1,B=A,C=A} => error: variable 'A' is unbound - [A=1 | [B=A | [C=A | []]]] => error: variable 'A' is unbound Given that kind of behaior, I'd have to agree with you, Anthony, that in both original cases, the right hand side 'X' shouldn't be matched, unless we're going to change some deeper (and apparently) stable semantics in the language there. (Incidentally, I wonder if the changes to pattern matching recommended/planned for maps that would start allowing these use cases also.) Regards, Fred. On 05/04, Anthony Ramine wrote: > Because it makes the evaluation order relevant to scoping, while it shouldn?t be. > > Compare with: > > [(fun (Y) -> X = Y end)(ok),X=not_ok]. > [case ok of ok -> X = ok; _ -> ok end,X=not_ok]. > > Also, Bj?rn-Egil confirmed that the expression with the fun is indeed a bug. Nobody confirmed anything for the case with the unsafe X though. > > The Erlang documentation agrees that there is no defined evaluation order. > > And erl_lint agrees with me that the X in the fun shouldn?t match against the previous X, claiming both are unused. > > In both cases, I think the X in the fun (or the case) shouldn?t match against anything and just be declared as unused by erl_lint. > > Ideally, such code would just be forbidden by erl_lint because it is confusing. > > -- > Anthony Ramine > > Le 4 mai 2014 ? 13:00, Kostis Sagonas a ?crit : > > > On 05/04/2014 11:13 AM, Anthony Ramine wrote: > >> Now the only remaining bug concerns some edge cases: > >> > >> [X=not_ok,(fun (Y) -> X = Y end)(ok)]. > >> [X=not_ok,case ok of ok -> X = ok; _ -> ok end]. > >> > >> In my opinion, in both cases the second X shouldn?t be matched against the first. > > > > Why not? Care to elaborate what is your rationale and what should happen in these cases? > > > > Kostis > > _______________________________________________ > > erlang-bugs mailing list > > erlang-bugs@REDACTED > > http://erlang.org/mailman/listinfo/erlang-bugs > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs From n.oxyde@REDACTED Sun May 4 15:11:01 2014 From: n.oxyde@REDACTED (Anthony Ramine) Date: Sun, 4 May 2014 15:11:01 +0200 Subject: [erlang-bugs] Match error when mapping a list of maps with anonymous functions in the shell In-Reply-To: <20140504124324.GA85111@ferdmbp.local> References: <6207E54E-3569-495E-BB6F-12D21A9F35F0@gmail.com> <535E50E1.80505@erlang.org> <20140429130802.GF68518@ferdair.local> <535FA680.7060005@erlang.org> <53661DC3.1020902@cs.ntua.gr> <20140504124324.GA85111@ferdmbp.local> Message-ID: <3B50173C-8F7D-41B4-88E2-ADF1A546D44A@gmail.com> No, augmented patterns require forbidding something currently allowed, namely: X = 1, fun (<>, X) -> {X,Y} end. Currently, this is compiled to: X = 1, fun (<>, X2) -> {X2,Y} end. But the new patterns would allow this, without an outer X: fun (<>, X) -> {X,Y} end. Where the X bit size is taken from the X argument. Given the ambiguity when a name is bound prior to the fun and both used and shadowed in the fun head itself, I think such confusing cases should be forbidden too. My opinion is that we should forbid everything where a single variable name has multiple states. So in compound expressions, forbid any case where a variable is both bound (or exported) and unsafe. In fun heads, forbid any case where a variable is both used and shadowed. -- Anthony Ramine Le 4 mai 2014 ? 14:43, Fred Hebert a ?crit : > (Incidentally, I wonder if the changes to pattern matching > recommended/planned for maps that would start allowing these use cases > also.) From wallentin.dahlberg@REDACTED Sun May 4 16:47:08 2014 From: wallentin.dahlberg@REDACTED (=?UTF-8?Q?Bj=C3=B6rn=2DEgil_Dahlberg?=) Date: Sun, 4 May 2014 16:47:08 +0200 Subject: [erlang-bugs] Negative integer literals as map keys In-Reply-To: <5361041E.5030904@erlang.org> References: <5361041E.5030904@erlang.org> Message-ID: I would like to clarify. Using non-values as keys in Maps will not work, it is a known current limitation. A negative integer is not a value from the compilers perspective, it is a unary *expression*. The same goes for using a plus sign in front of integers. This will be fixed when expressions are allowed. 2014-04-30 16:09 GMT+02:00 Bj?rn-Egil Dahlberg : > Yep, the linter is a bit harsh here. It's suppose to deny all non-value > keys, which technically is what it does here .. but it is a bit harsh. > > I'll look at it. > > // Bj?rn-Egil > > > On 2014-04-30 15:32, Alexey Lebedeff wrote: > > Hi, > > As soon as I add unary minus anywhere in a map key, it breaks with > "illegal map key" message: > > Erlang/OTP 17 [erts-6.0] [source-07b8f44] [64-bit] [smp:8:8] > [async-threads:10] [hipe] [kernel-poll:false] > Eshell V6.0 (abort with ^G) > 3> #{ -1 => 1}. > * 1: illegal map key > 4> #{ {a, -1} => 1 }. > * 1: illegal map key > > > > _______________________________________________ > erlang-bugs mailing listerlang-bugs@REDACTED://erlang.org/mailman/listinfo/erlang-bugs > > > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From lukas@REDACTED Mon May 5 12:11:10 2014 From: lukas@REDACTED (Lukas Larsson) Date: Mon, 5 May 2014 12:11:10 +0200 Subject: [erlang-bugs] epmd_srv.c:(.text+0x830): undefined reference to `sd_listen_fds' In-Reply-To: <877g65u8wu.fsf@pingviini.dy.fi> References: <535F60F1.9030400@erlang.org> <535F6806.8020308@erlang.org> <5360B0BD.9010308@erlang.org> <877g65u8wu.fsf@pingviini.dy.fi> Message-ID: <536763BE.2090506@erlang.org> Hello Dirkjan, Jani and Micheal. Thanks for the feedback and help with creating the fix. I think I've come up with a solution that should address all problems found, but as before I have no system to test it on so it would be great if you could test both with and without --enable-systemd on your machines. The extended patch is available on the same branch as before[1]. If something does not work, please send me the erts/config.log together with the error report. Lukas [1]: https://github.com/garazdawi/otp/tree/lukas/erts/autoconf-fixes From dirkjan@REDACTED Tue May 6 10:45:11 2014 From: dirkjan@REDACTED (Dirkjan Ochtman) Date: Tue, 6 May 2014 10:45:11 +0200 Subject: [erlang-bugs] epmd_srv.c:(.text+0x830): undefined reference to `sd_listen_fds' In-Reply-To: <536763BE.2090506@erlang.org> References: <535F60F1.9030400@erlang.org> <535F6806.8020308@erlang.org> <5360B0BD.9010308@erlang.org> <877g65u8wu.fsf@pingviini.dy.fi> <536763BE.2090506@erlang.org> Message-ID: Hi Lukas, On Mon, May 5, 2014 at 12:11 PM, Lukas Larsson wrote: > I think I've come up with a solution that should address all problems found, > but as before I have no system to test it on so it would be great if you > could test both with and without --enable-systemd on your machines. The > extended patch is available on the same branch as before[1]. I've posted an updated package on the Gentoo bug and asked for testing, I'll let you know when I hear back. Cheers, Dirkjan From dszoboszlay@REDACTED Wed May 7 11:04:50 2014 From: dszoboszlay@REDACTED (=?iso-8859-1?Q?D=E1niel_Szoboszlay?=) Date: Wed, 7 May 2014 11:04:50 +0200 Subject: [erlang-bugs] PEM encoding problems with PBES2-params in public_key Message-ID: Hi, I tried to export an RSA key in PEM format using PBES2 encryption (using Erlang/OTP 17.0). The first problem I noticed is a documentation issue: public_key states that cipher_info() = {"RC2-CBC | "DES-CBC" | "DES-EDE3-CBC", crypto:rand_bytes(8)} | 'PBES2-params'} However the last option should be a #'PBES2-params'{} record, not an atom in reality. This record is not documented in neither the user?s guide nor the reference manual. After reading some source code I came up with the following snippet, which almost works: Rand = crypto:rand_bytes(8), Params = #'PBES2-params'{ keyDerivationFunc = #'PBES2-params_keyDerivationFunc'{ algorithm = ?'id-PBKDF2', parameters = #'PBKDF2-params'{ salt = {specified, Rand}, iterationCount = 1, keyLength = 24, prf = #'PBKDF2-params_prf'{ algorithm = ?'id-hmacWithSHA1' } } }, encryptionScheme = #'PBES2-params_encryptionScheme'{ algorithm = ?'des-EDE3-CBC', parameters = <<4, 8, Rand/binary>> } }, Entry = public_key:pem_entry_encode('RSAPrivateKey', RSAKey, {{"DES-EDE3-CBC", Params}, "1234abcd"}), public_key:pem_encode([Entry]). The problem is that Entry will contain the #'PBES2-params'{} record, but pubkey_pem:encode_pem_entry/1 accepts only a salt (a binary) in that position. As far as I can tell decoding PEM files with PBES2-params work as expected, but encoding doesn?t, and this limitation is not documented. Regards, Daniel -------------- next part -------------- An HTML attachment was scrubbed... URL: From ess@REDACTED Wed May 7 17:19:53 2014 From: ess@REDACTED (=?ISO-8859-1?Q?Erik_S=F8e_S=F8rensen?=) Date: Wed, 7 May 2014 17:19:53 +0200 Subject: [erlang-bugs] Dialyzer chokes on remote types in t_contains_opaque() Message-ID: <536A4F19.4070200@trifork.com> Hi all / To whom it may concern - Using Erlang 17.0, I get Dialyzer errors like the following: {function_clause,[{erl_types,t_contains_opaque, [{c,remote,[{remote,ssl,sslsocket,[]}],unknown}, ...} Looking into the source, true enough, t_contains_opaque() does not handle the ?remote case. The same is true of the otp master branch on github at the time of writing. This is the full output: $ dialyzer --version Dialyzer version v2.7 $ erlc +debug_info bar.erl && dialyzer bar.beam bar.erl:8: Warning: record state is unused Checking whether the PLT /home/erik/.dialyzer_plt is up-to-date... yes Proceeding with analysis... =ERROR REPORT==== 7-May-2014::17:00:09 === Error in process <0.34.0> with exit value: {function_clause,[{erl_types,t_contains_opaque,[{c,remote,[{remote,ssl,sslsocket,[]}],unknown},[]],[{file,"erl_types.erl"},{line,486}]},{lists,any,2,[{file,"lists.erl"},{line,1223}]},{erl_types,t_contains_opaque,2,[{file,"erl_typ... dialyzer: Analysis failed with error: {function_clause,[{erl_types,t_contains_opaque, [{c,remote,[{remote,ssl,sslsocket,[]}],unknown}, []], [{file,"erl_types.erl"},{line,486}]}, {lists,any,2,[{file,"lists.erl"},{line,1223}]}, {erl_types,t_contains_opaque,2, [{file,"erl_types.erl"},{line,493}]}, {erl_types,subtype_is_equal,2, [{file,"erl_types.erl"},{line,479}]}, {erl_types,get_mod_record,3, [{file,"erl_types.erl"},{line,4472}]}, {erl_types,get_mod_record,5, [{file,"erl_types.erl"},{line,4448}]}, {erl_types,record_from_form,5, [{file,"erl_types.erl"},{line,4424}]}, {erl_types,type_from_form,5, [{file,"erl_types.erl"},{line,4372}]}]} Last messages in the log cache: Reading files and computing callgraph... where "bar.erl" is the following attempt at creating a minimal example: -module(bar). -type f(T) :: {ssl:sslsocket(), T}. -record(r1, { f1 :: f(_) }). -type r1(T) :: #r1{ f1 :: fun((ssl:sslsocket(), T) -> any()) }. -record(state, { r :: r1(T), arg :: T }). The following variation also triggers the bug - this one perhaps makes slightly more sense, as the two types for f1 are compatible: -module(baz). -export_type([f/1]). -type f(T) :: fun((erlang:timestamp(), T) -> any()). -record(r1, { f1 :: baz:f(_) }). -type r1(T) :: #r1{ f1 :: f(T) }. -record(state, { f1 :: r1(T), arg :: T }). (That actually just lead me to a workaround: making both types for f1 remote, like this: -record(r1, { f1 :: baz:f(_) }). -type r1(T) :: #r1{ f1 :: baz:f(T) }. makes the bug not be triggered. Which is nice, because then I can get on with my work :-)) Regards, Erik S?e S?rensen -- Mobile: + 45 26 36 17 55 | Skype: eriksoesorensen | Twitter: @eriksoe Trifork A/S | Margrethepladsen 4 | DK-8000 Aarhus C | www.trifork.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From dirkjan@REDACTED Thu May 8 08:59:56 2014 From: dirkjan@REDACTED (Dirkjan Ochtman) Date: Thu, 8 May 2014 08:59:56 +0200 Subject: [erlang-bugs] epmd_srv.c:(.text+0x830): undefined reference to `sd_listen_fds' In-Reply-To: References: <535F60F1.9030400@erlang.org> <535F6806.8020308@erlang.org> <5360B0BD.9010308@erlang.org> <877g65u8wu.fsf@pingviini.dy.fi> <536763BE.2090506@erlang.org> Message-ID: On Tue, May 6, 2014 at 10:45 AM, Dirkjan Ochtman wrote: > I've posted an updated package on the Gentoo bug and asked for > testing, I'll let you know when I hear back. Looks like this works, I'll add those patches for an updated 17.0 ebuild. Thanks! Cheers, Dirkjan From lukas@REDACTED Thu May 8 09:54:23 2014 From: lukas@REDACTED (Lukas Larsson) Date: Thu, 8 May 2014 09:54:23 +0200 Subject: [erlang-bugs] epmd_srv.c:(.text+0x830): undefined reference to `sd_listen_fds' In-Reply-To: References: <535F60F1.9030400@erlang.org> <535F6806.8020308@erlang.org> <5360B0BD.9010308@erlang.org> <877g65u8wu.fsf@pingviini.dy.fi> <536763BE.2090506@erlang.org> Message-ID: <536B382F.2050404@erlang.org> Great! I'll merge them into the maint branch for in Erlang/OTP 17.1 Lukas On 08/05/14 08:59, Dirkjan Ochtman wrote: > On Tue, May 6, 2014 at 10:45 AM, Dirkjan Ochtman wrote: >> I've posted an updated package on the Gentoo bug and asked for >> testing, I'll let you know when I hear back. > Looks like this works, I'll add those patches for an updated 17.0 ebuild. > > Thanks! > > Cheers, > > Dirkjan > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > From erlangsiri@REDACTED Thu May 8 10:05:55 2014 From: erlangsiri@REDACTED (Siri Hansen) Date: Thu, 8 May 2014 10:05:55 +0200 Subject: [erlang-bugs] reltool dependencies ignored In-Reply-To: <53628787.3070802@gmail.com> References: <53628787.3070802@gmail.com> Message-ID: Hi Michael! I haven't spent a lot of time on this yet, but I was just trying to find the chain of dependencies that lead to syntax_tools, but I find it a bit hard I would appreciate some help... I found one way but it didn't really make sense: reltool.config includes application 'cloudi_service_db_cassandra', and in cloudi_service_db_cassandra.app.src.in you have {applications,[...,cloudi_x_erlang_cassandra,...]} Under the directory external/cloudi_x_erlang_cassandra/src/ I then find erlang_cassandra.app.src, which indeed has {applications,[...,syntax_tools,...]} - but this is obviously an application named 'erlang_cassandra' and not 'cloudi_x_erlang_cassandra' as listed above... so how does this work? Regards /siri 2014-05-01 19:42 GMT+02:00 Michael Truog : > Hi, > > I believe I found a bug that causes reltool to ignore dependencies when > generating a release. I am not sure where the problem is within reltool, > but I at least have a way to demonstrate it. https://github.com/CloudI/ > CloudI/blob/develop/src/reltool.config.in#L78-L89 shows lines that are > unnecessary within the reltool.config file. The dependencies mentioned > there should be found automatically by reltool. If you remove those lines > and do a make install (after the autogen.sh and configure steps) you will > see the dependencies mentioned in these lines are not there. > > Thanks, > Michael > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mjtruog@REDACTED Thu May 8 10:41:28 2014 From: mjtruog@REDACTED (Michael Truog) Date: Thu, 08 May 2014 01:41:28 -0700 Subject: [erlang-bugs] reltool dependencies ignored In-Reply-To: References: <53628787.3070802@gmail.com> Message-ID: <536B4338.6040402@gmail.com> Hi Siri, I know the situation there is a bit unusual. The external CloudI dependencies are moved so that the "cloudi_x_" prefix is added to all the external Erlang application names, their modules, and their header files. The external dependency directory names already have the "cloudi_x_" prefix to satisfy include_lib usage within the modules (so that means external CloudI dependencies that depend on each other, in a way that uses a header file with -include_lib). This is all done with the script at https://github.com/okeuday/reltool_util/blob/master/scope with the command line at https://github.com/CloudI/CloudI/blob/develop/src/Makefile.am#L7-L66 (i.e., atoms are selectively changed within the source code, along with the files being moved). However, that process doesn't impact how the external CloudI dependencies work. The prefix is added to simulate a namespace concept which doesn't exist in Erlang to avoid any potential conflicts when CloudI shares the Erlang VM with other Erlang applications. That is unusual, but the reltool usage is the same either way, its just an addition of a prefix for referencing the names, as they are now. The compilation process makes sure the prefix is added, so the external dependency files do change to satisfy the compilation, testing and release requirements. While it would be natural to assume this process is at fault for the reltool issue, I am sure that is not the case. You should be able to see this if you do a "./configure && make" of the root src directory, since that will make sure the files are as expected. Thanks, Michael On 05/08/2014 01:05 AM, Siri Hansen wrote: > Hi Michael! > > I haven't spent a lot of time on this yet, but I was just trying to find the chain of dependencies that lead to syntax_tools, but I find it a bit hard I would appreciate some help... > > I found one way but it didn't really make sense: > > reltool.config includes application 'cloudi_service_db_cassandra', and in cloudi_service_db_cassandra.app.src.in you have {applications,[...,cloudi_x_erlang_cassandra,...]} > > Under the directory external/cloudi_x_erlang_cassandra/src/ I then find erlang_cassandra.app.src, which indeed has {applications,[...,syntax_tools,...]} - but this is obviously an application named 'erlang_cassandra' and not 'cloudi_x_erlang_cassandra' as listed above... so how does this work? > > Regards > /siri > > > 2014-05-01 19:42 GMT+02:00 Michael Truog >: > > Hi, > > I believe I found a bug that causes reltool to ignore dependencies when generating a release. I am not sure where the problem is within reltool, but I at least have a way to demonstrate it. https://github.com/CloudI/CloudI/blob/develop/src/reltool.config.in#L78-L89 shows lines that are unnecessary within the reltool.config file. The dependencies mentioned there should be found automatically by reltool. If you remove those lines and do a make install (after the autogen.sh and configure steps) you will see the dependencies mentioned in these lines are not there. > > Thanks, > Michael > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From erlangsiri@REDACTED Thu May 8 10:58:34 2014 From: erlangsiri@REDACTED (Siri Hansen) Date: Thu, 8 May 2014 10:58:34 +0200 Subject: [erlang-bugs] erlang module not in sticky dir? In-Reply-To: <535C023F.4040008@ninenines.eu> References: <535C023F.4040008@ninenines.eu> Message-ID: Thanks for reporting! I have written a ticket for this. Regards /siri 2014-04-26 21:00 GMT+02:00 Lo?c Hoguin : > A user got confused by pretty much this: > > % erl > Erlang/OTP 17 [erts-6.0] [source] [64-bit] [smp:4:4] [async-threads:10] > [hipe] [kernel-poll:false] > > Eshell V6.0 (abort with ^G) > 1> l(erlang). > {module,erlang} > 2> l(gen_server). > {error,sticky_directory} > 3> > =ERROR REPORT==== 26-Apr-2014::20:56:37 === > Can't load module that resides in sticky dir > > For some reasons his erlang:apply/3 ended up not being a BIF anymore and > instead called erlang:apply/3 in a loop because the file contains: > > apply(Mod, Name, Args) -> > erlang:apply(Mod, Name, Args). > > The file had been recompiled and reloaded automatically using the sync > application: https://github.com/rustyio/sync > > Details are not important. I suggest however making the preloaded Erlang > modules be sticky by default to prevent awkward behavior such as this. > > -- > Lo?c Hoguin > http://ninenines.eu > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > -------------- next part -------------- An HTML attachment was scrubbed... URL: From aronisstav@REDACTED Thu May 8 11:59:34 2014 From: aronisstav@REDACTED (Stavros Aronis) Date: Thu, 8 May 2014 11:59:34 +0200 Subject: [erlang-bugs] erlang module not in sticky dir? In-Reply-To: References: <535C023F.4040008@ninenines.eu> Message-ID: Somewhat related (posted earlier at http://erlang.org/pipermail/erlang-bugs/2014-April/004300.html ) $ erl Erlang/OTP 17 [erts-6.0] [source-07b8f44] [64-bit] [smp:8:8] [async-threads:10] [hipe] [kernel-poll:false] Eshell V6.0 (abort with ^G) 1> erlang:is_builtin(erlang,apply,3). false Regards, Stavros On Thu, May 8, 2014 at 10:58 AM, Siri Hansen wrote: > Thanks for reporting! I have written a ticket for this. > Regards > /siri > > > 2014-04-26 21:00 GMT+02:00 Lo?c Hoguin : > >> A user got confused by pretty much this: >> >> % erl >> Erlang/OTP 17 [erts-6.0] [source] [64-bit] [smp:4:4] [async-threads:10] >> [hipe] [kernel-poll:false] >> >> Eshell V6.0 (abort with ^G) >> 1> l(erlang). >> {module,erlang} >> 2> l(gen_server). >> {error,sticky_directory} >> 3> >> =ERROR REPORT==== 26-Apr-2014::20:56:37 === >> Can't load module that resides in sticky dir >> >> For some reasons his erlang:apply/3 ended up not being a BIF anymore and >> instead called erlang:apply/3 in a loop because the file contains: >> >> apply(Mod, Name, Args) -> >> erlang:apply(Mod, Name, Args). >> >> The file had been recompiled and reloaded automatically using the sync >> application: https://github.com/rustyio/sync >> >> Details are not important. I suggest however making the preloaded Erlang >> modules be sticky by default to prevent awkward behavior such as this. >> >> -- >> Lo?c Hoguin >> http://ninenines.eu >> _______________________________________________ >> erlang-bugs mailing list >> erlang-bugs@REDACTED >> http://erlang.org/mailman/listinfo/erlang-bugs >> > > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Ingela.Anderton.Andin@REDACTED Thu May 8 12:24:14 2014 From: Ingela.Anderton.Andin@REDACTED (Ingela Anderton Andin) Date: Thu, 8 May 2014 12:24:14 +0200 Subject: [erlang-bugs] PEM encoding problems with PBES2-params in public_key In-Reply-To: References: Message-ID: <536B5B4E.3020703@ericsson.com> Hi! Thank you for reporting this, it sounds like a bug. I will make at ticket for it. Regards Ingela Erlang/OTP team Ericsson AB On 05/07/2014 11:04 AM, D?niel Szoboszlay wrote: > Hi, > > I tried to export an RSA key in PEM format using PBES2 encryption (using > Erlang/OTP 17.0). The first problem I noticed is a documentation issue: > public_key states that > > cipher_info() = {"RC2-CBC | "DES-CBC" | "DES-EDE3-CBC", > > crypto:rand_bytes(8)} |'PBES2-params'} > > However the last option should be a #'PBES2-params'{} record, not an > atom in reality. This record is not documented in neither the user?s > guide nor the reference manual. > > After reading some source code I came up with the following snippet, > which almost works: > > Rand = crypto:rand_bytes(8), > Params = #'PBES2-params'{ > keyDerivationFunc = > #'PBES2-params_keyDerivationFunc'{ > algorithm = ?'id-PBKDF2', > parameters = > #'PBKDF2-params'{ > salt = {specified, Rand}, > iterationCount = 1, > keyLength = 24, > prf = > #'PBKDF2-params_prf'{ > algorithm = ?'id-hmacWithSHA1' > } > } > }, > encryptionScheme = > #'PBES2-params_encryptionScheme'{ > algorithm = ?'des-EDE3-CBC', > parameters = <<4, 8, Rand/binary>> > } > }, > Entry = public_key:pem_entry_encode('RSAPrivateKey', RSAKey, > {{"DES-EDE3-CBC", Params}, > "1234abcd"}), > public_key:pem_encode([Entry]). > > The problem is that Entry will contain the #'PBES2-params'{} record, but > pubkey_pem:encode_pem_entry/1 accepts only a salt (a binary) in that > position. > > As far as I can tell decoding PEM files with PBES2-params work as > expected, but encoding doesn?t, and this limitation is not documented. > > Regards, > Daniel > > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > From essen@REDACTED Thu May 8 14:01:09 2014 From: essen@REDACTED (=?UTF-8?B?TG/Dr2MgSG9ndWlu?=) Date: Thu, 08 May 2014 14:01:09 +0200 Subject: [erlang-bugs] erlang module not in sticky dir? In-Reply-To: References: <535C023F.4040008@ninenines.eu> Message-ID: <536B7205.4010209@ninenines.eu> There's also this which is just odd. essen@REDACTED (20) % erl Erlang/OTP 17 [erts-6.0] [source] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false] Eshell V6.0 (abort with ^G) 1> erlang:function_exported(erlang, apply, 3). true 2> erlang:function_exported(erlang, is_map, 1). false 3> erlang:function_exported(erlang, is_list, 1). false On 05/08/2014 11:59 AM, Stavros Aronis wrote: > Somewhat related (posted earlier at > http://erlang.org/pipermail/erlang-bugs/2014-April/004300.html ) > > $ erl > Erlang/OTP 17 [erts-6.0] [source-07b8f44] [64-bit] [smp:8:8] > [async-threads:10] [hipe] [kernel-poll:false] > > Eshell V6.0 (abort with ^G) > 1> erlang:is_builtin(erlang,apply,3). > false > > Regards, > > Stavros > > > On Thu, May 8, 2014 at 10:58 AM, Siri Hansen > wrote: > > Thanks for reporting! I have written a ticket for this. > Regards > /siri > > > 2014-04-26 21:00 GMT+02:00 Lo?c Hoguin >: > > A user got confused by pretty much this: > > % erl > Erlang/OTP 17 [erts-6.0] [source] [64-bit] [smp:4:4] > [async-threads:10] [hipe] [kernel-poll:false] > > Eshell V6.0 (abort with ^G) > 1> l(erlang). > {module,erlang} > 2> l(gen_server). > {error,sticky_directory} > 3> > =ERROR REPORT==== 26-Apr-2014::20:56:37 === > Can't load module that resides in sticky dir > > For some reasons his erlang:apply/3 ended up not being a BIF > anymore and instead called erlang:apply/3 in a loop because the > file contains: > > apply(Mod, Name, Args) -> > erlang:apply(Mod, Name, Args). > > The file had been recompiled and reloaded automatically using > the sync application: https://github.com/rustyio/__sync > > > Details are not important. I suggest however making the > preloaded Erlang modules be sticky by default to prevent awkward > behavior such as this. > > -- > Lo?c Hoguin > http://ninenines.eu > _________________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/__listinfo/erlang-bugs > > > > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > > -- Lo?c Hoguin http://ninenines.eu From erlangsiri@REDACTED Thu May 8 15:40:59 2014 From: erlangsiri@REDACTED (Siri Hansen) Date: Thu, 8 May 2014 15:40:59 +0200 Subject: [erlang-bugs] reltool dependencies ignored In-Reply-To: <536B4338.6040402@gmail.com> References: <53628787.3070802@gmail.com> <536B4338.6040402@gmail.com> Message-ID: ok, thanks! I will try this and continue digging :) /siri 2014-05-08 10:41 GMT+02:00 Michael Truog : > Hi Siri, > > I know the situation there is a bit unusual. The external CloudI > dependencies are moved so that the "cloudi_x_" prefix is added to all the > external Erlang application names, their modules, and their header files. > The external dependency directory names already have the "cloudi_x_" prefix > to satisfy include_lib usage within the modules (so that means external > CloudI dependencies that depend on each other, in a way that uses a header > file with -include_lib). This is all done with the script at > https://github.com/okeuday/reltool_util/blob/master/scope with the > command line at > https://github.com/CloudI/CloudI/blob/develop/src/Makefile.am#L7-L66(i.e., atoms are selectively changed within the source code, along with the > files being moved). However, that process doesn't impact how the external > CloudI dependencies work. The prefix is added to simulate a namespace > concept which doesn't exist in Erlang to avoid any potential conflicts when > CloudI shares the Erlang VM with other Erlang applications. > > That is unusual, but the reltool usage is the same either way, its just an > addition of a prefix for referencing the names, as they are now. The > compilation process makes sure the prefix is added, so the external > dependency files do change to satisfy the compilation, testing and release > requirements. While it would be natural to assume this process is at fault > for the reltool issue, I am sure that is not the case. You should be able > to see this if you do a "./configure && make" of the root src directory, > since that will make sure the files are as expected. > > Thanks, > Michael > > > On 05/08/2014 01:05 AM, Siri Hansen wrote: > > Hi Michael! > > I haven't spent a lot of time on this yet, but I was just trying to find > the chain of dependencies that lead to syntax_tools, but I find it a bit > hard I would appreciate some help... > > I found one way but it didn't really make sense: > > reltool.config includes application 'cloudi_service_db_cassandra', and > in cloudi_service_db_cassandra.app.src.in you have > {applications,[...,cloudi_x_erlang_cassandra,...]} > > Under the directory external/cloudi_x_erlang_cassandra/src/ I then > find erlang_cassandra.app.src, which indeed has > {applications,[...,syntax_tools,...]} - but this is obviously an > application named 'erlang_cassandra' and not 'cloudi_x_erlang_cassandra' as > listed above... so how does this work? > > Regards > /siri > > > 2014-05-01 19:42 GMT+02:00 Michael Truog : > >> Hi, >> >> I believe I found a bug that causes reltool to ignore dependencies when >> generating a release. I am not sure where the problem is within reltool, >> but I at least have a way to demonstrate it. >> https://github.com/CloudI/CloudI/blob/develop/src/reltool.config.in#L78-L89shows lines that are unnecessary within the reltool.config file. The >> dependencies mentioned there should be found automatically by reltool. If >> you remove those lines and do a make install (after the autogen.sh and >> configure steps) you will see the dependencies mentioned in these lines are >> not there. >> >> Thanks, >> Michael >> _______________________________________________ >> erlang-bugs mailing list >> erlang-bugs@REDACTED >> http://erlang.org/mailman/listinfo/erlang-bugs >> > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From erlangsiri@REDACTED Thu May 8 17:20:19 2014 From: erlangsiri@REDACTED (Siri Hansen) Date: Thu, 8 May 2014 17:20:19 +0200 Subject: [erlang-bugs] reltool dependencies ignored In-Reply-To: References: <53628787.3070802@gmail.com> <536B4338.6040402@gmail.com> Message-ID: Michael, it looks like reltool only follows the dependencies in the .app file (applications tag) for applications that are included in a release in the reltool config. For other applications that are mentioned in the config reltool only follows dependencies found with xref. I can not see that any of the applications that mention syntax_tools in their .app actually call any of the modules in this application from the erlang code. How is syntax_tools used? I'm not sure why reltool behaves this way, so I have to investigate a bit further to find out if it is a bug or not. Regards /siri torsdagen den 8:e maj 2014 skrev Siri Hansen : > ok, thanks! I will try this and continue digging :) > /siri > > > 2014-05-08 10:41 GMT+02:00 Michael Truog > >: > > Hi Siri, > > I know the situation there is a bit unusual. The external CloudI > dependencies are moved so that the "cloudi_x_" prefix is added to all the > external Erlang application names, their modules, and their header files. > The external dependency directory names already have the "cloudi_x_" prefix > to satisfy include_lib usage within the modules (so that means external > CloudI dependencies that depend on each other, in a way that uses a header > file with -include_lib). This is all done with the script at > https://github.com/okeuday/reltool_util/blob/master/scope with the > command line at > https://github.com/CloudI/CloudI/blob/develop/src/Makefile.am#L7-L66(i.e., atoms are selectively changed within the source code, along with the > files being moved). However, that process doesn't impact how the external > CloudI dependencies work. The prefix is added to simulate a namespace > concept which doesn't exist in Erlang to avoid any potential conflicts when > CloudI shares the Erlang VM with other Erlang applications. > > That is unusual, but the reltool usage is the same either way, its just an > addition of a prefix for referencing the names, as they are now. The > compilation process makes sure the prefix is added, so the external > dependency files do change to satisfy the compilation, testing and release > requirements. While it would be natural to assume this process is at fault > for the reltool issue, I am sure that is not the case. You should be able > to see this if you do a "./configure && make" of the root src directory, > since that will make sure the files are as expected. > > Thanks, > Michael > > > On 05/08/2014 01:05 AM, Siri Hansen wrote: > > Hi Michael! > > I haven't spent a lot of time on this yet, but I was just trying to find > the chain of dependencies that lead to syntax_tools, but I find it a bit > hard I would appreciate some help... > > I found one way but it didn't really make sense: > > reltool.config includes application 'cloudi_service_db_cassandra', and > in cloudi_service_db_cassandra.app.src.in you have > {applications,[...,cloudi_x_erlang_cassandra,...]} > > Under the directory external/cloudi_x_erlang_cassandra/src/ I then > find erlang_cassandra.app.src, which indeed has > {applications,[...,syntax_tools,...]} - but this is obviously an > application named 'erlang_cassandra' and not 'cloudi_x_erlang_cassandra' as > listed above... so how does this work? > > Regards > /siri > > > 2014-05-01 19:42 GMT+02:00 Michael Truog : > > Hi, > > I believe I found a bug that causes reltool to ignore dependencies when > generating a release. I am not sure where the problem is within reltool, > but I at least have a way to demonstrate it. > https://github.com/CloudI/CloudI/blob/develop/src/reltool.config.in#L78-L89shows lines that are unnecessary within the reltool.config file. The > dependencies mentioned there should be found automatically by reltool. If > you remove those lines and do a make install (after the autogen.sh and > configure steps) you will see the dependencies mentioned in these lines are > not there. > > Thanks, > Michael > _______________________________________________ > erlang-bugs mailing list > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mjtruog@REDACTED Thu May 8 18:18:55 2014 From: mjtruog@REDACTED (Michael Truog) Date: Thu, 08 May 2014 09:18:55 -0700 Subject: [erlang-bugs] reltool dependencies ignored In-Reply-To: References: <53628787.3070802@gmail.com> <536B4338.6040402@gmail.com> Message-ID: <536BAE6F.3080308@gmail.com> Hi Siri, Thanks for determining this. I am not sure how the dependencies are used, it is possible syntax_tools wasn't being used where it is mentioned. However, it really seems like this should be a bug simply due to the Erlang application startup. I know the release (script/boot files) generated by this particular reltool file doesn't start these applications (with the problematic dependencies), but anything else that starts the applications would do so by the dependencies mentioned. So, I don't see how this can't be a bug. If xref determined that the dependencies were not called, it could remove the application dependencies from the .app file dependencies list, but having dependencies culled should be an option that you can turn off like it can be with modules selected with reltool. I think culling the dependencies is a bit dangerous (especially by default) because it should be possible to have dependencies xref is unable to see (though I don't have a good example of this). Thanks, Michael On 05/08/2014 08:20 AM, Siri Hansen wrote: > Michael, it looks like reltool only follows the dependencies in the .app file (applications tag) for applications that are included in a release in the reltool config. For other applications that are mentioned in the config reltool only follows dependencies found with xref. I can not see that any of the applications that mention syntax_tools in their .app actually call any of the modules in this application from the erlang code. How is syntax_tools used? > > I'm not sure why reltool behaves this way, so I have to investigate a bit further to find out if it is a bug or not. > > Regards > /siri > > torsdagen den 8:e maj 2014 skrev Siri Hansen >: > > ok, thanks! I will try this and continue digging :) > /siri > > > 2014-05-08 10:41 GMT+02:00 Michael Truog >: > > Hi Siri, > > I know the situation there is a bit unusual. The external CloudI dependencies are moved so that the "cloudi_x_" prefix is added to all the external Erlang application names, their modules, and their header files. The external dependency directory names already have the "cloudi_x_" prefix to satisfy include_lib usage within the modules (so that means external CloudI dependencies that depend on each other, in a way that uses a header file with -include_lib). This is all done with the script at https://github.com/okeuday/reltool_util/blob/master/scope with the command line at https://github.com/CloudI/CloudI/blob/develop/src/Makefile.am#L7-L66 (i.e., atoms are selectively changed within the source code, along with the files being moved). However, that process doesn't impact how the external CloudI dependencies work. The prefix is added to simulate a namespace concept which doesn't exist in Erlang to avoid any potential conflicts when CloudI shares the Erlang VM > with other Erlang applications. > > That is unusual, but the reltool usage is the same either way, its just an addition of a prefix for referencing the names, as they are now. The compilation process makes sure the prefix is added, so the external dependency files do change to satisfy the compilation, testing and release requirements. While it would be natural to assume this process is at fault for the reltool issue, I am sure that is not the case. You should be able to see this if you do a "./configure && make" of the root src directory, since that will make sure the files are as expected. > > Thanks, > Michael > > > On 05/08/2014 01:05 AM, Siri Hansen wrote: >> Hi Michael! >> >> I haven't spent a lot of time on this yet, but I was just trying to find the chain of dependencies that lead to syntax_tools, but I find it a bit hard I would appreciate some help... >> >> I found one way but it didn't really make sense: >> >> reltool.config includes application 'cloudi_service_db_cassandra', and in cloudi_service_db_cassandra.app.src.in you have {applications,[...,cloudi_x_erlang_cassandra,...]} >> >> Under the directory external/cloudi_x_erlang_cassandra/src/ I then find erlang_cassandra.app.src, which indeed has {applications,[...,syntax_tools,...]} - but this is obviously an application named 'erlang_cassandra' and not 'cloudi_x_erlang_cassandra' as listed above... so how does this work? >> >> Regards >> /siri >> >> >> 2014-05-01 19:42 GMT+02:00 Michael Truog : >> >> Hi, >> >> I believe I found a bug that causes reltool to ignore dependencies when generating a release. I am not sure where the problem is within reltool, but I at least have a way to demonstrate it. https://github.com/CloudI/CloudI/blob/develop/src/reltool.config.in#L78-L89 shows lines that are unnecessary within the reltool.config file. The dependencies mentioned there should be found automatically by reltool. If you remove those lines and do a make install (after the autogen.sh and configure steps) you will see the dependencies mentioned in these lines are not there. >> >> Thanks, >> Michael >> _______________________________________________ >> erlang-bugs mailing list >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From dirkjan@REDACTED Fri May 9 08:06:10 2014 From: dirkjan@REDACTED (Dirkjan Ochtman) Date: Fri, 9 May 2014 08:06:10 +0200 Subject: [erlang-bugs] epmd_srv.c:(.text+0x830): undefined reference to `sd_listen_fds' In-Reply-To: <536B382F.2050404@erlang.org> References: <535F60F1.9030400@erlang.org> <535F6806.8020308@erlang.org> <5360B0BD.9010308@erlang.org> <877g65u8wu.fsf@pingviini.dy.fi> <536763BE.2090506@erlang.org> <536B382F.2050404@erlang.org> Message-ID: On Thu, May 8, 2014 at 9:54 AM, Lukas Larsson wrote: > Great! I'll merge them into the maint branch for in Erlang/OTP 17.1 Just FYI: today I was linked to a Gentoo bug explaining that linking to systemd should probably be done by using pkg-config, instead of manually trying to find it. See here: https://bugs.gentoo.org/show_bug.cgi?id=502522 This may be nice for some future enhancement. Cheers, Dirkjan From hans.bolinder@REDACTED Fri May 9 14:53:12 2014 From: hans.bolinder@REDACTED (Hans Bolinder) Date: Fri, 9 May 2014 12:53:12 +0000 Subject: [erlang-bugs] Dialyzer chokes on remote types in t_contains_opaque() In-Reply-To: <536A4F19.4070200@trifork.com> References: <536A4F19.4070200@trifork.com> Message-ID: <56466BD70414EA48969B4064696CF28C037DC7D4@ESESSMB207.ericsson.se> Hi, > Using Erlang 17.0, I get Dialyzer errors like the following: > {function_clause,[{erl_types,t_contains_opaque, > [{c,remote,[{remote,ssl,sslsocket,[]}],unknown}, ...} Thanks for reporting this. It seems to an old bug with a new symptom since 17.0. Best regards, Hans Bolinder, Erlang/OTP team, Ericsson A diff against 66e9c3d: diff --git a/lib/hipe/cerl/erl_types.erl b/lib/hipe/cerl/erl_types.erl index 6065b79..06c0d10 100644 --- a/lib/hipe/cerl/erl_types.erl +++ b/lib/hipe/cerl/erl_types.erl @@ -209,6 +209,7 @@ type_is_defined/4, record_field_diffs_to_string/2, subst_all_vars_to_any/1, + subst_all_remote/2, lift_list_to_pos_empty/1, is_opaque_type/2, is_erl_type/1, @@ -3161,6 +3162,18 @@ t_subst_aux(?union(List), VarMap) -> t_subst_aux(T, _VarMap) -> T. +-spec subst_all_remote(erl_type(), erl_type()) -> erl_type(). + +subst_all_remote(Type0, Substitute) -> + Map = + fun(Type) -> + case erl_types:t_is_remote(Type) of + true -> Substitute; + false -> Type + end + end, + erl_types:t_map(Map, Type0). + %%----------------------------------------------------------------------------- %% Unification %% @@ -4474,7 +4487,7 @@ get_mod_record([{FieldName, DeclType}|Left1], [{FieldName, ModType}|Left2], Acc) -> ModTypeNoVars = subst_all_vars_to_any(ModType), case - t_is_remote(ModTypeNoVars) orelse t_is_subtype(ModTypeNoVars, DeclType) + contains_remote(ModTypeNoVars) orelse t_is_subtype(ModTypeNoVars, DeclType) of false -> {error, FieldName}; true -> get_mod_record(Left1, Left2, [{FieldName, ModType}|Acc]) @@ -4488,6 +4501,10 @@ get_mod_record(DeclFields, [], Acc) -> get_mod_record(_, [{FieldName2, _ModType}|_], _Acc) -> {error, FieldName2}. +contains_remote(Type) -> + TypeNoRemote = subst_all_remote(Type, t_none()), + not t_is_equal(Type, TypeNoRemote). + fields_from_form([], _TypeNames, _RecDict, _VarDict) -> {[], []}; fields_from_form([{Name, Type}|Tail], TypeNames, RecDict, -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlsson.richard@REDACTED Fri May 9 15:23:21 2014 From: carlsson.richard@REDACTED (Richard Carlsson) Date: Fri, 09 May 2014 15:23:21 +0200 Subject: [erlang-bugs] SSL choking on concurrent clients? Message-ID: <536CD6C9.3010601@gmail.com> Friday afternoon SSL fun: we're seeing long pauses where no client is getting any replies. See attached module. At first we thought it was a problem with lhttpc, but it turned out we could repeat the symptoms by making some simple concurrent ssl connections. (In our original case, the server was on another machine, and probably not using Erlang.) /Richard -------------- next part -------------- %% NOTE: copy cert+key to current dir or modify CERTFILE and KEYFILE paths below %% %% First compile and start the server: %% erlc ssl_test.erl %% erl -sname server -s ssl_test server %% %% Then start a second shell in the same directory and run the client: %% erl -sname client -s ssl_test client_test -s init stop %% %% Look for messages like "didn't get anything for a while". Run the client %% again a few times. Sometimes it works fine, and sometimes you get lots of %% long pauses. Larger number of concurrent clients increase the probability %% of pauses. Tested on R15, R16, and 17.0. -define(CERTFILE, "cert.pem"). -define(KEYFILE, "key.pem"). -define(CLIENTS, 30). -module(ssl_test). -export([ server/0 , client_test/0 ]). server() -> ssl:start(), {ok, ListenSocket} = ssl:listen(9999, [{certfile, ?CERTFILE}, {keyfile, ?KEYFILE}, {reuseaddr, true} ]), server_loop(ListenSocket, 1). server_loop(ListenSocket, N) -> {ok, Socket} = ssl:transport_accept(ListenSocket), ok = ssl:ssl_accept(Socket), error_logger:info_msg("~w accepted\n", [N]), ssl:send(Socket, <>), ssl:close(Socket), error_logger:info_msg("~w closed\n", [N]), server_loop(ListenSocket, N + 1). client_test() -> ssl:start(), Parent = self(), Pids = [spawn(fun() -> client(Parent) end) || _ <- lists:seq(1, ?CLIENTS)], collect(Pids). collect(Pids) -> {T0, _} = statistics(wall_clock), collect(Pids, T0). collect([], Time) -> T = element(1, statistics(wall_clock)) - Time, io:format("~w Test server got all replies\n", [T]); collect(Pids, Time) -> receive {client_reply, Pid, Res} -> T = element(1, statistics(wall_clock)) - Time, io:format("~w Test server got reply from ~w: ~w\n", [T, Pid, Res]), collect(Pids -- [Pid], Time) after 1000 -> T = element(1, statistics(wall_clock)) - Time, io:format("~w Server didn't get anything for a while: ~w left\n", [T, length(Pids)]), collect(Pids, Time) end. client(Parent) -> case ssl:connect("localhost", 9999, [], infinity) of {ok, Socket} -> flush_until_closed(Socket), Parent ! {client_reply, self(), ok}; Other -> error_logger:info_msg("Client ~w failed to connect: ~w\n", [self(), Other]), flush_all(), Parent ! {client_reply, self(), error} end. flush_until_closed(Socket) -> receive {ssl_closed, Socket} = X -> error_logger:info_msg("Client ~w got: ~w\n", [self(), X]); X -> error_logger:info_msg("Client ~w got: ~w\n", [self(), X]), flush_until_closed(Socket) end. flush_all() -> receive X -> error_logger:info_msg("Client ~w got: ~w\n", [self(), X]), flush_all() after 0 -> ok end. From Ingela.Anderton.Andin@REDACTED Mon May 12 10:27:46 2014 From: Ingela.Anderton.Andin@REDACTED (Ingela Anderton Andin) Date: Mon, 12 May 2014 10:27:46 +0200 Subject: [erlang-bugs] SSL choking on concurrent clients? In-Reply-To: <536CD6C9.3010601@gmail.com> References: <536CD6C9.3010601@gmail.com> Message-ID: <53708602.7020108@ericsson.com> Hi! Thank you for the report I will investigate. Regards Ingela Erlang/OTP team - Ericsson AB On 05/09/2014 03:23 PM, Richard Carlsson wrote: > Friday afternoon SSL fun: we're seeing long pauses where no client is > getting any replies. See attached module. At first we thought it was a > problem with lhttpc, but it turned out we could repeat the symptoms by > making some simple concurrent ssl connections. (In our original case, > the server was on another machine, and probably not using Erlang.) > > /Richard > > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > From ivan.martinez@REDACTED Mon May 12 10:52:21 2014 From: ivan.martinez@REDACTED (=?UTF-8?B?SXbDoW4gTWFydMOtbmV6?=) Date: Mon, 12 May 2014 10:52:21 +0200 Subject: [erlang-bugs] "erl -name app" fails if hostname doesn't contain a dot Message-ID: Thank you Raimo, What if i'm working in a project managed by rebar and shared in a repository?. Then I have to pull, change the configuration to make it work, work with it, remember to change the hostname configuration back, and push to the repo. Quite annoying and dangerous. Greetings, Ivan Martinez Date: Fri, 25 Apr 2014 12:33:29 +0200 From: Raimo Niskanen To: Subject: Re: [erlang-bugs] "erl -name app" fails if hostname doesn't contain a dot Message-ID: <20140425103329.GA20398@REDACTED> Content-Type: text/plain; charset="iso-8859-1" On Fri, Apr 25, 2014 at 12:25:38PM +0200, Iv?n Mart?nez wrote: > Thank you Bengt. I think it should allow "localhost". Not every computer is > a server in a registered domain name, and in such situations, I don't think > having no domain name is so uncommon. I'm using a Ubuntu-based distro and > it didn't require setting a domain during installation, so I think it's > likely that many people will have the same issue. I didn't have any issue > with any other piece of software. For this situation you are supposed to use "erl -sname app" i.e explicitly use short host names. > Also, like I said, there is a misleading contradiction. If you decide that > a FQDN is required, then "erl -name app@REDACTED" should fail. > Iv?n -------------- next part -------------- An HTML attachment was scrubbed... URL: From bjorn@REDACTED Mon May 12 12:24:29 2014 From: bjorn@REDACTED (=?UTF-8?Q?Bj=C3=B6rn_Gustavsson?=) Date: Mon, 12 May 2014 12:24:29 +0200 Subject: [erlang-bugs] erlang module not in sticky dir? In-Reply-To: <535C023F.4040008@ninenines.eu> References: <535C023F.4040008@ninenines.eu> Message-ID: On Sat, Apr 26, 2014 at 9:00 PM, Lo?c Hoguin wrote: > Details are not important. I suggest however making the preloaded Erlang > modules be sticky by default to prevent awkward behavior such as this. Agreed, I except that I don't think it will should ever be allowed to unstick a pre-loaded module. We will fix this in the next maintenance release. /Bjorn -- Bj?rn Gustavsson, Erlang/OTP, Ericsson AB From bjorn@REDACTED Mon May 12 12:35:12 2014 From: bjorn@REDACTED (=?UTF-8?Q?Bj=C3=B6rn_Gustavsson?=) Date: Mon, 12 May 2014 12:35:12 +0200 Subject: [erlang-bugs] erlang module not in sticky dir? In-Reply-To: <536B7205.4010209@ninenines.eu> References: <535C023F.4040008@ninenines.eu> <536B7205.4010209@ninenines.eu> Message-ID: On Thu, May 8, 2014 at 2:01 PM, Lo?c Hoguin wrote: > There's also this which is just odd. > > essen@REDACTED (20) % erl > > Erlang/OTP 17 [erts-6.0] [source] [64-bit] [smp:4:4] [async-threads:10] > [hipe] [kernel-poll:false] > > Eshell V6.0 (abort with ^G) > 1> erlang:function_exported(erlang, apply, 3). > true > 2> erlang:function_exported(erlang, is_map, 1). > false > 3> erlang:function_exported(erlang, is_list, 1). > false > Yes, I agree. It's weird, especially since is_map/1 and is_list/1 are exported and have definitions in the erlang module. But since the documentation explicitly says that erlang:function_exported/3 does not return true for BIFs, and since it has behaved this way since ancient times, we don't want to fix it in a minor release. So we will fix it in 18.0. /Bjorn -- Bj?rn Gustavsson, Erlang/OTP, Ericsson AB From bjorn@REDACTED Mon May 12 12:41:40 2014 From: bjorn@REDACTED (=?UTF-8?Q?Bj=C3=B6rn_Gustavsson?=) Date: Mon, 12 May 2014 12:41:40 +0200 Subject: [erlang-bugs] erlang module not in sticky dir? In-Reply-To: References: <535C023F.4040008@ninenines.eu> Message-ID: On Thu, May 8, 2014 at 11:59 AM, Stavros Aronis wrote: > Somewhat related (posted earlier at > http://erlang.org/pipermail/erlang-bugs/2014-April/004300.html ) > > $ erl > Erlang/OTP 17 [erts-6.0] [source-07b8f44] [64-bit] [smp:8:8] > [async-threads:10] [hipe] [kernel-poll:false] > > Eshell V6.0 (abort with ^G) > 1> erlang:is_builtin(erlang,apply,3). > false > I am not sure what to do about this one. It is not really a BIF. It is defined in the erlang module like this: apply(Mod, Name, Args) -> erlang:apply(Mod, Name, Args). That may seem a little bit strange, but it works because the loader replaces the call to erlang:apply/3 with an instruction. Perhaps we should call it a built-in. After all, it is implemented in C, but not in the same way as (for example) is_list/1. Any suggestions? /Bjorn -- Bj?rn Gustavsson, Erlang/OTP, Ericsson AB From abstractius@REDACTED Mon May 12 13:27:39 2014 From: abstractius@REDACTED (Anastasios Tsiolakidis) Date: Mon, 12 May 2014 12:27:39 +0100 (BST) Subject: [erlang-bugs] Something up with the mangz directory? Message-ID: <1399894059.19156.YahooMailNeo@web171606.mail.ir2.yahoo.com> Hello, I seem to have compiled OTP 17 on Ubuntu 14.04 without any problems (havent ran the tests yet), but what should be a routine saving of man pages produces an avalanche of troff: fatal error: can't open `/usr/lib/erlang/man/mangz/DoesBackingStore.3.gz': No such file or directory for pretty much all the man pages. In fact the mangz directory was never created by make install, not that it made a difference when I created it manually. I thought that maybe fop was what I was missing, but now that I am making the docs it is clear fop is in full effect. Finally the docs failed too, some java error that does not concern me much, as follows: fop -c /home/z/otp_src_17.0/bootstrap/lib/erl_docgen/priv/fop.xconf -fo ../pdf/jinterface-1.5.9.fo -pdf ../pdf/jinterface-1.5.9.pdf Rendered page #1. Rendered page #2. Rendered page #3. Line 2 of a paragraph overflows the available area by more than 50 points. (See position 199:224) Rendered page #4. Rendered page #5. Rendered page #6. Rendered page #7. Rendered page #8. Rendered page #9. Rendered page #10. Rendered page #11. Rendered page #12. /usr/bin/install -c -m 644 notes.gif ../html/notes.gif /usr/bin/install -c -m 644 ref_man.gif ../html/ref_man.gif /usr/bin/install -c -m 644 user_guide.gif ../html/user_guide.gif date=`date +"%B %e, %Y"`; \ ??????? xsltproc --noout \ ????????? --stringparam outdir ../html \ ????????? --stringparam docgen "/home/z/otp_src_17.0/bootstrap/lib/erl_docgen" \ ????????? --stringparam topdocdir "../../../../doc" \ ????????? --stringparam pdfdir "../pdf" \ ????????? --xinclude? --stringparam mod2app_file "/home/z/otp_src_17.0/make/x86_64-unknown-linux-gnu/mod2app.xml" \ ????????? --stringparam gendate "$date" \ ????????? --stringparam appname "jinterface" \ ????????? --stringparam appver "1.5.9" \ ????????? --stringparam stylesheet "otp_doc.css" \ ????????? --stringparam winprefix "Erlang" \ ????????? --stringparam logo "erlang-logo.png" \ ????????? --stringparam pdfname "" \ ????????? -path /home/z/otp_src_17.0/bootstrap/lib/erl_docgen/priv/dtd \ ????????? -path /home/z/otp_src_17.0/bootstrap/lib/erl_docgen/priv/dtd_html_entities \ ??????????? /home/z/otp_src_17.0/bootstrap/lib/erl_docgen/priv/xsl/db_html.xsl book.xml (cd ../../java_src;javadoc -sourcepath . -d ../doc/html/java \ ??????????????? -windowtitle 'Java-Erlang Interface Library' com.ericsson.otp.erlang) Loading source files for package com.ericsson.otp.erlang... Constructing Javadoc information... Creating destination directory: "../doc/html/java/" Standard Doclet version 1.8.0_05 Building tree for all the packages and classes... Generating ../doc/html/java/com/ericsson/otp/erlang/AbstractConnection.html... ./com/ericsson/otp/erlang/AbstractConnection.java:213: warning: no @param for e ??? public abstract void deliver(Exception e); ???????????????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:218: warning: no @param for msg ??? public abstract void deliver(OtpMsg msg); ???????????????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:232: warning: no @param for from ??? protected void sendBuf(final OtpErlangPid from, final String dest, ?????????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:269: error: @param name not found ???? * @param msg ????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:276: warning: no @param for from ??? protected void sendBuf(final OtpErlangPid from, final OtpErlangPid dest, ?????????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:276: warning: no @param for payload ??? protected void sendBuf(final OtpErlangPid from, final OtpErlangPid dest, ?????????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:382: warning: no @param for from ??? protected void sendLink(final OtpErlangPid from, final OtpErlangPid dest) ?????????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:418: warning: no @param for from ??? protected void sendUnlink(final OtpErlangPid from, final OtpErlangPid dest) ?????????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:460: warning: no @param for from ??? protected void sendExit2(final OtpErlangPid from, final OtpErlangPid dest, ?????????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:42: warning: empty

tag ?*

?? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:181: warning: no @param for self ??? protected AbstractConnection(final OtpLocalNode self, final OtpPeer other) ????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:181: warning: no @param for other ??? protected AbstractConnection(final OtpLocalNode self, final OtpPeer other) ????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:138: warning: no @param for self ??? protected AbstractConnection(final OtpLocalNode self, final Socket s) ????????????? ^ ./com/ericsson/otp/erlang/AbstractConnection.java:138: warning: no @param for s ??? protected AbstractConnection(final OtpLocalNode self, final Socket s) ????????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/AbstractNode.html... ./com/ericsson/otp/erlang/AbstractNode.java:246: warning: no @param for cookie ??? public String setCookie(final String cookie) { ????????????????? ^ ./com/ericsson/otp/erlang/AbstractNode.java:150: warning: no @param for node ??? protected AbstractNode(final String node) { ????????????? ^ ./com/ericsson/otp/erlang/AbstractNode.java:157: warning: no @param for name ??? protected AbstractNode(final String name, final String cookie) { ????????????? ^ ./com/ericsson/otp/erlang/AbstractNode.java:157: warning: no @param for cookie ??? protected AbstractNode(final String name, final String cookie) { ????????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/GenericQueue.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpAuthException.html... ./com/ericsson/otp/erlang/OtpAuthException.java:34: warning: no @param for s ??? public OtpAuthException(final String s) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpConnection.html... ./com/ericsson/otp/erlang/OtpConnection.java:124: warning: no @return ??? public int msgCount() { ?????????????? ^ ./com/ericsson/otp/erlang/OtpConnection.java:407: error: @param name not found ???? * @param msg ????????????? ^ ./com/ericsson/otp/erlang/OtpConnection.java:414: warning: no @param for payload ??? public void sendBuf(final OtpErlangPid dest, final OtpOutputStream payload) ??????????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpCookedConnection.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpEpmd.html... ./com/ericsson/otp/erlang/OtpEpmd.java:107: warning: no @param for port ??? public static void useEpmdPort(int port) { ?????????????????????? ^ ./com/ericsson/otp/erlang/OtpEpmd.java:120: warning: no @param for node ??? public static int lookupPort(final AbstractNode node) throws IOException { ????????????????????? ^ ./com/ericsson/otp/erlang/OtpEpmd.java:158: warning: no @param for node ??? public static void unPublishPort(final OtpLocalNode node) { ?????????????????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangAtom.html... ./com/ericsson/otp/erlang/OtpErlangAtom.java:80: warning: no @param for t ??? public OtpErlangAtom(final boolean t) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangBinary.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangBitstr.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangBoolean.html... ./com/ericsson/otp/erlang/OtpErlangBoolean.java:52: warning: no @param for buf ??? public OtpErlangBoolean(final OtpInputStream buf) ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangByte.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangChar.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangDecodeException.html... ./com/ericsson/otp/erlang/OtpErlangDecodeException.java:32: warning: no @param for msg ??? public OtpErlangDecodeException(final String msg) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangDouble.html... ./com/ericsson/otp/erlang/OtpErlangDouble.java:39: warning: no @param for d ??? public OtpErlangDouble(final double d) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangException.html... ./com/ericsson/otp/erlang/OtpErlangException.java:37: warning: no @param for msg ??? public OtpErlangException(final String msg) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangExit.html... ./com/ericsson/otp/erlang/OtpErlangExit.java:102: warning: no @return ??? public OtpErlangObject reason() { ?????????????????????????? ^ ./com/ericsson/otp/erlang/OtpErlangExit.java:109: warning: no @return ??? public OtpErlangPid pid() { ??????????????????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangExternalFun.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangFloat.html... ./com/ericsson/otp/erlang/OtpErlangFloat.java:34: warning: no @param for f ??? public OtpErlangFloat(final float f) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangFun.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangInt.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangList.html... ./com/ericsson/otp/erlang/OtpErlangList.java:95: warning: no description for @param ???? * @param lastTail ?????? ^ ./com/ericsson/otp/erlang/OtpErlangList.java:96: warning: no description for @throws ???? * @throws OtpErlangException ?????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangList.SubList.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangLong.html... ./com/ericsson/otp/erlang/OtpErlangLong.java:54: error: @param name not found ???? * @param val ????????????? ^ ./com/ericsson/otp/erlang/OtpErlangLong.java:57: warning: no @param for v ??? public OtpErlangLong(final BigInteger v) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangMap.html... ./com/ericsson/otp/erlang/OtpErlangMap.java:61: error: @param name not found ???? * @param elems ????????????? ^ ./com/ericsson/otp/erlang/OtpErlangMap.java:63: error: @param name not found ???? * @param start ????????????? ^ ./com/ericsson/otp/erlang/OtpErlangMap.java:71: warning: no @param for keys ??? public OtpErlangMap(final OtpErlangObject[] keys, final int kstart, ?????????? ^ ./com/ericsson/otp/erlang/OtpErlangMap.java:71: warning: no @param for kstart ??? public OtpErlangMap(final OtpErlangObject[] keys, final int kstart, ?????????? ^ ./com/ericsson/otp/erlang/OtpErlangMap.java:71: warning: no @param for kcount ??? public OtpErlangMap(final OtpErlangObject[] keys, final int kstart, ?????????? ^ ./com/ericsson/otp/erlang/OtpErlangMap.java:71: warning: no @param for values ??? public OtpErlangMap(final OtpErlangObject[] keys, final int kstart, ?????????? ^ ./com/ericsson/otp/erlang/OtpErlangMap.java:71: warning: no @param for vstart ??? public OtpErlangMap(final OtpErlangObject[] keys, final int kstart, ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangObject.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangObject.Hash.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangPid.html... ./com/ericsson/otp/erlang/OtpErlangPid.java:165: error: @param name not found ???? * @param port ????????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangPort.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangRangeException.html... ./com/ericsson/otp/erlang/OtpErlangRangeException.java:39: warning: no @param for msg ??? public OtpErlangRangeException(final String msg) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangRef.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangShort.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangString.html... ./com/ericsson/otp/erlang/OtpErlangString.java:193: warning: no @param for bytes ??? public static String newString(final byte[] bytes) { ???????????????????????? ^ ./com/ericsson/otp/erlang/OtpErlangString.java:193: warning: no @return ??? public static String newString(final byte[] bytes) { ???????????????????????? ^ ./com/ericsson/otp/erlang/OtpErlangString.java:45: error: invalid use of @return ???? * @return an Erlang string with Unicode code units. ?????? ^ ./com/ericsson/otp/erlang/OtpErlangString.java:53: warning: no @param for list ??? public OtpErlangString(final OtpErlangList list) ?????????? ^ ./com/ericsson/otp/erlang/OtpErlangString.java:38: warning: no @param for str ??? public OtpErlangString(final String str) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangTuple.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangUInt.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpErlangUShort.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpException.html... ./com/ericsson/otp/erlang/OtpException.java:35: warning: no @param for msg ??? public OtpException(final String msg) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpExternal.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpInputStream.html... ./com/ericsson/otp/erlang/OtpInputStream.java:110: warning: no @param for buf ??? public int readN(final byte[] buf) throws OtpErlangDecodeException { ?????????????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:123: warning: no @param for buf ??? public int readN(final byte[] buf, final int off, final int len) ?????????????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:123: warning: no @param for off ??? public int readN(final byte[] buf, final int off, final int len) ?????????????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:123: warning: no @param for len ??? public int readN(final byte[] buf, final int off, final int len) ?????????????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:138: warning: no @return ??? public int peek() throws OtpErlangDecodeException { ?????????????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:138: warning: no @throws for com.ericsson.otp.erlang.OtpErlangDecodeException ??? public int peek() throws OtpErlangDecodeException { ?????????????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:39: warning: no description for @param ???? * @param buf ?????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:48: warning: no description for @param ???? * @param flags ?????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:50: warning: no @param for buf ??? public OtpInputStream(final byte[] buf, final int flags) { ?????????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:59: warning: no description for @param ???? * @param flags ?????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:61: warning: no @param for buf ??? public OtpInputStream(final byte[] buf, final int offset, final int length, ?????????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:61: warning: no @param for offset ??? public OtpInputStream(final byte[] buf, final int offset, final int length, ?????????? ^ ./com/ericsson/otp/erlang/OtpInputStream.java:61: warning: no @param for length ??? public OtpInputStream(final byte[] buf, final int offset, final int length, ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpLocalNode.html... ./com/ericsson/otp/erlang/OtpLocalNode.java:42: warning: no @param for node ??? protected OtpLocalNode(final String node) { ????????????? ^ ./com/ericsson/otp/erlang/OtpLocalNode.java:50: warning: no @param for node ??? protected OtpLocalNode(final String node, final String cookie) { ????????????? ^ ./com/ericsson/otp/erlang/OtpLocalNode.java:50: warning: no @param for cookie ??? protected OtpLocalNode(final String node, final String cookie) { ????????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpMbox.html... ./com/ericsson/otp/erlang/OtpMbox.java:423: error: unexpected end tag:

???? *

?????? ^ ./com/ericsson/otp/erlang/OtpMbox.java:427: warning: no @param for reason ??? public void exit(final String reason) { ??????????????? ^ ./com/ericsson/otp/erlang/OtpMbox.java:458: warning: no @param for to ??? public void exit(final OtpErlangPid to, final String reason) { ??????????????? ^ ./com/ericsson/otp/erlang/OtpMbox.java:458: warning: no @param for reason ??? public void exit(final OtpErlangPid to, final String reason) { ??????????????? ^ ./com/ericsson/otp/erlang/OtpMbox.java:598: warning: no @return ??? public boolean ping(final String node, final long timeout) { ?????????????????? ^ ./com/ericsson/otp/erlang/OtpMbox.java:632: warning: no @param for name ??? public OtpErlangPid whereis(final String name) { ??????????????????????? ^ ./com/ericsson/otp/erlang/OtpMbox.java:76: error: unexpected end tag:

?*

?? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpMsg.html... ./com/ericsson/otp/erlang/OtpMsg.java:187: warning: no @return ??? public int type() { ?????????????? ^ ./com/ericsson/otp/erlang/OtpMsg.java:33: error: unknown tag: lu ?* The header information that is available is as follows: ?????????????????????????????????????????????????????????? ^ ./com/ericsson/otp/erlang/OtpMsg.java:34: error: tag not allowed here:
  • ?*
  • a tag indicating the type of message ?? ^ ./com/ericsson/otp/erlang/OtpMsg.java:35: error: tag not allowed here:
  • ?*
  • the intended recipient of the message, either as a ?? ^ ./com/ericsson/otp/erlang/OtpMsg.java:37: error: tag not allowed here:
  • ?*
  • (sometimes) the sender of the message. Due to some eccentric ?? ^ ./com/ericsson/otp/erlang/OtpMsg.java:40: error: unknown tag: lu ?* is {@link OtpMsg#regSendTag regSendTag} contain sender information. ?????????????????????????????????????????????????????????????????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpNode.html... ./com/ericsson/otp/erlang/OtpNode.java:304: warning: no @param for name ??? public OtpErlangPid whereis(final String name) { ??????????????????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpNode.Acceptor.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpNode.Mailboxes.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpNodeStatus.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpOutputStream.html... ./com/ericsson/otp/erlang/OtpOutputStream.java:205: error: @param name not found ???? * @param buf ????????????? ^ ./com/ericsson/otp/erlang/OtpOutputStream.java:209: warning: no @param for bytes ??? public void writeN(final byte[] bytes) { ??????????????? ^ ./com/ericsson/otp/erlang/OtpOutputStream.java:640: error: @param name not found ???? * @param s ????????????? ^ ./com/ericsson/otp/erlang/OtpOutputStream.java:643: warning: no @param for us ??? public void write_ushort(final short us) { ??????????????? ^ ./com/ericsson/otp/erlang/OtpOutputStream.java:64: warning: no @param for size ??? public OtpOutputStream(final int size) { ?????????? ^ ./com/ericsson/otp/erlang/OtpOutputStream.java:71: warning: no @param for o ??? public OtpOutputStream(final OtpErlangObject o) { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpPeer.html... Generating ../doc/html/java/com/ericsson/otp/erlang/OtpSelf.html... ./com/ericsson/otp/erlang/OtpSelf.java:71: warning: no @throws for java.io.IOException ??? public OtpSelf(final String node) throws IOException { ?????????? ^ ./com/ericsson/otp/erlang/OtpSelf.java:85: warning: no @throws for java.io.IOException ??? public OtpSelf(final String node, final String cookie) throws IOException { ?????????? ^ Generating ../doc/html/java/com/ericsson/otp/erlang/OtpServer.html... Generating ../doc/html/java/com/ericsson/otp/erlang/package-frame.html... Generating ../doc/html/java/com/ericsson/otp/erlang/package-summary.html... Generating ../doc/html/java/com/ericsson/otp/erlang/package-tree.html... Generating ../doc/html/java/constant-values.html... Generating ../doc/html/java/serialized-form.html... Building index for all the packages and classes... Generating ../doc/html/java/overview-tree.html... Generating ../doc/html/java/index-all.html... Generating ../doc/html/java/deprecated-list.html... Building index for all classes... Generating ../doc/html/java/allclasses-frame.html... Generating ../doc/html/java/allclasses-noframe.html... Generating ../doc/html/java/index.html... Generating ../doc/html/java/help-doc.html... 16 errors 74 warnings make[5]: *** [jdoc] Error 1 -------------- next part -------------- An HTML attachment was scrubbed... URL: From n.oxyde@REDACTED Mon May 12 14:53:44 2014 From: n.oxyde@REDACTED (Anthony Ramine) Date: Mon, 12 May 2014 14:53:44 +0200 Subject: [erlang-bugs] erlang module not in sticky dir? In-Reply-To: References: <535C023F.4040008@ninenines.eu> Message-ID: Hello Bj?rn, I don?t like things being exported and being builtin not being advertised as such. In the same vein, the pseudo-module erts_debug gets on my nerve too. I understand it?s an internal thing, but I don?t like lies. Regards, -- Anthony Ramine Le 12 mai 2014 ? 12:41, Bj?rn Gustavsson a ?crit : > On Thu, May 8, 2014 at 11:59 AM, Stavros Aronis wrote: >> Somewhat related (posted earlier at >> http://erlang.org/pipermail/erlang-bugs/2014-April/004300.html ) >> >> $ erl >> Erlang/OTP 17 [erts-6.0] [source-07b8f44] [64-bit] [smp:8:8] >> [async-threads:10] [hipe] [kernel-poll:false] >> >> Eshell V6.0 (abort with ^G) >> 1> erlang:is_builtin(erlang,apply,3). >> false >> > > I am not sure what to do about this one. > It is not really a BIF. It is defined in the > erlang module like this: > > apply(Mod, Name, Args) -> > erlang:apply(Mod, Name, Args). > > That may seem a little bit strange, but it > works because the loader replaces the call > to erlang:apply/3 with an instruction. > > Perhaps we should call it a built-in. After > all, it is implemented in C, but not in the same > way as (for example) is_list/1. > > Any suggestions? > > /Bjorn > > -- > Bj?rn Gustavsson, Erlang/OTP, Ericsson AB > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs From Ingela.Anderton.Andin@REDACTED Mon May 12 17:02:56 2014 From: Ingela.Anderton.Andin@REDACTED (Ingela Anderton Andin) Date: Mon, 12 May 2014 17:02:56 +0200 Subject: [erlang-bugs] SSL choking on concurrent clients? In-Reply-To: <536CD6C9.3010601@gmail.com> References: <536CD6C9.3010601@gmail.com> Message-ID: <5370E2A0.3010804@ericsson.com> Hi! I changed your server loop to: server_loop(ListenSocket, N) -> {ok, Socket} = ssl:transport_accept(ListenSocket), spawn(fun() -> ok = ssl:ssl_accept(Socket), ssl:send(Socket, <>), ssl:close(Socket) end), error_logger:info_msg("~w accepted\n", [N]), server_loop(ListenSocket, N + 1). This will improve the situation. But increasing the number of concurrent clients can still cause a connectivity problem. When the server gets resource problems and sockets will be terminated already on tcp level. However so far I have not been able to find a bug only a load regulation problem. Regards Ingela Erlang/OTP team - Ericsson AB On 05/09/2014 03:23 PM, Richard Carlsson wrote: > Friday afternoon SSL fun: we're seeing long pauses where no client is > getting any replies. See attached module. At first we thought it was a > problem with lhttpc, but it turned out we could repeat the symptoms by > making some simple concurrent ssl connections. (In our original case, > the server was on another machine, and probably not using Erlang.) > > /Richard > > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > From tobias.lindahl@REDACTED Tue May 13 14:46:12 2014 From: tobias.lindahl@REDACTED (Tobias Lindahl) Date: Tue, 13 May 2014 14:46:12 +0200 Subject: [erlang-bugs] SSL choking on concurrent clients? In-Reply-To: <5370E2A0.3010804@ericsson.com> References: <536CD6C9.3010601@gmail.com> <5370E2A0.3010804@ericsson.com> Message-ID: 2014-05-12 17:02 GMT+02:00 Ingela Anderton Andin < Ingela.Anderton.Andin@REDACTED>: > Hi! > > I changed your server loop to: > > server_loop(ListenSocket, N) -> > {ok, Socket} = ssl:transport_accept(ListenSocket), > spawn(fun() -> > ok = ssl:ssl_accept(Socket), > ssl:send(Socket, <>), > ssl:close(Socket) > end), > error_logger:info_msg("~w accepted\n", [N]), > server_loop(ListenSocket, N + 1). > > This will improve the situation. But increasing the number of concurrent > clients can still cause a connectivity problem. When the > server gets resource problems and sockets will be terminated already on > tcp level. However so far I have not been able to find a bug only a load > regulation problem. Typically what happens is that some clients will not get a connection on the ssl:connect("localhost", 9999, [], infinity) but instead an {error, closed}. And it with that a pretty long delay for the remaining connections. > > > Regards Ingela Erlang/OTP team - Ericsson AB > > > On 05/09/2014 03:23 PM, Richard Carlsson wrote: > >> Friday afternoon SSL fun: we're seeing long pauses where no client is >> getting any replies. See attached module. At first we thought it was a >> problem with lhttpc, but it turned out we could repeat the symptoms by >> making some simple concurrent ssl connections. (In our original case, >> the server was on another machine, and probably not using Erlang.) >> >> /Richard >> >> >> _______________________________________________ >> erlang-bugs mailing list >> erlang-bugs@REDACTED >> http://erlang.org/mailman/listinfo/erlang-bugs >> >> > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > -------------- next part -------------- An HTML attachment was scrubbed... URL: From vladdu55@REDACTED Mon May 19 09:58:52 2014 From: vladdu55@REDACTED (Vlad Dumitrescu) Date: Mon, 19 May 2014 09:58:52 +0200 Subject: [erlang-bugs] corba_request.erl is removed? Message-ID: Hi, I noticed that orber/src/corba_request.erl has syntax errors and it also isn't included in the release at least since R14. Shouldn't it be removed altogether? regards, Vlad -------------- next part -------------- An HTML attachment was scrubbed... URL: From vladdu55@REDACTED Mon May 19 11:54:40 2014 From: vladdu55@REDACTED (Vlad Dumitrescu) Date: Mon, 19 May 2014 11:54:40 +0200 Subject: [erlang-bugs] Malformed macros in orber_iiop.hrl Message-ID: A couple of macros were malformed, missing commas: PROFILEBODY_1_1_TYPEDEF and PROFILEBODY_1_2_TYPEDEF > git fetch git://github.com/vladdu/otp.git orber_macro_fixes > > https://github.com/vladdu/otp/compare/erlang:maint...orber_macro_fixes https://github.com/vladdu/otp/compare/erlang:maint...orber_macro_fixes.patch regards, Vlad -------------- next part -------------- An HTML attachment was scrubbed... URL: From vladdu55@REDACTED Mon May 19 13:56:48 2014 From: vladdu55@REDACTED (Vlad Dumitrescu) Date: Mon, 19 May 2014 13:56:48 +0200 Subject: [erlang-bugs] jinterface: fix bug in equality for OtpErlangFun Message-ID: Arrays (here: md5 and freeVars) must not be compared with equals, which is broken (compares identity). > git fetch git://github.com/vladdu/otp.git jinterface_fun_equals > > https://github.com/vladdu/otp/compare/erlang:maint...jinterface_fun_equals > https://github.com/vladdu/otp/compare/erlang > :maint...jinterface_fun_equals.patch regards, Vlad -------------- next part -------------- An HTML attachment was scrubbed... URL: From z@REDACTED Tue May 20 13:44:33 2014 From: z@REDACTED (Danil Zagoskin) Date: Tue, 20 May 2014 15:44:33 +0400 Subject: [erlang-bugs] repl previous command result incompatible with maps manipulation Message-ID: Hello! Currently it's impossible to use v(N) result as map: Erlang/OTP 17 [DEVELOPMENT] [erts-6.1] [source-a3c5de1] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false] Eshell V6.1 (abort with ^G) 1> #{a => 1}. #{a => 1} 2> (v(1)). #{a => 1} 3> (v(1))#{a := 2}. ** exception error: undefined shell command v/1 -- Danil Zagoskin | z@REDACTED -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlsson.richard@REDACTED Tue May 20 14:50:56 2014 From: carlsson.richard@REDACTED (Richard Carlsson) Date: Tue, 20 May 2014 14:50:56 +0200 Subject: [erlang-bugs] io_lib format infinite loop Message-ID: Here's a fun one: 1> io:format("~3.3w",[3.14]). ***ok 2> io:format("~2.3w",[3.14]). BREAK: (a)bort (c)ontinue (p)roc info (i)nfo (l)oaded (v)ersion (k)ill (D)b-tables (d)istribution ^C And this would be bad to run on a production machine: 1> error_logger:format("~3.3w",[3.14]). ok =ERROR REPORT==== 20-May-2014::14:38:25 === *** 2> error_logger:format("~2.3w",[3.14]). ok 3> (since the formatting is performed by the receiving io server process, the shell remains useful in this case, but the logger becomes locked in an infinite loop consuming all available memory). /Richard -------------- next part -------------- An HTML attachment was scrubbed... URL: From n.oxyde@REDACTED Tue May 20 16:23:29 2014 From: n.oxyde@REDACTED (Anthony Ramine) Date: Tue, 20 May 2014 16:23:29 +0200 Subject: [erlang-bugs] io_lib format infinite loop In-Reply-To: References: Message-ID: Bug is in io_lib_format:term/5 when {4,2,3} = {lists:flatlength(T),F,P0}. -- Anthony Ramine Le 20 mai 2014 ? 14:50, Richard Carlsson a ?crit : > Here's a fun one: > > 1> io:format("~3.3w",[3.14]). > ***ok > 2> io:format("~2.3w",[3.14]). > > BREAK: (a)bort (c)ontinue (p)roc info (i)nfo (l)oaded > (v)ersion (k)ill (D)b-tables (d)istribution > ^C > > And this would be bad to run on a production machine: > > 1> error_logger:format("~3.3w",[3.14]). > ok > =ERROR REPORT==== 20-May-2014::14:38:25 === > *** > 2> error_logger:format("~2.3w",[3.14]). > ok > 3> > > (since the formatting is performed by the receiving io server process, the shell remains useful in this case, but the logger becomes locked in an infinite loop consuming all available memory). > > /Richard > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs From n.oxyde@REDACTED Tue May 20 16:32:10 2014 From: n.oxyde@REDACTED (Anthony Ramine) Date: Tue, 20 May 2014 16:32:10 +0200 Subject: [erlang-bugs] io_lib format infinite loop In-Reply-To: References: Message-ID: <51327D10-827E-490D-B43B-FD2E4758C174@gmail.com> Found a fix, will submit it later with a test. -- Anthony Ramine Le 20 mai 2014 ? 16:23, Anthony Ramine a ?crit : > Bug is in io_lib_format:term/5 when {4,2,3} = {lists:flatlength(T),F,P0}. > > -- > Anthony Ramine > > Le 20 mai 2014 ? 14:50, Richard Carlsson a ?crit : > >> Here's a fun one: >> >> 1> io:format("~3.3w",[3.14]). >> ***ok >> 2> io:format("~2.3w",[3.14]). >> >> BREAK: (a)bort (c)ontinue (p)roc info (i)nfo (l)oaded >> (v)ersion (k)ill (D)b-tables (d)istribution >> ^C >> >> And this would be bad to run on a production machine: >> >> 1> error_logger:format("~3.3w",[3.14]). >> ok >> =ERROR REPORT==== 20-May-2014::14:38:25 === >> *** >> 2> error_logger:format("~2.3w",[3.14]). >> ok >> 3> >> >> (since the formatting is performed by the receiving io server process, the shell remains useful in this case, but the logger becomes locked in an infinite loop consuming all available memory). >> >> /Richard >> >> _______________________________________________ >> erlang-bugs mailing list >> erlang-bugs@REDACTED >> http://erlang.org/mailman/listinfo/erlang-bugs > From n.oxyde@REDACTED Tue May 20 22:06:12 2014 From: n.oxyde@REDACTED (Anthony Ramine) Date: Tue, 20 May 2014 22:06:12 +0200 Subject: [erlang-bugs] io_lib format infinite loop In-Reply-To: <51327D10-827E-490D-B43B-FD2E4758C174@gmail.com> References: <51327D10-827E-490D-B43B-FD2E4758C174@gmail.com> Message-ID: Hello, Here is the fix: https://github.com/erlang/otp/pull/376 I also fixed another related bug while I was at it: 1> io_lib_format:fwrite("~2.5w", [3.14]). ** exception error: no true branch found when evaluating an if expression in function io_lib_format:term/5 (io_lib_format.erl, line 259) in call from io_lib_format:build/3 (io_lib_format.erl, line 150) Regards, -- Anthony Ramine Le 20 mai 2014 ? 16:32, Anthony Ramine a ?crit : > Found a fix, will submit it later with a test. > > -- > Anthony Ramine > > Le 20 mai 2014 ? 16:23, Anthony Ramine a ?crit : > >> Bug is in io_lib_format:term/5 when {4,2,3} = {lists:flatlength(T),F,P0}. >> >> -- >> Anthony Ramine >> >> Le 20 mai 2014 ? 14:50, Richard Carlsson a ?crit : >> >>> Here's a fun one: >>> >>> 1> io:format("~3.3w",[3.14]). >>> ***ok >>> 2> io:format("~2.3w",[3.14]). >>> >>> BREAK: (a)bort (c)ontinue (p)roc info (i)nfo (l)oaded >>> (v)ersion (k)ill (D)b-tables (d)istribution >>> ^C >>> >>> And this would be bad to run on a production machine: >>> >>> 1> error_logger:format("~3.3w",[3.14]). >>> ok >>> =ERROR REPORT==== 20-May-2014::14:38:25 === >>> *** >>> 2> error_logger:format("~2.3w",[3.14]). >>> ok >>> 3> >>> >>> (since the formatting is performed by the receiving io server process, the shell remains useful in this case, but the logger becomes locked in an infinite loop consuming all available memory). >>> >>> /Richard >>> >>> _______________________________________________ >>> erlang-bugs mailing list >>> erlang-bugs@REDACTED >>> http://erlang.org/mailman/listinfo/erlang-bugs >> > From carlsson.richard@REDACTED Wed May 21 13:13:15 2014 From: carlsson.richard@REDACTED (Richard Carlsson) Date: Wed, 21 May 2014 13:13:15 +0200 Subject: [erlang-bugs] Latin-1 source code compatibility bug Message-ID: The attached file (originally an extract from Mochiweb) triggers the following problem: erlc bar.erl /home/richardc/bar.erl:7: cannot parse file, giving up /Richard -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: bar.erl Type: application/octet-stream Size: 120 bytes Desc: not available URL: From shayan@REDACTED Wed May 21 15:33:10 2014 From: shayan@REDACTED (Shayan Pooya) Date: Wed, 21 May 2014 09:33:10 -0400 Subject: [erlang-bugs] Dialyzer fails to detect unused variables in R16B03 Message-ID: Hello, In this piece of code, dialyzer fails to detect unused variable RState: https://github.com/pooya/disco/blob/dialyzer_bug/master/src/disco_worker.erl#L235 (The code should be changed to use _ instead of RState, but I left it like this to report this issue). Erlang versions prior to R16B03 seem to correctly detect and report this issue: https://travis-ci.org/pooya/disco/builds/25693989 Therefore, this seem to be an issue in dialyzer which is also present in Erlang 17.0 -------------- next part -------------- An HTML attachment was scrubbed... URL: From kostis@REDACTED Wed May 21 16:35:29 2014 From: kostis@REDACTED (Kostis Sagonas) Date: Wed, 21 May 2014 16:35:29 +0200 Subject: [erlang-bugs] Dialyzer fails to detect unused variables in R16B03 In-Reply-To: References: Message-ID: <537CB9B1.9000102@cs.ntua.gr> On 05/21/2014 03:33 PM, Shayan Pooya wrote: > Hello, > > In this piece of code, dialyzer fails to detect unused variable RState: > https://github.com/pooya/disco/blob/dialyzer_bug/master/src/disco_worker.erl#L235 > > (The code should be changed to use _ instead of RState, but I left it > like this to report this issue). > > Erlang versions prior to R16B03 seem to correctly detect and report this > issue: > https://travis-ci.org/pooya/disco/builds/25693989 > > Therefore, this seem to be an issue in dialyzer which is also present in > Erlang 17.0 This is bit of a strange report since dialyzer does not really detect unused variables (and never has). It's the Erlang compiler/linter that does this. Kostis From jan_kowalski6669@REDACTED Wed May 21 16:34:15 2014 From: jan_kowalski6669@REDACTED (jan_kowalski6669) Date: Wed, 21 May 2014 16:34:15 +0200 Subject: [erlang-bugs] xmerl xsd validation error Message-ID: <47355108-fed3e62cb3334b5421e72241f8b28288@pmq3v.m5r2.onet> This validates ok: ??? ??? ??? ??? ??? ??? ??? ??? ??? ??? ??? ??? ??? ??? ??? But this not: ??? ??? ??? ??? ??? ??? ??? ??? ??? ??? Those xsd's are equal, but not for xmerl. -------------- next part -------------- An HTML attachment was scrubbed... URL: From shayan@REDACTED Wed May 21 17:25:08 2014 From: shayan@REDACTED (Shayan Pooya) Date: Wed, 21 May 2014 11:25:08 -0400 Subject: [erlang-bugs] Dialyzer fails to detect unused variables in R16B03 In-Reply-To: <537CB9B1.9000102@cs.ntua.gr> References: <537CB9B1.9000102@cs.ntua.gr> Message-ID: That is right. Here is a minimal code that emits a warning in R15B03 but not in later versions: -module(warning_test). -export([start/0]). start() -> try case recv() of {hello, W} -> io:format("hello"); _ -> ok end catch K:V -> io:format("issue: ~p ~p", [K, V]) end. recv() -> {hello, world}. On Wed, May 21, 2014 at 10:35 AM, Kostis Sagonas wrote: > On 05/21/2014 03:33 PM, Shayan Pooya wrote: > >> Hello, >> >> In this piece of code, dialyzer fails to detect unused variable RState: >> https://github.com/pooya/disco/blob/dialyzer_bug/ >> master/src/disco_worker.erl#L235 >> >> (The code should be changed to use _ instead of RState, but I left it >> like this to report this issue). >> >> Erlang versions prior to R16B03 seem to correctly detect and report this >> issue: >> https://travis-ci.org/pooya/disco/builds/25693989 >> >> Therefore, this seem to be an issue in dialyzer which is also present in >> Erlang 17.0 >> > > This is bit of a strange report since dialyzer does not really detect > unused variables (and never has). It's the Erlang compiler/linter that > does this. > > Kostis > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > -------------- next part -------------- An HTML attachment was scrubbed... URL: From n.oxyde@REDACTED Wed May 21 22:33:31 2014 From: n.oxyde@REDACTED (Anthony Ramine) Date: Wed, 21 May 2014 22:33:31 +0200 Subject: [erlang-bugs] Dialyzer fails to detect unused variables in R16B03 In-Reply-To: References: <537CB9B1.9000102@cs.ntua.gr> Message-ID: <98F4F1D7-143D-46ED-B9E5-EE6FC7DA6FE5@gmail.com> I?m currently recompiling Erlang on https://github.com/erlang/otp/pull/296 because I suspect it fixes that bug too. Will confirm later. -- Anthony Ramine Le 21 mai 2014 ? 17:25, Shayan Pooya a ?crit : > That is right. Here is a minimal code that emits a warning in R15B03 but not in later versions: > > -module(warning_test). > -export([start/0]). > > start() -> > try case recv() of > {hello, W} -> io:format("hello"); > _ -> ok > end > catch K:V -> > io:format("issue: ~p ~p", [K, V]) > end. > > recv() -> > {hello, world}. > > > > On Wed, May 21, 2014 at 10:35 AM, Kostis Sagonas wrote: > On 05/21/2014 03:33 PM, Shayan Pooya wrote: > Hello, > > In this piece of code, dialyzer fails to detect unused variable RState: > https://github.com/pooya/disco/blob/dialyzer_bug/master/src/disco_worker.erl#L235 > > (The code should be changed to use _ instead of RState, but I left it > like this to report this issue). > > Erlang versions prior to R16B03 seem to correctly detect and report this > issue: > https://travis-ci.org/pooya/disco/builds/25693989 > > Therefore, this seem to be an issue in dialyzer which is also present in > Erlang 17.0 > > This is bit of a strange report since dialyzer does not really detect unused variables (and never has). It's the Erlang compiler/linter that does this. > > Kostis > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs > > _______________________________________________ > erlang-bugs mailing list > erlang-bugs@REDACTED > http://erlang.org/mailman/listinfo/erlang-bugs From n.oxyde@REDACTED Wed May 21 22:38:26 2014 From: n.oxyde@REDACTED (Anthony Ramine) Date: Wed, 21 May 2014 22:38:26 +0200 Subject: [erlang-bugs] Dialyzer fails to detect unused variables in R16B03 In-Reply-To: <98F4F1D7-143D-46ED-B9E5-EE6FC7DA6FE5@gmail.com> References: <537CB9B1.9000102@cs.ntua.gr> <98F4F1D7-143D-46ED-B9E5-EE6FC7DA6FE5@gmail.com> Message-ID: <411C74D5-210B-4272-BB90-45F114AC486C@gmail.com> $ bin/erlc warning_test.erl warning_test.erl:6: Warning: variable 'W' is unused -- Anthony Ramine Le 21 mai 2014 ? 22:33, Anthony Ramine a ?crit : > I?m currently recompiling Erlang on https://github.com/erlang/otp/pull/296 because I suspect it fixes that bug too. > > Will confirm later. > > -- > Anthony Ramine > > Le 21 mai 2014 ? 17:25, Shayan Pooya a ?crit : > >> That is right. Here is a minimal code that emits a warning in R15B03 but not in later versions: >> >> -module(warning_test). >> -export([start/0]). >> >> start() -> >> try case recv() of >> {hello, W} -> io:format("hello"); >> _ -> ok >> end >> catch K:V -> >> io:format("issue: ~p ~p", [K, V]) >> end. >> >> recv() -> >> {hello, world}. >> >> >> >> On Wed, May 21, 2014 at 10:35 AM, Kostis Sagonas wrote: >> On 05/21/2014 03:33 PM, Shayan Pooya wrote: >> Hello, >> >> In this piece of code, dialyzer fails to detect unused variable RState: >> https://github.com/pooya/disco/blob/dialyzer_bug/master/src/disco_worker.erl#L235 >> >> (The code should be changed to use _ instead of RState, but I left it >> like this to report this issue). >> >> Erlang versions prior to R16B03 seem to correctly detect and report this >> issue: >> https://travis-ci.org/pooya/disco/builds/25693989 >> >> Therefore, this seem to be an issue in dialyzer which is also present in >> Erlang 17.0 >> >> This is bit of a strange report since dialyzer does not really detect unused variables (and never has). It's the Erlang compiler/linter that does this. >> >> Kostis >> _______________________________________________ >> erlang-bugs mailing list >> erlang-bugs@REDACTED >> http://erlang.org/mailman/listinfo/erlang-bugs >> >> _______________________________________________ >> erlang-bugs mailing list >> erlang-bugs@REDACTED >> http://erlang.org/mailman/listinfo/erlang-bugs > From tony@REDACTED Mon May 26 01:43:11 2014 From: tony@REDACTED (Tony Rogvall) Date: Mon, 26 May 2014 01:43:11 +0200 Subject: [erlang-bugs] nif reload Message-ID: <2C042F7F-135A-4816-9F61-D59F3C57FF57@rogvall.se> Hi! I have something strange niff stuff going on, I think. (tested R17/R16) I have a very simple demo nif application (attached), one function (not really needed) and a nif that I want to be able to load/upgrade/unload. I have removed the reload callback, that according to documentation is deprecated. Following sequence can be seen, when I repeat the > l(niffy). from the erlang shell. Eshell V6.1 (abort with ^G) 1> niffy:hello(). Loading: ./niffy/priv/niffy_drv c_src/niffy_nif.c:61: niffy_load: *priv_data=0x0 ptr=0x1e1820e8, ptr->n c_src/niffy_nif.c:51: niffy_hello: priv_data=0x1e1820e8 world 2> niffy:hello(). c_src/niffy_nif.c:51: niffy_hello: priv_data=0x1e1820e8 world 3> l(niffy). Loading: ./niffy/priv/niffy_drv c_src/niffy_nif.c:72: niffy_upgrade: *priv_data=0x0 *old_priv_data=0x1e1820e8 ptr->n=1 {module,niffy} 4> niffy:hello(). c_src/niffy_nif.c:51: niffy_hello: priv_data=0x1e1820e8 world 5> l(niffy). c_src/niffy_nif.c:81: niffy_unload: priv_data=0x1e1820e8 ptr->n=2 Loading: ./niffy/priv/niffy_drv c_src/niffy_nif.c:72: niffy_upgrade: *priv_data=0x0 *old_priv_data=0x1e1820e8 ptr->n=504889344 {module,niffy} 6> 6> l(niffy). c_src/niffy_nif.c:81: niffy_unload: priv_data=0x1e1820e8 ptr->n=504889345 Loading: ./niffy/priv/niffy_drv c_src/niffy_nif.c:72: niffy_upgrade: *priv_data=0x0 *old_priv_data=0x1e1820e8 ptr->n=504889344 {module,niffy} 7> l(niffy). c_src/niffy_nif.c:81: niffy_unload: priv_data=0x1e1820e8 ptr->n=504889345 Segmentation fault: 11 I can see that the unload is called and I free the priv_data, then upgrade is called on that very same memory. But why? -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: niffy.tgz Type: application/octet-stream Size: 1218 bytes Desc: not available URL: -------------- next part -------------- An HTML attachment was scrubbed... URL: From sverker.eriksson@REDACTED Mon May 26 14:51:10 2014 From: sverker.eriksson@REDACTED (Sverker Eriksson) Date: Mon, 26 May 2014 14:51:10 +0200 Subject: [erlang-bugs] nif reload In-Reply-To: <2C042F7F-135A-4816-9F61-D59F3C57FF57@rogvall.se> References: <2C042F7F-135A-4816-9F61-D59F3C57FF57@rogvall.se> Message-ID: <538338BE.40005@erix.ericsson.se> On 05/26/2014 01:43 AM, Tony Rogvall wrote: > Hi! > > I have something strange niff stuff going on, I think. > (tested R17/R16) > > I have a very simple demo nif application (attached), one function (not really > needed) and > a nif that I want to be able to load/upgrade/unload. I have removed the reload > callback, > that according to documentation is deprecated. > > Following sequence can be seen, when I repeat the > > l(niffy). > from the erlang shell. > > > Eshell V6.1 (abort with ^G) > 1> niffy:hello(). > Loading: ./niffy/priv/niffy_drv > c_src/niffy_nif.c:61: niffy_load: *priv_data=0x0 ptr=0x1e1820e8, ptr->n > c_src/niffy_nif.c:51: niffy_hello: priv_data=0x1e1820e8 > world > 2> niffy:hello(). > c_src/niffy_nif.c:51: niffy_hello: priv_data=0x1e1820e8 > world > 3> l(niffy). > Loading: ./niffy/priv/niffy_drv > c_src/niffy_nif.c:72: niffy_upgrade: *priv_data=0x0 *old_priv_data=0x1e1820e8 > ptr->n=1 > {module,niffy} > 4> niffy:hello(). > c_src/niffy_nif.c:51: niffy_hello: priv_data=0x1e1820e8 > world > 5> l(niffy). > c_src/niffy_nif.c:81: niffy_unload: priv_data=0x1e1820e8 ptr->n=2 > Loading: ./niffy/priv/niffy_drv > c_src/niffy_nif.c:72: niffy_upgrade: *priv_data=0x0 *old_priv_data=0x1e1820e8 > ptr->n=504889344 > {module,niffy} > 6> > 6> l(niffy). > c_src/niffy_nif.c:81: niffy_unload: priv_data=0x1e1820e8 ptr->n=504889345 > Loading: ./niffy/priv/niffy_drv > c_src/niffy_nif.c:72: niffy_upgrade: *priv_data=0x0 *old_priv_data=0x1e1820e8 > ptr->n=504889344 > {module,niffy} > 7> l(niffy). > c_src/niffy_nif.c:81: niffy_unload: priv_data=0x1e1820e8 ptr->n=504889345 > Segmentation fault: 11 > > I can see that the unload is called and I free the priv_data, then upgrade is > called on that very same memory. > But why? > Your niffy_upgrade-callback does *priv_data = *old_priv_data; which means your old and new module instances share the same data. You then free that data when the old instance is unloaded which leaves the new module with a dangling pointer. Either copy the data in niffy_upgrade or use reference counting in niffy_unload: if (--ptr->n == 0) { enif_free(ptr); } /Sverker, Erlang/OTP From tony@REDACTED Mon May 26 18:32:33 2014 From: tony@REDACTED (Tony Rogvall) Date: Mon, 26 May 2014 18:32:33 +0200 Subject: [erlang-bugs] nif reload In-Reply-To: <538338BE.40005@erix.ericsson.se> References: <2C042F7F-135A-4816-9F61-D59F3C57FF57@rogvall.se> <538338BE.40005@erix.ericsson.se> Message-ID: On 26 maj 2014, at 14:51, Sverker Eriksson wrote: ... > Your niffy_upgrade-callback does > > *priv_data = *old_priv_data; > > which means your old and new module instances share the same data. > You then free that data when the old instance is unloaded which leaves the new module with a dangling pointer. > Got it. > Either copy the data in niffy_upgrade or use reference counting in niffy_unload: > > if (--ptr->n == 0) { > enif_free(ptr); > } > I had some problem understanding how to handle to old_priv_data in the the upgrade callback, I thought unload always had to free the priv_data memory. Now I know better :-) Thanks /Tony > > /Sverker, Erlang/OTP "Installing applications can lead to corruption over time. Applications gradually write over each other's libraries, partial upgrades occur, user and system errors happen, and minute changes may be unnoticeable and difficult to fix" -------------- next part -------------- An HTML attachment was scrubbed... URL: From rvirding@REDACTED Tue May 27 17:45:12 2014 From: rvirding@REDACTED (Robert Virding) Date: Tue, 27 May 2014 17:45:12 +0200 Subject: [erlang-bugs] Trace bug? Message-ID: We have discovered strange behaviour when tracing message sends. We turn on tracing message send for a process. In R16 and 17 it seems like there is no trace message when sending to a registered process name, while sending to a pid generates a trace message as it should. In R15 however you get a trace message both sending to a registered name and hen sending to a pid. Is this a bug or is it a new undocumented feature? As an example I include simple program in which worker sends a message to a registered server and the server replies by sending the worker pid. Here are outputs when running in 17: Erlang/OTP 17 [erts-6.0] [source-07b8f44] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false] [dtrace] Eshell V6.0 (abort with ^G) 1> c(trace_procs). {ok,trace_procs} 2> trace_procs:start(). trace_procs 7 Server: '<0.39.0>' trace_procs 10 Worker: '<0.40.0>' trace_procs 34 Message: '{trace,<0.39.0>,send,answer,<0.40.0>}' trace_procs 34 Message: '{trace,<0.39.0>,send,answer,<0.40.0>}' trace_procs 34 Message: '{trace,<0.39.0>,send,answer,<0.40.0>}' trace_procs 34 Message: '{trace,<0.39.0>,send,answer,<0.40.0>}' trace_procs 34 Message: '{trace,<0.39.0>,send,answer,<0.40.0>}' and in R15: Erlang R15B03 (erts-5.9.3.1) [source] [64-bit] [smp:4:4] [async-threads:0] [hipe] [kernel-poll:false] Eshell V5.9.3.1 (abort with ^G) 1> c(trace_procs). {ok,trace_procs} 2> trace_procs:start(). trace_procs 7 Server: '<0.38.0>' trace_procs 10 Worker: '<0.39.0>' trace_procs 34 Message: '{trace,<0.39.0>,send,{request,<0.39.0>},server}' trace_procs 34 Message: '{trace,<0.38.0>,send,answer,<0.39.0>}' trace_procs 34 Message: '{trace,<0.39.0>,send,{request,<0.39.0>},server}' trace_procs 34 Message: '{trace,<0.38.0>,send,answer,<0.39.0>}' trace_procs 34 Message: '{trace,<0.39.0>,send,{request,<0.39.0>},server}' trace_procs 34 Message: '{trace,<0.38.0>,send,answer,<0.39.0>}' trace_procs 34 Message: '{trace,<0.39.0>,send,{request,<0.39.0>},server}' What gives? Robert -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: trace_procs.erl Type: text/x-erlang Size: 896 bytes Desc: not available URL: From rvirding@REDACTED Fri May 30 23:18:26 2014 From: rvirding@REDACTED (Robert Virding) Date: Fri, 30 May 2014 23:18:26 +0200 Subject: [erlang-bugs] Trace bug? In-Reply-To: References: Message-ID: Can anyone tell me if this is a bug? If not how do I get around it in simple way? Robert On 27 May 2014 17:45, Robert Virding wrote: > We have discovered strange behaviour when tracing message sends. We turn > on tracing message send for a process. In R16 and 17 it seems like there is > no trace message when sending to a registered process name, while sending > to a pid generates a trace message as it should. In R15 however you get a > trace message both sending to a registered name and hen sending to a pid. > Is this a bug or is it a new undocumented feature? > > As an example I include simple program in which worker sends a message to > a registered server and the server replies by sending the worker pid. Here > are outputs when running in 17: > > Erlang/OTP 17 [erts-6.0] [source-07b8f44] [64-bit] [smp:4:4] > [async-threads:10] [hipe] [kernel-poll:false] [dtrace] > > Eshell V6.0 (abort with ^G) > 1> c(trace_procs). > {ok,trace_procs} > 2> trace_procs:start(). > trace_procs 7 Server: '<0.39.0>' > trace_procs 10 Worker: '<0.40.0>' > trace_procs 34 Message: '{trace,<0.39.0>,send,answer,<0.40.0>}' > trace_procs 34 Message: '{trace,<0.39.0>,send,answer,<0.40.0>}' > trace_procs 34 Message: '{trace,<0.39.0>,send,answer,<0.40.0>}' > trace_procs 34 Message: '{trace,<0.39.0>,send,answer,<0.40.0>}' > trace_procs 34 Message: '{trace,<0.39.0>,send,answer,<0.40.0>}' > > and in R15: > > Erlang R15B03 (erts-5.9.3.1) [source] [64-bit] [smp:4:4] [async-threads:0] > [hipe] [kernel-poll:false] > > Eshell V5.9.3.1 (abort with ^G) > 1> c(trace_procs). > {ok,trace_procs} > 2> trace_procs:start(). > trace_procs 7 Server: '<0.38.0>' > trace_procs 10 Worker: '<0.39.0>' > trace_procs 34 Message: '{trace,<0.39.0>,send,{request,<0.39.0>},server}' > trace_procs 34 Message: '{trace,<0.38.0>,send,answer,<0.39.0>}' > trace_procs 34 Message: '{trace,<0.39.0>,send,{request,<0.39.0>},server}' > trace_procs 34 Message: '{trace,<0.38.0>,send,answer,<0.39.0>}' > trace_procs 34 Message: '{trace,<0.39.0>,send,{request,<0.39.0>},server}' > trace_procs 34 Message: '{trace,<0.38.0>,send,answer,<0.39.0>}' > trace_procs 34 Message: '{trace,<0.39.0>,send,{request,<0.39.0>},server}' > > What gives? > > Robert > > -------------- next part -------------- An HTML attachment was scrubbed... URL: