Lines Matching refs:dirname
161 char* dirname = NEW_C_HEAP_ARRAY(char, nbytes, mtInternal);
164 _snprintf(dirname, nbytes, "%s\\%s_%s", tmpdir, perfdir, user);
166 return dirname;
468 static char* get_sharedmem_filename(const char* dirname, int vmid) {
471 size_t nbytes = strlen(dirname) + UINT_CHARS + 2;
474 _snprintf(name, nbytes, "%s\\%d", dirname, vmid);
486 static void remove_file(const char* dirname, const char* filename) {
488 size_t nbytes = strlen(dirname) + strlen(filename) + 2;
491 strcpy(path, dirname);
618 static void cleanup_sharedmem_resources(const char* dirname) {
621 DIR* dirp = os::opendir(dirname);
628 if (!is_directory_secure(dirname)) {
642 char* dbuf = NEW_C_HEAP_ARRAY(char, os::readdir_buf_size(dirname), mtInternal);
653 remove_file(dirname, entry->d_name);
680 remove_file(dirname, entry->d_name);
1222 static bool make_user_tmp_dir(const char* dirname) {
1232 if (!CreateDirectory(dirname, pDirSA)) {
1239 if (!is_directory_secure(dirname)) {
1242 warning("%s directory is insecure\n", dirname);
1252 if (!SetFileSecurity(dirname, secInfo, pDirSA->lpSecurityDescriptor)) {
1256 dirname, lasterror);
1279 static HANDLE create_sharedmem_resources(const char* dirname, const char* filename, const char* objectname, size_t size) {
1299 if (!make_user_tmp_dir(dirname)) {
1447 char* dirname = get_user_tmp_dir(user);
1450 if (!is_filesystem_secure(dirname)) {
1457 char* filename = get_sharedmem_filename(dirname, vmid);
1461 cleanup_sharedmem_resources(dirname);
1470 create_sharedmem_resources(dirname, filename, objectname, size);
1474 FREE_C_HEAP_ARRAY(char, dirname, mtInternal);
1622 char* dirname = get_user_tmp_dir(luser);
1627 if (!is_directory_secure(dirname)) {
1628 FREE_C_HEAP_ARRAY(char, dirname, mtInternal);
1633 char* filename = get_sharedmem_filename(dirname, vmid);
1648 FREE_C_HEAP_ARRAY(char, dirname, mtInternal);