"Attribute to set\n", "attr-name", 'n'); fprintf(stream, "\t--%s (-%c) <string>\t: " "Which section of the CIB to set the attribute: (%s|%s|%s)\n", "type", 't', XML_CIB_TAG_NODES, XML_CIB_TAG_STATUS, XML_CIB_TAG_CRMCONFIG); fprintf(stream, "\t    -t=%s options: -(U|u) -n [-s]\n", XML_CIB_TAG_NODES); fprintf(stream, "\t    -t=%s options: -(U|u) -n [-s]\n", XML_CIB_TAG_STATUS); fprintf(stream, "\t    -t=%s options: -n [-s]\n", XML_CIB_TAG_CRMCONFIG);
"Host name\n", "host-uname", 'H');
usage(const char *cmd, int exit_status){	FILE *stream;	stream = exit_status ? stderr : stdout;	if(safe_str_eq(cmd, "crm_master")) {		fprintf(stream, "usage: %s [-?VQ] -(D|G|v) [-l]\n", cmd);	} else if(safe_str_eq(cmd, "crm_standby")) {		fprintf(stream, "usage: %s [-?V] -(u|U) -(D|G|v) [-l]\n", cmd);	} else {		fprintf(stream, "usage: %s [-?V] -(D|G|v) [options]\n", cmd);	}		fprintf(stream, "Options\n");	fprintf(stream, "\t--%s (-%c)\t: this help message\n", "help", '?');	fprintf(stream, "\t--%s (-%c)\t: "		"turn on debug info. additional instances increase verbosity\n",		"verbose", 'V');	fprintf(stream, "\t--%s (-%c)\t: Print only the value on stdout"		" (use with -G)\n", "quiet", 'Q');	fprintf(stream, "\t--%s (-%c)\t: "		"Retrieve rather than set the attribute\n", "get-value", 'G');	fprintf(stream, "\t--%s (-%c)\t: "		"Delete rather than set the attribute\n", "delete-attr", 'D');	fprintf(stream, "\t--%s (-%c) <string>\t: "		"Value to use (ignored with -G)\n", "attr-value", 'v');	if(safe_str_eq(cmd, "crm_master")) {		fprintf(stream, "\t--%s (-%c) <string>\t: "			"How long the preference lasts (reboot|forever)\n",			"lifetime", 'l');		exit(exit_status);	} else if(safe_str_eq(cmd, "crm_standby")) {		fprintf(stream, "\t--%s (-%c) <node_uuid>\t: "			"UUID of the node to change\n", "node-uuid", 'u');		fprintf(stream, "\t--%s (-%c) <node_uuid>\t: "			"uname of the node to change\n", "node-uname", 'U');		fprintf(stream, "\t--%s (-%c) <string>\t: "			"How long the preference lasts (reboot|forever)\n"			"\t    If a forever value exists, it is ALWAYS used by the CRM\n"			"\t    instead of any reboot value\n", "lifetime", 'l');		exit(exit_status);	}		fprintf(stream, "\t--%s (-%c) <node_uuid>\t: "		"UUID of the node to change\n", "node-uuid", 'u');	fprintf(stream, "\t--%s (-%c) <node_uuid>\t: "		"uname of the node to change\n", "node-uname", 'U');	fprintf(stream, "\t--%s (-%c) <string>\t: "		"Set of attributes in which to read/write the attribute\n",		"set-name", 's');	fprintf(stream, "\t--%s (-%c) <string>\t: "		"Attribute to set\n", "attr-name", 'n');	fprintf(stream, "\t--%s (-%c) <string>\t: "		"Which section of the CIB to set the attribute: (%s|%s|%s)\n",		"type", 't',		XML_CIB_TAG_NODES, XML_CIB_TAG_STATUS, XML_CIB_TAG_CRMCONFIG);	fprintf(stream, "\t    -t=%s options: -(U|u) -n [-s]\n", XML_CIB_TAG_NODES);	fprintf(stream, "\t    -t=%s options: -(U|u) -n [-s]\n", XML_CIB_TAG_STATUS);	fprintf(stream, "\t    -t=%s options: -n [-s]\n", XML_CIB_TAG_CRMCONFIG);	fflush(stream);	exit(exit_status);}