Sophie

Sophie

distrib > Scientific%20Linux > 5x > x86_64 > by-pkgid > d536e3b2143fe88c174c968d683c0f4f > files > 28

conga-0.12.2-24.el5_6.1.src.rpm

diff -up conga-0.12.2/ricci/ricci/main.cpp.bz602459 conga-0.12.2/ricci/ricci/main.cpp
--- conga-0.12.2/ricci/ricci/main.cpp.bz602459	2009-05-21 08:35:23.000000000 -0500
+++ conga-0.12.2/ricci/ricci/main.cpp	2010-08-10 15:54:41.000000000 -0500
@@ -42,13 +42,22 @@ bool foreground = false;
 bool debug = false;
 bool advertise_cluster = false;
 
+void print_help(void) {
+        printf("Usage: ricci [options]\n\
+   -c         Announce cluster name and OS to unauthenticated clients.\n\
+   -d         Enable debugging.\n\
+   -f         Run in the foreground.\n\
+   -h         Print this help dialog.\n\
+   -u <UID>   Run with the specified uid.\n");
+}
+
 int main(int argc, char** argv)
 {
 	uint32_t uid = 0;
 	int32_t ricci_port = RICCI_SERVER_PORT;
 
 	int rv;
-	while ((rv = getopt(argc, argv, "cdfu:p:")) != EOF) {
+	while ((rv = getopt(argc, argv, "cdfhu:p:")) != EOF) {
 		switch (rv) {
 			case 'c':
 				advertise_cluster = true;
@@ -62,6 +71,10 @@ int main(int argc, char** argv)
 				foreground = true;
 				break;
 
+			case 'h':
+				print_help();
+				exit(0);
+
 			case 'p':
 				if (optarg != NULL) {
 					uint32_t port;