ReactOS  0.4.10-dev-348-gbcec1fd
delete.c File Reference
#include <k32.h>
#include <reactos/debug.h>
Include dependency graph for delete.c:

Go to the source code of this file.

Macros

#define NDEBUG
 

Functions

BOOL WINAPI DeleteFileA (IN LPCSTR lpFileName)
 
BOOL WINAPI DeleteFileW (IN LPCWSTR lpFileName)
 

Macro Definition Documentation

#define NDEBUG

Definition at line 14 of file delete.c.

Function Documentation

BOOL WINAPI DeleteFileA ( IN LPCSTR  lpFileName)

Definition at line 24 of file delete.c.

Referenced by _tempnam(), _unlink(), activate_context(), add_table_to_db(), append_file_test(), check_dirid(), check_dotnet20(), clean_after_shfo_tests(), Cleanup(), cleanup_gcc_exe(), cleanup_msvc_exe(), cleanup_test(), compare_export_(), crash_and_debug(), create_backup(), create_cc_test_files(), create_database(), create_database_wordcount(), create_file(), create_manifest(), create_package_db(), create_test_file(), create_test_files(), delete_cf(), delete_chm(), delete_file(), delete_manifest_file(), delete_pf(), delete_pf_native(), delete_test_files(), delete_win_ini(), demFileDelete(), doChild(), DoEntry(), fci_delete(), generate_transform(), helper_createpackage(), import_reg(), init_test(), InternetLockRequestFile_test(), is_old_shell32(), load_v6_module(), map_image_section(), print_something(), process_pending_renames(), remove(), run_child_process(), run_cmd(), run_script(), run_test(), SHAddToRecentDocs(), shell_execute_(), shell_execute_ex_(), START_TEST(), tear_down_case_test(), test__creat(), test__hread(), test__hwrite(), test__lclose(), test__lcreat(), test__llopen(), test__llseek(), test__lread(), test__lwrite(), test__open_osfhandle(), test_abort_proc(), test_access(), test_actctx(), test_actctx_classes(), test_AddDelBackupEntry(), test_admin(), test_adminimage(), test_adminprops(), test_AdvInstallFile(), test_allowDelayedBinding(), test_allusers_prop(), test_alter(), test_amh_corruption(), test_ApplicationAttributes(), test_appsearch(), test_appsearch_complocator(), test_appsearch_drlocator(), test_appsearch_inilocator(), test_appsearch_reglocator(), test_ash1_corruption(), test_ash1_corruption2(), test_backup(), test_binary(), test_binary_import(), test_bind_image_ex(), test_BindToObject(), test_cabisextracted(), test_caborder(), test_calchash(), test_carriagereturn(), test_catalog_properties(), test_ccpsearch(), test_cdf_parsing(), test_CheckDatabaseManually(), test_CleanupPathA(), test_clear(), test_close(), test_cmdline(), test_collation(), test_columnorder(), test_comctl32_class(), test_command_line_parsing(), test_CommandLine(), test_compatibility(), test_complocator(), test_concurrentinstall(), test_condition(), test_Console(), test_continuouscabs(), test_controlevent(), test_copy(), test_CopyFileA(), test_CopyFileEx(), test_CopyMetaFile(), test_copyto(), test_copyto_iidexclusions_storage(), test_copyto_iidexclusions_stream(), test_copyto_locking(), test_copyto_recursive(), test_copyto_snbexclusions(), test_count(), test_create_and_fail(), test_create_catalog_file(), test_create_remove_folder(), test_create_remove_shortcut(), test_create_storage_modes(), test_create_typelib_lcid(), test_create_wide_and_fail(), test_CreateFile(), test_CreateFileA(), test_CreateFileMapping_protection(), test_createpackage(), test_CreateScalableFontResource(), test_createtable(), test_CreateTypeLib(), test_CryptCATAdminAddRemoveCatalog(), test_CryptCATOpen(), test_currentworkingdir(), test_customaction1(), test_customaction51(), test_date_format(), test_dbmerge(), test_dbtopackage(), test_debug_children(), test_debug_loop(), test_DebuggingFlag(), test_default_data(), test_defaultdatabase(), test_deferred_action(), test_delete_services(), test_DeleteFileA(), test_deleterow(), test_DetachConsoleHandles(), test_DetachStdHandles(), test_dib_bits_access(), test_Directory(), test_dllredirect_section(), test_doaction(), test_domdoc(), test_driver_install(), test_droptable(), test_duplicate_files(), test_DuplicateHandle(), test_embedded_nulls(), test_enumerate_name(), test_Environment(), test_envvar(), test_ExitCode(), test_ExitProcess(), test_externalui(), test_externalui_message(), test_Extract(), test_ExtractFiles(), test_ExtractIcon(), test_FDICopy(), test_FDIIsCabinet(), test_feature_override(), test_feature_tree(), test_featureparents(), test_ffcn_directory_overlap(), test_fieldzero(), test_file_disposition_information(), test_file_in_use(), test_file_in_use_cab(), test_file_inherit(), test_file_security(), test_file_sharing(), test_filemap_security(), test_filenames(), test_FileSecurity(), test_find_file(), test_find_related_products(), test_FindFirstChangeNotification(), test_FindFirstFile_wildcards(), test_FindFirstFileA(), test_FindFirstFileExA(), test_flush_buffers_file(), test_fmtusertypestg(), test_forcecodepage(), test_formatrecord2(), test_formatrecord_package(), test_formatrecord_tables(), test_get_digest_stream(), test_GetDisplayName(), test_getfile(), test_GetFileInformationByHandleEx(), test_GetFileType(), test_GetLongPathNameA(), test_GetMappedFileName(), test_GetPrivateProfileString(), test_getproperty(), test_gettargetpath_bad(), test_height_selection_vdmx(), test_http_cache(), test_icon_table(), test_image_load(), test_import_resolution(), test_inffilelist(), test_inffilelistA(), test_info_size(), test_InitPathA(), test_insertorder(), test_install_remove_odbc(), test_install_services(), test_install_svc_from(), test_InstallAssembly(), test_installed_prop(), test_installprops(), test_installstate(), test_integers(), test_interthread_messages(), test_invalid_callbackA(), test_invalid_parametersA(), test_iocp_callback(), test_items(), test_join(), test_lastusedsource(), test_launchconditions(), test_LaunchINFSection(), test_LaunchINFSectionEx(), test_listbox_dlgdir(), test_listbox_LB_DIR(), test_load(), test_load_save(), test_load_texture(), test_Loader(), test_LoadImage(), test_LoadImageFile(), test_LoadLibraryEx_search_flags(), test_LoadRegTypeLib(), test_LocalizedNames(), test_LockFile(), test_long_names(), test_longstrings(), test_LZCopy(), test_LZRead(), test_MapFile(), test_Mapfile_createtemp(), test_mapping(), test_MapViewOfFile(), test_markers(), test_mhtml_protocol_binding(), test_missingcab(), test_missingcomponent(), test_mixed_package(), test_mixedmedia(), test_mmio_buffer_pointer(), test_mmio_end_of_file(), test_mmioSeek(), test_monochrome_icon(), test_move(), test_move_files(), test_MoveFileA(), test_msibadqueries(), test_MsiConfigureProductEx(), test_msidatabase(), test_MsiDatabaseCommit(), test_MsiEnumComponentCosts(), test_msiexport(), test_MsiGetComponentPath(), test_MsiGetComponentPathEx(), test_MsiGetFeatureInfo(), test_MsiGetFileHash(), test_MsiGetFileSignatureInformation(), test_MsiGetFileVersion(), test_MsiGetProductProperty(), test_MsiGetSourcePath(), test_msiimport(), test_msiinsert(), test_MsiInstallProduct(), test_MsiOpenDatabase(), test_MsiOpenProduct(), test_msipackage(), test_MsiProvideComponent(), test_MsiProvideQualifiedComponentEx(), test_msirecord(), test_MsiSetComponentState(), test_MsiSetFeatureAttributes(), test_MsiSetProperty(), test_nonroot_transacted(), test_noquotes(), test_NtAreMappedFilesTheSame(), test_NtMapViewOfSection(), test_offset_in_overlapped_structure(), test_ok(), test_oldest(), test_OleLoadPicturePath(), test_open_storage(), test_openbackup(), test_openfile(), test_OpenFileById(), test_overwrite(), test_package_validation(), test_packagecoltypes(), test_parent_free(), test_patch_registration(), test_persiststreaminit(), test_PlaySound(), test_preselected(), test_PrivateExtractIcons(), test_process_components(), test_processmessage(), test_profile_existing(), test_profile_int(), test_profile_items(), test_profile_sections(), test_profile_sections_names(), test_profile_string(), test_propcase(), test_property_table(), test_props(), test_publish(), test_publish_assemblies(), test_publish_components(), test_publish_features(), test_publish_product(), test_publish_sourcelist(), test_putfile(), test_query_object(), test_QueryAssemblyInfo(), test_quotes(), test_read_write(), test_readonly(), test_readonlyfile(), test_readonlyfile_cab(), test_recordWAVE(), test_references(), test_reg_unload_key(), test_register_class_info(), test_register_extension_info(), test_register_font(), test_register_mime_info(), test_register_product(), test_register_progid_info(), test_register_typelib(), test_register_user(), test_registry(), test_relative_path(), test_remove_duplicate_files(), test_remove_env_strings(), test_remove_existing_products(), test_remove_files(), test_remove_ini_values(), test_remove_registry_values(), test_remove_upgrade_code(), test_removefiles(), test_rename(), test_ReplaceFileA(), test_ResolveDelayLoadedAPI(), test_retrieveObjectByUrl(), test_revert(), test_riff_write(), test_rows_order(), test_RunSetupCommand(), test_samesequence(), test_save(), test_SavingImages(), test_saxreader(), test_saxreader_encoding(), test_SdbGetPermLayerKeys(), test_SearchPathA(), test_section_access(), test_select_column_names(), test_select_markers(), test_select_with_tablenames(), test_self_registration(), test_setdirproperty(), test_SetDocString(), test_SetFileValidData(), test_SetFuncAndParamNames(), test_SetPermLayer(), test_setpropertyfolder(), test_SetSearchPathMode(), test_settargetpath(), test_SetTypeDescAlias(), test_SetupAddInstallSectionToDiskSpaceListA(), test_SetupAddSectionToDiskSpaceListA(), test_SetupCopyOEMInf(), test_SetupDecompressOrCopyFile(), test_SetupDiInstallClassExA(), test_SetupGetFileCompressionInfo(), test_SetupGetFileCompressionInfoEx(), test_SetupGetInfInformation(), test_SetupGetSourceFileLocation(), test_SetupGetSourceInfo(), test_SetupGetTargetPath(), test_SetupInstallServicesFromInfSectionExA(), test_SetupInstallServicesFromInfSectionExW(), test_SetVarHelpContext(), test_sh_new_link_info(), test_shared_component(), test_SHCreateShellItem(), test_SHCreateStreamOnFileA(), test_SHCreateStreamOnFileEx(), test_SHCreateStreamOnFileW(), test_ShellItemCompare(), test_shortcut(), test_shortlongsource(), test_simple(), test_simple_enumerationA(), test_simple_patch(), test_SIPRetrieveSubjectGUID(), test_sourcedir(), test_sourcedir_props(), test_sourcedirprop(), test_sourcefolder(), test_sourcepath(), test_start_stop_services(), test_start_trace(), test_Startup(), test_StartupNoConsole(), test_states(), test_stdout_handle(), test_stgcreatestorageex(), test_storage_refcount(), test_storage_stream(), test_storage_suminfo(), test_storages_table(), test_streamenum(), test_streamtable(), test_stringtable(), test_substorage_enum(), test_substorage_share(), test_suminfo(), test_suminfo_import(), test_summary_binary(), test_SuspendFlag(), test_system_tables(), test_tables_order(), test_temporary_table(), test_texture_qi(), test_thread_actctx(), test_Toolhelp(), test_top_level_action(), test_toplevel_stat(), test_trailing_slash(), test_transact(), test_transacted_shared(), test_transformprop(), test_TransformWithLoadingLocalFile(), test_try_transform(), test_TypeInfo(), test_typelib_section(), test_uiLevelFlags(), test_update(), test_upgrade_code(), test_urlcacheA(), test_URLDownloadToFile(), test_URLDownloadToFile_abort(), test_validate_product_id(), test_vertical_font(), test_viewmodify(), test_viewmodify_assign(), test_viewmodify_delete(), test_viewmodify_delete_temporary(), test_viewmodify_refresh(), test_viewmodify_update(), test_volume_props(), test_where(), test_where_not_in_selected(), test_where_viewmodify(), test_wndclass_section(), test_write_registry_values(), test_writeclassstg(), test_WriteFileGather(), test_WritePrivateProfileString(), test_xmldoc(), test_xmlelem_collection(), testInstallClass(), testLoadLibraryEx(), testSetupDiGetINFClassA(), translateinfstring_test(), translateinfstringex_test(), unload_v6_module(), and VerInstallFileA().

