summaryrefslogtreecommitdiffstats
path: root/applypatch/include/applypatch/applypatch.h
diff options
context:
space:
mode:
authorTianjie Xu <xunchang@google.com>2017-10-25 22:16:54 +0200
committerTianjie Xu <xunchang@google.com>2017-11-03 22:09:11 +0100
commita88cc5440ed79a0927f57bbd03377ff3ce04a760 (patch)
tree493507d15c2ec159ee74a3e21a0cee91bee58d28 /applypatch/include/applypatch/applypatch.h
parentMerge "Add libbrotli as a dependency for libbsdiff" (diff)
downloadandroid_bootable_recovery-a88cc5440ed79a0927f57bbd03377ff3ce04a760.tar
android_bootable_recovery-a88cc5440ed79a0927f57bbd03377ff3ce04a760.tar.gz
android_bootable_recovery-a88cc5440ed79a0927f57bbd03377ff3ce04a760.tar.bz2
android_bootable_recovery-a88cc5440ed79a0927f57bbd03377ff3ce04a760.tar.lz
android_bootable_recovery-a88cc5440ed79a0927f57bbd03377ff3ce04a760.tar.xz
android_bootable_recovery-a88cc5440ed79a0927f57bbd03377ff3ce04a760.tar.zst
android_bootable_recovery-a88cc5440ed79a0927f57bbd03377ff3ce04a760.zip
Diffstat (limited to '')
-rw-r--r--applypatch/include/applypatch/applypatch.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/applypatch/include/applypatch/applypatch.h b/applypatch/include/applypatch/applypatch.h
index 2a3b3ef39..bcb8a4126 100644
--- a/applypatch/include/applypatch/applypatch.h
+++ b/applypatch/include/applypatch/applypatch.h
@@ -36,12 +36,11 @@ struct FileContents {
struct stat st;
};
-// When there isn't enough room on the target filesystem to hold the
-// patched version of the file, we copy the original here and delete
-// it to free up space. If the expected source file doesn't exist, or
-// is corrupted, we look to see if this file contains the bits we want
-// and use it as the source instead.
-#define CACHE_TEMP_SOURCE "/cache/saved.file"
+// When there isn't enough room on the target filesystem to hold the patched version of the file,
+// we copy the original here and delete it to free up space. If the expected source file doesn't
+// exist, or is corrupted, we look to see if the cached file contains the bits we want and use it as
+// the source instead. The default location for the cached source is "/cache/saved.file".
+extern std::string cache_temp_source;
using SinkFn = std::function<size_t(const unsigned char*, size_t)>;