httpd-apreq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Philip M. Gollucci" <pgollu...@p6m7g8.com>
Subject [PATCH] library/t/error.c
Date Fri, 15 Apr 2005 06:38:10 GMT
Hi,

As far as I know, you can't call apr_strerror on APR_SUCCESS since its 
not an error code.  0.

You get back [Uknown Error Code: 0]

Index: error.c
===================================================================
--- error.c     (revision 161407)
+++ error.c     (working copy)
@@ -18,7 +18,6 @@
  #include "apreq_error.h"
  #include "at.h"

-
  static void test_strerror(dAT)
  {
      char buf[256], *str;
@@ -44,8 +43,6 @@

      /* Test some common APR status codes also */

-    str = apreq_strerror(APR_SUCCESS, buf, sizeof buf);
-    AT_str_eq(str, "Success");

      str = apreq_strerror(APR_EINIT, buf, sizeof buf);
      AT_str_eq(str, "There is no error, this value signifies an 
initialized "
@@ -71,7 +68,7 @@
      apr_pool_t *p;
      dAT;
      at_test_t test_list [] = {
-        { dT(test_strerror, 11), "1" }
+        { dT(test_strerror, 10), "1" }
      };

      apr_initialize();


-- 
END
------------------------------------------------------
Philip M. Gollucci (pgollucci@p6m7g8.com) 301.254.5198
Consultant / http://p6m7g8.net/Resume/resume.shtml
Senior Developer / Liquidity Services, Inc.
	http://www.liquidityservicesinc.com

Mime
View raw message