summaryrefslogtreecommitdiff
path: root/usr.bin/patch/patch.c
AgeCommit message (Expand)Author
2022-08-03fix locate_hunk in empty filesOmar Polo
2022-08-03fix dwim for reversed patchesOmar Polo
2019-12-02Use getline(3) to handle lines longer than 8192 bytes in patch filesJeremie Courreges-Anglas
2019-06-28When system calls indicate an error they return -1, not some arbitraryTheo de Raadt
2019-06-28mkstemp() returns -1 on failureTheo de Raadt
2018-06-22Add --dry-run as synonym to -C/--check.Vadim Zhukov
2018-04-07Remove unused pathnames.h header since patch was refactoring into not invokinganton
2017-06-12rejname[] is also -r option buffer, and should be PATH_MAXTheo de Raadt
2016-01-04usage() should exit 2 here, not EXIT_SUCCESSGleydson Soares
2015-12-29fix exit status on pledge(2) failure.Gleydson Soares
2015-11-11exit() after perror() for pledge failure. Perhaps this got introducedTheo de Raadt
2015-10-16Add native support for ed-style diffs. No need to pledge "proc exec" anymore.Tobias Stoeckmann
2015-10-09Change all tame callers to namechange to pledge(2).Theo de Raadt
2015-10-07patch(1) can move to "stdio rpath wpath cpath tmppath fattr proc exec"Theo de Raadt
2015-10-04remove tame "proc". it is not useful, because the "ed" diffs requireTheo de Raadt
2015-10-03As pointed out by tobiasu, ed-style patches still use popen() and executeTheo de Raadt
2015-10-03patch appears to work fully with tame "stdio rpath wpath cpath tmppath fattr".Theo de Raadt
2014-12-13The function savestr allows NULL return values during Plan A patching so inTobias Stoeckmann
2014-12-08spacesTheo de Raadt
2014-11-26Prefer setvbuf() to setlinebuf() for portability; ok deraadt@Todd C. Miller
2013-11-26unsigned char casts for ctypeTheo de Raadt
2012-05-15Fix confusing patch(1) output on failure when using -C. FromTodd C. Miller
2010-07-24Send normal output to stdout instead of everything to stderr. ThisRay Lai
2009-10-28rcsid[] and sccsid[] and copyright[] are essentially unmaintained (andTheo de Raadt
2009-04-05If no patch can be found in input, in addition to complaining on stderr,Stefan Sperling
2008-08-20The code to detect multiple applied diffs to empty files I introduced 4Otto Moerbeek
2007-04-18adds a detailed synopsis to the man page; sorts options inIgor Sobrado
2006-03-11type police and assorted cleanup. From Lionel Fourquaux; ok ray@Otto Moerbeek
2004-11-19Write reject file in unified format if the original diff was inOtto Moerbeek
2004-09-14remove unused variableTheo de Raadt
2004-07-09Properly detect if a patch already has been applied, even if thereOtto Moerbeek
2004-06-18Unbreak handling of standard diffs (which have an empty context).Otto Moerbeek
2004-06-14Teach patch(1) to detect if a diff creating a file (or one addingOtto Moerbeek
2003-10-31o fairly major man page reorganizationTodd C. Miller
2003-08-10Do not add an extra newline at the end if the last line of the inputOtto Moerbeek
2003-08-10Warn if the diff is a context or unified diff and the contextOtto Moerbeek
2003-08-01- use stdbool.h instead of roll-your-own booleansOtto Moerbeek
2003-07-31Historically, patch would treat a bare -p as -p0. This contradictsTodd C. Miller
2003-07-31Print a maximum of one invalid line number warning per patch in a patch file.Otto Moerbeek
2003-07-30Add POSIX -i option; tedu@ OKTodd C. Miller
2003-07-29o add pathnames.hTodd C. Miller
2003-07-28minor knf and cleanups; otto okTheo de Raadt
2003-07-28Be more exact on how backup files are handled.Otto Moerbeek
2003-07-28Make patch(1) exit value match POSIX and be consistent with diff.Todd C. Miller
2003-07-25Add POSIX -b option but don't change the default beahvior wrt backupsTodd C. Miller
2003-07-23New version of invalid line number fix. Passes patch(1) regressions.Otto Moerbeek
2003-07-22Make rejname[] static to patch.c and crank its size to NAME_MAX+1Todd C. Miller
2003-07-22Use getopt_long() to parse options instead of rolling our own.Todd C. Miller
2003-07-22More cleanup.Otto Moerbeek
2003-07-21Back out invalid line number fix. It core dumps in some cases. Problem found byOtto Moerbeek