Questions tagged [patch]

A patch is a piece of software designed to fix problems with, or update a computer program or its supporting data. This includes fixing security vulnerabilities and other bugs, and improving the usability or performance.

Programmers publish and apply patches in various forms. Because proprietary software authors withhold their source code, their patches are distributed as binary executables instead of source. This type of patch modifies the program executable—the program the user actually runs—either by modifying the binary file to include the fixes or by completely replacing it.

Patches can also circulate in the form of source code modifications. In these cases, the patches consist of textual differences between two source code files. These types of patches commonly come out of open source projects. In these cases, developers expect users to compile the new or changed files themselves.

Because the word "patch" carries the connotation of a small fix, large fixes may use different nomenclature. Bulky patches or patches that significantly change a program may circulate as "service packs" or as "software updates". Microsoft Windows NT and its successors (including Windows 2000, Windows XP, and later versions) use the "service pack" terminology.

In several Unix-like systems, particularly Linux, updates between releases are delivered as new software packages. These updates are in the same format as the original installation so they can be used either to update an existing package in-place (effectively patching) or be used directly for new installations.

2809 questions
1
vote
1 answer

Merge conflict - No rebase in progress? Why am I on master?

I am in the middle of a confusing merge conflict between my branch (fix/disambiguate-property-meaning) and another repo's staging branch that would like to merge in my updated pull request. At present, I find myself on some master branch awaiting…
1
vote
1 answer

Git commit, then rebase from master, then making small changes to the original commit

Ok, this one is a little complicated and most probably is very specific. Let me try to explain. Lets say I pull this git repo into my local drive. Then make a number of changes. As these changes are in many different files and are aimed for…
Haris
  • 12,120
  • 6
  • 43
  • 70
1
vote
0 answers

WIN10 "Unknown publisher" UAC-warning with program compiled with MinGW and "patch" in name

I actually found a solution, but the problem is so odd I want to tell nevertheless. On Win10 I compiled a little program once with MinGW and VS2012. The VS2012-version worked without issues, but the MinGW-version popped up an UAC warning "Do you…
Joachim
  • 891
  • 9
  • 12
1
vote
1 answer

Golang: calculate diff between two array of bytes and patch an array

I'm trying to find the difference between two byte ararys and store the delta. I've read this documentation https://golang.org/pkg/bytes/ but I didn't find anything that show how to find the diff. Thanks.
Alex. b
  • 669
  • 2
  • 10
  • 18
1
vote
0 answers

Using a *.patch file to change a Linux kernel's source

I have been provided with a patch file for Linux kernel 3.18.3 and must use it with a custom Linux kernel scheduler. By default, it's used in "Debian GNU Linux Wheezy 7.8.2 (32bit) - linux 3.18.3". Details here. But now, I want to use it with Linux…
chimsau93
  • 11
  • 2
1
vote
1 answer

removing middle lines of a git chunk

I am trying to remove a small amount of lines of a diff with git patch -p foobar. The resulting chunk is like this (without git's comments): @@ -142,4 +150,26 @@ { perr( "fcntl" ); + return stream_s(); + } + return stream; +} + +int…
user3459474
  • 145
  • 1
  • 7
1
vote
1 answer

Apply patch to solr version 5.2.1

I am a new user of Solr and I want to use this classification module ? but I don't know how to apply the patch mentioned in the previous link. I am working with Solr 5.2.1 on Ubuntu. I found this page that describe how to work with patches but I…
tonnebrre
  • 11
  • 2
1
vote
1 answer

Override partial_update (PATCH DJANGO)

I have a simple PATCH method, where I sent a bunch of paramaters to my object Foo, including a parameter new_bar. I want to first patch all the other fields, and then append new_bar to the current obejcts bar data. I'm having issues where Django…
DaynaJuliana
  • 1,144
  • 1
  • 14
  • 33
1
vote
1 answer

Apply local patch to new GIT version

There is a large program product, I've downloaded it's sources in ZIP file a few months ago. (ver. 3.7.28 at that time). I was working hard on few specific patches (about 70 files in different subfolders were created or modified). I've noticed their…
Sarah
  • 11
  • 1
1
vote
1 answer

C fread/fwrite behaves weird when dealing with newlines

I am currently trying to create a binary byte patcher but got stuck at one little issue. When trying to read the input file byte by byte and simultanously writing these bytes to an output file, newline characters are somehow doubled. An input like…
McSebi
  • 129
  • 2
  • 11
1
vote
0 answers

Android expansion (obb) patch file version number

I have uploaded my application to the Play Store with a huge expansion (obb) file. Everything's working fine, no problem with that. But now I have to upload a small update to the expansion file. I want to use the patch expansion file because I don't…
Blasius
  • 29
  • 3
1
vote
1 answer

how to get linux patch util to use env var in patch file

I am using omnibus to build a cli package, in which I have a patch I use to inject a few things into a file. The patch itself is a git diff. I want to use an environment variable as part of the content. Something like: diff --git a/cli/common.py…
Gil Zellner
  • 889
  • 1
  • 9
  • 20
1
vote
1 answer

Assign Turtles to Random Empty Patch

In my setup, I am using the following code to create agents called "darks", and these agents are assigned to a designated set of patches (free-patches). I am trying to have each turtle assigned to a random patch within the designated area without…
HS3
  • 25
  • 5
1
vote
1 answer

Rails integration test syntax - using get :edit vs get edit_user_path

I'm going through Hartl's exercises in chapter 9, and got to the part about writing integration test for Requiring logged-in users . I notice that Listing 9.17 (i) uses get :edit, id: @user whereas Listing 9.14 (ii) uses: get…
1
vote
1 answer

How to create patches?

I am using Git-Extensions for Windows. I want to create patches from yesterday specific user automatically, so I need command code e.g: git format-patch from date_from to date_to user my_user Is it possible? Command line example would be great.
Edijs Kolesnikovičs
  • 1,627
  • 3
  • 18
  • 34