Remove RefIndx == 0 condition, as BACnet norm allows this case (#539)
This commit is contained in:
@@ -76,13 +76,7 @@ static int Encode_RR_payload(uint8_t *apdu, BACNET_READ_RANGE_DATA *pRequest)
|
|||||||
/* We try and do some of the more generic error checking here to cut
|
/* We try and do some of the more generic error checking here to cut
|
||||||
* down on duplication of effort */
|
* down on duplication of effort */
|
||||||
|
|
||||||
if ((pRequest->RequestType == RR_BY_POSITION) &&
|
if (((PropInfo.RequestTypes & RR_ARRAY_OF_LISTS) == 0) &&
|
||||||
(pRequest->Range.RefIndex ==
|
|
||||||
0)) { /* First index is 1 so can't accept 0 */
|
|
||||||
pRequest->error_code =
|
|
||||||
ERROR_CODE_OTHER; /* I couldn't see anything more appropriate
|
|
||||||
so... */
|
|
||||||
} else if (((PropInfo.RequestTypes & RR_ARRAY_OF_LISTS) == 0) &&
|
|
||||||
(pRequest->array_index != 0) &&
|
(pRequest->array_index != 0) &&
|
||||||
(pRequest->array_index != BACNET_ARRAY_ALL)) {
|
(pRequest->array_index != BACNET_ARRAY_ALL)) {
|
||||||
/* Array access attempted on a non array property */
|
/* Array access attempted on a non array property */
|
||||||
|
|||||||
Reference in New Issue
Block a user