![]() |
pacemaker
1.1.18-7fdfbbe
Scalable High-Availability cluster resource manager
|
#include <glib.h>
#include <dirent.h>
#include <unistd.h>
#include <sys/types.h>
#include <crm/common/logging.h>
Go to the source code of this file.
Macros | |
#define | CRM_FAIL_COUNT_PREFIX "fail-count" |
#define | CRM_LAST_FAILURE_PREFIX "last-failure" |
Functions | |
char * | generate_series_filename (const char *directory, const char *series, int sequence, gboolean bzip) |
int | get_last_sequence (const char *directory, const char *series) |
void | write_last_sequence (const char *directory, const char *series, int sequence, int max) |
int | crm_chown_last_sequence (const char *directory, const char *series, uid_t uid, gid_t gid) |
gboolean | crm_is_writable (const char *dir, const char *file, const char *user, const char *group, gboolean need_both) |
void | crm_sync_directory (const char *name) |
char * | crm_read_contents (const char *filename) |
int | crm_write_sync (int fd, const char *contents) |
int | crm_set_nonblocking (int fd) |
int | crm_procfs_process_info (struct dirent *entry, char *name, int *pid) |
int | crm_procfs_pid_of (const char *name) |
unsigned int | crm_procfs_num_cores (void) |
void | crm_schema_init (void) |
void | crm_schema_cleanup (void) |
char * | crm_concat (const char *prefix, const char *suffix, char join) |
void | g_hash_destroy_str (gpointer data) |
long long | crm_int_helper (const char *text, char **end_text) |
bool | crm_starts_with (const char *str, const char *prefix) |
Check whether a string starts with a certain sequence. More... | |
gboolean | crm_ends_with (const char *s, const char *match) |
gboolean | crm_ends_with_ext (const char *s, const char *match) |
char * | add_list_element (char *list, const char *value) |
bool | crm_compress_string (const char *data, int length, int max, char **result, unsigned int *result_len) |
gint | crm_alpha_sort (gconstpointer a, gconstpointer b) |
Compare two strings alphabetically (case-insensitive) More... | |
#define CRM_FAIL_COUNT_PREFIX "fail-count" |
Definition at line 88 of file internal.h.
#define CRM_LAST_FAILURE_PREFIX "last-failure" |
Definition at line 89 of file internal.h.
char* add_list_element | ( | char * | list, |
const char * | value | ||
) |
gint crm_alpha_sort | ( | gconstpointer | a, |
gconstpointer | b | ||
) |
Compare two strings alphabetically (case-insensitive)
[in] | a | First string to compare |
[in] | b | Second string to compare |
int crm_chown_last_sequence | ( | const char * | directory, |
const char * | series, | ||
uid_t | uid, | ||
gid_t | gid | ||
) |
bool crm_compress_string | ( | const char * | data, |
int | length, | ||
int | max, | ||
char ** | result, | ||
unsigned int * | result_len | ||
) |
char* crm_concat | ( | const char * | prefix, |
const char * | suffix, | ||
char | join | ||
) |
gboolean crm_ends_with | ( | const char * | s, |
const char * | match | ||
) |
gboolean crm_ends_with_ext | ( | const char * | s, |
const char * | match | ||
) |
long long crm_int_helper | ( | const char * | text, |
char ** | end_text | ||
) |
gboolean crm_is_writable | ( | const char * | dir, |
const char * | file, | ||
const char * | user, | ||
const char * | group, | ||
gboolean | need_both | ||
) |
int crm_procfs_process_info | ( | struct dirent * | entry, |
char * | name, | ||
int * | pid | ||
) |
bool crm_starts_with | ( | const char * | str, |
const char * | prefix | ||
) |
Check whether a string starts with a certain sequence.
[in] | str | String to check |
[in] | match | Sequence to match against beginning of str |
TRUE
if str
begins with match, FALSE
otherwise char* generate_series_filename | ( | const char * | directory, |
const char * | series, | ||
int | sequence, | ||
gboolean | bzip | ||
) |
int get_last_sequence | ( | const char * | directory, |
const char * | series | ||
) |