[elbe-devel] [PATCH] fix unit symbol for kibibyte
John Ogness
john.ogness at linutronix.de
Wed Jan 13 10:40:15 CET 2016
IEC 80000-13 defines the unit symbol for the kibibyte as KiB.
ATTENTION: This patch modifies the XML Schema Reference!
Signed-off-by: John Ogness <john.ogness at linutronix.de>
---
elbepack/dbsfed.xsd | 2 +-
elbepack/hdimg.py | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/elbepack/dbsfed.xsd b/elbepack/dbsfed.xsd
index c135321..2160197 100644
--- a/elbepack/dbsfed.xsd
+++ b/elbepack/dbsfed.xsd
@@ -1341,7 +1341,7 @@
</documentation>
</annotation>
<restriction base="string">
- <pattern value="(\d+(k|M|G|kB|MB|GB|kiB|MiB|GiB)?|remain)" />
+ <pattern value="(\d+(k|M|G|kB|MB|GB|KiB|MiB|GiB)?|remain)" />
</restriction>
</simpleType>
diff --git a/elbepack/hdimg.py b/elbepack/hdimg.py
index 39a95af..3c93138 100644
--- a/elbepack/hdimg.py
+++ b/elbepack/hdimg.py
@@ -166,7 +166,7 @@ def size_to_int( size ):
if size.endswith( "k" ):
unit = 1000
s = size[:-1]
- elif size.endswith( "kiB" ):
+ elif size.endswith( "KiB" ):
unit = 1024
s = size[:-3]
elif size.endswith( "kB" ):
--
1.7.10.4
More information about the elbe-devel
mailing list