libaacs | branch: master | npzacs <npz...@gmail.com> | Sun Jul 22 16:32:13 2018 
+0300| [8f12cbf3ee58ec08a0306486e8708009228923b0] | committer: npzacs

Simplify

> http://git.videolan.org/gitweb.cgi/libaacs.git/?a=commit;h=8f12cbf3ee58ec08a0306486e8708009228923b0
---

 src/libaacs/mmc.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/src/libaacs/mmc.c b/src/libaacs/mmc.c
index 6bf2121..7898380 100644
--- a/src/libaacs/mmc.c
+++ b/src/libaacs/mmc.c
@@ -225,17 +225,16 @@ static int _mmc_check_aacs(MMC *mmc)
     if (_mmc_get_configuration(mmc, 0x010d, buf, 16)) {
         uint16_t feature = MKINT_BE16(buf+8);
         if (feature == 0x010d) {
+            mmc->read_drive_cert = !!(buf[4+8] & 0x10);
             BD_DEBUG(DBG_MMC, "AACS feature descriptor:\n");
             BD_DEBUG(DBG_MMC, "  AACS version: %d\n", buf[7+8]);
             BD_DEBUG(DBG_MMC, "  AACS active: %d\n", buf[2+8] & 1);
             BD_DEBUG(DBG_MMC, "  Binding Nonce generation support: %d\n", 
buf[4+8] & 1);
             BD_DEBUG(DBG_MMC, "  Binding Nonce block count: %d\n", buf[5+8]);
             BD_DEBUG(DBG_MMC, "  Bus encryption support: %d\n", !!(buf[4+8] & 
2));
-            BD_DEBUG(DBG_MMC, "  Read drive certificate: %d\n", !!(buf[4+8] & 
0x10));
+            BD_DEBUG(DBG_MMC, "  Read drive certificate: %d\n", 
mmc->read_drive_cert);
             BD_DEBUG(DBG_MMC, "  AGID count: %d\n", buf[6+8] & 0xf);
 
-            mmc->read_drive_cert = !!(buf[4+8] & 0x10);
-
             return buf[2+8] & 1;
         }
         BD_DEBUG(DBG_MMC, "incorrect feature ID %04x\n", feature);

_______________________________________________
libaacs-devel mailing list
libaacs-devel@videolan.org
https://mailman.videolan.org/listinfo/libaacs-devel

Reply via email to