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

Commit 5fdc0c73 authored by Brad Fitzpatrick's avatar Brad Fitzpatrick
Browse files

resolved conflicts for merge of 14d151bf to master

Change-Id: Ib1ac9acfd6dc71b5fa4e1456a056d1e9dee65fda
parents e28c8f28 14d151bf
Loading
Loading
Loading
Loading
+13 −2
Original line number Diff line number Diff line
@@ -41,16 +41,17 @@ import android.os.ServiceManager;
import android.os.StrictMode;
import android.os.SystemClock;
import android.os.SystemProperties;
import android.provider.Contacts.People;
import android.provider.Settings;
import android.server.BluetoothA2dpService;
import android.server.BluetoothService;
import android.server.search.SearchManagerService;
import android.view.Display;
import android.view.WindowManager;
import android.util.DisplayMetrics;
import android.util.EventLog;
import android.util.Log;
import android.util.Slog;
import android.view.Display;
import android.view.WindowManager;

import java.io.File;
import java.util.Timer;
@@ -592,6 +593,16 @@ public class SystemServer {
    native public static void init1(String[] args);

    public static void main(String[] args) {
        if (System.currentTimeMillis() < 0) {
            // If a device's clock is before 1970 (before 0), a lot of
            // APIs crash dealing with negative numbers, notably
            // java.io.File#setLastModified, so instead we fake it and
            // hope that time from cell towers or NTP fixes it
            // shortly.
            Slog.w(TAG, "System clock is before 1970; setting to 1970.");
            SystemClock.setCurrentTimeMillis(1);  // 0 isn't allowed
        }

        if (SamplingProfilerIntegration.isEnabled()) {
            SamplingProfilerIntegration.start();
            timer = new Timer();