Commit ec4a9181 authored by maruel@chromium.org's avatar maruel@chromium.org

Add --no-backup-if-mismatch so no .orig file is created when fuzzing occurs.

Nobody cares about those .orig files and they get in the way on the try server
for some specific license check.

R=cmp@chromium.org
BUG=152507


Review URL: https://chromiumcodereview.appspot.com/10983092

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@159329 0039d316-1c4b-4281-b951-d872f2087c98
parent ade83db1
...@@ -343,7 +343,13 @@ class SvnCheckout(CheckoutBase, SvnMixIn): ...@@ -343,7 +343,13 @@ class SvnCheckout(CheckoutBase, SvnMixIn):
self._check_output_svn( self._check_output_svn(
['copy', p.source_filename, p.filename]) ['copy', p.source_filename, p.filename])
if p.diff_hunks: if p.diff_hunks:
cmd = ['patch', '-p%s' % p.patchlevel, '--forward', '--force'] cmd = [
'patch',
'-p%s' % p.patchlevel,
'--forward',
'--force',
'--no-backup-if-mismatch',
]
stdout += subprocess2.check_output( stdout += subprocess2.check_output(
cmd, stdin=p.get(False), cwd=self.project_path) cmd, stdin=p.get(False), cwd=self.project_path)
elif p.is_new and not os.path.exists(filepath): elif p.is_new and not os.path.exists(filepath):
......
...@@ -307,7 +307,7 @@ class SvnCheckout(SvnBaseTest): ...@@ -307,7 +307,7 @@ class SvnCheckout(SvnBaseTest):
def testException(self): def testException(self):
self._check_exception( self._check_exception(
self._get_co(None), self._get_co(None),
'While running patch -p1 --forward --force;\n' 'While running patch -p1 --forward --force --no-backup-if-mismatch;\n'
'patching file chrome/file.cc\n' 'patching file chrome/file.cc\n'
'Hunk #1 FAILED at 3.\n' 'Hunk #1 FAILED at 3.\n'
'1 out of 1 hunk FAILED -- saving rejects to file ' '1 out of 1 hunk FAILED -- saving rejects to file '
...@@ -513,7 +513,7 @@ class ReadOnlyCheckout(SvnBaseTest): ...@@ -513,7 +513,7 @@ class ReadOnlyCheckout(SvnBaseTest):
def testException(self): def testException(self):
self._check_exception( self._check_exception(
self._get_co(None), self._get_co(None),
'While running patch -p1 --forward --force;\n' 'While running patch -p1 --forward --force --no-backup-if-mismatch;\n'
'patching file chrome/file.cc\n' 'patching file chrome/file.cc\n'
'Hunk #1 FAILED at 3.\n' 'Hunk #1 FAILED at 3.\n'
'1 out of 1 hunk FAILED -- saving rejects to file ' '1 out of 1 hunk FAILED -- saving rejects to file '
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment