bugGNU patch - Bugs: bug #44102, Patch doesn't check old file mode


bug #44102: Patch doesn't check old file mode

Submitted by:  Andreas Gruenbacher <agruen>
Submitted on:  Wed 28 Jan 2015 10:09:18 AM UTC  
Category:  None Severity:  3 - Normal
Item Group:  None Status:  None
Privacy:  Public Assigned to:  None
Open/Closed:  Open

Add a New Comment(Rich Markup)

You are not logged in

Please log in, so followups can be emailed to you.


Wed 28 Jan 2015 10:09:18 AM UTC, original submission:

The following patch creates a file with mode 0644 and then changes the file mode from 0755 to 0644. Patch doesn't
recognize that the file has the wrong file mode and happily
applies the second patch as well; it should complain.

diff --git a/f b/f
new file mode 100644
index 0000000..257cc56
--- /dev/null
+++ b/f
@@ -0,0 +1 @@
diff --git a/f b/f
old mode 100755
new mode 100644

Andreas Gruenbacher <agruen>
Project Administrator


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by agruen (Submitted the item)

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.




    No changes have been made to this item

    Back to the top

    Powered by Savane 3.3