Deleted Added
sdiff udiff text old ( 6654:4c84e771cca7 ) new ( 7777:369f90d32e2e )
full compact
1# Copyright (c) 2005 The Regents of The University of Michigan
2# All rights reserved.
3#
4# Redistribution and use in source and binary forms, with or without
5# modification, are permitted provided that the following conditions are
6# met: redistributions of source code must retain the above copyright
7# notice, this list of conditions and the following disclaimer;
8# redistributions in binary form must reproduce the above copyright

--- 234 unchanged lines hidden (view full) ---

243 elif value.endswith('MB'):
244 return long(value[:-2]) * mebi
245 elif value.endswith('kB'):
246 return long(value[:-2]) * kibi
247 elif value.endswith('B'):
248 return long(value[:-1])
249
250 raise ValueError, "cannot convert '%s' to memory size" % value