• R/O
  • HTTP
  • SSH
  • HTTPS

コミット

タグ
未設定

よく使われているワード(クリックで追加)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

frameworks/base


コミットメタ情報

リビジョンbf10629e34e836527a7cb855d633f6a932fed89a (tree)
日時2018-04-25 19:46:45
作者Chih-Wei Huang <cwhuang@linu...>
コミッターChih-Wei Huang

ログメッセージ

houdini: match package name by patterns

PRC apps from different markets usually have different package names.
This change tries to match them by patterns.

To test it, install the Implosion apps from Wandoujia and CoolMarket
and run them OK.

変更サマリ

差分

--- a/core/jni/abipicker/ABIPicker.cpp
+++ b/core/jni/abipicker/ABIPicker.cpp
@@ -5,6 +5,7 @@
55
66 #include <androidfw/ZipFileRO.h>
77 #include <androidfw/ZipUtils.h>
8+#include <fnmatch.h>
89
910 namespace android {
1011 #define ARR_SIZE(x) (sizeof(x)/sizeof(x[0]))
@@ -106,8 +107,8 @@ bool isInOEMWhiteList(const char* pkgName) {
106107 Vector<char*>::iterator it = cfgWhite.begin();
107108 for (; it != cfgWhite.end(); it++) {
108109 P_LOG("whitelist : %s", *it);
109- if (0 == strcmp(pkgName, *it)) {
110- ALOGI("found %s in whitelist", pkgName);
110+ if (0 == fnmatch(*it, pkgName, 0)) {
111+ ALOGI("whitelist %s by %s", pkgName, *it);
111112 result = true;
112113 break;
113114 }
@@ -128,8 +129,8 @@ bool isInOEMBlackList(const char* pkgName) {
128129
129130 Vector<char*>::iterator it = cfgBlack.begin();
130131 for (; it != cfgBlack.end(); it++) {
131- if (0 == strcmp(pkgName, *it)) {
132- ALOGI("found %s in blacklist", pkgName);
132+ if (0 == fnmatch(*it, pkgName, 0)) {
133+ ALOGI("blacklist %s by %s", pkgName, *it);
133134 result = true;
134135 break;
135136 }