From 72599b5500ebdd0c418a0ef1e2c93c833bd31d75 Mon Sep 17 00:00:00 2001 From: Ed Bartosh Date: Tue, 2 Jun 2015 17:02:03 +0300 Subject: wic: Make _ptable_format public Names with one leasding underscore considered protected in Python. _ptable_format is accessed outside of its class. Made it public by removing underscore. This pylint warning should be fixed now: Access to a protected member _ptable_format of a client class Signed-off-by: Ed Bartosh Signed-off-by: Ross Burton --- scripts/lib/wic/plugins/source/bootimg-pcbios.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'scripts/lib/wic/plugins/source/bootimg-pcbios.py') diff --git a/scripts/lib/wic/plugins/source/bootimg-pcbios.py b/scripts/lib/wic/plugins/source/bootimg-pcbios.py index ab62b7a9e9..1c3c6e605c 100644 --- a/scripts/lib/wic/plugins/source/bootimg-pcbios.py +++ b/scripts/lib/wic/plugins/source/bootimg-pcbios.py @@ -44,12 +44,12 @@ class BootimgPcbiosPlugin(SourcePlugin): disk image. In this case, we install the MBR. """ mbrfile = "%s/syslinux/" % bootimg_dir - if cr._ptable_format == 'msdos': + if cr.ptable_format == 'msdos': mbrfile += "mbr.bin" - elif cr._ptable_format == 'gpt': + elif cr.ptable_format == 'gpt': mbrfile += "gptmbr.bin" else: - msger.error("Unsupported partition table: %s" % cr._ptable_format) + msger.error("Unsupported partition table: %s" % cr.ptable_format) if not os.path.exists(mbrfile): msger.error("Couldn't find %s. If using the -e option, do you have the right MACHINE set in local.conf? If not, is the bootimg_dir path correct?" % mbrfile) @@ -104,7 +104,7 @@ class BootimgPcbiosPlugin(SourcePlugin): kernel = "/vmlinuz" syslinux_conf += "KERNEL " + kernel + "\n" - if cr._ptable_format in ('msdos', 'gpt'): + if cr.ptable_format in ('msdos', 'gpt'): rootstr = rootdev else: raise ImageError("Unsupported partition table format found") -- cgit 1.2.3-korg