aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKenneth Russel <[email protected]>2007-04-21 01:34:54 +0000
committerKenneth Russel <[email protected]>2007-04-21 01:34:54 +0000
commitd22ef032e84a79f86683db1e2f829f403c4bb3e2 (patch)
treef95661d00a85104a605a9aa6f847c6ad49e366ac /src
parent2d10eb3db6578a369a1038a6173e7fa78d005fcc (diff)
Re-fixed Issue 226: JOGL seg faulting on Solaris AMD64
The autogenerated GLX_JNI.c was not receiving a prototype for glXGetProcAddressARB and so was receiving the implicit one returning an int, which is obviously wrong on 64-bit architectures. Re-fixed this bug by providing a prototype; removed the workaround in X11GLDrawableFactory. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@1211 232f8b59-042b-4e1e-8c03-345bb8c30851
Diffstat (limited to 'src')
-rw-r--r--src/classes/com/sun/opengl/impl/x11/X11GLDrawableFactory.java18
1 files changed, 1 insertions, 17 deletions
diff --git a/src/classes/com/sun/opengl/impl/x11/X11GLDrawableFactory.java b/src/classes/com/sun/opengl/impl/x11/X11GLDrawableFactory.java
index feb3233b1..594fb0f7f 100644
--- a/src/classes/com/sun/opengl/impl/x11/X11GLDrawableFactory.java
+++ b/src/classes/com/sun/opengl/impl/x11/X11GLDrawableFactory.java
@@ -54,10 +54,6 @@ import com.sun.opengl.impl.*;
public class X11GLDrawableFactory extends GLDrawableFactoryImpl {
private static final boolean DEBUG = Debug.debug("X11GLDrawableFactory");
- // There is currently a bug on Linux/AMD64 and Solaris/AMD64
- // distributions in glXGetProcAddressARB
- private static boolean isAMD64;
-
// ATI's proprietary drivers apparently send GLX tokens even for
// direct contexts, so we need to disable the context optimizations
// in this case
@@ -102,16 +98,6 @@ public class X11GLDrawableFactory extends GLDrawableFactoryImpl {
com.sun.opengl.impl.NativeLibLoader.loadCore();
DRIHack.end();
-
- AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- String arch = System.getProperty("os.arch").toLowerCase();
- if (arch.equals("amd64") || arch.equals("x86_64")) {
- isAMD64 = true;
- }
- return null;
- }
- });
}
public X11GLDrawableFactory() {
@@ -346,9 +332,7 @@ public class X11GLDrawableFactory extends GLDrawableFactoryImpl {
public long dynamicLookupFunction(String glFuncName) {
long res = 0;
- if (!isAMD64) {
- res = GLX.glXGetProcAddressARB(glFuncName);
- }
+ res = GLX.glXGetProcAddressARB(glFuncName);
if (res == 0) {
// GLU routines aren't known to the OpenGL function lookup
res = GLX.dlsym(glFuncName);