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

Commit f71728f0 authored by Peter Kalauskas's avatar Peter Kalauskas Committed by Gerrit Code Review
Browse files

Merge "Convert LazyServiceRegistrar usage to singleton"

parents 651869e0 701e7f66
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -46,8 +46,8 @@ int main() {
    android::sp<IMediaCasService> service = new MediaCasService();
    android::status_t status;
    if (kLazyService) {
        auto serviceRegistrar = std::make_shared<LazyServiceRegistrar>();
        status = serviceRegistrar->registerService(service);
        auto serviceRegistrar = LazyServiceRegistrar::getInstance();
        status = serviceRegistrar.registerService(service);
    } else {
        status = service->registerAsService();
    }
+1 −1
Original line number Diff line number Diff line
@@ -32,7 +32,7 @@ int main() {
    configureRpcThreadpool(1, true);

    sp<IStorage> service = new Storage();
    LazyServiceRegistrar registrar;
    auto registrar = LazyServiceRegistrar::getInstance();
    status_t result = registrar.registerService(service);

    if (result != OK) {