25 {
27 
28  /* Convert the string to unicode, and call the wide function */
30  if (FileName) return DeleteFileW(FileName->Buffer);
31  return FALSE;
32 }
PUNICODE_STRING WINAPI Basep8BitStringToStaticUnicodeString(IN LPCSTR String)
Definition: utils.c:188
#define FALSE
Definition: types.h:117
BOOL WINAPI DeleteFileW(IN LPCWSTR lpFileName)
Definition: delete.c:39
struct _FileName FileName
Definition: fatprocs.h:884
_In_ LPCSTR lpFileName
Definition: winbase.h:3011
BOOL WINAPI DeleteFileW ( IN LPCWSTR  lpFileName)

Definition at line 39 of file delete.c.

Referenced by _delete_testfontfile(), _wremove(), _wtempnam(), _wunlink(), ACTION_RemoveFiles(), BackgroundCopyJob_Cancel(), BasepCopyFileExW(), cabinet_copy_file(), cache_UninstallAssembly(), BtrfsRecv::cmd_removexattr(), BtrfsRecv::cmd_unlink(), copy_install_file(), create_db(), create_package_db(), create_temp_binary(), CryptCATAdminRemoveCatalog(), delete_directory(), delete_file(), delete_object(), CAvailableApps::DeleteCurrentAppsDB(), DeleteDesktopItemW(), DeleteFileA(), DeleteItemW(), DELNODE_recurse_dirtree(), do_file_copyW(), DoEntry(), DoExport(), download_proc(), ExportRegistryFile(), FinishDlgProc(), free_package_structures(), FreeJob(), FTP_FtpGetFileW(), get_temp_path(), CJournaledTestList::GetNextTestInfo(), GetVersionFromFileExW(), IAssemblyCacheImpl_UninstallAssembly(), InitializeSetupActionLog(), InitLogging(), IntDeleteRecursive(), ITERATE_PublishIcon(), ITERATE_RemoveDuplicateFiles(), ITERATE_RemoveFiles(), ITERATE_RemoveShortcuts(), ITERATE_UnpublishIcon(), makeFile(), MoveFileWithProgressW(), msi_apply_patch_package(), MSI_CloseDatabase(), MSI_FreePackage(), msi_load_image(), MSI_OpenPackageW(), MsiEnableLogW(), OLECONVERT_GetOLE20FromOLE10(), OLECONVERT_WriteOLE20ToBuffer(), OnClearRecentItems(), open_file_test(), OpenFile(), patch_file(), pendingRename(), PrintingThreadProc(), processFile(), RecursiveRemoveDir(), RegInstallW(), ReleaseStgMedium(), RemoveTempFont(), req_file_release(), CShellLink::Save(), save_persistent_cookie(), SetupCommitFileQueueW(), SetupCopyOEMInfW(), SetupInitializeFileLogW(), SetupUninstallOEMInfW(), SHNotifyDeleteFileW(), START_TEST(), tear_down_attribute_test(), test_AddDllDirectory(), test_AtlAxCreateControl(), test_ax_win(), test_color_contexts(), Test_CommandLine(), test_CompleteLocal(), test_CompleteLocalURL(), test_convert(), test_CopyFile2(), test_CopyFileW(), test_createconfigstream(), test_CreateFile2(), test_CreateFileW(), test_CreateTextFile(), test_Data(), test_dbmerge(), test_DeleteFileW(), test_dep(), test_direct_swmr(), test_dispatch(), Test_EmptyFile(), test_ExtractIcon(), test_file_link_information(), test_file_protocol(), test_file_rename_information(), test_filename(), test_filesourcefilter(), test_fillpath(), test_filter_graph(), test_GetLongPathNameW(), test_GetShortPathNameW(), test_HttpOptions(), test_Installer(), test_Installer_InstallProduct(), test_int_widths(), test_invalid_callbackW(), test_invalid_parametersW(), test_ITEMIDLIST_format(), test_ITextDocument_Open(), test_junction_points(), test_LoadIconWithScaleDown(), test_locking(), test_longstrings(), test_match_ex(), test_MatchApplications(), test_MatchApplicationsEx(), test_mediadet(), test_mode_generic(), test_MoveFileW(), test_msidatabase(), test_msiexport(), test_NtCreateFile(), test_overwrite(), test_Read(), test_ReadAll(), test_readdirectorychanges_cr(), test_readdirectorychanges_filedir(), test_readonly(), test_recinfo(), test_render_run(), test_ReplaceFileW(), test_Sdb(), Test_SectionContents(), test_SHCreateShellItem(), test_SHCreateStreamOnFileEx_CopyTo(), test_SHGetIniString(), test_SHGetPathFromIDList(), test_SHSetIniString(), test_simple_enumerationW(), test_sip(), test_sip_create_indirect_data(), test_stringtable(), test_stub(), test_TagRef(), test_textstream(), Test_Truncate(), test_unicode(), test_wintrust(), test_wintrust_digest(), test_WriteLine(), testAddCertificateLink(), testCodepage(), testCollectionStore(), testFileNameStore(), testFileStore(), testObjTrust(), TestPrivMoveFileIdentityW(), testPropsHelper(), CDownloadManager::ThreadFunc(), uninstall_assembly(), UninstallColorProfileW(), unpack_avi_file(), CAvailableApps::UpdateAppsDB(), urlcache_delete_file(), WAVE_mciSave(), wmain(), and write_raw_resources().

40 {
41  FILE_DISPOSITION_INFORMATION FileDispInfo;
44  UNICODE_STRING NtPathU;
47  RTL_RELATIVE_NAME_U RelativeName;
48  PWCHAR PathBuffer;
49  FILE_ATTRIBUTE_TAG_INFORMATION FileTagInformation;
50 
51  /* Convert to NT path and get the relative name too */
53  &NtPathU,
54  NULL,
55  &RelativeName))
56  {
57  /* Bail out if the path name makes no sense */
59  return FALSE;
60  }
61 
62  /* Save the path buffer in case we free it later */
63  PathBuffer = NtPathU.Buffer;
64 
65  /* If we have a relative name... */
66  if (RelativeName.RelativeName.Length)
67  {
68  /* Do a relative open with only the relative path set */
69  NtPathU = RelativeName.RelativeName;
70  }
71  else
72  {
73  /* Do a full path open with no containing directory */
74  RelativeName.ContainingDirectory = NULL;
75  }
76 
77  /* Now open the directory name that was passed in */
78  InitializeObjectAttributes(&ObjectAttributes,
79  &NtPathU,
81  RelativeName.ContainingDirectory,
82  NULL);
83  Status = NtOpenFile(&FileHandle,
85  &ObjectAttributes,
86  &IoStatusBlock,
91  if (NT_SUCCESS(Status))
92  {
93  /* Check if there's a reparse point associated with this file handle */
94  Status = NtQueryInformationFile(FileHandle,
95  &IoStatusBlock,
96  &FileTagInformation,
97  sizeof(FileTagInformation),
99  if ((NT_SUCCESS(Status)) &&
100  (FileTagInformation.FileAttributes & FILE_ATTRIBUTE_REPARSE_POINT) &&
101  (FileTagInformation.ReparseTag != IO_REPARSE_TAG_MOUNT_POINT))
102  {
103  /* There is, so now try to open it with reparse behavior */
104  NtClose(FileHandle);
105  Status = NtOpenFile(&FileHandle,
106  DELETE,
107  &ObjectAttributes,
108  &IoStatusBlock,
114  if (!NT_SUCCESS(Status))
115  {
116  /* We failed -- maybe whoever is handling this tag isn't there */
117  if (Status == STATUS_IO_REPARSE_TAG_NOT_HANDLED)
118  {
119  /* Try to open it for delete, without reparse behavior */
120  Status = NtOpenFile(&FileHandle,
121  DELETE,
122  &ObjectAttributes,
123  &IoStatusBlock,
130  }
131 
132  if (!NT_SUCCESS(Status))
133  {
134  RtlReleaseRelativeName(&RelativeName);
135  RtlFreeHeap(RtlGetProcessHeap(), 0, PathBuffer);
136  BaseSetLastNTError(Status);
137  return FALSE;
138  }
139  }
140  }
141  else if (!(NT_SUCCESS(Status)) &&
142  (Status != STATUS_NOT_IMPLEMENTED) &&
143  (Status != STATUS_INVALID_PARAMETER))
144  {
145  /* We had some critical error querying the attributes, bail out */
146  RtlReleaseRelativeName(&RelativeName);
147  RtlFreeHeap(RtlGetProcessHeap(), 0, PathBuffer);
148  NtClose(FileHandle);
149  BaseSetLastNTError(Status);
150  return FALSE;
151  }
152  }
153  else
154  {
155  /* It's possible that FILE_OPEN_REPARSE_POINT was not understood */
156  if (Status == STATUS_INVALID_PARAMETER)
157  {
158  /* Try opening the file normally, with reparse behavior */
159  Status = NtOpenFile(&FileHandle,
160  DELETE,
161  &ObjectAttributes,
162  &IoStatusBlock,
168  if (!NT_SUCCESS(Status))
169  {
170  /* This failed too, fail */
171  RtlReleaseRelativeName(&RelativeName);
172  RtlFreeHeap(RtlGetProcessHeap(), 0, PathBuffer);
173  BaseSetLastNTError(Status);
174  return FALSE;
175  }
176  }
177  else
178  {
179  /* Maybe we didn't have READ_ATTRIBUTE rights? */
180  if (Status != STATUS_ACCESS_DENIED)
181  {
182  /* Nope, it was something else, let's fail */
183  RtlReleaseRelativeName(&RelativeName);
184  RtlFreeHeap(RtlGetProcessHeap(), 0, PathBuffer);
185  BaseSetLastNTError(Status);
186  return FALSE;
187  }
188 
189  /* Let's try again, without querying attributes */
190  Status = NtOpenFile(&FileHandle,
191  DELETE,
192  &ObjectAttributes,
193  &IoStatusBlock,
200  if (!NT_SUCCESS(Status))
201  {
202  /* This failed too, so bail out */
203  RtlReleaseRelativeName(&RelativeName);
204  RtlFreeHeap(RtlGetProcessHeap(), 0, PathBuffer);
205  BaseSetLastNTError(Status);
206  return FALSE;
207  }
208  }
209  }
210 
211  /* Ready to delete the file, so cleanup temporary data */
212  RtlReleaseRelativeName(&RelativeName);
213  RtlFreeHeap(RtlGetProcessHeap(), 0, PathBuffer);
214 
215  /* Ask for the file to be deleted */
216  FileDispInfo.DeleteFile = TRUE;
217  Status = NtSetInformationFile(FileHandle,
218  &IoStatusBlock,
219  &FileDispInfo,
222  NtClose(FileHandle);
223  if (!NT_SUCCESS(Status))
224  {
225  /* Deletion failed, tell the caller */
226  BaseSetLastNTError(Status);
227  return FALSE;
228  }
229 
230  /* Tell the caller deletion worked */
231  return TRUE;
232 }
IN PUNICODE_STRING IN POBJECT_ATTRIBUTES ObjectAttributes
Definition: conport.c:35
#define TRUE
Definition: types.h:120
#define STATUS_NOT_IMPLEMENTED
Definition: ntstatus.h:225
#define STATUS_INVALID_PARAMETER
Definition: udferr_usr.h:135
HANDLE ContainingDirectory
Definition: rtltypes.h:1364
VOID NTAPI RtlReleaseRelativeName(_In_ PRTL_RELATIVE_NAME_U RelativeName)
BOOLEAN NTAPI RtlFreeHeap(IN PVOID HeapHandle, IN ULONG Flags, IN PVOID HeapBase)
Definition: heap.c:603
#define STATUS_IO_REPARSE_TAG_NOT_HANDLED
Definition: ntstatus.h:743
uint16_t * PWCHAR
Definition: typedefs.h:54
#define FILE_SHARE_WRITE
Definition: nt_native.h:681
#define FILE_SHARE_READ
Definition: compat.h:125
#define IO_REPARSE_TAG_MOUNT_POINT
Definition: iotypes.h:6865
#define FALSE
Definition: types.h:117
smooth NULL
Definition: ftsmooth.c:416
DWORD BaseSetLastNTError(IN NTSTATUS Status)
Definition: reactos.cpp:166
#define FILE_ATTRIBUTE_REPARSE_POINT
Definition: ntifs_ex.h:381
NTSYSAPI NTSTATUS NTAPI NtOpenFile(OUT PHANDLE phFile, IN ACCESS_MASK DesiredAccess, IN POBJECT_ATTRIBUTES ObjectAttributes, OUT PIO_STATUS_BLOCK pIoStatusBlock, IN ULONG ShareMode, IN ULONG OpenMode)
Definition: file.c:3508
LONG NTSTATUS
Definition: precomp.h:26
#define NT_SUCCESS(StatCode)
Definition: apphelp.c:24
#define STATUS_ACCESS_DENIED
Definition: udferr_usr.h:145
#define SetLastError(x)
Definition: compat.h:409
NTSTATUS NTAPI NtClose(IN HANDLE Handle)
Definition: obhandle.c:3392
#define OBJ_CASE_INSENSITIVE
Definition: winternl.h:228
#define FILE_READ_ATTRIBUTES
Definition: nt_native.h:647
#define FILE_SHARE_DELETE
Definition: nt_native.h:682
#define FILE_NON_DIRECTORY_FILE
Definition: constants.h:492
NTSTATUS NTAPI NtQueryInformationFile(HANDLE hFile, PIO_STATUS_BLOCK io, PVOID ptr, ULONG len, FILE_INFORMATION_CLASS FileInformationClass)
Status
Definition: gdiplustypes.h:24
static HANDLE FileHandle
Definition: cabinet.c:48
DWORD *typedef HANDLE
Definition: winlogon.h:52
#define FILE_OPEN_FOR_BACKUP_INTENT
Definition: from_kernel.h:42
static OUT PIO_STATUS_BLOCK IoStatusBlock
Definition: pipe.c:75
#define InitializeObjectAttributes(p, n, a, r, s)
Definition: reg.c:106
UNICODE_STRING RelativeName
Definition: rtltypes.h:1363
#define ERROR_PATH_NOT_FOUND
Definition: winerror.h:106
#define FILE_OPEN_REPARSE_POINT
Definition: from_kernel.h:46
NTSYSAPI NTSTATUS NTAPI NtSetInformationFile(IN HANDLE hFile, OUT PIO_STATUS_BLOCK pIoStatusBlock, IN PVOID FileInformationBuffer, IN ULONG FileInformationBufferLength, IN FILE_INFORMATION_CLASS FileInfoClass)
Definition: iofunc.c:2854
NTSYSAPI BOOLEAN NTAPI RtlDosPathNameToNtPathName_U(_In_opt_z_ PCWSTR DosPathName, _Out_ PUNICODE_STRING NtPathName, _Out_opt_ PCWSTR *NtFileNamePart, _Out_opt_ PRTL_RELATIVE_NAME_U DirectoryInfo)
_In_ LPCSTR lpFileName
Definition: winbase.h:3011
#define DELETE
Definition: nt_native.h:57