Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

xdiff_file_bpatch(3) [php man page]

XDIFF_FILE_BPATCH(3)							 1						      XDIFF_FILE_BPATCH(3)

xdiff_file_bpatch - Patch a file with a binary diff

SYNOPSIS
bool xdiff_file_bpatch (string $file, string $patch, string $dest) DESCRIPTION
Patches a $file with a binary $patch and stores the result in a file $dest. This function accepts patches created both via xdiff_file_bdiff(3) and xdiff_file_rabdiff(3) functions or their string counterparts. PARAMETERS
o $file - The original file. o $patch - The binary patch file. o $dest - Path of the resulting file. RETURN VALUES
Returns TRUE on success or FALSE on failure. EXAMPLES
Example #1 xdiff_file_bpatch(3) example The following code applies binary diff to a file. <?php $old_version = 'archive-1.0.tgz'; $patch = 'archive.bpatch'; $result = xdiff_file_bpatch($old_version, $patch, 'archive-1.1.tgz'); if ($result) { echo "File patched"; } else { echo "File couldn't be patched"; } ?> NOTES
Note Both files ($file and $patch) will be loaded into memory so ensure that your memory_limit is set high enough. SEE ALSO
xdiff_file_bdiff(3), xdiff_file_rabdiff(3). PHP Documentation Group XDIFF_FILE_BPATCH(3)

Check Out this Related Man Page

XDIFF_FILE_RABDIFF(3)							 1						     XDIFF_FILE_RABDIFF(3)

xdiff_file_rabdiff - Make binary diff of two files using the Rabin's polynomial fingerprinting algorithm

SYNOPSIS
bool xdiff_file_rabdiff (string $old_file, string $new_file, string $dest) DESCRIPTION
Makes a binary diff of two files and stores the result in a patch file. The difference between this function and xdiff_file_bdiff(3) is different algorithm used which should result in faster execution and smaller diff produced. This function works with both text and binary files. Resulting patch file can be later applied using xdiff_file_bpatch(3)/xdiff_string_bpatch(3). For more details about differences between algorithm used please check libxdiff website. PARAMETERS
o $old_file - Path to the first file. This file acts as "old" file. o $new_file - Path to the second file. This file acts as "new" file. o $dest - Path of the resulting patch file. Resulting file contains differences between "old" and "new" files. It is in binary format and is human-unreadable. RETURN VALUES
Returns TRUE on success or FALSE on failure. EXAMPLES
Example #1 xdiff_file_rabdiff(3) example The following code makes binary diff of two archives. <?php $old_version = 'my_script_1.0.tgz'; $new_version = 'my_script_1.1.tgz'; xdiff_file_rabdiff($old_version, $new_version, 'my_script.bdiff'); ?> NOTES
Note Both files will be loaded into memory so ensure that your memory_limit is set high enough. SEE ALSO
xdiff_file_bpatch(3). PHP Documentation Group XDIFF_FILE_RABDIFF(3)
Man Page

14 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

unzip .tgz files

hi all How to unzip .tgz files waiting for suggestions Praful (5 Replies)
Discussion started by: Prafulla
5 Replies

2. Windows & DOS: Issues & Discussions

*.tgz file on WinXP

Could anyone of y'all gurus tell me of how to open *.tgz files in WinXP....which program should i use to open it...i have tried going online to open it ut all in vain...please help Gerry... (5 Replies)
Discussion started by: gerald_agoi
5 Replies

3. Shell Programming and Scripting

Path data

I trying to convert the path data where \ are used to /. Can anyone help as I am obviously doing something incorrect! echo "File One" read fileone | sed 's#\\#/#g' echo "File Two" read filetwo | sed 's#\\#/#g' diff $fileone $filetwo pg (1 Reply)
Discussion started by: ithomp
1 Replies

4. Solaris

Patch help?

Hello... I'm looking for latest patch for automount and what it does on Solaris8, Thanks! :confused: (2 Replies)
Discussion started by: catwomen
2 Replies

5. UNIX for Dummies Questions & Answers

Create individual tgz files from a set of files

Hello I have a ton of files in a directory of the format app.log.2008-04-04 I'd like to run a command that would archive each of these files as app.log.2008-04-04.tgz I tried a few combinations of find with xargs etc but no luck. Thanks Amit (4 Replies)
Discussion started by: amitg
4 Replies

6. Solaris

sendmail failed after patch update

Hi, I was troubleshooting H/W issue on a Ultra 5 workstation, whereby the system kept rebooting. In the course of isolating the issue, I patched the system with the latest Recommended cluster patch for solaris 7. SInce then, sendmail is not working and am getting the following errors. Kindly check... (6 Replies)
Discussion started by: incredible
6 Replies

7. UNIX for Dummies Questions & Answers

file.tgz.1of2 & file.tgz.2of2

Hi all, Need help. Anybody seen this kind of file before? file.tgz.1of2 file.tgz.2of2 how to extract this tgz file? Any help? Tq (5 Replies)
Discussion started by: zeedwolf
5 Replies

8. Solaris

Which tool to Patch SOL 9? - 3 tools found

I have found 3 different tools to patch Solaris 9: 1. Patch Check Advanced (PCA) by Martin Paul BigAdmin: Solaris Information Center - Patching Support Patch Check Advanced 2. Update Manager from Sun Sun Connection 3. pkg-get, wget, etc. from Blastwave.org Blastwave.org - How to get... (2 Replies)
Discussion started by: johne1
2 Replies

9. UNIX for Dummies Questions & Answers

Question on using a variable in KSH

Hi all, The below command tries to copy ".tgz" instead of "hello_test.tgz" -- It seems as if the underscore gets in the way. I tried with different ways of using quotes, with no luck, unfortunately...it's probably very simple, but may I ask how this would be done: How would the below be... (3 Replies)
Discussion started by: chatguy
3 Replies

10. Red Hat

RedHat patch date?

Other than looking at the dates when pkgs were applied in /var/log/yum.log* how can I tell when the last time a RedHat system was patched? My systems don't have regular access to the web. Thanks in advance. ---------- Post updated at 02:37 PM ---------- Previous update was at 02:27 PM... (0 Replies)
Discussion started by: toor13
0 Replies

11. Hardware

Verify patching

I patched a linux kernel 2.6.28 with lttng patch. Now I have two folder of linux patched and unpatched. How can I verify whether the linux is patched or unptahced(original version)? (0 Replies)
Discussion started by: rupeshkp728
0 Replies

12. Cybersecurity

Need patch policy help

I'm working on developing a patch policy for a mid-size and quickly growing company. Patches have been at the bottom of the totem pole for years. I possess the ability and care enough to straighten it out. However I'd like some others input on the best way to handle the patch policy. From when... (1 Reply)
Discussion started by: jlouki01
1 Replies

13. HP-UX

[Solved] Patching HP-UX 11.31 from DVD vs. ITRC

Howdy folks, in keeping my servers patched up to date, I normally use the swainv shell script to generate inventory.xml, upload it to ITRC for patch analysis, and then download the recommended bundle. I have a whole bunch of 11.31 servers that are not internet-connected now, but I do have the... (2 Replies)
Discussion started by: lupin..the..3rd
2 Replies

14. AIX

AIX server patching

Can anyone here help me in understanding how to patch AIX machine.Its all vulnerability patching and i have sent an attachment with this saying what needs to be patched.I have not done patching at all.Can anyone help me with the steps on how to do the Patching.Whoever is helping i think this is... (3 Replies)
Discussion started by: Revathi2089
3 Replies