Bsdifflib
Portable binary diff/patch library based on the binary diff/patch utilities bsdiff/bspatch
Install / Use
/learn @petervas/BsdifflibREADME
Binary diff/patch library (bsdifflib/bspatchlib) 1.2 is based on the original binary diff/patch utility (bsdiff/bspatch) by Colin Percival and the Win32 port by Andreas John.
Binary diff/patch library adds an API to make it usable as a cross-platform C/C++ library. This library generates patches that are compatible with the original bsdiff tool. The patch routine now works on memory instead of files so multiple patches in succession can be applied without disk access.
See bsdiff.c/bspatch.c for example usage.
Error handling was inspired by GetWAD, written by Copyright 2003-2024 Hippocrates Sendoukas hsendoukas@hotmail.com available at http://getwad.zdaemon.org/
I would like to thank Hippocrates Sendoukas for helping me out with some C related questions and giving me helpful coding suggestions in general. You can visit his site at http://hs.zdaemon.org/
Compile:
Linux: Just run make
Windows: Unpack bzip2 source code to the bzip2 folder.
Run nmake -f Makefile.mak
Changelog:
bsdifflib/bspatchlib 1.3 (21 September 2024)
Restored compatibility with older Visual Studio versions.
Fixed manifest handling. No more UAC in Windows.
bsdifflib/bspatchlib 1.2 (9 September 2023)
Removed Visual Studio Project files.
Removed bzip2 source code.
Added nmake file for Windows.
Updated Makefile.
Minor code cleanups.
Pass patch file only to bspatch to print decompressed ctrl/diff/extra sizes.
Fixed CVE-2014-9862.
Fixed CVE-2020-14315.
Fixed memory leaks and add more checks in decompress_block.
Fixed handling of empty source/destination files.
bsdifflib/bspatchlib 1.1 (9 November 2010)
Included own header in source files.
Hippocrates Sendoukas optimized the patching process to
take place in memory. New functions have been added to the bspatchlib
API to make use of the optimizations for certain use cases.
Updated libbzip2 to 1.0.6.
bsdifflib/bspatchlib 1.0 (26 May 2010)
Initial release.
Related Skills
node-connect
344.4kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
99.2kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
344.4kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
344.4kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
