Utility functions that are missing in string.h  
More...
Utility functions that are missing in string.h 
Definition in file string_utils.h.
#include <assert.h>#include <errno.h>#include <stdint.h>#include <string.h>#include <strings.h>#include <sys/types.h>#include "flash_utils.h"#include "modules.h"
 Include dependency graph for string_utils.h:Go to the source code of this file.
Data Structures | |
| struct | string_writer_t | 
| String Writer structure.  More... | |
Functions | |
| static void | string_writer_init (string_writer_t *sw, void *buffer, size_t len) | 
| Initialize a string writer structure.  More... | |
| static size_t | string_writer_len (const string_writer_t *sw) | 
| Get the size of the string contained by the string writer.  More... | |
| static const char * | string_writer_str (const string_writer_t *sw) | 
| Get the string contained by the string writer.  More... | |
| int | swprintf (string_writer_t *sw, FLASH_ATTR const char *restrict format,...) | 
| Write a formatted string to a buffer The string will be truncated if there is not enough space left in the destination buffer.  More... | |
| static void | explicit_bzero (void *dest, size_t n_bytes) | 
Like memset(dest, 0, n_bytes), but secure.  More... | |
| ssize_t | strscpy (char *dest, const char *src, size_t count) | 
| Copy the string, or as much of it as fits, into the dest buffer.  More... | |
| const void * | memchk (const void *data, uint8_t c, size_t len) | 
| Check if the entire buffer is filled with the same byte.  More... | |
| void | reverse_buf (void *buf, size_t len) | 
| Reverse the order of bytes in a buffer.  More... | |