Relax assertion criteria in HIDL sensors convert code
Because this code may be used to translate from/between subsequent
sensor types (e.g. new AIDL sensor types), relax the assertion
criteria to allow this generic conversion.
Bug: 215702376
Test: Compile
Change-Id: I40b67aa91d5e0d35199b561d32b2d7f7d59a4ac4
diff --git a/sensors/1.0/default/convert.cpp b/sensors/1.0/default/convert.cpp
index 53ceb0d..43ee327 100644
--- a/sensors/1.0/default/convert.cpp
+++ b/sensors/1.0/default/convert.cpp
@@ -190,8 +190,6 @@
}
default: {
- CHECK_GE((int32_t)dst->sensorType, (int32_t)SensorType::DEVICE_PRIVATE_BASE);
-
memcpy(dst->u.data.data(), src.data, 16 * sizeof(float));
break;
}
@@ -330,9 +328,6 @@
}
default: {
- CHECK_GE((int32_t)src.sensorType,
- (int32_t)SensorType::DEVICE_PRIVATE_BASE);
-
memcpy(dst->data, src.u.data.data(), 16 * sizeof(float));
break;
}