No implementation found for long org.chromium.chrome.browser.search_engines.TemplateUrlService.nativeInit()

54 views
Skip to first unread message

אבי וזהו

unread,
Jun 3, 2017, 5:08:00 PM6/3/17
to Chromium-dev
Hi

I get the following error:

06-04 00:01:36.708 1727-1727/? E/AndroidRuntime: FATAL EXCEPTION: main
     Process: org.chromium.chrome.browser, PID: 1727
     java.lang.UnsatisfiedLinkError: No implementation found for long org.chromium.chrome.browser.search_engines.TemplateUrlService.nativeInit() (tried Java_org_chromium_chrome_browser_search_1engines_TemplateUrlService_nativeInit and Java_org_chromium_chrome_browser_search_1engines_TemplateUrlService_nativeInit__)
         at org.chromium.chrome.browser.search_engines.TemplateUrlService.nativeInit(Native Method)
         at org.chromium.chrome.browser.search_engines.TemplateUrlService.<init>(TemplateUrlService.java:107)
         at org.chromium.chrome.browser.search_engines.TemplateUrlService.getInstance(TemplateUrlService.java:94)
         at org.chromium.chrome.browser.preferences.PrefServiceBridge.<init>(PrefServiceBridge.java:128)
         at org.chromium.chrome.browser.preferences.PrefServiceBridge.getInstance(PrefServiceBridge.java:138)
         at org.chromium.chrome.browser.ChromeApplication.onCreate(ChromeApplication.java:114)
         at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1024)
         at android.app.ActivityThread.handleBindApplication(ActivityThread.java:5405)
         at android.app.ActivityThread.-wrap2(ActivityThread.java)
         at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1546)
         at android.os.Handler.dispatchMessage(Handler.java:102)
         at android.os.Looper.loop(Looper.java:154)
         at android.app.ActivityThread.main(ActivityThread.java:6121)
         at java.lang.reflect.Method.invoke(Native Method)
         at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:889)
         at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:779)

 when trying to run the following code in the ChromeApplication => onCreate:

PrefServiceBridge.getInstance().nativeSetContentSettingForPattern(ContentSettingsType.CONTENT_SETTINGS_TYPE_JAVASCRIPT,
"SOME_URL", ContentSetting.BLOCK.toInt());


Can anyone help with this issue?

Thanks 

Tommy Nyquist

unread,
Jun 4, 2017, 3:34:13 PM6/4/17
to avi...@gmail.com, Chromium-dev
ChromeApplication#onCreate() is invoked very early in the startup of Chrome. At that point in time, we have not finished loading the native library yet.

You might be better off to invoke that at a later stage in the startup process.


--
Tommy

--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev
---
You received this message because you are subscribed to the Google Groups "Chromium-dev" group.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-dev/f708fa21-e39d-492e-b46c-639d36401d14%40chromium.org.

אבי וזהו

unread,
Jun 7, 2017, 9:26:32 AM6/7/17
to Chromium-dev, avi...@gmail.com
Thanks a lot
Reply all
Reply to author
Forward
0 new messages