[Openais] [PATCH]: openais/trunk: Remove printf from timer service library

Ryan O'Hara rohara at redhat.com
Wed Jul 8 11:39:25 PDT 2009


Remove printf from timer service library.

Ryan

-------------- next part --------------
Index: lib/tmr.c
===================================================================
--- lib/tmr.c	(revision 2034)
+++ lib/tmr.c	(working copy)
@@ -68,7 +68,7 @@
 	SaTmrHandleT tmrHandle;
 };
 
-DECLARE_HDB_DATABASE(tmrHandleDatabase,NULL);
+DECLARE_HDB_DATABASE (tmrHandleDatabase, NULL);
 
 static SaVersionT tmrVersionsSupported[] = {
 	{ 'A', 1, 1 }
@@ -88,9 +88,6 @@
 	struct tmrInstance *tmrInstance;
 	SaAisErrorT error = SA_AIS_OK;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTmrInitialize\n");
-
 	if (tmrHandle == NULL) {
 		error = SA_AIS_ERR_INVALID_PARAM;
 		goto error_exit;
@@ -151,9 +148,6 @@
 	SaAisErrorT error = SA_AIS_OK;
 	int fd;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTmrSelectionObjectGet\n");
-
 	if (selectionObject == NULL) {
 		error = SA_AIS_ERR_INVALID_PARAM;
 		goto error_exit;
@@ -220,9 +214,9 @@
 
 		if (dispatch_data == NULL) {
 			if (dispatchFlags == CPG_DISPATCH_ALL) {
-				break; /* exit do while cont is 1 loop */
+				break;
 			} else {
-				continue; /* next poll */
+				continue;
 			}
 		}
 
@@ -274,9 +268,6 @@
 	struct tmrInstance *tmrInstance;
 	SaAisErrorT error = SA_AIS_OK;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTmrFinalize\n");
-
 	error = hdb_error_to_sa(hdb_handle_get (&tmrHandleDatabase, tmrHandle, (void *)&tmrInstance));
 	if (error != SA_AIS_OK) {
 		goto error_exit;
@@ -313,10 +304,6 @@
 	struct res_lib_tmr_timerstart res_lib_tmr_timerstart;
 	struct iovec iov;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTmrTimerStart { data=%p }\n",
-		(void *)(timerData));
-
 	if ((timerAttributes == NULL) || (callTime == NULL) || (timerId == NULL)) {
 		error = SA_AIS_ERR_INVALID_PARAM;
 		goto error_exit;
@@ -394,10 +381,6 @@
 	struct res_lib_tmr_timerreschedule res_lib_tmr_timerreschedule;
 	struct iovec iov;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTmrTimerReschedule { id=%u }\n",
-		(unsigned int)(timerId));
-
 	if ((timerAttributes == NULL) || (callTime == NULL)) {
 		error = SA_AIS_ERR_INVALID_PARAM;
 		goto error_exit;
@@ -457,10 +440,6 @@
 	struct res_lib_tmr_timercancel res_lib_tmr_timercancel;
 	struct iovec iov;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTmrTimerCancel { id=%u }\n",
-		(unsigned int)(timerId));
-
 	if (timerDataP == NULL) {
 		error = SA_AIS_ERR_INVALID_PARAM;
 		goto error_exit;
@@ -511,10 +490,6 @@
 	struct res_lib_tmr_periodictimerskip res_lib_tmr_periodictimerskip;
 	struct iovec iov;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTmrPeriodicTimerSkip { id=%u }\n",
-		(unsigned int)(timerId));
-
 	error = hdb_error_to_sa(hdb_handle_get (&tmrHandleDatabase, tmrHandle, (void *)&tmrInstance));
 	if (error != SA_AIS_OK) {
 		goto error_exit;
@@ -557,10 +532,6 @@
 	struct res_lib_tmr_timerremainingtimeget res_lib_tmr_timerremainingtimeget;
 	struct iovec iov;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTimerRemainingTimeGet { id=%u }\n",
-		(unsigned int)(timerId));
-
 	if (remainingTime == NULL) {
 		error = SA_AIS_ERR_INVALID_PARAM;
 		goto error_exit;
@@ -610,10 +581,6 @@
 	struct res_lib_tmr_timerattributesget res_lib_tmr_timerattributesget;
 	struct iovec iov;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTmrTimerAttributesGet { id=%u }\n",
-		(unsigned int)(timerId));
-
 	if (timerAttributes == NULL) {
 		error = SA_AIS_ERR_INVALID_PARAM;
 		goto error_exit;
@@ -663,9 +630,6 @@
 	struct res_lib_tmr_timeget res_lib_tmr_timeget;
 	struct iovec iov;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTmrTimeGet\n");
-
 	if (currentTime == NULL) {
 		error = SA_AIS_ERR_INVALID_PARAM;
 		goto error_exit;
@@ -713,9 +677,6 @@
 	struct res_lib_tmr_clocktickget res_lib_tmr_clocktickget;
 	struct iovec iov;
 
-	/* DEBUG */
-	printf ("[DEBUG]: saTmrClockTickGet\n");
-
 	if (clockTick == NULL) {
 		error = SA_AIS_ERR_INVALID_PARAM;
 		goto error_exit;


More information about the Openais mailing list