Use b'foo' instead of _unicode_encode() where appropriate.
authorZac Medico <zmedico@gentoo.org>
Thu, 15 Jul 2010 03:32:33 +0000 (20:32 -0700)
committerZac Medico <zmedico@gentoo.org>
Thu, 15 Jul 2010 03:32:33 +0000 (20:32 -0700)
bin/repoman

index 65d076adc9a48d7eecedfafe9d0f16c41ce9c72b..235d4f079d0fabda0c6ea750d94d2cc9d6e8b383 100755 (executable)
@@ -2431,7 +2431,7 @@ else:
                        fd, commitmessagefile = tempfile.mkstemp(".repoman.msg")
                        mymsg = os.fdopen(fd, "wb")
                        mymsg.write(_unicode_encode(commitmessage))
-                       mymsg.write("\n (Unsigned Manifest commit)")
+                       mymsg.write(b"\n (Unsigned Manifest commit)")
                        mymsg.close()
 
                        commit_cmd = [vcs]
@@ -2536,9 +2536,9 @@ else:
                # strip the closing parenthesis
                mymsg.write(_unicode_encode(commitmessage[:-1]))
                if signed:
-                       mymsg.write(_unicode_encode(", signed Manifest commit)"))
+                       mymsg.write(b", signed Manifest commit)")
                else:
-                       mymsg.write(_unicode_encode(", unsigned Manifest commit)"))
+                       mymsg.write(b", unsigned Manifest commit)")
                mymsg.close()
 
                commit_cmd = []