Return-Path: X-Original-To: apmail-commons-commits-archive@minotaur.apache.org Delivered-To: apmail-commons-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 54E0C8E48 for ; Sat, 3 Sep 2011 07:22:49 +0000 (UTC) Received: (qmail 88135 invoked by uid 500); 3 Sep 2011 07:22:47 -0000 Delivered-To: apmail-commons-commits-archive@commons.apache.org Received: (qmail 88065 invoked by uid 500); 3 Sep 2011 07:22:18 -0000 Mailing-List: contact commits-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@commons.apache.org Delivered-To: mailing list commits@commons.apache.org Received: (qmail 88055 invoked by uid 99); 3 Sep 2011 07:22:06 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 03 Sep 2011 07:22:06 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 03 Sep 2011 07:22:02 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 3326223889E5 for ; Sat, 3 Sep 2011 07:21:41 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1164810 - in /commons/sandbox/runtime/trunk/src/main/native: modules/openssl/api.c os/win32/dirent.c os/win32/posix.c Date: Sat, 03 Sep 2011 07:21:41 -0000 To: commits@commons.apache.org From: mturk@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20110903072141.3326223889E5@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: mturk Date: Sat Sep 3 07:21:40 2011 New Revision: 1164810 URL: http://svn.apache.org/viewvc?rev=1164810&view=rev Log: Misc fixes Modified: commons/sandbox/runtime/trunk/src/main/native/modules/openssl/api.c commons/sandbox/runtime/trunk/src/main/native/os/win32/dirent.c commons/sandbox/runtime/trunk/src/main/native/os/win32/posix.c Modified: commons/sandbox/runtime/trunk/src/main/native/modules/openssl/api.c URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/modules/openssl/api.c?rev=1164810&r1=1164809&r2=1164810&view=diff ============================================================================== --- commons/sandbox/runtime/trunk/src/main/native/modules/openssl/api.c (original) +++ commons/sandbox/runtime/trunk/src/main/native/modules/openssl/api.c Sat Sep 3 07:21:40 2011 @@ -37,6 +37,11 @@ ACR_JNI_EXPORT(jboolean, Native, ldopenssl0)(JNI_STDARGS) { + if (SSLeay() < 0x00908000L) { + AcrThrow(env, ACR_EX_ERUNTIME, + "OpenSSL 0.9.8 or greater is required"); + return JNI_FALSE; + } return JNI_TRUE; } Modified: commons/sandbox/runtime/trunk/src/main/native/os/win32/dirent.c URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/os/win32/dirent.c?rev=1164810&r1=1164809&r2=1164810&view=diff ============================================================================== --- commons/sandbox/runtime/trunk/src/main/native/os/win32/dirent.c (original) +++ commons/sandbox/runtime/trunk/src/main/native/os/win32/dirent.c Sat Sep 3 07:21:40 2011 @@ -65,8 +65,8 @@ DIR *opendir(const wchar_t *path) ACR_SET_OS_ERROR(ACR_ERANGE); return 0; } - if (dir->d_name[len-2] != L'\\') - dir->d_name[len] = L'\\'; + if (dir->d_name[len-1] != L'\\') + dir->d_name[len++] = L'\\'; dir->d_star = len; dir->d_find = INVALID_HANDLE_VALUE; dir->d_stat = 0; Modified: commons/sandbox/runtime/trunk/src/main/native/os/win32/posix.c URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/os/win32/posix.c?rev=1164810&r1=1164809&r2=1164810&view=diff ============================================================================== --- commons/sandbox/runtime/trunk/src/main/native/os/win32/posix.c (original) +++ commons/sandbox/runtime/trunk/src/main/native/os/win32/posix.c Sat Sep 3 07:21:40 2011 @@ -148,7 +148,7 @@ wcslcat(wchar_t *dst, const wchar_t *src n = siz - dlen; if (n == 0) - return(dlen + wcslen(s)); + return (dlen + wcslen(s)); while (*s != L'\0') { if (n != 1) { *d++ = *s; @@ -158,7 +158,7 @@ wcslcat(wchar_t *dst, const wchar_t *src } *d = L'\0'; - return(dlen + (s - src)); /* count does not include NUL */ + return (dlen + (s - src)); /* count does not include NUL */ } int