You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by mt...@apache.org on 2009/09/04 14:28:17 UTC

svn commit: r811361 - in /commons/sandbox/runtime/trunk/src/main/native: include/acr.h shared/clazz.c srclib/bzip2/bzlib.h srclib/zlib/zconf.h srclib/zlib/zdeflate.c

Author: mturk
Date: Fri Sep  4 12:28:17 2009
New Revision: 811361

URL: http://svn.apache.org/viewvc?rev=811361&view=rev
Log:
More namespace code protection

Modified:
    commons/sandbox/runtime/trunk/src/main/native/include/acr.h
    commons/sandbox/runtime/trunk/src/main/native/shared/clazz.c
    commons/sandbox/runtime/trunk/src/main/native/srclib/bzip2/bzlib.h
    commons/sandbox/runtime/trunk/src/main/native/srclib/zlib/zconf.h
    commons/sandbox/runtime/trunk/src/main/native/srclib/zlib/zdeflate.c

Modified: commons/sandbox/runtime/trunk/src/main/native/include/acr.h
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/include/acr.h?rev=811361&r1=811360&r2=811361&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/native/include/acr.h (original)
+++ commons/sandbox/runtime/trunk/src/main/native/include/acr.h Fri Sep  4 12:28:17 2009
@@ -300,6 +300,7 @@
 
 #if defined(_WIN32)
 
+#define ACR_DECLARE_LOCAL
 #if defined(ACR_DECLARE_STATIC)
 #define ACR_DECLARE(type)                   type __stdcall
 #define ACR_DECLARE_NONSTD(type)            type __cdecl
@@ -362,10 +363,12 @@
 #define ACR_DECLARE(type)                   type
 #define ACR_DECLARE_NONSTD(type)            type
 #define ACR_DECLARE_DATA
+#define ACR_DECLARE_LOCAL
 #elif defined(ACR_DECLARE_EXPORT)
 #define ACR_DECLARE(type)                 __attribute__ ((visibility("default"))) type
 #define ACR_DECLARE_NONSTD(type)          __attribute__ ((visibility("default"))) type
 #define ACR_DECLARE_DATA                  __attribute__ ((visibility("default")))
+#define ACR_DECLARE_LOCAL                 __attribute__ ((visibility("hidden")))
 #else
 /**
  * The public ACR functions are declared with ACR_DECLARE(), so they may
@@ -416,6 +419,7 @@
 
 #else /* !_WIN32 && !__GNUC__ >= 4 */
 
+#define ACR_DECLARE_LOCAL
 /**
  * The public ACR functions are declared with ACR_DECLARE(), so they may
  * use the most appropriate calling convention.  Public ACR functions with

Modified: commons/sandbox/runtime/trunk/src/main/native/shared/clazz.c
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/shared/clazz.c?rev=811361&r1=811360&r2=811361&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/native/shared/clazz.c (original)
+++ commons/sandbox/runtime/trunk/src/main/native/shared/clazz.c Fri Sep  4 12:28:17 2009
@@ -125,7 +125,7 @@
     "()Z"
 };
 
-struct {
+static struct {
     const char *name;
     jclass      clazz;
 } core_classes[] = {

Modified: commons/sandbox/runtime/trunk/src/main/native/srclib/bzip2/bzlib.h
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/srclib/bzip2/bzlib.h?rev=811361&r1=811360&r2=811361&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/native/srclib/bzip2/bzlib.h (original)
+++ commons/sandbox/runtime/trunk/src/main/native/srclib/bzip2/bzlib.h Fri Sep  4 12:28:17 2009
@@ -52,6 +52,7 @@
 #define BZ2_indexIntoF              acr_BZ2_indexIntoF
 #define BZ2_decompress              acr_BZ2_decompress
 #define BZ2_hbCreateDecodeTables    acr_BZ2_hbCreateDecodeTables
+#define BZ2_rNums                   acr_BZ2_rNums
 
 #define BZ_RUN               0
 #define BZ_FLUSH             1

Modified: commons/sandbox/runtime/trunk/src/main/native/srclib/zlib/zconf.h
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/srclib/zlib/zconf.h?rev=811361&r1=811360&r2=811361&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/native/srclib/zlib/zconf.h (original)
+++ commons/sandbox/runtime/trunk/src/main/native/srclib/zlib/zconf.h Fri Sep  4 12:28:17 2009
@@ -78,6 +78,13 @@
 
 #  define z_verbose             acr_z_verbose
 #  define z_error               acr_z_error
+
+#  define _tr_init              acr_z__tr_init
+#  define _tr_tally             acr_z__tr_tally
+#  define _tr_flush_block       acr_z__tr_flush_block
+#  define _tr_align             acr_z__tr_align
+#  define _tr_stored_block      acr_z__tr_stored_block
+
 #endif
 
 #if defined(__MSDOS__) && !defined(MSDOS)

Modified: commons/sandbox/runtime/trunk/src/main/native/srclib/zlib/zdeflate.c
URL: http://svn.apache.org/viewvc/commons/sandbox/runtime/trunk/src/main/native/srclib/zlib/zdeflate.c?rev=811361&r1=811360&r2=811361&view=diff
==============================================================================
--- commons/sandbox/runtime/trunk/src/main/native/srclib/zlib/zdeflate.c (original)
+++ commons/sandbox/runtime/trunk/src/main/native/srclib/zlib/zdeflate.c Fri Sep  4 12:28:17 2009
@@ -32,8 +32,8 @@
 #define Z_MEMLEVEL  8
 #define ZBUF        10
 
-int window_inflate = -1 * MAX_WBITS;
-int window_deflate = -12;
+static int window_inflate = -1 * MAX_WBITS;
+static int window_deflate = -12;
 
 struct deflate_buf {
     Byte *out;