httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j..@apache.org
Subject svn commit: r1415753 - /httpd/httpd/trunk/server/mpm/eventopt/skiplist.c
Date Fri, 30 Nov 2012 17:24:01 GMT
Author: jim
Date: Fri Nov 30 17:24:01 2012
New Revision: 1415753

URL: http://svn.apache.org/viewvc?rev=1415753&view=rev
Log:
Fix peek

Modified:
    httpd/httpd/trunk/server/mpm/eventopt/skiplist.c

Modified: httpd/httpd/trunk/server/mpm/eventopt/skiplist.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/mpm/eventopt/skiplist.c?rev=1415753&r1=1415752&r2=1415753&view=diff
==============================================================================
--- httpd/httpd/trunk/server/mpm/eventopt/skiplist.c (original)
+++ httpd/httpd/trunk/server/mpm/eventopt/skiplist.c Fri Nov 30 17:24:01 2012
@@ -661,9 +661,11 @@ void *skiplist_pop(Skiplist *a, FreeFunc
 void *skiplist_peek(Skiplist *a)
 {
     skiplistnode *sln;
-    void *data = NULL;
     sln = skiplist_getlist(a);
-    return data;
+    if (sln) {
+        return sln->data;
+    }
+    return NULL;
 }
 
 static void skiplisti_destroy(void *vsl)



Mime
View raw message