Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERL-194: code_server crashes adding code path #3384

Closed
OTP-Maintainer opened this issue Jul 14, 2016 · 1 comment
Closed

ERL-194: code_server crashes adding code path #3384

OTP-Maintainer opened this issue Jul 14, 2016 · 1 comment
Labels
bug Issue is reported as a bug priority:medium team:VM Assigned to OTP team VM
Milestone

Comments

@OTP-Maintainer
Copy link

Original reporter: imrivera
Affected version: OTP-19.0
Fixed in version: OTP-19.1
Component: kernel
Migrated from: https://bugs.erlang.org/browse/ERL-194


When adding a code path ending with "ebin" and with 2 levels, erlang crashes, for example:
{code}
$ erl -pa /myproject/ebin
2016-07-14 12:44:06 Error in process ~p with exit value:~n~p~n
	<0.36.0>
	{{case_clause,[]},[{code_server,split_base,1,[{file,"code_server.erl"},{line,639}]},{code_server,archive_subdirs,1,[{file,"code_server.erl"},{line,825}]},{code_server,do_insert_name,3,[{file,"code_server.erl"},{line,819}]},{code_server,init_namedb,2,[{file,"code_server.erl"},{line,794}]},{code_server,init_namedb,1,[{file,"code_server.erl"},{line,790}]},{code_server,init,3,[{file,"code_server.erl"},{line,96}]}]}

$ erl
Erlang/OTP 19 [erts-8.0] [source] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false]

Eshell V8.0  (abort with ^G)
1> code:add_path("/myproject/ebin").
{"Kernel pid terminated",error_logger,badarg}

Crash dump is being written to: erl_crash.dump...done
Kernel pid terminated (error_logger) (badarg)
{code}

But there is no problem if the path doesn't end with "ebin":
{code}
$ erl
Erlang/OTP 19 [erts-8.0] [source] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false]

Eshell V8.0  (abort with ^G)
1> code:add_path("/myproject/test").
true
{code}

I'm creating a pull request to fix this.
@OTP-Maintainer
Copy link
Author

imrivera said:

Pull request created

[https://github.com/erlang/otp/pull/1128]

@OTP-Maintainer OTP-Maintainer added bug Issue is reported as a bug team:VM Assigned to OTP team VM priority:medium labels Feb 10, 2021
@OTP-Maintainer OTP-Maintainer added this to the OTP-19.1 milestone Feb 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue is reported as a bug priority:medium team:VM Assigned to OTP team VM
Projects
None yet
Development

No branches or pull requests

1 participant