This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: java.lang.System.getEnv()
> Erik, given that this is working again in 1.5, sure, we'll accept a
> patch.
On what version in CVS should I apply and test this? Should I use the patch utility
to create one of these structured patches? What is the procedure to follow?
To be replaced in libjava/java/lang/System.java
public static native String getenv(String name) ;
* We also need to regenerate the CNI header file (done automatically?, can't find
them in cvsview)
To be added to natSystem.cc, in libjava/java/lang/natSystem.cc:
jstring
java::lang::System::getenv (jstring jname)
{
const char *name, *value ;
if ( jname == NULL ) return NULL ;
name = JvGetStringChars(jname);
value = getenv(name) ;
if(value == NULL) return NULL;
else return JvNewStringUTF (value);
}
Greetings
Erik