#include <stdlib.h>#include <string.h>#include <strings.h>#include <ctype.h>#include "common/common_types.h"
Go to the source code of this file.
Functions | |
| char *EXPORT() | strscpy (char *dest, const char *src, size_t size) |
| char *EXPORT() | strscat (char *dest, const char *src, size_t size) |
| void EXPORT() | str_trim (char **ptr) |
| void EXPORT() str_trim | ( | char ** | ptr | ) |
Removes leading and trailing whitespaces from a string. Instead of moving characters around, it will change the pointer to the beginning of the buffer.
| ptr | pointer to string-pointer |
Definition at line 106 of file string.c.
Referenced by netaddr_from_string().
| char* EXPORT() strscat | ( | char * | dest, | |
| const char * | src, | |||
| size_t | size | |||
| ) |
A safer version of strncat that ensures that the target buffer will be null-terminated if its size is greater than zero.
If the target buffer is already full, it will not be changed.
| dest | target string buffer | |
| src | source string buffer | |
| size | size of target buffer |
Definition at line 84 of file string.c.
References strscpy().
Referenced by name_constructor(), name_init(), read_cfg(), read_cfg_cat(), and txtinfo_enable().

| char* EXPORT() strscpy | ( | char * | dest, | |
| const char * | src, | |||
| size_t | size | |||
| ) |
A safer version of strncpy that ensures that the destination string will be null-terminated if its length is greater than 0.
| dest | target string buffer | |
| src | source string buffer | |
| size | size of target buffer |
Definition at line 58 of file string.c.
Referenced by bind_socket_to_device(), calculate_if_metric(), check_wireless_interface(), chk_if_changed(), decap_namemsg(), get_ipv6_address(), GetIntInfo(), inet_ntop4(), inet_ntop6(), lq_etxff_print_link_entry_lq(), lq_etxfpm_print_link_entry_lq(), main(), name_constructor(), name_init(), netaddr_from_string(), olsr_com_parse_http(), olsr_get_linkcost_text(), olsr_sockaddr_to_string(), os_init_interface(), os_interface_set_state(), os_is_interface_up(), read_cfg(), read_cfg_cat(), secure_plugin_init(), set_plugin_string(), strscat(), txtinfo_enable(), txtinfo_hna(), txtinfo_interfaces(), txtinfo_link(), txtinfo_mid(), txtinfo_neigh(), txtinfo_routes(), txtinfo_topology(), win32_strerror(), and zebra_connect().
1.6.3