Added a copy method for octet strings.
This commit is contained in:
@@ -360,6 +360,15 @@ bool octetstring_init(
|
|||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool octetstring_copy(
|
||||||
|
BACNET_OCTET_STRING *octet_string_dest,
|
||||||
|
BACNET_OCTET_STRING *octet_string_src)
|
||||||
|
{
|
||||||
|
return octetstring_init(octet_string_dest,
|
||||||
|
octetstring_value(octet_string_src),
|
||||||
|
octetstring_length(octet_string_src));
|
||||||
|
}
|
||||||
|
|
||||||
/* returns false if the string exceeds capacity */
|
/* returns false if the string exceeds capacity */
|
||||||
bool octetstring_append(
|
bool octetstring_append(
|
||||||
BACNET_OCTET_STRING *octet_string,
|
BACNET_OCTET_STRING *octet_string,
|
||||||
|
|||||||
@@ -126,6 +126,9 @@ bool octetstring_init(
|
|||||||
BACNET_OCTET_STRING *octet_string,
|
BACNET_OCTET_STRING *octet_string,
|
||||||
uint8_t *value,
|
uint8_t *value,
|
||||||
size_t length);
|
size_t length);
|
||||||
|
bool octetstring_copy(
|
||||||
|
BACNET_OCTET_STRING *octet_string_dest,
|
||||||
|
BACNET_OCTET_STRING *octet_string_src);
|
||||||
/* returns false if the string exceeds capacity */
|
/* returns false if the string exceeds capacity */
|
||||||
bool octetstring_append(
|
bool octetstring_append(
|
||||||
BACNET_OCTET_STRING *octet_string,
|
BACNET_OCTET_STRING *octet_string,
|
||||||
|
|||||||
Reference in New Issue
Block a user