• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Aucun tag

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

system/corennnnn


Commit MetaInfo

Révision42b1f638dba8ed02588e45d74aff8cb8ff84443a (tree)
l'heure2016-08-03 17:34:23
AuteurAndrew Boie <andrew.p.boie@inte...>
CommiterChih-Wei Huang

Message de Log

diskconfig: Fix disk_layout.conf size parsing

If the user was appending 'K' to their lengths (which is valid
but redundant) it was being treated as megabytes instead of
kilobytes.

Change-Id: I979ec4d01f1342de1f3209b946201ca87bad32a7

Change Summary

Modification

--- a/libdiskconfig/diskconfig.c
+++ b/libdiskconfig/diskconfig.c
@@ -76,7 +76,7 @@ parse_len(const char *str, uint64_t *plen)
7676 }
7777 } else {
7878 /* convert len to kilobytes */
79- if (multiple > 1024)
79+ if (multiple >= 1024)
8080 multiple >>= 10;
8181 *plen *= multiple;
8282