MCPcopy Create free account
hub / github.com/ClusterLabs/pacemaker / generate_transition_magic

Function generate_transition_magic

lib/common/utils.c:813–828  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

811}
812
813char *
814generate_transition_magic(const char *transition_key, int op_status, int op_rc)
815{
816 int len = 80;
817 char *fail_state = NULL;
818
819 CRM_CHECK(transition_key != NULL, return NULL);
820
821 len += strlen(transition_key);
822
823 fail_state = calloc(1, len);
824 if (fail_state != NULL) {
825 snprintf(fail_state, len, "%d:%d;%s", op_status, op_rc, transition_key);
826 }
827 return fail_state;
828}
829
830gboolean
831decode_transition_magic(const char *magic, char **uuid, int *transition_id, int *action_id,

Callers 1

create_operation_updateFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected