Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 219b26d3 authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "Resolve change in getService return type" into main

parents 2aeec5bd e000aac3
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -277,7 +277,8 @@ public final class ServiceManager {
            if (service != null) {
                return service;
            } else {
                return Binder.allowBlocking(getIServiceManager().checkService(name).getBinder());
                return Binder.allowBlocking(
                        getIServiceManager().checkService(name).getServiceWithMetadata().service);
            }
        } catch (RemoteException e) {
            Log.e(TAG, "error in checkService", e);
@@ -425,7 +426,8 @@ public final class ServiceManager {
    private static IBinder rawGetService(String name) throws RemoteException {
        final long start = sStatLogger.getTime();

        final IBinder binder = getIServiceManager().getService2(name).getBinder();
        final IBinder binder =
                getIServiceManager().getService2(name).getServiceWithMetadata().service;

        final int time = (int) sStatLogger.logDurationStat(Stats.GET_SERVICE, start);

+1 −1
Original line number Diff line number Diff line
@@ -61,7 +61,7 @@ class ServiceManagerProxy implements IServiceManager {
    @UnsupportedAppUsage
    public IBinder getService(String name) throws RemoteException {
        // Same as checkService (old versions of servicemanager had both methods).
        return checkService(name).getBinder();
        return checkService(name).getServiceWithMetadata().service;
    }

    public Service getService2(String name) throws RemoteException {