提交 54c29251 编写于 作者: Z zgu

Merge

...@@ -917,7 +917,7 @@ void VMError::report_and_die() { ...@@ -917,7 +917,7 @@ void VMError::report_and_die() {
bool copy_ok = bool copy_ok =
Arguments::copy_expand_pid(ErrorFile, strlen(ErrorFile), buffer, sizeof(buffer)); Arguments::copy_expand_pid(ErrorFile, strlen(ErrorFile), buffer, sizeof(buffer));
if (copy_ok) { if (copy_ok) {
fd = open(buffer, O_RDWR | O_CREAT | O_TRUNC, 0666); fd = open(buffer, O_RDWR | O_CREAT | O_TRUNC, 0600);
} }
} }
...@@ -928,7 +928,7 @@ void VMError::report_and_die() { ...@@ -928,7 +928,7 @@ void VMError::report_and_die() {
// so use the default name in the current directory // so use the default name in the current directory
jio_snprintf(&buffer[len], sizeof(buffer)-len, "%shs_err_pid%u.log", jio_snprintf(&buffer[len], sizeof(buffer)-len, "%shs_err_pid%u.log",
os::file_separator(), os::current_process_id()); os::file_separator(), os::current_process_id());
fd = open(buffer, O_RDWR | O_CREAT | O_TRUNC, 0666); fd = open(buffer, O_RDWR | O_CREAT | O_TRUNC, 0600);
} }
if (fd == -1) { if (fd == -1) {
...@@ -937,7 +937,7 @@ void VMError::report_and_die() { ...@@ -937,7 +937,7 @@ void VMError::report_and_die() {
if (tmpdir != NULL && tmpdir[0] != '\0') { if (tmpdir != NULL && tmpdir[0] != '\0') {
jio_snprintf(buffer, sizeof(buffer), "%s%shs_err_pid%u.log", jio_snprintf(buffer, sizeof(buffer), "%s%shs_err_pid%u.log",
tmpdir, os::file_separator(), os::current_process_id()); tmpdir, os::file_separator(), os::current_process_id());
fd = open(buffer, O_RDWR | O_CREAT | O_TRUNC, 0666); fd = open(buffer, O_RDWR | O_CREAT | O_TRUNC, 0600);
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册