mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 23:04:50 +02:00
8072694: Need errno info when CDS archive creation fails
Add errno output to error message when CDS archive creation fails Reviewed-by: dholmes, lfoltan
This commit is contained in:
parent
c6b7e46d0d
commit
811df313ff
1 changed files with 3 additions and 2 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2003, 2014, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
|
@ -388,7 +388,8 @@ void FileMapInfo::open_for_write() {
|
|||
remove(_full_path);
|
||||
int fd = open(_full_path, O_RDWR | O_CREAT | O_TRUNC | O_BINARY, 0444);
|
||||
if (fd < 0) {
|
||||
fail_stop("Unable to create shared archive file %s.", _full_path);
|
||||
fail_stop("Unable to create shared archive file %s: (%s).", _full_path,
|
||||
strerror(errno));
|
||||
}
|
||||
_fd = fd;
|
||||
_file_offset = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue