diff options
Diffstat (limited to 'zucchini_integration.h')
-rw-r--r-- | zucchini_integration.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/zucchini_integration.h b/zucchini_integration.h index 2ae6091..2b6287b 100644 --- a/zucchini_integration.h +++ b/zucchini_integration.h @@ -63,6 +63,16 @@ status::Code Apply(const base::FilePath& old_path, const base::FilePath& new_path, bool force_keep = false); +// Verifies the patch format in |patch_file| and returns +// Code::kStatusPatchReadError if the patch is malformed or version is +// unsupported. Since this uses memory mapped files, crashes are expected in +// case of I/O errors. +status::Code VerifyPatch(base::File patch_file); + +// Alternative VerifyPatch() interface that takes base::FilePath as arguments. +// Performs proper cleanup in Windows and UNIX if failure occurs. +status::Code VerifyPatch(const base::FilePath& patch_path); + } // namespace zucchini #endif // COMPONENTS_ZUCCHINI_ZUCCHINI_INTEGRATION_H_ |