#include <stdlib.h>#include <stdio.h>#include <time.h>#include <stdint.h>Include dependency graph for utils.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.
Functions | |
| void * | check_malloc (size_t size) |
| void * | check_realloc (void *ptr, size_t size) |
| void * | check_calloc (size_t elements, size_t size) |
| char * | word_flatten (char **words, int start_word, int n) |
| unsigned long | data_hash (void *pack, unsigned long ecount, unsigned long esize, unsigned long elength, unsigned long offset, unsigned long hashsize) |
| uint64_t | data_hash64 (void *pack, unsigned long datalen) |
| unsigned long long | string_hash (char *string, unsigned long long size) |
| void | print_time (FILE *stream) |
| void | usage (char *pname) |
| void | casefold (char *string) |
| int | fcomp (const void *f1, const void *f2) |
Definition in file utils.h.
| void casefold | ( | char * | string | ) |
| void* check_calloc | ( | size_t | elements, | |
| size_t | size | |||
| ) |
A wrapper around calloc that spews if a NULL pointer is returned
| void* check_malloc | ( | size_t | size | ) |
A wrapper around malloc that spews if NULL is returned
| void* check_realloc | ( | void * | ptr, | |
| size_t | size | |||
| ) |
A wrapper around realloc that spews if a NULL pointer is returned
| unsigned long data_hash | ( | void * | pack, | |
| unsigned long | ecount, | |||
| unsigned long | esize, | |||
| unsigned long | elength, | |||
| unsigned long | offset, | |||
| unsigned long | hashsize | |||
| ) |
| uint64_t data_hash64 | ( | void * | pack, | |
| unsigned long | datalen | |||
| ) |
| int fcomp | ( | const void * | f1, | |
| const void * | f2 | |||
| ) |
| void print_time | ( | FILE * | stream | ) |
Print the current date and time in a nicely formatted way
| unsigned long long string_hash | ( | char * | string, | |
| unsigned long long | size | |||
| ) |
Hash a string using the Karp-Rubin string hashing algorithm
| void usage | ( | char * | pname | ) |
Print the usage information for this program
| char* word_flatten | ( | char ** | words, | |
| int | start_word, | |||
| int | n | |||
| ) |
Takes an array of words and returns a single string composed of all those words appended to each other, separated by spaces.
1.5.2