Additional fixes. draft
authorNick Alexander <nalexander@mozilla.com>
Wed, 31 May 2017 16:38:18 -0700
changeset 589162 bc47be47be81fb116e3aba5bde592949a5553bd6
parent 589161 574042fb50934ef5a5ab1735a8a609fe1018c3b3
child 589163 53fefa6d38dc8a52c9f8b8fdc62d18dc474d4521
push id62262
push usernalexander@mozilla.com
push dateMon, 05 Jun 2017 18:25:07 +0000
milestone55.0a1
Additional fixes. MozReview-Commit-ID: A8pIoz0FXdB
mozglue/android/nsGeckoUtils.cpp
mozglue/rustifoo/moz.build
--- a/mozglue/android/nsGeckoUtils.cpp
+++ b/mozglue/android/nsGeckoUtils.cpp
@@ -6,22 +6,24 @@
 #include <jni.h>
 
 #include <stdlib.h>
 #include <fcntl.h>
 #include "APKOpen.h"
 #include "Zip.h"
 #include "mozilla/RefPtr.h"
 
+extern "C" char* rustifoo_msg();
+
 extern "C"
 __attribute__ ((visibility("default")))
 void MOZ_JNICALL
 Java_org_mozilla_gecko_mozglue_GeckoLoader_putenv(JNIEnv *jenv, jclass, jstring map)
 {
-    const char* str;
+    const char* str = rustifoo_msg();
     // XXX: java doesn't give us true UTF8, we should figure out something
     // better to do here
     str = jenv->GetStringUTFChars(map, nullptr);
     if (str == nullptr)
         return;
     putenv(strdup(str));
     jenv->ReleaseStringUTFChars(map, str);
 }
--- a/mozglue/rustifoo/moz.build
+++ b/mozglue/rustifoo/moz.build
@@ -1,7 +1,9 @@
 # -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
 # vim: set filetype=python:
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 RustLibrary('rustifoo', [], '..')
+
+FINAL_LIBRARY = 'mozglue'