Convert the property list values into int32_t to support the larger property values when an int is 8-bit or 16-bit. (#1145)
This commit is contained in:
+12
-12
@@ -16,7 +16,7 @@
|
||||
|
||||
/* index and text pairs */
|
||||
typedef const struct {
|
||||
const unsigned index; /* index number that matches the text */
|
||||
const uint32_t index; /* index number that matches the text */
|
||||
const char *pString; /* text pair - use NULL to end the list */
|
||||
} INDTEXT_DATA;
|
||||
|
||||
@@ -31,29 +31,29 @@ extern "C" {
|
||||
the first index where the string was found. */
|
||||
BACNET_STACK_EXPORT
|
||||
bool indtext_by_string(
|
||||
INDTEXT_DATA *data_list, const char *search_name, unsigned *found_index);
|
||||
INDTEXT_DATA *data_list, const char *search_name, uint32_t *found_index);
|
||||
/* case insensitive version */
|
||||
BACNET_STACK_EXPORT
|
||||
bool indtext_by_istring(
|
||||
INDTEXT_DATA *data_list, const char *search_name, unsigned *found_index);
|
||||
INDTEXT_DATA *data_list, const char *search_name, uint32_t *found_index);
|
||||
/* Searches for a matching string and returns the index to the string
|
||||
or the default_index if the string is not found. */
|
||||
BACNET_STACK_EXPORT
|
||||
unsigned indtext_by_string_default(
|
||||
INDTEXT_DATA *data_list, const char *search_name, unsigned default_index);
|
||||
uint32_t indtext_by_string_default(
|
||||
INDTEXT_DATA *data_list, const char *search_name, uint32_t default_index);
|
||||
/* case insensitive version */
|
||||
BACNET_STACK_EXPORT
|
||||
unsigned indtext_by_istring_default(
|
||||
INDTEXT_DATA *data_list, const char *search_name, unsigned default_index);
|
||||
uint32_t indtext_by_istring_default(
|
||||
INDTEXT_DATA *data_list, const char *search_name, uint32_t default_index);
|
||||
/* for a given index, return the matching string,
|
||||
or NULL if not found */
|
||||
BACNET_STACK_EXPORT
|
||||
const char *indtext_by_index(INDTEXT_DATA *data_list, unsigned index);
|
||||
const char *indtext_by_index(INDTEXT_DATA *data_list, uint32_t index);
|
||||
/* for a given index, return the matching string,
|
||||
or default_name if not found */
|
||||
BACNET_STACK_EXPORT
|
||||
const char *indtext_by_index_default(
|
||||
INDTEXT_DATA *data_list, unsigned index, const char *default_name);
|
||||
INDTEXT_DATA *data_list, uint32_t index, const char *default_name);
|
||||
/* for a given index, return the matching string,
|
||||
or default_name if not found.
|
||||
if the index is before the split,
|
||||
@@ -61,14 +61,14 @@ const char *indtext_by_index_default(
|
||||
BACNET_STACK_EXPORT
|
||||
const char *indtext_by_index_split_default(
|
||||
INDTEXT_DATA *data_list,
|
||||
unsigned index,
|
||||
unsigned split_index,
|
||||
uint32_t index,
|
||||
uint32_t split_index,
|
||||
const char *before_split_default_name,
|
||||
const char *default_name);
|
||||
|
||||
/* returns the number of elements in the list */
|
||||
BACNET_STACK_EXPORT
|
||||
unsigned indtext_count(INDTEXT_DATA *data_list);
|
||||
uint32_t indtext_count(INDTEXT_DATA *data_list);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user