commit 4c36d1897211469da80eebfe98e49626eb3463de
Author: Arkadiusz MiĆkiewicz <[email protected]>
Date: Fri Mar 5 09:28:33 2021 +0100
Be sure that we got any comment actually.
rediff-patches.py | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/rediff-patches.py b/rediff-patches.py
index 2fb1986..beba06d 100755
--- a/rediff-patches.py
+++ b/rediff-patches.py
@@ -66,12 +66,14 @@ def unpack(spec, appsourcedir, builddir):
def patch_comment_get(patch):
patch_comment = ""
+ patch_got = False
with open(patch, 'rt') as f:
for line in f:
if line.startswith('diff ') or line.startswith('--- '):
+ patch_got = True
break
patch_comment += line
- return patch_comment
+ return patch_comment if patch_got else ""
def diff(diffdir_org, diffdir, builddir, patch_comment, output):
diffdir_org = os.path.basename(diffdir_org)
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/rpm-build-tools.git/commitdiff/4c36d1897211469da80eebfe98e49626eb3463de
_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit