[PATCH libXp] fix build: Return 0 instead of NULL in XpGetPdmStartParams() (v2)

Tobias Droste tdroste at gmx.de
Thu Nov 24 15:47:15 PST 2011


Status is defined as int -> NULL is not a valid return value

v2: Remove unneeded cast to Status

Signed-off-by: Tobias Droste <tdroste at gmx.de>
---
 src/XpNotifyPdm.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/XpNotifyPdm.c b/src/XpNotifyPdm.c
index c1ceb8e..c77f9e1 100644
--- a/src/XpNotifyPdm.c
+++ b/src/XpNotifyPdm.c
@@ -231,7 +231,7 @@ XpGetPdmStartParams (
 	/*
 	 * Error - cannot determine or establish a selection_display.
 	 */
-	return( (Status) NULL );
+	return( 0 );
     }
 
     /*
@@ -268,7 +268,7 @@ XpGetPdmStartParams (
 	    XCloseDisplay( *selection_display );
 	    *selection_display = (Display *) NULL;
 	}
-	return( (Status) NULL );
+	return( 0 );
     }
 
     status = XmbTextListToTextProperty( *selection_display, list, 6,
@@ -283,7 +283,7 @@ XpGetPdmStartParams (
 	    XCloseDisplay( *selection_display );
 	    *selection_display = (Display *) NULL;
 	}
-	return( (Status) NULL );
+	return( 0 );
     }
 
     *type              = text_prop.encoding;
@@ -293,7 +293,7 @@ XpGetPdmStartParams (
 
     XFree(list[5]);
 
-    return( (Status) 1 );
+    return( 1 );
 }
 
 /******************************************************************************
-- 
1.7.3.4



More information about the xorg-devel mailing list