urlString = env->NewStringUTF((const char *) charResult);
urlString = ::util_NewStringUTF(env, (const char *) charResult);
JNIEXPORT jstring JNICALL Java_org_mozilla_webclient_wrapper_1native_CurrentPageImpl_nativeGetCurrentURL(JNIEnv *env, jobject obj, jint webShellPtr){	JNIEnv	*	pEnv = env;	jobject		jobj = obj;	char	*	charResult = nsnull;	jstring		urlString = nsnull;    WebShellInitContext* initContext = (WebShellInitContext *) webShellPtr;	if (initContext == nsnull) {		::util_ThrowExceptionToJava(env, "Exception: null webShellPtr passed to raptorWebShellGetURL");		return nsnull;	}	if (initContext->initComplete) {        nsISessionHistory *yourHistory;        nsresult rv;                rv = initContext->webShell->GetSessionHistory(yourHistory);                if (NS_FAILED(rv)) {            ::util_ThrowExceptionToJava(env, "Exception: can't get SessionHistory from webshell");            return urlString;        }		wsGetURLEvent	* actionEvent = new wsGetURLEvent(yourHistory);        PLEvent	   	  	* event       = (PLEvent*) *actionEvent;		charResult = (char *) ::util_PostSynchronousEvent(initContext, event);		if (charResult != nsnull) {			urlString = env->NewStringUTF((const char *) charResult);		}		else {			::util_ThrowExceptionToJava(env, "raptorWebShellGetURL Exception: GetURL() returned NULL");			return nsnull;		}        nsCRT::free(charResult);	}	return urlString;}