From 3636f18d847f326d338adff4cb2f214608b08298 Mon Sep 17 00:00:00 2001 From: Michael Hamann Date: Sun, 17 Jan 2016 15:44:00 +0100 Subject: [PATCH 1/4] McsInputStream: terminate if error occurred This terminates the input stream when an error occurred and does not wait for the handler thread in the McsService to send the interrupt signal. This hopefully fixes a situation that I had where tear down messages were created in a busy loop because of repeatedly reading -1 from the input (I don't know how it got into the situation as the log was filled with the messages from the tear down). --- .../src/main/java/org/microg/gms/gcm/McsInputStream.java | 1 + 1 file changed, 1 insertion(+) diff --git a/play-services-core/src/main/java/org/microg/gms/gcm/McsInputStream.java b/play-services-core/src/main/java/org/microg/gms/gcm/McsInputStream.java index 6af110171f..17d86f0e76 100644 --- a/play-services-core/src/main/java/org/microg/gms/gcm/McsInputStream.java +++ b/play-services-core/src/main/java/org/microg/gms/gcm/McsInputStream.java @@ -77,6 +77,7 @@ public void run() { mainHandler.dispatchMessage(mainHandler.obtainMessage(MSG_INPUT, msg)); } else { mainHandler.dispatchMessage(mainHandler.obtainMessage(MSG_TEARDOWN, "null message")); + break; // if input is empty, do not continue looping } } } catch (IOException e) { From 48809464a74fffc5abf027b8e6d434d941c8095e Mon Sep 17 00:00:00 2001 From: Michael Hamann Date: Sun, 17 Jan 2016 15:56:03 +0100 Subject: [PATCH 2/4] McsService: only send to the output stream if it is alive The output stream handler thread might not be alive, this occurs reproducibly when connecting fails and a tear down is initiated. Messages shouldn't be sent when the output handler thread is not alive (triggers an expection which is catched but logged), this check avoids this unless some special race condition occurs. Dropping the messages shouldn't hurt (they were dropped anyway). --- .../src/main/java/org/microg/gms/gcm/McsService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/play-services-core/src/main/java/org/microg/gms/gcm/McsService.java b/play-services-core/src/main/java/org/microg/gms/gcm/McsService.java index efbbb4b322..96f3752559 100644 --- a/play-services-core/src/main/java/org/microg/gms/gcm/McsService.java +++ b/play-services-core/src/main/java/org/microg/gms/gcm/McsService.java @@ -323,7 +323,7 @@ private void send(Message message) { private void sendOutputStream(int what, Object obj) { McsOutputStream os = outputStream; - if (os != null) { + if (os != null && os.isAlive()) { Handler outputHandler = os.getHandler(); if (outputHandler != null) outputHandler.sendMessage(outputHandler.obtainMessage(what, obj)); From 24645afee873661540c7c133b7870f95c5853072 Mon Sep 17 00:00:00 2001 From: Jonathan Morford Date: Sat, 23 Jan 2016 00:12:45 -0500 Subject: [PATCH 3/4] Move information to wiki --- README.md | 30 +----------------------------- 1 file changed, 1 insertion(+), 29 deletions(-) diff --git a/README.md b/README.md index 2bd9e7e64c..3d4cc344a9 100644 --- a/README.md +++ b/README.md @@ -5,37 +5,9 @@ microG GmsCore is a FLOSS (Free/Libre Open Source Software) framework to allow applications designed for Google Play Services to run on systems, where Play Services is not available. If you use your phone without GAPPS this might become a useful tool for you. **This is currently alpha-grade Software. Don't use it if you're not aware of possible consequences. Possible consequences include that your very private data leaks to Fort Meade.** -Project Status --------------- -See "Current Implementation progress" on the [XDA Thread](http://forum.xda-developers.com/android/apps-games/app-microg-gmscore-floss-play-services-t3217616) -Instructions ------------- -Requirements and Installation instructions can be found on the [XDA Thread](http://forum.xda-developers.com/android/apps-games/app-microg-gmscore-floss-play-services-t3217616) +### Please refer to the [wiki](https://github.com/ibleedbinari/android_packages_apps_GmsCore/wiki) for downloads and instructions -Signature Spoofing ------------------- -You need a ROM that supports signature spoofing. Some custom ROMs are patched to support signature spoofing out of the box, however most ROMs will require a patch or a Xposed module. Please ask your ROM developer if unsure. - -The following ROMs have out-of-box support for signature spoofing. **This feature has to be enabled at the bottom of the developer settings first.** -* [OmniROM](http://omnirom.org/) - -If you have the **Xposed Framework** installed, the following module will enable signature spoofing: [FakeGApps by thermatk](http://repo.xposed.info/module/com.thermatk.android.xf.fakegapps) - -If you have **Root**, but are not using Xposed, you can try patching your already-installed ROM using [Needle by moosd](https://github.com/moosd/Needle) - -If you are a **ROM developer** or just do **custom builds** for whatever reason, you can download and include the patch from [here](https://gerrit.omnirom.org/#/c/14898/) and [here](https://gerrit.omnirom.org/#/c/14899). - -Downloads ---------- -Standard Releases: [XDA Thread](http://forum.xda-developers.com/android/apps-games/app-microg-gmscore-floss-play-services-t3217616) and [GitHub release page](https://github.com/microg/android_packages_apps_GmsCore/releases) - -Nightly Releases: [Latest](http://files.brnmod.rocks/apps/GmsCore/Latest/play-services-core-debug.apk) or [Other Builds](http://files.brnmod.rocks/apps/GmsCore/) - -Building --------- -This can be build using Gradle. -Prebuilt libraries of [vtm](https://github.com/opensciencemap/vtm) are included within `./libs`. License ------- From 5f0b429278e8c1e43c4512686d69158539949c2f Mon Sep 17 00:00:00 2001 From: Jonathan Morford Date: Sat, 23 Jan 2016 00:14:27 -0500 Subject: [PATCH 4/4] Fix wiki URL and move decription --- README.md | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 3d4cc344a9..4edd777445 100644 --- a/README.md +++ b/README.md @@ -2,11 +2,9 @@ ======= [![Build Status](https://travis-ci.org/microg/android_packages_apps_GmsCore.svg?branch=master)](https://travis-ci.org/microg/android_packages_apps_GmsCore) -microG GmsCore is a FLOSS (Free/Libre Open Source Software) framework to allow applications designed for Google Play Services to run on systems, where Play Services is not available. If you use your phone without GAPPS this might become a useful tool for you. -**This is currently alpha-grade Software. Don't use it if you're not aware of possible consequences. Possible consequences include that your very private data leaks to Fort Meade.** +microG GmsCore is a FLOSS (Free/Libre Open Source Software) framework to allow applications designed for Google Play Services to run on systems, where Play Services is not available. - -### Please refer to the [wiki](https://github.com/ibleedbinari/android_packages_apps_GmsCore/wiki) for downloads and instructions +### Please refer to the [wiki](https://github.com/microg/android_packages_apps_GmsCore/wiki) for downloads and instructions License