]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Scripts/BinToPcd.py
BaseTools/BinToPcd: Encode string returned from ByteArray()
[mirror_edk2.git] / BaseTools / Scripts / BinToPcd.py
index 25b74f60049335d57f0878ed69e40fe0c6f0c5d9..1495a36933c4ce5516aeb6bd48f4e8465da20fc3 100644 (file)
@@ -70,7 +70,8 @@ if __name__ == '__main__':
         #\r
         # Return a PCD value of the form '{0x01, 0x02, ...}' along with the PCD length in bytes\r
         #\r
-        return '{' + (', '.join (['0x{Byte:02X}'.format (Byte = Item) for Item in Buffer])) + '}', len (Buffer)\r
+        PcdValue = '{' + ', '.join (['0x{Byte:02X}'.format (Byte = Item) for Item in Buffer]) + '}'\r
+        return PcdValue.encode (), len (Buffer)\r
 \r
     #\r
     # Create command line argument parser object\r