You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by tr...@apache.org on 2011/04/02 16:56:57 UTC

svn commit: r1088044 - /apr/apr-util/branches/1.3.x/test/testpass.c

Author: trawick
Date: Sat Apr  2 14:56:57 2011
New Revision: 1088044

URL: http://svn.apache.org/viewvc?rev=1088044&view=rev
Log:
Grab apr trunk r1088039:

avoid trying to test crypt[_r]()-based hash on the three
platforms which don't provide it

(apr-util exports no feature test for this)

Modified:
    apr/apr-util/branches/1.3.x/test/testpass.c

Modified: apr/apr-util/branches/1.3.x/test/testpass.c
URL: http://svn.apache.org/viewvc/apr/apr-util/branches/1.3.x/test/testpass.c?rev=1088044&r1=1088043&r2=1088044&view=diff
==============================================================================
--- apr/apr-util/branches/1.3.x/test/testpass.c (original)
+++ apr/apr-util/branches/1.3.x/test/testpass.c Sat Apr  2 14:56:57 2011
@@ -28,6 +28,14 @@
 #include "abts.h"
 #include "testutil.h"
 
+#if defined(WIN32) || defined(BEOS) || defined(NETWARE)
+#define CRYPT_ALGO_SUPPORTED 0
+#else
+#define CRYPT_ALGO_SUPPORTED 1
+#endif
+
+#if CRYPT_ALGO_SUPPORTED
+
 static struct {
     const char *password;
     const char *hash;
@@ -104,6 +112,8 @@ static void test_threadsafe(abts_case *t
 }
 #endif
 
+#endif /* CRYPT_ALGO_SUPPORTED */
+
 static void test_shapass(abts_case *tc, void *data)
 {
     const char *pass = "hellojed";
@@ -130,10 +140,12 @@ abts_suite *testpass(abts_suite *suite)
 {
     suite = ADD_SUITE(suite);
 
+#if CRYPT_ALGO_SUPPORTED
     abts_run_test(suite, test_crypt, NULL);
 #if APR_HAS_THREADS
     abts_run_test(suite, test_threadsafe, NULL);
 #endif
+#endif /* CRYPT_ALGO_SUPPORTED */
     abts_run_test(suite, test_shapass, NULL);
     abts_run_test(suite, test_md5pass, NULL);