Loading services/core/java/com/android/server/BootReceiver.java +7 −0 Original line number Diff line number Diff line Loading @@ -50,6 +50,7 @@ import com.android.modules.utils.TypedXmlPullParser; import com.android.modules.utils.TypedXmlSerializer; import com.android.server.am.DropboxRateLimiter; import libcore.io.IoUtils; import org.xmlpull.v1.XmlPullParser; import org.xmlpull.v1.XmlPullParserException; Loading Loading @@ -147,6 +148,10 @@ public class BootReceiver extends BroadcastReceiver { @Override public void onReceive(final Context context, Intent intent) { if (!Intent.ACTION_BOOT_COMPLETED.equals(intent.getAction())) { return; } // Log boot events in the background to avoid blocking the main thread with I/O new Thread() { @Override Loading Loading @@ -212,6 +217,8 @@ public class BootReceiver extends BroadcastReceiver { } catch (Exception e) { Slog.wtf(TAG, "Error watching for trace events", e); return 0; // Unregister the handler. } finally { IoUtils.closeQuietly(fd); } return OnFileDescriptorEventListener.EVENT_INPUT; } Loading Loading
services/core/java/com/android/server/BootReceiver.java +7 −0 Original line number Diff line number Diff line Loading @@ -50,6 +50,7 @@ import com.android.modules.utils.TypedXmlPullParser; import com.android.modules.utils.TypedXmlSerializer; import com.android.server.am.DropboxRateLimiter; import libcore.io.IoUtils; import org.xmlpull.v1.XmlPullParser; import org.xmlpull.v1.XmlPullParserException; Loading Loading @@ -147,6 +148,10 @@ public class BootReceiver extends BroadcastReceiver { @Override public void onReceive(final Context context, Intent intent) { if (!Intent.ACTION_BOOT_COMPLETED.equals(intent.getAction())) { return; } // Log boot events in the background to avoid blocking the main thread with I/O new Thread() { @Override Loading Loading @@ -212,6 +217,8 @@ public class BootReceiver extends BroadcastReceiver { } catch (Exception e) { Slog.wtf(TAG, "Error watching for trace events", e); return 0; // Unregister the handler. } finally { IoUtils.closeQuietly(fd); } return OnFileDescriptorEventListener.EVENT_INPUT; } Loading