89 uu_list_find() leaves error unset when successfully returning NULL
Reviewed by:
[email protected]
Reviewed by:
[email protected]
Approved by:
[email protected]
--- a/usr/src/lib/libuutil/common/uu_list.c Thu Jan 20 22:09:09 2011 +0300
+++ b/usr/src/lib/libuutil/common/uu_list.c Thu Jan 20 22:59:52 2011 -0600
@@ -18,13 +18,14 @@
*
* CDDL HEADER END
*/
+
/*
* Copyright 2008 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
+ *
+ * Copyright 2011 Jason King. All rights reserved.
*/
-#pragma ident "%Z%%M% %I% %E% SMI"
-
#include "libuutil_common.h"
#include <stdlib.h>
@@ -318,6 +319,8 @@
uu_compare_fn_t *func = lp->ul_pool->ulp_cmp;
uu_list_node_impl_t *np;
+ uu_set_error(UU_ERROR_NONE);
+
if (func == NULL) {
if (out != NULL)
*out = 0;