Age | Commit message (Collapse) | Author |
|
* ks/file_open-mode:
Add the {encoding, _} options to file:open/2's modes
|
|
|
|
* maint-r14:
Prepare release
Fix that the documentation top index generator can handle an Ericsson internal application group
Teach -init_debug to print info about on_load handlers begin run
Fix hang in on_load handlers in embedded mode
Conflicts:
erts/vsn.mk
lib/kernel/vsn.mk
|
|
In embedded mode, all on_load handlers will be called after
loading all modules but before starting any servers. Therefore,
if an on_load handler calls any function in the code module that
calls the code server (such as code:priv_dir/1), there will be a
deadlock because the code server has not yet been started.
Fix this problem by invoking the on_load handlers after
having started most servers in the kernel application.
|
|
Although the {encoding, encoding()} set of options is documented in
the manual page of the 'file' module, they do not appear in the Mode
description on that page nor in the mode() type declaration.
The patch adds this information in both the code of the module and
the documentation of the module.
To avoid duplication, the declaration of the encoding() type is added
to the 'unicode' module where it most probably belongs.
While at it, added a proper declaration for posix(), took out the
now superfluous information about the types of file:open/2 from the
erl_bif_types module, and corrected the return type of file:open/2
so that it corresponds to the published documentation.
|
|
* pan/epmd-vulnerabilities/OTP-8780:
Teach testcases to survive TIME_WAIT overload
Update erl_interface doc and testsuite for epmd changes
Restore null termination of input buffer
Teach testcase epmd_SUITE:too_large to accept econnaborted
Teach epmd_cli.c to not respond 'Killed' when killing denied
Calculate minimal packet size for ALIVE2 requests correctly
Document epmd and it's options properly and fixup help text
Fix anomalies in epmd not yet reported as security issues
Remove two buffer overflow vulnerabilities in EPMD
Remove all support for ancient EPMD protocol
Remove very old protocol from EPMD
Conflicts:
lib/erl_interface/src/epmd/epmd_port.c
|
|
|
|
* ph/auto_recognize_ipv6:
Add tests
Let an 8-tuple given as ip_address() for gen_tcp/gen_udp/gen_sctp imply 'inet6'
OTP-8822
|
|
Currently an 8-tuple representing an IPv6 address is not accepted by
gen_tcp:listen/2, gen_tcp:connect/3,4, gen_udp:open/2, or
gen_sctp:open/1,2, unless the 'inet6' option is also given. This means
that an application that has obtained the address, e.g. from
configuration that allows for either IPv4 or IPv6, must always check the
type of the address before passing it to these functions. Letting the
functions infer 'inet6' from the 8-tuple, in case other options do not
override this choice, improves usability.
|
|
Conflicts:
lib/kernel/doc/src/notes.xml
lib/kernel/vsn.mk
|
|
* rani/sctp-sndrcvinfo/OTP-8795:
Fix xfer_active close expection for Solaris behaviour
Keep default #sctp_sndrcvinfo{} fields on gen_sctp:send/4
Fill in sinfo_assoc_id in struct sctp_sndrcvinfo for getopt()
Conflicts:
lib/kernel/test/gen_sctp_SUITE.erl
|
|
|
|
|
|
A bug introduced in kernel-2.13.5.3 has been fixed. If running
net_kernel:set_net_ticktime/1 twice within the TransitionPerod the
second call caused the net_kernel process to crash with a badmatch.
|
|
OTP-8686 A bug introduced in kernel-2.13.5.3 has been fixed.
|
|
OTP-8643 Under certain circumstances the net kernel could hang. (Thanks
to Scott Lystig Fritchie.)
|
|
OTP-8502 A race condition in <c>os:cmd/1</c> could cause the caller to
get stuck in <c>os:cmd/1</c> forever.
|
|
When configuring erlang with --enable-native-libs, some core modules are
compiled with hipe, yet because they are loaded before the code server,
their native code is not loaded. The fix consists in quietly trying to
load the native code for all loaded modules just after the code server
is started.
|
|
* ks/auth-specs:
auth: Fix types and specs
|
|
* pan/otp_8698_file_typespecs:
Change typespecs for file.erl to match reality
|
|
|
|
|
|
A bug introduced in kernel-2.13.5.3 has been fixed.
|
|
* ms/file-exclusive-mode:
Update preloaded modules
Support opening files in exclusive mode
OTP-8670 ms/file-exclusive-mode
There is a new option 'exclusive' to file:open/2 that uses the OS O_EXCL
flag where supported to open the file in exclusive mode.
|
|
Add an option that atomically tests for the existence of a file and
creates it if the file does not exist, by passing the O_EXCL flag
to open() on Unix and CREATE_NEW flag on Windows. Support for O_EXCL
varies across platforms and filesystems.
{ok, Fd} = file:open("/tmp/foo", [write,exclusive]),
{error, eexist} = file:open("/tmp/foo", [write,exclusive]).
|
|
|
|
* pan/otp_8611_standard_io:
Teach file:write/read/read_line about named io_servers
OTP-8611 file:write,read and read_line on named io_device()
The file module's functions write,read and read_line now handles named
io_servers like 'standard_io' and 'standard_error' correctly.
|
|
* pan/otp_3626_win_find_executable:
Teach os.erl to find executable names with extension (i.e. .exe) on windows
OTP-3626 os:find_executable bug on Windows
os:find_executable can now be fed with the complete name of the executable
on Windows and still find it. I.e os:find_executable("werl.exe") will work
as os:find_executable("werl").
|
|
|
|
* am/net_kernel_catchall:
Add catch all handle_call to net_kernel
|
|
* rn/resolver-leaking-ports:
Resolver: make inet_dns decode ugly truncated reply
Resolver: stop inet_res leaking ports
OTP-8652 inet_res leaking ports
The kernel DNS resolver was leaking one or two ports if the DNS reply could
not be parsed or if the resolver(s) caused noconnection type errors. Bug
now fixed. A DNS specification borderline truncated reply triggering the
port leakage bug has also been fixed.
|
|
Of the core networking apps only net_kernel fails to have a catchall
for unknown gen_server:call messages causing it to exit and eventually
bring down kernal_sup and beam if it had not been manually started.
For stability and consistancy it has been altered to include a
catchall which does not reply.
|
|
|
|
Under certain circumstances the net kernel could hang. (Thanks to Scott
Lystig Fritchie.)
|
|
* bg/dist_utils:
dist_utils: Eliminate crash when list_to_existing_atom/1 fails
|
|
Bugfix: a DNS reply with the truncation bit set containing
misleading section length (i.e header claimed length greater
than what was actually in the reply section) in the header
caused decode error in inet_dns.
|
|
Bugfix: when all nameservers return a reply causing decode errors
or when errors enetunreach or econnrefused occured while
contacting them, one or two UDP ports was leaked i.e
left open and forgotten.
|
|
In the following scenario list_to_existing_atom/1 may crash
during handshake:
Start a node in one window:
erl -sname adam@localhost
Start another node in another window:
erl -sname bertil
In this node, ping the first node (use the actual hostname
in the command):
net:ping(adam@hostname).
There will be an error report similar to:
=ERROR REPORT==== 27-May-2010::15:03:14 ===
Error in process <0.40.0> on node 'bertil@hostname' with exit value: {badarg,[{erlang,list_to_existing_atom,
["adam@localhost"]},{dist_util,recv_challenge,1},{dist_util,handshake_we_started,1}]}
Eliminate the crash and the error report by catching the call to
list_to_existing_atom/1 and do a clean shutdown if it fails.
|
|
When exchanging groups between nodes pg2 did not remove duplicated members.
This bug was introduced in R13B03 (kernel-2.13.4).
|
|
* fm/file-operations:
Update preloaded modules
Add file:advise/4 - a wrapper to the POSIX syscall posix_fadvise
Add file:datasync/1 for syncing file contents only
sys.h: Correct the get_int64() macro
OTP-8637 fm/file-operations
The functions file:advise/4 and file:datasync/1 have been added. (Thanks to
Filipe David Manana.)
|
|
Useful for informing the Operating System about the access pattern
for a file's data, so that it can adapt the caching strategy to
maximize disk IO performance.
|
|
file:datasync/1 invokes the POSIX system call "int fdatasync(int fd)".
This system call is similar to "fsync" but, unlike fsync, it does not
update the metadata associated with the file (like the access time for
example). It's used by many DBMSs (MySQL and SQLite of example) to
increase disk IO performance, as it avoids disk seeks and disk write
operations compared to fsync.
More details on it at:
http://linux.die.net/man/2/fdatasync
An example, from the MySQL source:
http://bazaar.launchpad.net/~mysql/mysql-server/mysql-5.1-telco-6.1/annotate/head%3A/mysys/my_sync.c#L61
This new function just calls fsync on systems not implementing fdatasync.
|
|
* dp/shell-line-editing:
Readline-style line edit history
OTP-8635 dp/shell-line-editing
The shell's line editing has been improved to more resemble the behaviour
of readline and other shells. (Thanks to Dave Peticolas)
|
|
* ks/kernel:
kernel: Clean up as suggested by tidier
OTP-8606 ks/kernel
|
|
|
|
erl_prim_loader:list_dir/1 returns error on failure and not
{error,_}.
Also update tests in code_SUITE:clash/1.
Defect was introduced with fix for listing .ez archives in 49da83de4b.
Initial code:clash/0 tests added in 79194d5fa7.
Signed-off-by: Tuncer Ayaz <[email protected]>
|
|
* jb/inet6-dist:
Support IPv6 addresses in long host names
Fix implementation of IPv6 TCP distribution protocol
Fix compilation of epmd with IPv6 enabled
OTP-8575 jb/inet6-dist
|
|
When distributing over IPv4, node@<IPv4-address>
(e.g. [email protected]) works correctly.
Permit node@<IPv6-address> (e.g. node@::1) when
distributing over IPv6.
|
|
TCP distribution over IPv6 did not work. The TCP socket
was forcibly closed before any communication could take place.
The following changes resolve this:
* Make the kernel use the inet6 variant of accept.
* Use inet6 variants of TCP socket functions.
* Ensure that the inet6 address family is used in all cases.
|
|
As of this version, the global name server no longer supports nodes running
Erlang/OTP R11B.
|