Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4198708

JRE examples inaccurate wrt JAVA_HOME

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: P4 P4
    • None
    • 1.1.6
    • docs
    • sparc
    • solaris_2.6

      Name: dg70945 Date: 12/18/98


      On this page:

      http://java.sun.com:81/products/jdk/1.1/jre/example/

      and this

      http://java.sun.com:81/products/jdk/1.1/jre/example/src/win32/hello.c

      there is talk about how you
      are supposed to "clobber JAVA_HOME".

      The example shows setting it to nothing
      i.e. putenv("JAVA_HOME=").

      This works w/ all JREs except for the
      prereleased JRE from sun.com, maybe because
      it is an exe whereas other JRE's are initally
      shell scripts.

      It seems that you really gotta remove JAVA_HOME
      from your env if you want to be able to invoke
      any JRE. There doesn't seem to be such a routine
      ('removeenv?') on Solaris but other Unixes
      (Linux?) may have it.

      I suggest [a] clarify the example or [b] make
      the sun.com JRE more tolerant of JAVA_HOME
      being set to nothing/empty string.

      Sorry if this is a dup of my own reports - I've
      known this for a few weeks and can't recall
      if I've reported it yet...
      (Review ID: 35157)
      ======================================================================

            Unassigned Unassigned
            dgreensunw Dale Green (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: