8012260: ciReplay: Include PID into the name of replay data file

Reviewed-by: kvn, twisti
This commit is contained in:
Vladimir Ivanov 2013-04-25 11:02:32 -07:00
parent 670aea401a
commit f26c1a6c88
12 changed files with 97 additions and 76 deletions

View file

@ -1221,8 +1221,10 @@ bool os::dll_build_name(char *buffer, size_t buflen,
// Needs to be in os specific directory because windows requires another
// header file <direct.h>
const char* os::get_current_directory(char *buf, int buflen) {
return _getcwd(buf, buflen);
const char* os::get_current_directory(char *buf, size_t buflen) {
int n = static_cast<int>(buflen);
if (buflen > INT_MAX) n = INT_MAX;
return _getcwd(buf, n);
}
//-----------------------------------------------------------
@ -4098,6 +4100,10 @@ int os::open(const char *path, int oflag, int mode) {
return ::open(pathbuf, oflag | O_BINARY | O_NOINHERIT, mode);
}
FILE* os::open(int fd, const char* mode) {
return ::_fdopen(fd, mode);
}
// Is a (classpath) directory empty?
bool os::dir_is_empty(const char* path) {
WIN32_FIND_DATA fd;