Lines Matching refs:entry

175 	char *entry, *found, *save;  in phar_make_dirstream()  local
219 entry = (char *) safe_emalloc(found - ZSTR_VAL(str_key), 1, 1); in phar_make_dirstream()
220 memcpy(entry, ZSTR_VAL(str_key), found - ZSTR_VAL(str_key)); in phar_make_dirstream()
222 entry[keylen] = '\0'; in phar_make_dirstream()
224 entry = (char *) safe_emalloc(keylen, 1, 1); in phar_make_dirstream()
225 memcpy(entry, ZSTR_VAL(str_key), keylen); in phar_make_dirstream()
226 entry[keylen] = '\0'; in phar_make_dirstream()
253 entry = (char *) safe_emalloc(found - save + dirlen, 1, 1); in phar_make_dirstream()
254 memcpy(entry, save + dirlen + 1, found - save - dirlen - 1); in phar_make_dirstream()
256 entry[keylen] = '\0'; in phar_make_dirstream()
260 entry = (char *) safe_emalloc(keylen - dirlen, 1, 1); in phar_make_dirstream()
261 memcpy(entry, save + dirlen + 1, keylen - dirlen - 1); in phar_make_dirstream()
262 entry[keylen - dirlen - 1] = '\0'; in phar_make_dirstream()
267 phar_add_empty(data, entry, keylen); in phar_make_dirstream()
270 efree(entry); in phar_make_dirstream()
299 phar_entry_info *entry = NULL; in phar_wrapper_open_dir() local
357 …if (NULL != (entry = zend_hash_str_find_ptr(&phar->manifest, internal_file, strlen(internal_file))… in phar_wrapper_open_dir()
360 } else if (entry && entry->is_dir) { in phar_wrapper_open_dir()
361 if (entry->is_mounted) { in phar_wrapper_open_dir()
363 return php_stream_opendir(entry->tmp, options, context); in phar_wrapper_open_dir()
401 phar_entry_info entry, *e; in phar_wrapper_mkdir() local
484 memset((void *) &entry, 0, sizeof(phar_entry_info)); in phar_wrapper_mkdir()
488 entry.is_zip = 1; in phar_wrapper_mkdir()
491 entry.filename = estrdup(ZSTR_VAL(resource->path) + 1); in phar_wrapper_mkdir()
494 entry.is_tar = 1; in phar_wrapper_mkdir()
495 entry.tar_type = TAR_DIR; in phar_wrapper_mkdir()
498 entry.filename_len = ZSTR_LEN(resource->path) - 1; in phar_wrapper_mkdir()
500 entry.is_dir = 1; in phar_wrapper_mkdir()
501 entry.phar = phar; in phar_wrapper_mkdir()
502 entry.is_modified = 1; in phar_wrapper_mkdir()
503 entry.is_crc_checked = 1; in phar_wrapper_mkdir()
504 entry.flags = PHAR_ENT_PERM_DEF_DIR; in phar_wrapper_mkdir()
505 entry.old_flags = PHAR_ENT_PERM_DEF_DIR; in phar_wrapper_mkdir()
507 …if (NULL == zend_hash_str_add_mem(&phar->manifest, entry.filename, entry.filename_len, (void*)&ent… in phar_wrapper_mkdir()
508 …annot create directory \"%s\" in phar \"%s\", adding to manifest failed", entry.filename, phar->fn… in phar_wrapper_mkdir()
510 efree(entry.filename); in phar_wrapper_mkdir()
517 …options, "phar error: cannot create directory \"%s\" in phar \"%s\", %s", entry.filename, phar->fn… in phar_wrapper_mkdir()
518 zend_hash_str_del(&phar->manifest, entry.filename, entry.filename_len); in phar_wrapper_mkdir()
523 phar_add_virtual_dirs(phar, entry.filename, entry.filename_len); in phar_wrapper_mkdir()
533 phar_entry_info *entry; in phar_wrapper_rmdir() local
589 …if (!(entry = phar_get_entry_info_dir(phar, ZSTR_VAL(resource->path) + 1, path_len, 2, &error, 1))… in phar_wrapper_rmdir()
600 if (!entry->is_deleted) { in phar_wrapper_rmdir()
609 if (entry->is_temp_dir) { in phar_wrapper_rmdir()
610 efree(entry->filename); in phar_wrapper_rmdir()
611 efree(entry); in phar_wrapper_rmdir()
626 if (entry->is_temp_dir) { in phar_wrapper_rmdir()
627 efree(entry->filename); in phar_wrapper_rmdir()
628 efree(entry); in phar_wrapper_rmdir()
636 if (entry->is_temp_dir) { in phar_wrapper_rmdir()
638 efree(entry->filename); in phar_wrapper_rmdir()
639 efree(entry); in phar_wrapper_rmdir()
641 entry->is_deleted = 1; in phar_wrapper_rmdir()
642 entry->is_modified = 1; in phar_wrapper_rmdir()
646 …options, "phar error: cannot remove directory \"%s\" in phar \"%s\", %s", entry->filename, phar->f… in phar_wrapper_rmdir()