diff options
author | Mike Lockwood <lockwood@android.com> | 2010-12-07 13:51:54 -0800 |
---|---|---|
committer | Mike Lockwood <lockwood@android.com> | 2010-12-07 17:16:20 -0800 |
commit | bf1dbd193827c05fcb017ea5a87953b47a75dbd5 (patch) | |
tree | 3117eadcd6e3bf803b2147e1c0aebee0185685b3 /media/mtp/MtpProperty.cpp | |
parent | e4880e421fba5f429f4c6d43ec41ae17902c1626 (diff) | |
download | frameworks_base-bf1dbd193827c05fcb017ea5a87953b47a75dbd5.zip frameworks_base-bf1dbd193827c05fcb017ea5a87953b47a75dbd5.tar.gz frameworks_base-bf1dbd193827c05fcb017ea5a87953b47a75dbd5.tar.bz2 |
MTP: Read property code before calling isDeviceProperty in MtpProperty::read()
Change-Id: I0b1493f3af5d9caac08327f9ffba91ee255d3d55
Signed-off-by: Mike Lockwood <lockwood@android.com>
Diffstat (limited to 'media/mtp/MtpProperty.cpp')
-rw-r--r-- | media/mtp/MtpProperty.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/media/mtp/MtpProperty.cpp b/media/mtp/MtpProperty.cpp index 3b38720..b095ce1 100644 --- a/media/mtp/MtpProperty.cpp +++ b/media/mtp/MtpProperty.cpp @@ -122,9 +122,8 @@ MtpProperty::~MtpProperty() { } void MtpProperty::read(MtpDataPacket& packet) { - bool deviceProp = isDeviceProperty(); - mCode = packet.getUInt16(); + bool deviceProp = isDeviceProperty(); mType = packet.getUInt16(); mWriteable = (packet.getUInt8() == 1); switch (mType) { |