Add WPM workaround for BTL Specified Test 9.23.2.X5 (#548)

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
This commit is contained in:
Steve Karg
2023-12-21 09:52:32 -06:00
committed by GitHub
parent 19539c3fd5
commit 548b2ea580
+9
View File
@@ -92,6 +92,15 @@ static int write_property_multiple_decode(uint8_t *apdu,
(long)wp_data->array_index);
if (device_write_property) {
if (device_write_property(wp_data) == false) {
/* Workaround BTL Specified Test 9.23.2.X5 */
if ((wp_data->error_class ==
ERROR_CLASS_PROPERTY) &&
(wp_data->error_code ==
ERROR_CODE_INVALID_DATA_TYPE)) {
wp_data->error_class = ERROR_CLASS_SERVICES;
wp_data->error_code =
ERROR_CODE_INVALID_TAG;
}
return BACNET_STATUS_ERROR;
}
}