From 0fd14d64fd3b59d735f730e66a1da0d0255c5a14 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Tue, 17 Oct 2006 21:32:43 +0000 Subject: [PATCH] Make empty digest-* files 0 bytes instead of 1 byte. Thanks to Sven Wegener for reporting this. svn path=/main/trunk/; revision=4743 --- pym/portage_manifest.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/pym/portage_manifest.py b/pym/portage_manifest.py index aa6f0c015..1266e33df 100644 --- a/pym/portage_manifest.py +++ b/pym/portage_manifest.py @@ -252,8 +252,12 @@ class Manifest(object): else: raise if update_digest: - write_atomic(dname, - "\n".join(self._createDigestLines1(distlist, self.fhashdict))+"\n") + mylines = self._createDigestLines1(distlist, self.fhashdict) + if mylines: + mylines = "\n".join(mylines) + "\n" + else: + mylines = "" + write_atomic(dname, mylines) rval.append(dname) return rval -- 2.26.2