aboutsummaryrefslogtreecommitdiffstats
path: root/erts
diff options
context:
space:
mode:
authorSverker Eriksson <[email protected]>2017-11-27 20:07:57 +0100
committerSverker Eriksson <[email protected]>2017-11-27 20:07:57 +0100
commit2de02457c36d594f953efa0003186c8d5bbe7b41 (patch)
treeb58da6fe4faba75dc884f88a09680d7131d045fd /erts
parent7716381b10e23709b3c383e3fb5c8fcd579bf799 (diff)
parent851d82dae27e89275b2a107f98b2fa7bd9c08a1e (diff)
downloadotp-2de02457c36d594f953efa0003186c8d5bbe7b41.tar.gz
otp-2de02457c36d594f953efa0003186c8d5bbe7b41.tar.bz2
otp-2de02457c36d594f953efa0003186c8d5bbe7b41.zip
Merge branch 'sverker/run_erl-log-gen-doc' into maint
Diffstat (limited to 'erts')
-rw-r--r--erts/doc/src/run_erl.xml6
-rw-r--r--erts/etc/unix/run_erl.c7
2 files changed, 8 insertions, 5 deletions
diff --git a/erts/doc/src/run_erl.xml b/erts/doc/src/run_erl.xml
index a9b6a7e2c6..e4c1b943c4 100644
--- a/erts/doc/src/run_erl.xml
+++ b/erts/doc/src/run_erl.xml
@@ -181,6 +181,12 @@
<item>
<p>Controls the number of log files written before older
files are reused. Defaults to 5, minimum is 2, maximum is 1000.</p>
+ <p>Note that, as a way to indicate the newest file, <c>run_erl</c> will
+ delete the oldest log file to maintain a "hole" in the file
+ sequences. For example, if log files #1, #2, #4 and #5 exists, that
+ means #2 is the latest and #4 is the oldest. You will therefore at most
+ get one less log file than the value set by
+ <c>RUN_ERL_LOG_GENERATIONS</c>.</p>
</item>
<tag><c>RUN_ERL_LOG_MAXSIZE</c></tag>
<item>
diff --git a/erts/etc/unix/run_erl.c b/erts/etc/unix/run_erl.c
index f05c729eeb..81a0036c99 100644
--- a/erts/etc/unix/run_erl.c
+++ b/erts/etc/unix/run_erl.c
@@ -1343,11 +1343,8 @@ static int sf_open(const char *path, int type, mode_t mode) {
return fd;
}
static int sf_close(int fd) {
- int res = 0;
-
- do { res = close(fd); } while(fd < 0 && errno == EINTR);
-
- return res;
+ /* "close() should not be retried after an EINTR" */
+ return close(fd);
}
/* Extract any control sequences that are ment only for run_erl
* and should not be forwarded to the pty.